[Design of JBoss ESB] - Missing method isNotNull() in AssertArgument?
by bruno
Hello, please excuse me if this is not the proper place to make this question.
I'm trying to compile JBossESB from the SVN trunk (updated today). At a certain point, while executing "ant dist", I get a NoSuchMethodError:
[java] [junit] Testcase: test_no_collections took 1.212 sec
[java] [junit] Caused an ERROR
[java] [junit] org.jboss.internal.soa.esb.assertion.AssertArgument.isNotNull(Ljava/lang/Object;Ljava/lang/String;)V
[java] [junit] java.lang.NoSuchMethodError: org.jboss.internal.soa.esb.assertion.AssertArgument.isNotNull(Ljava/lang/Object;Ljava/lang/String;)V
[java] [junit] at org.jboss.soa.esb.http.HttpClientFactory.createHttpClient(HttpClientFactory.java:53)
[java] [junit] at org.jboss.soa.esb.services.soapui.SoapUIClientService.createWsdlLoader(SoapUIClientService.java:152)
[java] [junit] at org.jboss.soa.esb.services.soapui.SoapUIClientService.getWsdlInterfaces(SoapUIClientService.java:127)
[java] [junit] at org.jboss.soa.esb.services.soapui.SoapUIClientService.getOperation(SoapUIClientService.java:139)
[java] [junit] at org.jboss.soa.esb.services.soapui.SoapUIClientService.buildRequest(SoapUIClientService.java:102)
[java] [junit] at org.jboss.soa.esb.services.soapui.SoapUIClientServiceMBeanUnitTest.test_no_collections(SoapUIClientServiceMBeanUnitTest.java:65)
It seems to me that the method AssertArgument.isNotNull() is expected be of type void. However, in the AssertArgument class, it is of type Object.
After changing the method to be of type void, everything compiles like a charm. What is happening here? Thanks in advance for your help.
PS: here, the diff I've created (from directory "product"):
--- rosetta/src/org/jboss/internal/soa/esb/assertion/AssertArgument.java (revision 16081)
+++ rosetta/src/org/jboss/internal/soa/esb/assertion/AssertArgument.java (working copy)
@@ -38,7 +38,7 @@
* @param argName Argument name.
* @throws IllegalArgumentException Argument is null.
*/
- public static Object isNotNull(Object arg, String argName) throws IllegalArgumentException {
+ public static void isNotNull(Object arg, String argName) throws IllegalArgumentException {
if (arg == null) {
throw new IllegalArgumentException("null '" + argName
+ "' arg in method call.");
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4099201#4099201
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4099201
18 years, 5 months
[Design the new POJO MicroContainer] - Demand / Supply string transformation
by alesj
Talking yesterday at Zurich JUG, describing our IoC, when mentioning Demand/Supply, Bela got an idea of extending that notion with a regexp.
Thinking about it, we could have a generic 'transfromer' attribute on the demand/supply element.
e.g.
| <demand transformer="org.jboss.ioc.transformer.RegExp">^[A-Z0-9._%+-]+(a)jboss\.((org)|(com))$</demand>
|
| <supply>mc(a)jboss.org</supply>
|
| <demand transformer="org.jboss.ioc.transformer.IntLimit">(0,255]</demand>
|
| <supply transformer="org.jboss.util.propertyeditor.IntegerEditor">128</supply>
|
Where a demand transformer would create Matcheable, supply transformer would simple be a PropertyEditor.
e.g.
| public interface Matcheable
| {
| boolean match(Object other);
| }
|
| for(Map.Entry entry : suppliers.keySet())
| {
| if (name instance of Matcheable)
| {
| Matcheable matcheable = (Matcheable)name;
| if (matcheable.match(entry.getKey()))
| List<KernelControllerContext> list = entry.getValue();
| if (list != null && list.isEmpty() == false)
| return list.get(0);
| }
|
| ...
| }
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4099181#4099181
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4099181
18 years, 5 months