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 "Venkat Reddy (JIRA)" <ax...@ws.apache.org> on 2005/01/21 10:36:16 UTC
[jira] Created: (AXIS-1775) WSDL2Java won't resolve name clashes when -p is specified
WSDL2Java won't resolve name clashes when -p is specified
---------------------------------------------------------
Key: AXIS-1775
URL: http://issues.apache.org/jira/browse/AXIS-1775
Project: Axis
Type: Bug
Environment: Axis 1.2 RC2
Reporter: Venkat Reddy
If the WSDL has same value for name attribute for both <service> and <portType>, WSDL2Java with -p option results in DuplicateFileException.
C:\web_services>java org.apache.axis.wsdl.WSDL2Java -p com.test GlobalWeather.wsdl
org.apache.axis.wsdl.toJava.DuplicateFileException: Duplicate file name: com\test\GlobalWeather.java.
Hint: you may have mapped two namespaces with elements of the same name to the same package name.
Cause: Namespaces.getCreate() simply returns default doesn't populate pkg2NamespacesMap resulting in empty collisionCanidates in JavaGeneratorFactory.resolveNameClashes(), and the java class names wont get resolved, like when the -p option is not used.
Fix: add a call to put(key, defaultPackage) inside Namespaces.getCreate() method to populate pkg2NamespacesMap even when the default package is used.
Result: WSDL2Java will use file names like GolbalWeather_Service.java GolbalWeather_PortType.java instead of GlobaWeather.java, thus resolving name conflicts when the -p is used. If -p is not used, it will work as usual.
Please let me know if this fix can potentially break something else.
Venkat
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
[jira] Resolved: (AXIS-1775) WSDL2Java won't resolve name clashes when -p is specified
Posted by "Davanum Srinivas (JIRA)" <ax...@ws.apache.org>.
[ http://issues.apache.org/jira/browse/AXIS-1775?page=history ]
Davanum Srinivas resolved AXIS-1775:
------------------------------------
Resolution: Fixed
looks like venkat, applied his patch.
-- dims
> WSDL2Java won't resolve name clashes when -p is specified
> ---------------------------------------------------------
>
> Key: AXIS-1775
> URL: http://issues.apache.org/jira/browse/AXIS-1775
> Project: Axis
> Type: Bug
> Environment: Axis 1.2 RC2
> Reporter: Venkat Reddy
> Attachments: diff.txt
>
> If the WSDL has same value for name attribute for both <service> and <portType>, WSDL2Java with -p option results in DuplicateFileException.
> C:\web_services>java org.apache.axis.wsdl.WSDL2Java -p com.test GlobalWeather.wsdl
> org.apache.axis.wsdl.toJava.DuplicateFileException: Duplicate file name: com\test\GlobalWeather.java.
> Hint: you may have mapped two namespaces with elements of the same name to the same package name.
> Cause: Namespaces.getCreate() simply returns default doesn't populate pkg2NamespacesMap resulting in empty collisionCanidates in JavaGeneratorFactory.resolveNameClashes(), and the java class names wont get resolved, like when the -p option is not used.
> Fix: add a call to put(key, defaultPackage) inside Namespaces.getCreate() method to populate pkg2NamespacesMap even when the default package is used.
> Result: WSDL2Java will use file names like GolbalWeather_Service.java GolbalWeather_PortType.java instead of GlobaWeather.java, thus resolving name conflicts when the -p is used. If -p is not used, it will work as usual.
> Please let me know if this fix can potentially break something else.
> Venkat
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
[jira] Commented: (AXIS-1775) WSDL2Java won't resolve name clashes when -p is specified
Posted by "Davanum Srinivas (JIRA)" <ax...@ws.apache.org>.
[ http://issues.apache.org/jira/browse/AXIS-1775?page=comments#action_57896 ]
Davanum Srinivas commented on AXIS-1775:
----------------------------------------
Venkat,
Please attach a "cvs diff -u"...difficult to follow description w/o a diff -u
thanks,
dims
> WSDL2Java won't resolve name clashes when -p is specified
> ---------------------------------------------------------
>
> Key: AXIS-1775
> URL: http://issues.apache.org/jira/browse/AXIS-1775
> Project: Axis
> Type: Bug
> Environment: Axis 1.2 RC2
> Reporter: Venkat Reddy
>
> If the WSDL has same value for name attribute for both <service> and <portType>, WSDL2Java with -p option results in DuplicateFileException.
> C:\web_services>java org.apache.axis.wsdl.WSDL2Java -p com.test GlobalWeather.wsdl
> org.apache.axis.wsdl.toJava.DuplicateFileException: Duplicate file name: com\test\GlobalWeather.java.
> Hint: you may have mapped two namespaces with elements of the same name to the same package name.
> Cause: Namespaces.getCreate() simply returns default doesn't populate pkg2NamespacesMap resulting in empty collisionCanidates in JavaGeneratorFactory.resolveNameClashes(), and the java class names wont get resolved, like when the -p option is not used.
> Fix: add a call to put(key, defaultPackage) inside Namespaces.getCreate() method to populate pkg2NamespacesMap even when the default package is used.
> Result: WSDL2Java will use file names like GolbalWeather_Service.java GolbalWeather_PortType.java instead of GlobaWeather.java, thus resolving name conflicts when the -p is used. If -p is not used, it will work as usual.
> Please let me know if this fix can potentially break something else.
> Venkat
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
[jira] Updated: (AXIS-1775) WSDL2Java won't resolve name clashes when -p is specified
Posted by "Venkat Reddy (JIRA)" <ax...@ws.apache.org>.
[ http://issues.apache.org/jira/browse/AXIS-1775?page=history ]
Venkat Reddy updated AXIS-1775:
-------------------------------
Attachment: diff.txt
attaching diff.txt
> WSDL2Java won't resolve name clashes when -p is specified
> ---------------------------------------------------------
>
> Key: AXIS-1775
> URL: http://issues.apache.org/jira/browse/AXIS-1775
> Project: Axis
> Type: Bug
> Environment: Axis 1.2 RC2
> Reporter: Venkat Reddy
> Attachments: diff.txt
>
> If the WSDL has same value for name attribute for both <service> and <portType>, WSDL2Java with -p option results in DuplicateFileException.
> C:\web_services>java org.apache.axis.wsdl.WSDL2Java -p com.test GlobalWeather.wsdl
> org.apache.axis.wsdl.toJava.DuplicateFileException: Duplicate file name: com\test\GlobalWeather.java.
> Hint: you may have mapped two namespaces with elements of the same name to the same package name.
> Cause: Namespaces.getCreate() simply returns default doesn't populate pkg2NamespacesMap resulting in empty collisionCanidates in JavaGeneratorFactory.resolveNameClashes(), and the java class names wont get resolved, like when the -p option is not used.
> Fix: add a call to put(key, defaultPackage) inside Namespaces.getCreate() method to populate pkg2NamespacesMap even when the default package is used.
> Result: WSDL2Java will use file names like GolbalWeather_Service.java GolbalWeather_PortType.java instead of GlobaWeather.java, thus resolving name conflicts when the -p is used. If -p is not used, it will work as usual.
> Please let me know if this fix can potentially break something else.
> Venkat
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
[jira] Commented: (AXIS-1775) WSDL2Java won't resolve name clashes when -p is specified
Posted by "Davanum Srinivas (JIRA)" <ax...@ws.apache.org>.
[ http://issues.apache.org/jira/browse/AXIS-1775?page=comments#action_57968 ]
Davanum Srinivas commented on AXIS-1775:
----------------------------------------
please go ahead and commit :)
-- dims
> WSDL2Java won't resolve name clashes when -p is specified
> ---------------------------------------------------------
>
> Key: AXIS-1775
> URL: http://issues.apache.org/jira/browse/AXIS-1775
> Project: Axis
> Type: Bug
> Environment: Axis 1.2 RC2
> Reporter: Venkat Reddy
> Attachments: diff.txt
>
> If the WSDL has same value for name attribute for both <service> and <portType>, WSDL2Java with -p option results in DuplicateFileException.
> C:\web_services>java org.apache.axis.wsdl.WSDL2Java -p com.test GlobalWeather.wsdl
> org.apache.axis.wsdl.toJava.DuplicateFileException: Duplicate file name: com\test\GlobalWeather.java.
> Hint: you may have mapped two namespaces with elements of the same name to the same package name.
> Cause: Namespaces.getCreate() simply returns default doesn't populate pkg2NamespacesMap resulting in empty collisionCanidates in JavaGeneratorFactory.resolveNameClashes(), and the java class names wont get resolved, like when the -p option is not used.
> Fix: add a call to put(key, defaultPackage) inside Namespaces.getCreate() method to populate pkg2NamespacesMap even when the default package is used.
> Result: WSDL2Java will use file names like GolbalWeather_Service.java GolbalWeather_PortType.java instead of GlobaWeather.java, thus resolving name conflicts when the -p is used. If -p is not used, it will work as usual.
> Please let me know if this fix can potentially break something else.
> Venkat
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira