Amit's profileAll about BizTalk Server...PhotosBlogLists Tools Help

Blog


    January 30

    Expression Encoder and C#

     

    If you are planning to use Expression Encoder to encode your videos and audios, now you can all do this using OM of Expression Encoder.

    There are three options available

    1.       Use Existing Audio and Video profile like VideoProfiles.HardwareDeviceH264Small and AudioProfiles.WmaForZune

    2.       If you want to use some custom profiles you can save the profiles and then use them

    3.       The Last is when you use presets, which allows you to have the max control on the out put videos/audios..

     

    January 05

    Windows Azure and the APTCA(AllowPartiallyTrustedCallersAttribute) gotcha

     

    I have divided this article into three parts and that will make you understand some of the gotcha with Windows Azure.

    1.       Windows Azure and Live Mesh

    2.       Windows Azure and .NET Services

    3.       Windows Azure and WCF Services

     

    Windows Azure and Live Mesh

    If you are planning to have Live Mesh integrated with you Windows Azure applications in that case you just can’t use the Live Mesh assemblies like

    ·         Microsoft.LiveFX.Client

    ·         Microsoft.LiveFX.ResourceModel

    etc..etc..

    As these assemblies cannot be used from your Windows Azure code guess why? The reason being these assemblies are still not APTCA signed. And you will get a security Exception if you do this.

    So if you want to do functionalities from your Windows Azure Application like Connecting to Live Mesh, Creating folders, files, deleting files and folders you just can’t use these assemblies directly.

    The beauty of Live Mesh is that it supports pure REST based calls; in that case you can use all the functionality of Live Mesh from Windows Azure using “System.Net.Http.HttpWebRequest” only.

    For this I highly recommend Fiddler2. http://www.fiddlertool.com/fiddler/ which will definitely help do create you HttpRequest objects.

     

    Windows Azure and .NET Services

    If you are planning to integrate .NET Services from your Windows Azure code, you will face the same problem as you faced when you tried using the Live Mesh assemblies, i.e. you just can’t use assemblies like

    ·         Microsoft.ServiceBus

    ·         Microsoft.Workflow.Activities

    etc..etc..

    The reason being same these assemblies are still not APTCA signed.

    What if you want to call Service Bus Services from Windows Azure code?

    The only option is, when you host you Service Bus services use bindings like “Microsoft.ServiceBus.WebHttpRelayBinding”

    Now in this case if you want to call this service from your Windows Azure code you do not need to have  “Microsoft.ServiceBus” assembly referenced. You can call this service using plan…vanilla…our old and simple “System.Net.Http.HttpWebRequest”

    What if you want to call Workflow Service from Windows Azure code?

    If you want to use Workflow service from an Application you have to do a sequence of steps like

    1.       Create an instance of Workflow

    2.       Start the workflow instance

    3.       Now you can call this instance

    The first two steps of above are not possible directly when you try to do this from your windows Azure code because in that case you need to have “Microsoft.Workflow.Activities” assembly referenced, and you can’t use this assembly from your Windows Azure code.

    The last step of the above i.e. Call a cloud workflow instance. You can do this using “System.Net.Http.HttpWebRequest” from your windows Azure code.

     

    Windows Azure and WCF Services

    If you want to call and host WCF services in your Windows Azure application you can only use the Partial Trust profile of WCF.

     

     

    At last if you are planning to develop you Windows Azure application you should know some of the above gotcha, as this will help you to know what is and what’s not possible from Windows Azure Applications.