You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by "Martin Gainty (JIRA)" <ji...@apache.org> on 2009/11/04 14:49:32 UTC
[jira] Created: (AXIS2-4545)
org.apache.axis2.jaxws.binding.SOAPBinding refers to missing SOAPConstants
org.apache.axis2.jaxws.binding.SOAPBinding refers to missing SOAPConstants
--------------------------------------------------------------------------
Key: AXIS2-4545
URL: https://issues.apache.org/jira/browse/AXIS2-4545
Project: Axis 2.0 (Axis2)
Issue Type: Bug
Components: jaxws
Affects Versions: 1.5
Environment: java version "1.6.0_16"
Java(TM) SE Runtime Environment (build 1.6.0_16-b01)
Java HotSpot(TM) Client VM (build 14.2-b01, mixed mode)
Axis2 1.5.1
Reporter: Martin Gainty
org.apache.axis2.jaxws.binding.SOAPBinding details:
/** (non-Javadoc)
* @see javax.xml.ws.soap.SOAPBinding#setRoles(java.util.Set)
*/
public void setRoles(Set<String> set) {
// Validate the values in the set
if (set != null && !set.isEmpty()) {
// Throw an exception for setting a role of "none"
// Per JAXWS 2.0 Sec 10.1.1.1 SOAP Roles, page 116:
if (set.contains(SOAPConstants.URI_SOAP_1_2_ROLE_NONE)) {
throw ExceptionFactory.makeWebServiceException(Messages.getMessage("roleValidatioErr"));
}
}
roles = addDefaultRoles(set);
}
private Set<String> addDefaultRoles(Set<String> set) {
Set<String> returnSet = set;
if (returnSet == null) {
returnSet = new HashSet<String>();
// Make sure the defaults for the binding type are in the set
// and add them if not. Note that for both SOAP11 and SOAP12, the role of ultimate
// reciever can be indicated by the omission of the role attribute.
// REVIEW: This is WRONG because the bindingID from the WSDL is not the same value as
// SOAPBinding annotation constants. There are other places in the code that have
// this same issue I am sure.
if (SOAPBinding.SOAP12HTTP_BINDING.equals(bindingId)
|| SOAPBinding.SOAP12HTTP_MTOM_BINDING.equals(bindingId)) {
if (returnSet.isEmpty() || !returnSet.contains(SOAPConstants.URI_SOAP_1_2_ROLE_NEXT)) {
returnSet.add(SOAPConstants.URI_SOAP_1_2_ROLE_NEXT);
}
// SOAPConstants.URI_SOAP_1_2_ROLE_NEXT is not located in SOAPConstants
} else {
if (returnSet.isEmpty() || !returnSet.contains(SOAPConstants.URI_SOAP_ACTOR_NEXT)) {
// SOAPConstants.URI_SOAP_1_2_ACTOR_NEXT is not located in SOAPConstants
returnSet.add(SOAPConstants.URI_SOAP_ACTOR_NEXT);
}
}
return returnSet;
}
please supply missing SOAPConstants
thank you
Martin
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.