Hi.
I having a problem with a Java object call. It appears that the CF server does not create the objects exclusively when more than one instance of the same script is running. I have created a java class to do multi-threaded XML post to a web service. The java class works fine and everything is great if you only call the script once. If you call it more that once at the same time it appears that a new instance is the same as the other instance. Here is a code segment of how I'm creating the object.
<cfscript>
obj_PostXML = CreateObject('java', 'MultiThreadedXMLPost').init();
obj_PostXML.executePost(arr_Arguments);
while(obj_PostXML.completedCount LT 2) {}
str_output = obj_PostXML.theData;
</cfscript>
<cfdump var="#str_output#">
Is there anyway to make it exclusive?
Kind regards,
Andrew.
I having a problem with a Java object call. It appears that the CF server does not create the objects exclusively when more than one instance of the same script is running. I have created a java class to do multi-threaded XML post to a web service. The java class works fine and everything is great if you only call the script once. If you call it more that once at the same time it appears that a new instance is the same as the other instance. Here is a code segment of how I'm creating the object.
<cfscript>
obj_PostXML = CreateObject('java', 'MultiThreadedXMLPost').init();
obj_PostXML.executePost(arr_Arguments);
while(obj_PostXML.completedCount LT 2) {}
str_output = obj_PostXML.theData;
</cfscript>
<cfdump var="#str_output#">
Is there anyway to make it exclusive?
Kind regards,
Andrew.