Creating Windows Services using Topshelf

Windows services are computer programs which runs in background for doing some specific tasks automatically it is also known as NT services .Which is not having a specific interface to display or indicator to view its prograss. This will automatically starts when the computer boots up. We can also pause and restart this application.     Windows services are ideal for whenever we need a long running app which doesn't need a user interface with other system users. I have created windows service application for checking data change in Dynamic CRM in a regular intervene(say 100 seconds). Also sending push notifications to mobile client apps.Now you got the idea of what is windows services and in which scenario is best for windows application. In web applications we use windows service in order to reduce the service load by executing process which needs regular check up and does excite some particular process.
    We can monitor which all are the windows services that runs in our mach…

Design Patterns Interview questions

Design patterns are more related to the design level approach to a problem than coding level . Design pattern interview questions frequently asked in more experienced level of interviews. I have listed out most of them below please add as comment missed out questions.

Q) What are Design Patterns ? (Design patterns interview questions -1)

Design patterns are more general solution for a frequently occurring problem with in a software design . Design patterns are time tested practices for Object Oriented Programming .It help people to think Object Oriented aspect of thinking .
Q) What are the main types of design patterns ? (Design Patterns interview questions -2)

It mainly classifieds as three categories Creationals , structural and Behavioral patterns
Creational Patterns : It deals with the object creational mechanisms. It used in situations like its basic form of object creation increases the complexity of code base. It is mainly deals with the way of creating objects. The types of cre…

CRM-SDK FetchXML- Currency behavior while retrieve group by queries

Hi all I have faced an issue while getting aggregate sum of a currency field from Microsoft dynamic CRM. The Currency values saved Microsoft dynamic CRM is in US Dollar . While I am getting from Microsoft dynamic CRM using 'QueryExpression' , getting correct values as like it saved in dynamic CRM , after a while I had to get all the data in a group by format. I had to group the currencies based on the month in a year.
     For this requirement I was not able to use the 'QueryExpression'. I have done some research and finds out that the 'fetchxml' Is the best method for scenarios like this , so I have decided to use the 'fetchxml' aggregate queries. 
       It is nothing but a method of querying data from dynamic CRM in our desired format .While we are using 'fetchxml' method , we could understand that which gives us good flexibility over the CRM data manipulation. We could get the data in our desired format. I have used fetchxml for querying Data …

Common Security Issues Checklist For and Web services

· Session Expiry –  Issue: Even after a user logs out from the client side, the user session persists in the server. Solution:Whenever a user logs out of the client side (Mobile application OR Web application), the session should expire in the server also.
· Session Validation –  Issue: Session validation is not implemented properly in many projects. As a result, a logged in user can modify the data of another user. Solution:“Logged in user – Session” validation should be implemented correctly.
· Authorization –  Issue: Authorization and User role validations are not implemented correctly, especially in Web applications that have multiple user roles. Solution:All Web pages / Screens / Web service methods / Ajax calls, etc. should implement the logic for User role validation.
· Error Handling –  Issue: Error Pages / Broken links reveal confidential server information like SQL Query, Server details, Username, Password etc. to the end-user. Solution:Make sure that sensitive data is not revealed to …

Common Performance issue checklist for and Web API's

· Indexing –  Issue: In most cases, Indexes are not set from the beginning of the projects. Non-clustered indexes are rarely maintained. Solution:Try to use Indexes from the beginning of the project. Make decisions regarding Indexes very carefully after analyzing the use cases.
· Use of common stored procedures –  Issue:Use of common stored procedures has an adverse impact on the performance. Solution:Avoid the use of common stored procedures for multiple functionalities. Often it is noticed that the use of common stored procedures makes it difficult to optimize the performance without affecting the functionality.
· Fetching data from multiple tables in RDBMS –  Issue: A database query tends to become slower if it has to fetch data from multiple tables, especially when the number of records is high. Solution:Consider using NoSQL or caching mechanisms. For example - MongoDB, CouchDB, Redis, Memcached, etc.
· UnnecessaryAPI calls –  Issue: Unnecessary API calls from the client-side affects the pe…