Click here to Skip to main content
15,886,689 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more: , +
Dear all experts,

I have run into a strange issue - I understand the problem point - But, I can not think of a solution - so I thought I should get some advice.

I have the following built up;

1. An HTML page with a table of around 200 members (table data is regarding member details)
2. On a click of a button - for each member in the table, I need to run 6 crystal reports and then export it out at a location on the server.
3. I need the feedback of whether the reports are run successfully or not after each member processing.

The problem;

As soon as I click the button to run reports, say 200 AJAX async requests are fired up to a web service with an object as argument containing details of the member (used to run the reports).

Crystal reports can only handle 75 concurrent report processing. I have a global variable (in the web service section) which is incremented as soon as a set of reports get fired up and I limit that variable to 2 members at a time - like a throttle limiting simultaneous execution. As soon as the reports have finished processing for a member, I decrease the variable by 1. If the throttle has max out, I continuously re-check the throttle variable and only execute reports when the variable is available.

The problem is, because of the above scenario, the CPU is used kind of 100% (because of crystal reports and also continuously checking for throttle variable) and I can not fire any other ajax requests from the HTML page. I mean I can fire up the ajax requests but I think CPU is not available to process those request.

Can anyone guide on how to achieve what I want?

If you require any further clarification, please ask.

Thanks.

Regards,
Nayan
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900