Quantcast
Channel: Forum Microsoft Identity Manager
Viewing all articles
Browse latest Browse all 6944

How to speed up Export-FIMConfig queries?

$
0
0

I'm trying to write some PoSh scripts to pull information from FIM, and, Holy Toledo Batman!, they are slow! 

In the time it takes to run get results from a command like:

Export-FIMConfig -uri $FIMURI -onlybaseresources -customconfig ("/Group[Owner='$FIMuserObjID']")

I could easily start the web portal, manually log in, and load and peruse through a dozen pages.  All I really want is the group names and the object identifiers.  Why is this so slow? 

In searching for a way to speed this up, I have tried splitting it into simultaneous background jobs adding:

/Group[(starts-with(DisplayName,'$($letter)'))]

to the config and cycling through the alphabet, but because PoSh jobs each have to load the FIMAutomation snapin, it doesn't speed things up much and uses a lot of resources. 

I'm trying to wrap my head around using runspaces to do the same thing, but I'm not really certain it's any better.  All the examples and scripts "out there" involve distributing the load across multiple computers, not multi-threading on the same computer.  I realize there are "concerns" related to garbage collection and locking, but I'm not interested in using it for changing anything.  I just want to have a reasonable query response time.  I have some code that runs without error, but I'm not getting any results (as far as I can tell). 

Can someone tell me if runspaces are likely to help here (or not) and, if you are really kind, offer some assistance in getting it working?

Thanks.


Viewing all articles
Browse latest Browse all 6944

Trending Articles