On 3/6/07, C. Boyden <[EMAIL PROTECTED]> wrote:

Thank you Bruce,

I understand the direction you are sending me in. I must make a marsheller
in the org.apache.servicemix.http.endpoints package, then setup my
servicemix.xml configuration to utilize it on the HTTP Component.

Yes, that's exactly correct. The only real thing to decide is how to
parse the HTML into XML so it can become the content of a normalized
message. I've had to parse HTML for a number of different projects in
the past. Below are a couple of options I've used:

* Parse the HTML into XHTML using JTidy - JTidy will handle this very
easily but this method of parsing is very much a hack because you have
to manually wrap any Javascript, etc.

* Parse the HTML using Tag Soup - Tag Soup is a SAX compliant HTML
parser so it's rather free form and works very well. IIRC, I had the
best luck with this option.

Remember that for an in-out MEP (i.e., request/in -> response/out),
you'll have to parse the HTTP request to create the JBI in message and
then parse the HTTP response to create the JBI out message. This means
the new marshaler will need a method to marshal HTML -> XML and a
method to unmarshal XML -> HTML. This is really the overall path you
need to take with the marshaler. Whatever you're doing in between the
in message and the out message is up to you and how the message flow
amongst components is configured in your application.

Bruce
--
perl -e 'print unpack("u30","D0G)[EMAIL 
PROTECTED]&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
);'

Apache Geronimo - http://geronimo.apache.org/
Apache ActiveMQ - http://activemq.org/
Apache ServiceMix - http://servicemix.org/
Castor - http://castor.org/

Reply via email to