Tuesday, November 10, 2009

Win32/Linux Headers for C/C++

While interoperating between the Win32 and Linux, you will need equivalent headers.
Useful Lookup and resource: http://fearthecow.net/guest/rosetta/

Monday, November 9, 2009

Encrypted Real Time Messaging Protocol (RTMPE) and

RTMPE, is an encrypted version of RTMP. There are technical diffrences between Recording and Downloading! <>

Friday, November 6, 2009

REST with WCF 3.5

Let’s walk through Step by Step

Step 1: Create a contract, and mark the contract with WebGet Attribute

//Import the required Namespace/s
using System.ServiceModel;
using System.ServiceModel.Web;

namespace RestWithWCF
{
[ServiceContract]
public interface IGreeterService
{
[OperationContract]
[WebGet(UriTemplate = "greet/{name}")]
string DoGreet(string name);
}
}

Step 2: Implement the contract for the Service

namespace RestWithWCF
{
public class GreetService : IGreeterService
{
public string DoGreet (string name)
{
return string.Format("Hello, {0} , Welcome to the world of REST.", name);
}
}
}

Step 3: Create “Host” for the service

using System;
using System.ServiceModel;
using System.ServiceModel.Web;
namespace RestWithWCF
{
class Program
{
static void Main(string[] args)
{
using (WebServiceHost serviceHost =
new WebServiceHost(typeof(GreetService)))
{
serviceHost.Open();
Console.WriteLine("Host Started...");
Console.ReadLine();
serviceHost.Close();
}
}
}
}

Step 4: Create a Configuration file to expose a webHttpBinding endpoint for the service.

















Step 5: Compile and Execute the HOST

Step 6: Open browser and hit the REST Endpoint

Step 7: Check the XML response

That’s it.

Thursday, October 29, 2009

WCF 3.5, REST vs Soap

Starting with WCF 3.5 services can be rest enabled. MEaning you can either create services with SOAP or REST Extensions.
Few key constraints for this descision,
(1) SOAP requires knowledge of XML standards on the other hand Any client or Server application with HTTP support can make call to REST Services with HTTP Get verb.
(2) SOAP Requires XML packet across every Request/Response, where as REST Services does not have this constraint. this can make the SOAP services 10-15 times more heavy on Wire. this is one reason for utilizing the REST Services on low or limited profile mobile.
(3) SOAP operates on Heavy metada, this makes them very useful while designing Services which requires the formal contract to be established for describing the interface that the web service offers. REST on the other hand does not publish any Metadata.

Monday, July 6, 2009

NHibernate and Linq

If the objective is RAD [rapid Application Development], Linq comes in handy.NHibernate, has very interesting support for the inhertance and the object can be stored as Table per Calss, Sub-Class or "Hierarchy", this evaluates to the ability to write flexible code and "Polymorphic Queries". It is possible to either write mapping in xml document or as strongly typed objects, this should be design descision based on what you would like to acheive w.r.t ability to Refactor, configure etc...

Friday, June 26, 2009

WCF AJAX Page requests

WCF platform had not built-in support for consuming JSON objects or returning the same.
Starting with .Net framework 3.5 and “Orcas” this can be easily achieved e.g. <>

Wednesday, June 17, 2009

WCF 3.5, WF State Persistant Sessions [Durable Session]

You may require WCF services to persist the state information. You can take advantage of the WF persistent model. <>

Tuesday, June 16, 2009

Debugging SSL traffic

Debugging SSL web Traffic can be a hassel, Tools you can utilize are,
(1) ProxyTrace : http://www.pocketsoap.com/
(2) TcpTrace: http://www.pocketsoap.com/tcptrace/
Sniffing SSL traffic with a Proxy
(3) Charles: http://www.charlesproxy.com/
-

Bing it!

Tips
(1) Goto: www.bing.com/worldwide.aspx , Select a country/region: United States - English
Notice the Bing background image turns interactive.
(2) Bing provides RSS feed for the search result simply append &format=rss to the end of the URL and convert the link to the RSS feed.

Thursday, June 11, 2009

SQL Dependency - SQL Server 2005 Onwards

If your problem statement requires you to cache the DB recordset in the MiddleTier and invalidate the cached data on periodic or on certain notifications, you can take advantage of SQLDependency or Query Notifications. Ref Implementation details @:
http://support.microsoft.com/default.aspx/kb/555893

Managed Extensibility Framework [MEF]

If you are a Microsoft.NET developer, you can take advantage from the full source from codeplex at:
http://www.codeplex.com/MEF

Read more on MEF at:
http://code.msdn.microsoft.com/mef

the basic idea being extensible is being able to dynamically compose stuffs, without being able to recompile the entire application source.
As an example if you have seen or heard of the pouplar game War of the worlds (WoW), the model are being extended by many-2 contributors and the ability of the game application to handle these .
It may be required to restart the application in order to index or utilize the new models, Depending on the implementation it is highly possible to differentiate changes that requires restart and the changes which can be acomodated/invalidated dynamically.

In all MEF unleashes the Framework with capacity in order to build highly Extensible applications which can be maintained by. These can be leveraged in order to build highly customizable applications.

Syndication

It is possible you may want to be able to “Track” many websites whose contents change on a very unpredictable schedule. You can use RSS or ATOM.
RSS or Really Simple Syndication is a “Format” for delivering regularly changing web content. The feeds can be automated and can be channeled into a filtered display and the privacy is ensured as the tracking party need not subscribe to any email based newsletters.
Atom Syndication format is an xml based format used for feeds and AtomPub or APP or Atom Publishing Protocol is used for updating the resources.

Microsoft.Net 4.0 Framework, “Linq To SQL [L2S], Dead?”

Quick update for Development projects using Microsoft.NET and projects which have made investment in Linq,
As of Microsoft.Net 4.0 Framework, “Linq To SQL [L2S]” will not be recommended and “Linq To Entities” [L2E] will be the recommended Data access solution. Entity Framework [EF] will address most of the needs of L2S, some of the features which dev community wants in EF are already part of the L2S and Microsoft will be making investment in making both tools alike.

Ref: http://blogs.msdn.com/adonet/archive/2008/10/31/clarifying-the-message-on-l2s-futures.aspx

Wednesday, June 10, 2009

Windows Server service management extensions "Dublin"

Code named “Dublin” is the new set of extensions designed for the hosting environment for WF and WCF based applications. This will be set of “Service Management” extensions which will ship along with the windows server this has been built on top of IIS/Windows Activation Services.
Features and press release can be referenced at:
http://www.microsoft.com/NET/Dublin.aspx

Monday, June 8, 2009

Microsoft.NET Framework 4.0 Beta 1 and VisualStudio 2010

.NET Framework 4.0 Beta1 been made available to public, it can be downloaded from Microsoft. http://www.microsoft.com/NET/
Few interesting feature list:
<>