You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2009/06/19 21:53:41 UTC
svn commit: r786642 - in /cxf/branches/2.1.x-fixes: ./
common/common/src/main/java/org/apache/cxf/common/i18n/
rt/core/src/main/java/org/apache/cxf/wsdl11/
Author: dkulp
Date: Fri Jun 19 19:53:40 2009
New Revision: 786642
URL: http://svn.apache.org/viewvc?rev=786642&view=rev
Log:
Merged revisions 786640 via svnmerge from
https://svn.apache.org/repos/asf/cxf/branches/2.2.x-fixes
................
r786640 | dkulp | 2009-06-19 15:48:30 -0400 (Fri, 19 Jun 2009) | 9 lines
Merged revisions 786638 via svnmerge from
https://svn.apache.org/repos/asf/cxf/trunk
........
r786638 | dkulp | 2009-06-19 15:47:08 -0400 (Fri, 19 Jun 2009) | 1 line
[CXF-2295] Add better error message
........
................
Modified:
cxf/branches/2.1.x-fixes/ (props changed)
cxf/branches/2.1.x-fixes/common/common/src/main/java/org/apache/cxf/common/i18n/UncheckedException.java
cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/Messages.properties
cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLRuntimeException.java
cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java
Propchange: cxf/branches/2.1.x-fixes/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Jun 19 19:53:40 2009
@@ -1,2 +1,2 @@
-/cxf/branches/2.2.x-fixes:743446,753380,753397,753421,754585,755365,757499,757859,757899,757935,757951,758195,758303,758308,758378,758690,758910,759890,759961,759963-759964,759966,760029,760073,760150,760171,760178,760198,760212,760456,760468,760582,760938,761094,761113,761120,761317,761759,761789,762393,762518,762567,763200,763272,763495,763854,763931,763942,763953,764033-764034,764581,764599-764606,764887,765357,766013,766058,766100-766101,766763,766770,766860,766962-766963,767159,767191,767927,771416,772143,772402,772658,772714,773009-773010,773027,773049,773146,773581,773691,773693,774446-774496,774558,774760,774851,774979,775423,776024-776025,776218,776429,776459,777189,777224,777243,777481,777505,777572,777580,780033,780184,780213,780421,780664,780800,780902,780911,781497,781841,782733,782735-782736,783099,783407,784064,784197,785293,785296,785298-785299,785301,785656,786158,786587,786589,786591-786592
-/cxf/trunk:782181,782728-782730,783097,783396,784059,784181,784895,785279-785282,785468,786142,786271,786395,786582-786583
+/cxf/branches/2.2.x-fixes:743446,753380,753397,753421,754585,755365,757499,757859,757899,757935,757951,758195,758303,758308,758378,758690,758910,759890,759961,759963-759964,759966,760029,760073,760150,760171,760178,760198,760212,760456,760468,760582,760938,761094,761113,761120,761317,761759,761789,762393,762518,762567,763200,763272,763495,763854,763931,763942,763953,764033-764034,764581,764599-764606,764887,765357,766013,766058,766100-766101,766763,766770,766860,766962-766963,767159,767191,767927,771416,772143,772402,772658,772714,773009-773010,773027,773049,773146,773581,773691,773693,774446-774496,774558,774760,774851,774979,775423,776024-776025,776218,776429,776459,777189,777224,777243,777481,777505,777572,777580,780033,780184,780213,780421,780664,780800,780902,780911,781497,781841,782733,782735-782736,783099,783407,784064,784197,785293,785296,785298-785299,785301,785656,786158,786587,786589,786591-786592,786640
+/cxf/trunk:782181,782728-782730,783097,783396,784059,784181,784895,785279-785282,785468,786142,786271,786395,786582-786583,786638
Propchange: cxf/branches/2.1.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.
Modified: cxf/branches/2.1.x-fixes/common/common/src/main/java/org/apache/cxf/common/i18n/UncheckedException.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.1.x-fixes/common/common/src/main/java/org/apache/cxf/common/i18n/UncheckedException.java?rev=786642&r1=786641&r2=786642&view=diff
==============================================================================
--- cxf/branches/2.1.x-fixes/common/common/src/main/java/org/apache/cxf/common/i18n/UncheckedException.java (original)
+++ cxf/branches/2.1.x-fixes/common/common/src/main/java/org/apache/cxf/common/i18n/UncheckedException.java Fri Jun 19 19:53:40 2009
@@ -19,6 +19,9 @@
package org.apache.cxf.common.i18n;
+import java.util.ResourceBundle;
+import java.util.logging.Logger;
+
public class UncheckedException extends java.lang.RuntimeException {
@@ -41,7 +44,29 @@
message = null;
}
-
+ public UncheckedException(Logger log, String msg, Object ... params) {
+ message = new org.apache.cxf.common.i18n.Message(msg,
+ log,
+ params);
+ }
+ public UncheckedException(ResourceBundle bundle, String msg, Object ... params) {
+ message = new org.apache.cxf.common.i18n.Message(msg,
+ bundle,
+ params);
+ }
+ public UncheckedException(Logger log, String msg, Throwable t, Object ... params) {
+ super(t);
+ message = new org.apache.cxf.common.i18n.Message(msg,
+ log,
+ params);
+ }
+ public UncheckedException(ResourceBundle bundle, String msg, Throwable t, Object ... params) {
+ super(t);
+ message = new org.apache.cxf.common.i18n.Message(msg,
+ bundle,
+ params);
+ }
+
public String getCode() {
if (null != message) {
return message.getCode();
Modified: cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/Messages.properties
URL: http://svn.apache.org/viewvc/cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/Messages.properties?rev=786642&r1=786641&r2=786642&view=diff
==============================================================================
--- cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/Messages.properties (original)
+++ cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/Messages.properties Fri Jun 19 19:53:40 2009
@@ -30,3 +30,4 @@
MISSING_DESTINATION_FACTORY = Cannot find the destination factory, check the port //wsdl:port[@name=''{0}'']
MISSING_SERVICE= No definition of service {0} in the WSDL.
WSDL4J_BAD_ELEMENT_PART= Part {0} defined as element {1} which is not in the schema.
+NO_MESSAGE=No {0} message was found for operation {1} and input named {2}. Check the wsdl for errors.
Modified: cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLRuntimeException.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLRuntimeException.java?rev=786642&r1=786641&r2=786642&view=diff
==============================================================================
--- cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLRuntimeException.java (original)
+++ cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLRuntimeException.java Fri Jun 19 19:53:40 2009
@@ -19,6 +19,8 @@
package org.apache.cxf.wsdl11;
+import java.util.logging.Logger;
+
import org.apache.cxf.common.i18n.Message;
import org.apache.cxf.common.i18n.UncheckedException;
@@ -39,4 +41,9 @@
public WSDLRuntimeException(Throwable cause) {
super(cause);
}
+
+ public WSDLRuntimeException(Logger log, String msg, Object ... params) {
+ super(log, msg, params);
+ }
+
}
Modified: cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java?rev=786642&r1=786641&r2=786642&view=diff
==============================================================================
--- cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java (original)
+++ cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java Fri Jun 19 19:53:40 2009
@@ -553,6 +553,9 @@
this.copyExtensionAttributes(opInfo, op);
Input input = op.getInput();
if (input != null) {
+ if (input.getMessage() == null) {
+ throw new WSDLRuntimeException(LOG, "NO_MESSAGE", "input", op.getName(), input.getName());
+ }
MessageInfo minfo = opInfo.createMessage(input.getMessage().getQName(), MessageInfo.Type.INPUT);
opInfo.setInput(input.getName(), minfo);
buildMessage(minfo, input.getMessage());
@@ -561,6 +564,9 @@
}
Output output = op.getOutput();
if (output != null) {
+ if (output.getMessage() == null) {
+ throw new WSDLRuntimeException(LOG, "NO_MESSAGE", "output", op.getName(), output.getName());
+ }
MessageInfo minfo = opInfo.createMessage(output.getMessage().getQName(), MessageInfo.Type.OUTPUT);
opInfo.setOutput(output.getName(), minfo);
buildMessage(minfo, output.getMessage());