开发者

ProjectServer Interface ReadProject incredibly slow; creates 200MB XML file! faster way?

I'm trying to create a scheduled task that updates less than 5% of the tasks on project server but am having a problem with the ReadProject method taking way too long to complete;

Essentially because this is happening over web services a gigantic 200MB xml file is generated to represent the task data which is then only converted back to objects; The call can take up to 2 minutes to run.

I've had a poke around in the database and can get at the data I need with a quick query and get the data back in a reported开发者_如何学运维 0ms (probably somewhere between 0 and 16ms ?); however; I do need to update some of the task data's custom fields and I'd rather not do this via the database unless I have to.

Are there any better ways to access projects; return only a specific set of tasks; update those and check them back into the project?

Many thanks in advance, Chris


I ended up just going in via the database to read the data I wanted and then if I was making any changes use the PSI interface;

I also made sure to mark the items as updated if I changed anything and then only get the changes to submit back to the server. PSI has a limit of about 1,000 items so you need to batch them up if you have more than that. Wish that was documented in the function description... bloody msdn docs :(

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜