axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Doug Davis" <...@us.ibm.com>
Subject RE: new transport
Date Wed, 24 Oct 2001 11:03:23 GMT
It is possible to have a new transport kick in based solely
on the URL, I believe we have some transports in the
samples that do just that ( "local" maybe??).  Take a look
at the samples as see if they help.
-Dug


"Brain, Jim" <JBrain@Aegonusa.com> on 10/22/2001 02:45:51 PM

Please respond to axis-user@xml.apache.org

To:   "'axis-user@xml.apache.org'" <axis-user@xml.apache.org>
cc:
Subject:  RE: new transport



I have a followup to this question.

Newbie here, but I am trying to do the following:

Add a new messaging transport to Axis.  I chose axis over SOAP 2 because it
has the better transport capabilities.  I see how to do the server side
(basically, write a service that grabs messages from the queues, and then
rip out some code from AxisServlet to do the processing and send the reply
back, I hope)

However, from the client, I am unclear on how to add a new transport.  I
see
the new code below, but I would really like something a bit more "clean"
from the client's perspective.  Something like:

1) Take existing client axis code
2) Run client code with -DAXIS_TRANSPORT="com.me.jms.axistransport"
3) Code runs with new transport, and can use the new transport by using a
URL of the form jms://host....  (jms protocol provider maps to new
transport)

I appreciate the code below, and will try to set it up, but I'd like to
know
how feasible the above is (and sample code would be grand, but I am not
expecting any)

To be specific, the procotol I am trying to add is called CandleNet eBP,
which used to be called Roma (so protocol name would be roma://) which uses
MQSeries under the covers, and offers workflow.

Jim


Jim Brain, jbrain@aegonusa.com
"Good decisions are great, but bad decisions show more leadership than
indecisiveness."
(319) 369-2070 (work)
SYSTEMS ARCHITECT, INDIVIDUAL ITS, LIFE INVESTORS INSURANCE COMPANY OF
AMERICA

 -----Original Message-----
From:     Doug Davis [mailto:dug@us.ibm.com]
Sent:     Monday, October 22, 2001 5:59 AM
To:  axis-user@xml.apache.org
Subject:  RE: new transport

(Sorry for the delay)
The "docall" stuff looks right - that's what I've done when I needed
to use other transports.  I still have yet to be convinced of the value
of Transport objects so I didn't do your "init" stuff and it worked just
fine.
-Dug



"Torsten Curdt" <tcurdt@dff.st> on 10/17/2001 07:40:59 AM

Please respond to axis-user@xml.apache.org

To:   <axis-user@xml.apache.org>
cc:
Subject:  RE: new transport



So you mean:

init:
       AxisClient engine = new AxisClient();

       /* the new sender */
       JDBCTransportSender sender = new JDBCTransportSender();

       engine.deployHandler( "JDBCSender", sender );

       HandlerRegistry hr = engine.getHandlerRegistry();
       TargetedChainSupplier supp = new TransportSupplier("JDBCTransport",
                                                           null,
                                                           null,
                                                           "JDBCSender",
                                                           null,
                                                           hr);
       engine.deployTransport("JDBCTransport", supp);

inJDBCTransportSender:
       connection = (SQLConnection)
messagecontext.getProperty(JDBCTransportSender.CONNECTION);


dothecall:
       ServiceClient call = new ServiceClient();
       call.setTransportName("JDBCTransport");
       call.set( JDBCTransportSender.CONNECTION, connection );

       String res = (String) call.invoke(
         "urn:cominfo", "getInfo",
         new Object[] { args0, args1 }
       );

Is this what you mean? ... Actually I was wondering where there
is the connection between the ServiceClient and the AxisEngine.

What's the minimal target VM for axis? Will it work with JDK 1.2?

Thanks
--
Torsten

> Personally I find it easier to just create a new transport
> sender (ie. the handler that will send it across the wire).
> Define a new "transport" chain on the client side and
> then just have your code call "setTransportName(xxx)"
> where "xxx" is the name of the transport chain you want
> to use.
> -Dug
>
>> I have had just a short look into the axis project
>> yet, but all what I saw so far looks very promising.
>> Great!
>>
>> I've a question if following might be possible at
>> all with the current API:
>>
>> Instead of using HTTP or SMTP as transport I'd like
>> to create a new JDBC transport. Piping the SOAPRequest
>> through a JDBC connection as a parameter of a function
>> call and returning the SOAPResponse as a SQL result.
>>
>> The function acts as SOAPServer by calling
>> the appropriate methods inside the database's JVM.
>>
>> Someting similiar (not SOAP related) worked quite
>> well this way.
>>
>> (BTW: which JDK is required for axis?)
>>
>> Although the new transport might be easy to implement
>> I guess I also need a new Handler (extending BasicHandler)
>> don't I? How can I pass the connection to the Handler?
>>
>>       ServiceClient call = new ServiceClient
>>             (new JDBCTransport(connection));
>>
>>       String res = (String) call.invoke(
>>         "urn:cominfo", "getInfo",
>>         new Object[] { args0, args1 }
>>       );
>>
>> For the server inside the db's JVM I need to do what
>> the AxisServer excutes in the "invoke" message. Don't I?!
>>
>> Excuse me if my questions show that I don't
>> know what I am talking about ;) ... but I just
>> had a look into the API a couple of minutes ago.
>>
>> Some comments on the above would probably
>> help me a lot to get into this





Mime
View raw message