Quite honestly, I'm somewhat stumped by this one. This is definitely to do with Axis2 itself and the type of Java it generates. Using the command line to create the Java from the WSDL also produces a source file with the same errors. In addition to those errors are warnings that don't show up in OD:
[WARN] Type {http://www.company.com/t2im/entity/Product/v02}ProductInstanceStatus missing!
[WARN] Type {http://www.company.com/t2im/entity/Product/v02}ProductInstanceAdditionalDetails missing!
[WARN] Type {http://www.company.com/t2im/entity/Service/v01}ServiceAccountAdditionalDetails missing!
[WARN] Type {http://www.company.com/t2im/entity/Billing/v02}DirectDebitStatus missing!
[WARN] Type {http://www.company.com/t2im/entity/Billing/v02}BillingAccountStatus missing!
[WARN] Type {http://www.company.com/t2im/entity/Billing/v02}BillingAddress missing!
[WARN] Type {http://www.company.com/t2im/entity/Billing/v02}BillingAccountAdditionalDetails missing!
[WARN] Type {http://www.company.com/t2im/entity/ProductOffering/v01}ProductOfferingAdditionalDetails missing!
[WARN] Type {http://www.company.com/t2im/entity/Product/v02}ProductInstanceAdditionalDetails missing!
[WARN] Type {http://www.company.com/t2im/entity/Party/v02}ParentOrganizationNumber missing!
[WARN] Type {http://www.company.com/t2im/composition/PartyComposition/v03}ContactAdditionalDetails missing!
As well, when I try and use the Axis 1.4 connector, I receive a different issue:
Duplicate file name: C:\tools\OD6\workspace\err\WEB-INF\src\connectivity\ws\beans1\PhoneNumber.java.
Hint: you may have mapped two namespaces with elements of the same name to the same package name.
That happens when there might be namespace issues, and so Axis can't map the same Java file name for two different instances of an element. Even more perplexing than that, using the latest version of Axis2 from Apache's website results in a different issue, though I suspect it is related:
Exception in thread "main" org.apache.axis2.wsdl.codegen.CodeGenerationException: java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
...
Caused by: org.apache.axis2.schema.SchemaCompilationException: The referenced element {http://www.company.com/t2im/Common/v04}StatusName' was not found!
at org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler.java:753)
at org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler.java:604)
at org.apache.axis2.schema.SchemaCompiler.process(SchemaCompiler.java:2069)
...
As it stands, Axis2, regardless of whether its the OD connector or the standalone binaries, is not able to correctly create Java, or in some cases create Java at all, for the WSDL you're using. There are a couple of options you have: 1) You can try and change the WSDL so that Axis2 is able to read it correctly. This could turn out to be a non-trivial task, though. 2) You can create the Java web service client using a different mechanism, copy that Java file(s) or library into your OD project, and invoke the web service using hand-written Java in a servlet in your flow, rather than using WSOPs. This latter option might be the simplest choice, because even Apache states that the databinding we use, ADB, is:
By no means [...] intended to be a fully functional schema compiler like XMLBeans. [...] ADB is meant to be a 'Simple' databinding framework and was not meant to compile all types of schemas.
I did try using XMLBeans to generate Java using the wsdl2java tool provided with the Axis2 binaries, and it does not generate any errors during the code gen process.