CRM 2011 Sandbox Plugin Call Azure AppFabric Hosted Service RRS feed

  • Question

  • CRM 2011 has some AppFabric integration, but from what I can see it can only post the execution context. What I want to do is invoke, from a sandbox plugin (i.e. CRM2011 online compatible), a WCF service that is accessed via Azure AppFabric. I am concerned though that this is not possible due to the fact that the plugin is running in partial trust.

    I have tested the plugin calling a hosted WCF service, and also an Azure host WCF service. The downside was the lack of security & authentication - partial trust does not allow the use of message based security, but since this traffic is going over the cloud it needs to be secured! (Thanks Microsoft).

    I am concerned that the restrictions on WCF imposed by partial trust will prevent the plugin connecting to the AppFabric WCF service. I see that the Microsoft supplied plugin runs in full trust!

    My guess is that my plugin would have to program directly against the Microsoft.ServiceBus methods, create a channel to the target WCF service & then invoke the service methods.

    Anyone done this?

    Thursday, July 21, 2011 6:06 PM


  • Well, it seems that though you can create a Service Endpoint within CRM, there is no way to directly instantiate it. All you can do is get an instance of the CRM IServiceEndpointNotificationService interface. You can't instantiate a connection to your own WCF service hosted over AppFabric. Also, you can't use the Microsoft.ServiceBus DLL to create your own WCF connection because the Microsoft.ServiceBus DLL is full trust only.

    So well done Microsoft. You've moved CRM to the cloud, we can move our business services to the cloud (via AppFabric), but you can't connect the two. It seems that CRM 2011 Online is still stuck with minimal connectivity to the rest of the world. You would have thought MS would have got their own software working properly before exhorting us to do so too.

    • Marked as answer by Caratacus Friday, August 5, 2011 7:24 AM
    Friday, August 5, 2011 7:24 AM