Sorry about that. How did you try to send your post request ? Using an html form ? The problem is that such requests are not supported, as the data inside the post is not an xml, but a list of key=value pairs.
I'll try to update the wiki. On 12/1/06, crowne <[EMAIL PROTECTED]> wrote:
I found a fix by using the attached http://www.nabble.com/file/4398/client.html client.html file, which is provided as part of the servicemix distribution. The main difference between the file provided and the one that I made below is a whole lot of javascript, that I haven't taken the time to try understand. Perhaps someone can explain it to me in very basic terms :) What led me astray was the tutorial wiki page http://servicemix.org/site/creating-a-protocol-bridge.html here , which finishes off with saying, Then you can send an HTML POST request to http://localhost:8192/bridge/ and use a jmx console to check that the bridge.output queue contains a jms message. Then I created an html page to do a POST to http://localhost:8192/bridge/ and expected it to work, this was perhaps a bit presumtuous, maybe someone can update the wiki page to be more specific about all of the javascript stuff. crowne wrote: > > <p> > I downloaded the fuse-1.2.1 server and used the FUSE tooling to create the > servicemix bridge sample ( > http://servicemix.org/site/creating-a-protocol-bridge.html > http://servicemix.org/site/creating-a-protocol-bridge.html ). > </p><p> > Various errors were encountered along the way, but I finally created a > deployable SA in the form of a file called bridge-sa-1.0-SNAPSHOT.zip. > </p><p> > Deployment through the IDE didn't work, as it kept trying to undeploy and > redeploy the servicemix-shared library which was found to be already in > use by another component, namely the servicemix-bpe, I think that this > issue amy be resolved through jira issue > https://issues.apache.org/activemq/browse/SM-605 SM-605 > </p><p> > Installation through the web console worked, however I haven't manged a > successful test. > <br/>I used the following html to post a variety of messages from "hello" > to a SOAP & SOAP-1.2 envelopes. > </p> > > <br/><html> > <br/><form action="http://localhost:8192/bridge/" method="post"> > <br/><p> > <br/><textarea rows="15" cols="72"> > <br/></textarea></p> > <br/><p><input type="submit" value="Send"></p> > <br/></form> > <br/></html> > <p/> > Sample SOAP message:<br/> > <br/><?xml version="1.0" encoding="UTF-8"?> > <br/><Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/"> > <br/> <Body> > <br/> <helloWorld/> > <br/> </Body> > <br/></Envelope> > <p/> > > Sample SOAP-1.2 message:<br/> > <br/><?xml version="1.0" encoding="UTF-8"?> > <br/><Envelope xmlns="http://www.w3.org/2002/12/soap-envelope"> > <br/> <Body> > <br/> <helloWorld/> > <br/> </Body> > <br/></Envelope> > <p/> > > This was tested using the following JDK's: > <ul> > <li>1.5.0_09</li> > <li>1.5.0_05</li> > <li>1.5.0-beta2</li> > </ul> > <p/> > Below is the error that I consistently receive: > <br/><code> > SystemId Unknown; Line #-1; Column #-1; Premature end of file. > [Fatal Error] :-1:-1: Premature end of file. > ERROR - org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(45) | > Error processing exchange InOnly[ > id: ID:loaner55-1267-1164869965693-6:5 > status: Active > role: provider > service: {http://servicemix.apache.org/samples/bridge}jms > endpoint: endpoint > in: Unable to display: org.xml.sax.SAXParseException: Premature end of > file. > ] > com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog > at [row,col {unknown-source}]: [1,0] > at > com.ctc.wstx.sr.StreamScanner.throwUnexpectedEOF(StreamScanner.java:500) > at > com.ctc.wstx.sr.WstxStreamReader.nextFromProlog(WstxStreamReader.java:1950) > at com.ctc.wstx.sr.WstxStreamReader.next(WstxStreamReader.java:971) > at > org.apache.servicemix.jbi.jaxp.XMLStreamHelper.copy(XMLStreamHelper.java:78) > at > org.apache.servicemix.soap.marshalers.SoapWriter.writeContents(SoapWriter.java:198) > at > org.apache.servicemix.soap.marshalers.SoapWriter.writeSimpleMessage(SoapWriter.java:113) > at > org.apache.servicemix.soap.marshalers.SoapWriter.write(SoapWriter.java:82) > at > org.apache.servicemix.jms.AbstractJmsProcessor.fromNMS(AbstractJmsProcessor.java:157) > at > org.apache.servicemix.jms.AbstractJmsProcessor.fromNMS(AbstractJmsProcessor.java:151) > at > org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process(MultiplexingProviderProcessor.java:160) > at > org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:410) > at > org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:43) > at > org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623) > at > org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:169) > at > org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:177) > at > org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:227) > at > org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java:291) > at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown > Source) > at java.lang.Thread.run(Thread.java:595) > WARN - org.apache.servicemix.http.jetty.JCLLogger.warn(93) | EXCEPTION > javax.servlet.ServletException: Failed to process request: > java.lang.Exception: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in > prolog > at [row,col {unknown-source}]: [1,0] > at > org.apache.servicemix.http.HttpBridgeServlet.doPost(HttpBridgeServlet.java:79) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:615) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:688) > at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:442) > at > org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:356) > at > org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:615) > at > org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:149) > at > org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:123) > at > org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:141) > at org.mortbay.jetty.Server.handle(Server.java:269) > at > org.mortbay.jetty.HttpConnection.handlerRequest(HttpConnection.java:420) > at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:330) > at > org.mortbay.jetty.nio.HttpChannelEndPoint.run(HttpChannelEndPoint.java:270) > at > org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:475) > WARN - org.apache.servicemix.http.jetty.JCLLogger.warn(93) | Nested in > javax.servlet.ServletException: Failed to process request: > java.lang.Exception: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in > prolog > at [row,col {unknown-source}]: [1,0]: > java.lang.Exception: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in > prolog > at [row,col {unknown-source}]: [1,0] > at > org.apache.servicemix.http.processors.ConsumerProcessor.process(ConsumerProcessor.java:202) > at > org.apache.servicemix.http.HttpBridgeServlet.doPost(HttpBridgeServlet.java:71) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:615) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:688) > at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:442) > at > org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:356) > at > org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:615) > at > org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:149) > at > org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:123) > at > org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:141) > at org.mortbay.jetty.Server.handle(Server.java:269) > at > org.mortbay.jetty.HttpConnection.handlerRequest(HttpConnection.java:420) > at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:330) > at > org.mortbay.jetty.nio.HttpChannelEndPoint.run(HttpChannelEndPoint.java:270) > at > org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:475) > Caused by: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog > at [row,col {unknown-source}]: [1,0] > at > com.ctc.wstx.sr.StreamScanner.throwUnexpectedEOF(StreamScanner.java:500) > at > com.ctc.wstx.sr.WstxStreamReader.nextFromProlog(WstxStreamReader.java:1950) > at com.ctc.wstx.sr.WstxStreamReader.next(WstxStreamReader.java:971) > at > org.apache.servicemix.jbi.jaxp.XMLStreamHelper.copy(XMLStreamHelper.java:78) > at > org.apache.servicemix.soap.marshalers.SoapWriter.writeContents(SoapWriter.java:198) > at > org.apache.servicemix.soap.marshalers.SoapWriter.writeSimpleMessage(SoapWriter.java:113) > at > org.apache.servicemix.soap.marshalers.SoapWriter.write(SoapWriter.java:82) > at > org.apache.servicemix.jms.AbstractJmsProcessor.fromNMS(AbstractJmsProcessor.java:157) > at > org.apache.servicemix.jms.AbstractJmsProcessor.fromNMS(AbstractJmsProcessor.java:151) > at > org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process(MultiplexingProviderProcessor.java:160) > at > org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:410) > at > org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:43) > at > org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623) > at > org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:169) > at > org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:177) > at > org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:227) > at > org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java:291) > at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown > Source) > at java.lang.Thread.run(Thread.java:595) > WARN - org.apache.servicemix.http.jetty.JCLLogger.warn(93) | /bridge/: > java.lang.Exception: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in > prolog > at [row,col {unknown-source}]: [1,0] > at > org.apache.servicemix.http.processors.ConsumerProcessor.process(ConsumerProcessor.java:202) > at > org.apache.servicemix.http.HttpBridgeServlet.doPost(HttpBridgeServlet.java:71) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:615) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:688) > at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:442) > at > org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:356) > at > org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:615) > at > org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:149) > at > org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:123) > at > org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:141) > at org.mortbay.jetty.Server.handle(Server.java:269) > at > org.mortbay.jetty.HttpConnection.handlerRequest(HttpConnection.java:420) > at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:330) > at > org.mortbay.jetty.nio.HttpChannelEndPoint.run(HttpChannelEndPoint.java:270) > at > org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:475) > Caused by: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog > at [row,col {unknown-source}]: [1,0] > at > com.ctc.wstx.sr.StreamScanner.throwUnexpectedEOF(StreamScanner.java:500) > at > com.ctc.wstx.sr.WstxStreamReader.nextFromProlog(WstxStreamReader.java:1950) > at com.ctc.wstx.sr.WstxStreamReader.next(WstxStreamReader.java:971) > at > org.apache.servicemix.jbi.jaxp.XMLStreamHelper.copy(XMLStreamHelper.java:78) > at > org.apache.servicemix.soap.marshalers.SoapWriter.writeContents(SoapWriter.java:198) > at > org.apache.servicemix.soap.marshalers.SoapWriter.writeSimpleMessage(SoapWriter.java:113) > at > org.apache.servicemix.soap.marshalers.SoapWriter.write(SoapWriter.java:82) > at > org.apache.servicemix.jms.AbstractJmsProcessor.fromNMS(AbstractJmsProcessor.java:157) > at > org.apache.servicemix.jms.AbstractJmsProcessor.fromNMS(AbstractJmsProcessor.java:151) > at > org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process(MultiplexingProviderProcessor.java:160) > at > org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:410) > at > org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:43) > at > org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623) > at > org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:169) > at > org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:177) > at > org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:227) > at > org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java:291) > at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown > Source) > at java.lang.Thread.run(Thread.java:595) > WARN - org.apache.servicemix.http.jetty.JCLLogger.warn(93) | /bridge/ > java.lang.Exception: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in > prolog > at [row,col {unknown-source}]: [1,0] > at > org.apache.servicemix.http.processors.ConsumerProcessor.process(ConsumerProcessor.java:202) > at > org.apache.servicemix.http.HttpBridgeServlet.doPost(HttpBridgeServlet.java:71) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:615) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:688) > at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:442) > at > org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:356) > at > org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:615) > at > org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:149) > at > org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:123) > at > org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:141) > at org.mortbay.jetty.Server.handle(Server.java:269) > at > org.mortbay.jetty.HttpConnection.handlerRequest(HttpConnection.java:420) > at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:330) > at > org.mortbay.jetty.nio.HttpChannelEndPoint.run(HttpChannelEndPoint.java:270) > at > org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:475) > Caused by: com.ctc.wstx.exc.WstxEOFException: Unexpected EOF in prolog > at [row,col {unknown-source}]: [1,0] > at > com.ctc.wstx.sr.StreamScanner.throwUnexpectedEOF(StreamScanner.java:500) > at > com.ctc.wstx.sr.WstxStreamReader.nextFromProlog(WstxStreamReader.java:1950) > at com.ctc.wstx.sr.WstxStreamReader.next(WstxStreamReader.java:971) > at > org.apache.servicemix.jbi.jaxp.XMLStreamHelper.copy(XMLStreamHelper.java:78) > at > org.apache.servicemix.soap.marshalers.SoapWriter.writeContents(SoapWriter.java:198) > at > org.apache.servicemix.soap.marshalers.SoapWriter.writeSimpleMessage(SoapWriter.java:113) > at > org.apache.servicemix.soap.marshalers.SoapWriter.write(SoapWriter.java:82) > at > org.apache.servicemix.jms.AbstractJmsProcessor.fromNMS(AbstractJmsProcessor.java:157) > at > org.apache.servicemix.jms.AbstractJmsProcessor.fromNMS(AbstractJmsProcessor.java:151) > at > org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process(MultiplexingProviderProcessor.java:160) > at > org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:410) > at > org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:43) > at > org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623) > at > org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:169) > at > org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:177) > at > org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:227) > at > org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java:291) > at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown > Source) > at java.lang.Thread.run(Thread.java:595) > </code> > -- View this message in context: http://www.nabble.com/Bridge-Sample-Problem-tf2730799s12049.html#a7637936 Sent from the ServiceMix - User mailing list archive at Nabble.com.
-- Cheers, Guillaume Nodet
