}
public boolean beforeSubmit(Submit submit, SubmitContext context) {
WsrmContainer container = (WsrmContainer) submit.getRequest();
if (container.getWsrmConfig().isWsrmEnabled()) {
WsdlInterface iface = request.getOperation().getInterface();
WsrmUtils utils = new WsrmUtils(iface.getSoapVersion());
WsrmSequence sequence = utils.createSequence(request.getEndpoint(), iface.getSoapVersion(), request
.getWsrmConfig().getVersionNameSpace(), request.getWsrmConfig().getAckTo(), 0l, request.getOperation(),
((WsdlRequest) submit.getRequest()).getWsaConfig().getTo(), request.getWsrmConfig().getOfferEndpoint());
request.getWsrmConfig().setSequenceIdentifier(sequence.getIdentifier());
request.getWsrmConfig().setUuid(sequence.getUuid());
if (!request.getWsrmConfig().getVersion().equals(WsrmVersionTypeConfig.X_1_0.toString())) {
WsmcInjection receiveInjection = new WsmcInjection(request.getEndpoint(), request.getOperation(),
iface.getSoapVersion(), request.getWsrmConfig().getUuid());
request.setAfterRequestInjection(receiveInjection);
}
}
return true;