We just got a developer that will be working to develop helpful programs to aid us in administering our Orion environment. For now though we use a lot of PowerShell scripts that I write to automate many tasks, usually those tasks are automating custom properties. One issue I run into often is my PowerShell scripts take a long time to run. I've gotten better at improving my code to loop through items less often and things like that, but I'm looking for some additional tips.
- When I'm invoking verbs, specifically the Set-SwisObject verb, am I able to send multiple objects to this, or do I need to do one object at a time? I know I can send multiple properties for a single node to it, but can I just send a whole hash table full of Node Custom Property URI's, Properties, and their desired values at it, or is looping through each node necessary? If so how should this look?
- Same question with other verbs?
- Our Developer will be re-creating my PowerShell scripts into more robust .Net Programs using C# mostly. Are there any general performance tips for interacting with the API via C#?
- Any general performance tips for the API in general or just the API via PowerShell?
Thanks for any assistance you may be able to offer.