WCF Domain Model for SOA Part – 1
Hallo folks … see you again in my sharing knowledge moment in my
development journal blogs,
i would like to share to all of you about the knowledge of creating the
domain architecture,
in this case i would like to create the WCF ( Windows Communication
Foundation ) especially for further purpose is
implement the SOA ( Software Oriented Architecture ).
I will separate the part of the knowledge become the trilogy knowledge
which are :
- Introduction the Domain WCF or Web service
- Introduction the Service Factory from The Pattern and Practise team to implement the WCF or Web service as a Domain Artifact model.
- Sample implementation the WCF or Web service.
so..let’s try to rock’n roll …
Overview :
the application development in this era has already come to service
oriented architecture which is known by SOA, by using SOA
we implement the interoperability application architecture which avoid
the system operation platform or even the language
of application development and domain application as well. we using the
independence file format transferring or independence format that
allow every domain
application could leverage every programming functionality such as
procedure or method for IPO ( Input-Process-Output) processing
Because the original purpose of SOA is become a bridge of many platform
which cater the functionality of the application then the ser-
vice need the endpoint or even the contract which is tighten from one
service point to another service point or from one domain
application to another domain application but of course loosely
coupling architecture.
For further detail explanation i put some figure about the domain WCF :
Multipurpose of Exception Handling Class Part 3
Hi..see you again.. this section is the continue part of my trilogy Multipurpose of Exception Handling class, okay let’s make it this quickly, the last class that we need is EmailGenerator class :
- This class using 3 core of .Net library; System IO for accessing the XML email template,System XML and then System.Web.Email.
- The main idea for this class is service another class that want to generate the email notification so we need to produce the public method for sending the emai, here are the method
public void AutomaticSendEmailLogging(string ErrorMessage)
{
MailMessage mailMsg = new MailMessage(); // Create instance of EmailMessage Object
string templateName = FrameworkLayer.ConfigurationUtility.WebApplicationConfiguration.ProgrammerEmailName;
mailMsg.From = FrameworkLayer.ConfigurationUtility.WebApplicationConfiguration.EmailSender;
mailMsg.To = FrameworkLayer.ConfigurationUtility.WebApplicationConfiguration.ProgrammerEmail;
//mailMsg.Cc = EmailUser;
Multipurpose of Exception Handling Class Part 2
Okay in this section part i will talk more detail about those kind of class ,
- Logging Class
Prerequisite for this class :
- You need provide the xml file for become the email template, the simple form like this :<EMAIL>
<TITLE>Error Notification</TITLE>
<MESSAGE>
<SUBJECT>Global Coding System Notification
</SUBJECT>
<BODY>ERROR MESSAGE ALERT {0}
================================================\n\nPlease be advised that somthing error happen in your application :
{1} \N
</BODY>
</MESSAGE>
</EMAIL>
Multipurpose of Exception Handling Class Part 1
In this Part, i will share of my code project which is i have made the multipurpose exception handling class. What is the trully meaning of multipurpose ? in this class i have create the exception handling class which covered the function for throwing the exception message and also giving the email alert notification to the programmer or event for system administrator.
for instance is like this :
in DAL i am using the exception handling class –> if there is something error in my DAL class –> the error handler will capture the Exception stack trace –> the Exception class will talk to the Logging class and also either the email class.
and then my class like this Logging class and Email class :
Multipurpose Data Access Layer part 2
In this 2nd part i’ll try to describe more detail in coding which i mentioned it in part 1,
a. ConnectionString Class
- First Of all you need to save your connection string variable in your web config, in my case i put all of the setting in particular configuration setting class which being taken from webconfig setting.
- I must inherit from the WebPageBase class for become the master of base page class, this WebPageBase class inherit the System.web.UI.Page , this class will become the property provider to every page in Web UI such as retrive the current user,current password and of course the applicationID that we need.
- And the last thing i made two public static method which return the string of connectionstring and providername, both of those method will filter the appropriate connection string and provider name which inputed from each outside ( define input parameter ).
let see the complete module :
How handling Upload file module in Asp.Net
I would like to share about how to handling the upload file or creating something in your project which is need for file uploading, in this part there are some purpose that we want to achieve :
1. Browsing the file in local client into the list of file uploading
2. Move the all file list into the table which already to sent to web server
- The UI design * User Control for Editing and viewing Files
- From the UI design I made the MediaFileUpload.Aspx , and then in the code behind of this control you need to made a declaration for web file repository like this :
Multipurpose Data Access Layer part 1
In my current project i have made some DAL ( Data Access Layer ) class in my framework which has some purpose for handling many project needs such as :
1. Able to provide multiple connection string in my project
2. Able to provide the multiple datastore string with many provider
3. Should be able to handling many application parameter response redirect
see the picture below of my class design :
I put the all of my engine application in Framework layer project including the Data Access utility, wheter contain :
a. ConnectionString Class :
- This Class has purpose and duty to serving the connection string and provider name which will be consumed by the Query Builder class. In this class i set the Connection to database namespace and also i made inherit the web base class for accessing the web base class page property and method in the future utilization.
- Why i must inherit from the page base class, in this project framework i need to access the ApplicationID property which catered by the page base class wheter all of web page should inherit from this base class.
- After the initialially web page loaded in this case the default.aspx, there is an automatically fill the ApplicationID property in base class which consumed from the url parameter. Actually there is still need the decrypt class which serving for securing the parameter from URL but later i will create for this purpose.
- This class has 2 methods which will cater the connection string and provider name the mthods are GetCN which return on string and either for GetPV.
b. Query Builder Class ( Interface Class )
- This is sound of interesting part from the whole stories, this class has a duty for catering the automatically object parameter, object connection and the type of the sql command.
- Therefore this class has an may important part method that execution in any output parameter method such as execute the dataset return,data reader return,execute scalar return in integer and also add parameter method for processing the parameter input to this class.
- This Class has three kind overload method which catering the text string query, the stored procedure type of query which will be implemented in DAL project later.
Recent Comments