Hi, 

my problem is, that very often when i execute the following code:


  | public void prepare(GlobalTransaction gtx, String[] groupNames, 
BatchReplication[] batchReplication){
  |             if(isDebug)     log.debug("Begin Calling prepare");
  |             log2pc.info("coordinator begin_commit");
  |             try{
  |                     Object args[] = {gtx, groupNames, batchReplication};
  |                     Class classes[] = {GlobalTransaction.class, 
String[].class, BatchReplication[].class};
  | 
  |                     
  |                     long startTime = System.currentTimeMillis();
  |                     ArrayList responseList = 
partition.callMethodOnCluster(ReplicatedCacheManager.RPC_HANDLE_NAME, 
"_rpc_runPrepare", args, classes, false);
  |                     long endTime = System.currentTimeMillis();
  |                     log.debug("Prepare Time\t" + (endTime-startTime));      
        
  |                     
  |                     if 
(responsesOk(responseList,ReplicationStatus.SUCCESSFULLY_COMPLETED)){
  |                             log2pc.info("coordinator commit");
  |                             commit(gtx, groupNames);
  |                     }else{
  |                             log2pc.info("coordinator abort");
  |                             rollback(gtx, groupNames);
  |                     }
  |                     
  |                     /*if(isDebug){  
  |                     log.debug("The list of responses from the other nodes 
are:");
  |                     
  |                     Iterator it = responseList.iterator();
  |                     while(it.hasNext()){
  |                             log.debug("Response = " + it.next());
  |                     }       
  |                     }*/
  |                     
  |                     
  |             }catch(Exception e){
  |                     log.debug("Exception caught in prepare() = " + 
e.getMessage());
  |             }
  |     
  |     }
  | 
  | 

then only the coordinator (the one executing this) will receive the call and 
execute the method _rpc_runPrepare. Then, after 30 to 80 seconds all others 
will receive the call and execute it .
How can that happen? I get this problem only in 3 out of 10 tries and without 
the problem the call takes less then 100 ms. I'm using JBoss 4.0.2 .
Hope you can help me,

Sebastian

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3911036#3911036

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3911036


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to