hello
i ddnt read properly tutorial
i got exception coz i forgot to override processINOUt method of
MyEndProvider...
what a donkey..!
sorry and regards
marco
Marco MISTRONI
14/01/2008 16:09
To
users
cc
Subject
hello-world-bc not generating MyBootstrap.java
hi all,
i am trying the hello world sample for servicemix......following
instructions here http://servicemix.apache.org/hello-world-bc.html
i ran this maven command
C:\CRDS\servicemix\hello-world-smx>mvn archetype:create
-DarchetypeGroupId=org.a
pache.servicemix.tooling
-DarchetypeArtifactId=servicemix-binding-component -Dar
chetypeVersion=3.2.1 -DgroupId=org.apache.servicemix.samples.helloworld.bc
-Dart
ifactId=hello-world-bc
all i got was this java classes (in src/main)
MyComponent
MyConsumerEndpoiont
MyEndpontType
MyProviderEndpoint
no MyBootstrap...........
THis is my test
public void test() throws Exception {
DefaultServiceMixClient client = new DefaultServiceMixClient(jbi);
InOut me = client.createInOutExchange();
me.setService(new QName("urn:test", "service"));
me.getInMessage().setContent(new StringSource("<hello>THis is my
Test!</hello>"));
client.sendSync(me);
// By default, the endpoint throws an
UnsupportedOperationException
// so do not test anything here
if (me.getStatus() == ExchangeStatus.ERROR) {
if (me.getError() != null) {
throw me.getError();
} else {
fail("Received ERROR status");
}
} else if (me.getFault() != null) {
fail("Received fault: " + new
SourceTransformer().toString(me.getFault().getContent()));
}
System.err.println(new
SourceTransformer().toString(me.getOutMessage().getContent()));
client.done(me);
}
and this is the exception i have in surefire-report
-------------------------------------------------------------------------------
Test set:
org.apache.servicemix.samples.helloworld.bc.MySpringComponentTest
-------------------------------------------------------------------------------
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.89 sec
<<< FAILURE!
test(org.apache.servicemix.samples.helloworld.bc.MySpringComponentTest)
Time elapsed: 0.813 sec <<< ERROR!
java.lang.UnsupportedOperationException: Unsupported MEP:
http://www.w3.org/2004/08/wsdl/in-out
at
org.apache.servicemix.samples.helloworld.bc.MyProviderEndpoint.processInOut(MyProviderEndpoint.java:55)
at
org.apache.servicemix.common.endpoints.ProviderEndpoint.process(ProviderEndpoint.java:109)
at
org.apache.servicemix.common.AsyncBaseLifeCycle.doProcess(AsyncBaseLifeCycle.java:538)
at
org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:490)
at
org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:46)
at
org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:610)
at
org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:170)
at
org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:167)
at
org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:134)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
at java.lang.Thread.run(Thread.java:595)
docs says
The value of the archetypeVersion parameter in the command above (3.1.2)
may need to be updated to the current ServiceMix version in order for the
command to work correctly. The latest version can always be found in the
top level ServiceMix POM in the <version> element.
i went to chekc in the pom.xm of one of the examples........it shows 3.2.1
anyone could help?
thanks and regards
marco
This communication is confidential, may be privileged and is meant only for the
intended recipient. If you are
not the intended recipient, please notify the sender by reply and delete this
message from your system. Any
unauthorised dissemination, distribution or copying hereof is prohibited.
BNP Paribas Fund Services UK Limited, BNP Paribas Trust Corporation UK Limited,
BNP Paribas UK Limited,
BNP Paribas Commodity Futures Ltd and Investment Fund Services Limited are
authorised and regulated by
the Financial Services Authority.
BNP Paribas, BNP Paribas Securities Services and BNP Paribas Private Bank are
authorised by the CECEI
and AMF. BNP Paribas London Branch, BNP Paribas Securities Services London
Branch and BNP Paribas
Private Bank London Branch are regulated by the Financial Services Authority
for the conduct of their UK
business. BNP Paribas Securities Services London Branch is also a member of
the London Stock Exchange.