开发者

Citrix, MFCOM, Powershell, and the future?

开发者 https://www.devze.com 2023-03-05 17:09 出处:网络
I have been using MFCOM for many years to incorporate Citrix Xenapp management tasks into our custom administration applications that we write mostly in Java and partially in C++.

I have been using MFCOM for many years to incorporate Citrix Xenapp management tasks into our custom administration applications that we write mostly in Java and partially in C++.

Our Citrix adm开发者_开发百科inistrator has informed me now that MFCOM is being phased out, and Powershell Cmdlets are provided as the new Citrix XenApp API. He will be building our next farm without MFCOM support.

(And here is where I complain a litte. But you can skip the complaining if you wish as it is not essential to the questions I ask later: A scripting-only API is difficult and error prone to use from languages like Java/C++/C#. Catching and handling exceptions is unreliable, passing and receiving complicated arguments like collections or objects is cumbersome, and knowing that the script's interpreter exe is where you want it and the version you need requires lots of extra code. Complaining done.)

So I have to rewrite the applications. Here are my questions:

  • Are Powershell Cmdlets really the only API supported in the future for XenApp?

  • If so, how are people using non-Microsoft languages like Java/C++/Python/etc accessing this API? Is everyone launching scripts in separate processes?

  • If we use C# to rewrite the Citrix parts of our application, can we access these Cmdlets without shelling out a script in a separate process? I am amenable to using C#. My main desire is to not launch a separate process every time we need to call a Citrix function.

Thanks


Yes, the PowerShell SDK is the only supported API for XenApp 6 and probably also for future versions.

However, you do not have to start separate powershell.exe processes when working with the API (at least not from managed code). You can either use runspaces or the Citrix XenApp 6 wrapper assemblies. I recommend the latter mainly because of type safety.

Citrix CTP Jason Conger has written a series of articles that explain how to make the transition from MFCOM to the PowerShell SDK. You might want to read especially these two:

  • Background: Getting Started with the Citrix XenApp PowerShell SDK and C#
  • Examples: Citrix XenApp 6 PowerShell SDK: Getting a List of Applications with C#
0

精彩评论

暂无评论...
验证码 换一张
取 消