}
// -------------------------------
// Execute Query Plan Fragments
// -------------------------------
else if (work instanceof WorkFragmentMessage) {
WorkFragment fragment = ((WorkFragmentMessage)work).getFragment();
assert(fragment != null);
// HACK HACK HACK
if (ts.isInitialized() == false) {
LOG.warn(String.format("Skipping %s at partition %d for unitialized txn",
work.getClass().getSimpleName(), this.partitionId));
return;
}
// Get the ParameterSet array for this WorkFragment
// It can either be attached to the AbstractTransaction handle if it came
// over the wire directly from the txn's base partition, or it can be attached
// as for prefetch WorkFragments
ParameterSet parameters[] = null;
if (fragment.getPrefetch()) {
parameters = ts.getPrefetchParameterSets();
ts.markExecPrefetchQuery(this.partitionId);
if (trace.val && ts.isSysProc() == false)
LOG.trace(ts + " - Prefetch Parameters:\n" + StringUtil.join("\n", parameters));
} else {
parameters = ts.getAttachedParameterSets();
if (trace.val && ts.isSysProc() == false)
LOG.trace(ts + " - Attached Parameters:\n" + StringUtil.join("\n", parameters));
}
// At this point we know that we are either the current dtxn or the current dtxn is null
// We will allow any read-only transaction to commit if
// (1) The WorkFragment for the remote txn is read-only
// (2) This txn has always been read-only up to this point at this partition
ExecutionMode newMode = null;
if (hstore_conf.site.specexec_enable) {
if (fragment.getReadOnly() && ts.isExecReadOnly(this.partitionId)) {
newMode = ExecutionMode.COMMIT_READONLY ;
} else {
newMode = ExecutionMode.COMMIT_NONE;
}
} else {