Integer opendObjects1 = (Integer)context1.contentionMetadata;
Integer opendObjects2 = (Integer)context2.contentionMetadata;
Logger.debug(context1+":"+opendObjects1 + " vs " + context2+":"+opendObjects2);
if(opendObjects1 < opendObjects2 || opendObjects1.equals(opendObjects2) && context1.getContextId() < context2.getContextId())
throw new TransactionException();
else{
if(context2 instanceof ControlContext)
if(((ControlContext)context2).kill())
return 0;
else