You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by ANDREW MICONE <AM...@DEQ.IDAHO.GOV> on 2004/12/14 16:18:35 UTC

Re: Is JAX-RPC really not capable of processing complex data types? Whatabout the AXIS implementation?

Axis is fully capable of serializing and deserializing complex types. -- Andy

>>> roland.beuker@xs4all.nl 12/14/04 02:26AM >>>
Is JAX-RPC really not capable of processing complex data types? I am 
using Soap to fill the gap between C++ and Java... If JAX-RPC only 
supports simple type objects the whole idea is not working :-(

***********************************************************************

Hi!
JAX-RPC only receives the simple type object as parameters just because
they implement the Serialization interface which make sure these objects
can
be transformed over network!it works like this:
1)serialize your object before they are transformed
2)object is transformed over network in binary stream
3)at destination,the binary stream is deserialized,and form the correct
object!
4)the object is used at the destination
Of course,it is not you who do the serialization work and
deserialization work!
but you need to ensure your object can be serialized and
deserialized,and what
you actually need to do is to implement the serialization interface!If
you have done
some RMI programs,you would be very clear about this point!
So JAX-RPC only allows simple type objects used as params in the method!may
be in the future,this package can be more stronger and thus programmers can
obtain more choices!
Hope that my advice can help and have a nice day

***********************************************************************



Re: Re: Is JAX-RPC really not capable of processing complex data types? Whatabout the AXIS implementation?

Posted by Roland Beuker <ro...@xs4all.nl>.
Thanks,

Is it not true that JAX-RPC cannot handle complex types (like the story 
below) or has Axis an extension for this functionality (as Axis is a 
JAX-RPC implementation)?

Regards,

Roland Beuker


ANDREW MICONE wrote:

>Axis is fully capable of serializing and deserializing complex types. -- Andy
>
>  
>
>>>>roland.beuker@xs4all.nl 12/14/04 02:26AM >>>
>>>>        
>>>>
>Is JAX-RPC really not capable of processing complex data types? I am 
>using Soap to fill the gap between C++ and Java... If JAX-RPC only 
>supports simple type objects the whole idea is not working :-(
>
>***********************************************************************
>
>Hi!
>JAX-RPC only receives the simple type object as parameters just because
>they implement the Serialization interface which make sure these objects
>can
>be transformed over network!it works like this:
>1)serialize your object before they are transformed
>2)object is transformed over network in binary stream
>3)at destination,the binary stream is deserialized,and form the correct
>object!
>4)the object is used at the destination
>Of course,it is not you who do the serialization work and
>deserialization work!
>but you need to ensure your object can be serialized and
>deserialized,and what
>you actually need to do is to implement the serialization interface!If
>you have done
>some RMI programs,you would be very clear about this point!
>So JAX-RPC only allows simple type objects used as params in the method!may
>be in the future,this package can be more stronger and thus programmers can
>obtain more choices!
>Hope that my advice can help and have a nice day
>
>***********************************************************************
>
>
>
>
>
>  
>


Re: maintaining a database connection pool or a socket connection pool

Posted by Joe Plautz <jo...@customcall.com>.
In tomcat's documentation you can find all that you need for connection 
pooling. I don't know of any restrictions on pools, but I have at least 
10 going right now.

look here:

http://jakarta.apache.org/tomcat/tomcat-5.0-doc/jndi-datasource-examples-howto.html

Joe

METIN ZAVRAK wrote:
> 
> Hi,
> Is there a way to maintain a database connection pool or a socket 
> connection pool within Axis?
> I am developing a GUI which is dummy and don't know what to do except 
> how to connect web service.
> The web service, gets the parameters and connects to a database and runs 
> queries on tables, prepares results and sends the results back to GUI.
> 1 -  How could I return resultSet from a web service? (any code sample?)
> 2 - Could I maintain a connection pool in order to use existing 
> connections? I am using Tomcat as web server and it has its own db 
> connection pool but how can I register resource to JNDI? I have to 
> maintain two different connection pools (one for mysql and one for oracle)
> 
> Besides, the GUI sends some some commands to web service.
> Web service takes the commands and connects to an application over a 
> predefined socket. Get the results from the application and return results.
> 1 - Can I maintain a socket connection pool for this operation?
> 
> I know web services are stateless but how stateless they are?
> Thanks
> ======================
> Metin ZAVRAK
> Yazılım Geliştirme Mühendisi
> Oksijen Teknoloji
> 
> 0 543 502 03 63
> metin.zavrak@oksijen.com
> ======================
> Verba volent, scripta manent.
> (Söz uçar, yazı kalır).

Re: maintaining a database connection pool or a socket connection pool

Posted by Lyndon Tiu <lt...@alumni.sfu.ca>.
METIN ZAVRAK wrote:

>
> Hi,
> Is there a way to maintain a database connection pool or a socket 
> connection pool within Axis?

> 2 - Could I maintain a connection pool in order to use existing 
> connections? I am using Tomcat as web server and it has its own db 
> connection pool but how can I register resource to JNDI? I have to 
> maintain two different connection pools (one for mysql and one for 
> oracle)
>

In your webapps' META-INF/context.xml (Oracle):

<?xml version="1.0" encoding="UTF-8"?>
<Context docBase="D:\<TOMCAT_HOME>\webapp" path="/axis_app" 
reloadable="true">
  <Resource name="jdbc/xdb" scope="Shareable" type="javax.sql.DataSource"/>
  <ResourceParams name="jdbc/xdb">
    <parameter>
      <name>factory</name>
      <value>org.apache.commons.dbcp.BasicDataSourceFactory</value>
    </parameter>
    <!-- DBCP database connection settings -->
    <parameter>
      <name>url</name>
      <value>jdbc:oracle:thin:@192.168.0.1:1521:ORA_SID</value>
    </parameter>
    <parameter>
      <name>driverClassName</name>
      <value>oracle.jdbc.driver.OracleDriver</value>
    </parameter>
    <parameter>
      <name>username</name>
      <value>dbuser</value>
    </parameter>
    <parameter>
      <name>password</name>
      <value>dbpass</value>
    </parameter>
    <!-- DBCP connection pooling options -->
    <parameter>
      <name>maxWait</name>
      <value>3000</value>
    </parameter>
    <parameter>
      <name>maxIdle</name>
      <value>100</value>
    </parameter>
    <parameter>
      <name>maxActive</name>
      <value>10</value>
    </parameter>
  </ResourceParams>
</Context>



Make sure the Oracle JDBC jar file ( ojdbc14_g.jar ) is located under:

<TOMCAT_HOME>/common/endorsed


--
Lyndon Tiu


maintaining a database connection pool or a socket connection pool

Posted by METIN ZAVRAK <me...@oksijen.com>.
Hi, 
Is there a way to maintain a database connection pool or a socket 
connection pool within Axis? 
I am developing a GUI which is dummy and don't know what to do except how 
to connect web service. 
The web service, gets the parameters and connects to a database and runs 
queries on tables, prepares results and sends the results back to GUI. 
1 -  How could I return resultSet from a web service? (any code sample?)
2 - Could I maintain a connection pool in order to use existing 
connections? I am using Tomcat as web server and it has its own db 
connection pool but how can I register resource to JNDI? I have to 
maintain two different connection pools (one for mysql and one for oracle) 


Besides, the GUI sends some some commands to web service. 
Web service takes the commands and connects to an application over a 
predefined socket. Get the results from the application and return 
results. 
1 - Can I maintain a socket connection pool for this operation? 

I know web services are stateless but how stateless they are? 
Thanks
======================
Metin ZAVRAK
Yazılım Geliştirme Mühendisi
Oksijen Teknoloji 

0 543 502 03 63
metin.zavrak@oksijen.com
======================
Verba volent, scripta manent.
(Söz uçar, yazı kalır).