Gert Vanthienen wrote:
> 
> L.S.,
> 
> You can't simply use ServiceMix as a proxy server like this.  The HTTP 
> consumer endpoint receives an HTTP request and will send that through 
> the normalized message router.  It can be used e.g. to receive XML 
> messages posted over HTTP (or SOAP messages).  The message will then be 
> routed through the NMR to the provider endpoint, which enables you to do 
> send a normalized message (using plain HTTP or HTTP/SOAP) to a remote 
> HTTP service and possibly route a response message back.  Both of these 
> are built to work with normalized (read: XML) messages.  Moreover, by 
> browsing to the consumer endpoint (as you were doing), you would get the 
> WSDL for the service if there is any -- in your case, no WSDL is defined 
> so you get the 404 response.
> 
> Regards,
> 
> Gert
> 
> FreshAir wrote:
>> Hi
>> I am trying to use servicemix-http to visit a website(e.g
>> www.google.com), I
>> assume it should work.
>> I configured the xbean.xml as follows:
>> for consumer:
>>  <http:endpoint service="test:httpListener"
>>                  endpoint="httpListenerEndpoint"
>>                  targetService="test:httpProvider"
>>                  role="consumer" 
>>                  locationURI="http://0.0.0.0:8192/example/";
>>                  defaultMep="http://www.w3.org/2004/08/wsdl/in-out";
>>                  /> 
>>
>> and for provider:
>>  <http:endpoint service="test:httpProvider"
>>                  endpoint="httpProviderEndpoint"
>>                  role="provider"
>>                  locationURI="http://www.google.com/";
>>                  defaultMep="http://www.w3.org/2004/08/wsdl/in-out";
>>                  />
>>
>> Then after hotdeploying them, I enter the URL
>> http://localhost:8192/example/
>> into the web browser(Is it a too naive assumption?),and I expected there
>> can
>> be a response from www.google.com...
>> But it presented like this:
>>
>> HTTP ERROR: 404
>> Unable to find requested resource
>> RequestURI=/example/
>>
>> Powered by Jetty://
>>
>> I think this is a very straightforward example, so is there any
>> conceptual
>> misunderstanding in it?
>> Thanks in advance!
>>   
> 
> 
> 
> -----
> ---
> Gert Vanthienen
> http://www.anova.be
> 
Thanks for your replay.
So do you mean that for one thing the http-bc can only deal with XML
messages and my way of browsing it in IE  (that is GET URI) is not sending a
XML msg, for another, browsing it require there exists a web service
predefined? Then is there any way I can browsing a website using the http-bc
as a proxy?

best regards,
FreshAir
-- 
View this message in context: 
http://www.nabble.com/Can-I-use-servicemix-http-to-vist-website--tp18352895p18373798.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Reply via email to