Re: Question about exposing a database as a web service...

2009-03-05 Thread sumedha rubasinghe
This link[1] contains a collection of HOWTOs on WSO2 Data Services solution.
/sumedha

[1] http://wso2.org/library/3183



On Thu, Mar 5, 2009 at 10:12 PM, keith chapman keithgchap...@gmail.com wrote:
 Hi,

 Have you looked at the WSO2 DataServices Solution? [1]. It is a product
 thats built on Apache Axis2 which helps you expose a data base as a web
 service by simply following a wizard. I think using that will be more
 productive in your case. It is also released under the Apache License.

 Thanks,
 Keith.

 [1] http://wso2.org/projects/solutions/data-services/java

 On Thu, Mar 5, 2009 at 10:23 AM, riveraej river...@gmail.com wrote:

 Hi everyone!

 I come to you asking for help. I'm trying to mount a web service which
 consults a MySQL Database. I have already done the consult, but I can show
 all data contained in the database, or I can show data according to
 conditions setting these conditions manually in the code of the Java
 Class.
 Nevertheless I need to pass in some way to my class a value in order to
 make
 the SQL consult according to this.

 Talking in code terms... I have the next code:

 public class poDBService{

        public OrderData orderDetails(){
                Connection conn = (Connection)
 MessageContext.getCurrentMessageContext().getProperty(
                        poDataServiceLifeCycle.DB_CONNECTION);
                if (conn!=null){
                        try{
                                String SQL = SELECT * FROM `porder` WHERE
 order_id=1;
                                PreparedStatement statement =
 conn.prepareStatement(SQL);
                                ResultSet result =
 statement.executeQuery();
                                if (result.next()){
                                        OrderData orderData = new
 OrderData();

  orderData.setOrderId(result.getInt(order_id));

  orderData.setSoldTo(result.getInt(soldTo));

  orderData.setShipTo(result.getInt(shipTo));


 I can access to my service through my browser in the address:

 http://localhost:8080/axis2/services/poDataService/orderDetails

 It correctly displays the corresponding data contained in the table porder

 But I need to define my SQL sentence allowing to pass it the needed
 parameter for the WHERE clause.
 I already found that some people makes it with code like the next:

 public class poDBService{

        public OrderData orderDetails(int id){
                Connection conn = (Connection)
 MessageContext.getCurrentMessageContext().getProperty(
                        poDataServiceLifeCycle.DB_CONNECTION);
                if (conn!=null){
                        try{
                                String SQL = SELECT * FROM `porder` WHERE
 order_id =   + id ;
                                PreparedStatement statement =
 conn.prepareStatement(SQL);
                                ResultSet result =
 statement.executeQuery();
                                if (result.next()){
                                        OrderData orderData = new
 OrderData();

  orderData.setOrderId(result.getInt(order_id));

  orderData.setSoldTo(result.getInt(soldTo));

  orderData.setShipTo(result.getInt(shipTo));


 With this code theoretically it would be possible to pass paramete id to
 the
 service in the URL address:

 http://localhost:8080/axis2/services/poDataService/orderDetails?id=1

 But when I try to do it in this way Axis returns in my web browser a Soap
 message like this:

 soapenv:Reason
 soapenv:Text xml:lang=en-USunknown/soapenv:Text
 /soapenv:Reason

 No error is thorwn in JBoss console window.

 I'm using:
 - JBoss-4.2.2.G.A.
 - Axis2-1.3
 - jdk1.5.0_17
 - mysql-connector-java-5.1.7
 - MySQL Server 5.1

 Any ideas what is happening? or is there another way to do this?

 Thanks in advance!

 Ernesto J. Rivera
 --
 View this message in context:
 http://www.nabble.com/Question-about-exposing-a-database-as-a-web-service...-tp22345253p22345253.html
 Sent from the Axis - User mailing list archive at Nabble.com.




 --
 Keith Chapman
 Senior Software Engineer
 WSO2 Inc.
 Oxygenating the Web Service Platform.
 http://wso2.org/

 blog: http://www.keith-chapman.org



Re: java.lang.ClassCastException: com.ctc.wstx.stax.WstxInputFactory

2009-01-15 Thread sumedha rubasinghe
What is the version of Jboss?
My gut feeling is this particular version of Jboss is having a
different Stax implementation.

/sumedha



On Thu, Jan 15, 2009 at 2:13 PM, Appasamy Thirugnana
athirugn...@sapient.com wrote:
 Application server .. JBoss

 -Original Message-
 From: Paul Fremantle [mailto:pzf...@gmail.com]
 Sent: Thursday, January 15, 2009 12:46
 To: axis-user@ws.apache.org
 Subject: Re: java.lang.ClassCastException: com.ctc.wstx.stax.WstxInputFactory

 Are you running this under an application server or standalone?

 Paul

 On Thu, Jan 15, 2009 at 6:51 AM, Appasamy Thirugnana
 athirugn...@sapient.com wrote:

 Hi,

   I am getting folllowing stack trace from my Stub class when I try to 
 invoke a service. Any inputs to get rid of this will be appreciated


 17:46:25,124 ERROR [STDERR] java.lang.ClassCastException: 
 com.ctc.wstx.stax.WstxInputFactory
 17:46:25,124 ERROR [STDERR] at 
 javax.xml.stream.XMLInputFactory.newInstance(XMLInputFactory.java:41)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axiom.om.util.StAXUtils$7.run(StAXUtils.java:311)
 17:46:25,124 ERROR [STDERR] at 
 java.security.AccessController.doPrivileged(Native Method)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axiom.om.util.StAXUtils.getXMLInputFactory_perClassLoader(StAXUtils.java:306)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axiom.om.util.StAXUtils.getXMLInputFactory(StAXUtils.java:76)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axiom.om.util.StAXUtils.createXMLStreamReader(StAXUtils.java:131)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axis2.util.XMLUtils.toOM(XMLUtils.java:596)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axis2.util.XMLUtils.toOM(XMLUtils.java:581)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axis2.deployment.DescriptionBuilder.buildOM(DescriptionBuilder.java:97)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axis2.deployment.AxisConfigBuilder.populateConfig(AxisConfigBuilder.java:86)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.deployment.DeploymentEngine.populateAxisConfiguration(DeploymentEngine.java:641)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.deployment.FileSystemConfigurator.getAxisConfiguration(FileSystemConfigurator.java:116)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactor
 y.java:68)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContextFromFileSystem(Configuratio
 nContextFactory.java:184)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.client.ServiceClient.configureServiceClient(ServiceClient.java:150)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.client.ServiceClient.init(ServiceClient.java:143)



 Regards

 Appasamy T





 --
 Paul Fremantle
 Co-Founder and CTO, WSO2
 Apache Synapse PMC Chair
 OASIS WS-RX TC Co-chair

 blog: http://pzf.fremantle.org
 p...@wso2.com

 Oxygenating the Web Service Platform, www.wso2.com



Re: java.lang.ClassCastException: com.ctc.wstx.stax.WstxInputFactory

2009-01-15 Thread sumedha rubasinghe
Tested with Jboss 4.0.2.
It works without any error.

/sumedha


On Thu, Jan 15, 2009 at 2:49 PM, Appasamy Thirugnana
athirugn...@sapient.com wrote:

 Jboss 4.0.5


 -Original Message-
 From: sumedha rubasinghe [mailto:
 Sent: Thursday, January 15, 2009 14:44
 To: axis-user@ws.apache.org
 Subject: Re: java.lang.ClassCastException: com.ctc.wstx.stax.WstxInputFactory

 What is the version of Jboss?
 My gut feeling is this particular version of Jboss is having a
 different Stax implementation.

 /sumedha



 On Thu, Jan 15, 2009 at 2:13 PM, Appasamy Thirugnana
 athirugn...@sapient.com wrote:
 Application server .. JBoss

 -Original Message-
 From: Paul Fremantle [mailto:pzf...@gmail.com]
 Sent: Thursday, January 15, 2009 12:46
 To: axis-user@ws.apache.org
 Subject: Re: java.lang.ClassCastException: com.ctc.wstx.stax.WstxInputFactory

 Are you running this under an application server or standalone?

 Paul

 On Thu, Jan 15, 2009 at 6:51 AM, Appasamy Thirugnana
 athirugn...@sapient.com wrote:

 Hi,

   I am getting folllowing stack trace from my Stub class when I try to 
 invoke a service. Any inputs to get rid of this will be appreciated


 17:46:25,124 ERROR [STDERR] java.lang.ClassCastException: 
 com.ctc.wstx.stax.WstxInputFactory
 17:46:25,124 ERROR [STDERR] at 
 javax.xml.stream.XMLInputFactory.newInstance(XMLInputFactory.java:41)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axiom.om.util.StAXUtils$7.run(StAXUtils.java:311)
 17:46:25,124 ERROR [STDERR] at 
 java.security.AccessController.doPrivileged(Native Method)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axiom.om.util.StAXUtils.getXMLInputFactory_perClassLoader(StAXUtils.java:306)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axiom.om.util.StAXUtils.getXMLInputFactory(StAXUtils.java:76)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axiom.om.util.StAXUtils.createXMLStreamReader(StAXUtils.java:131)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axis2.util.XMLUtils.toOM(XMLUtils.java:596)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axis2.util.XMLUtils.toOM(XMLUtils.java:581)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axis2.deployment.DescriptionBuilder.buildOM(DescriptionBuilder.java:97)
 17:46:25,124 ERROR [STDERR] at 
 org.apache.axis2.deployment.AxisConfigBuilder.populateConfig(AxisConfigBuilder.java:86)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.deployment.DeploymentEngine.populateAxisConfiguration(DeploymentEngine.java:641)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.deployment.FileSystemConfigurator.getAxisConfiguration(FileSystemConfigurator.java:116)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactor
 y.java:68)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContextFromFileSystem(Configuratio
 nContextFactory.java:184)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.client.ServiceClient.configureServiceClient(ServiceClient.java:150)
 17:46:25,140 ERROR [STDERR] at 
 org.apache.axis2.client.ServiceClient.init(ServiceClient.java:143)



 Regards

 Appasamy T





 --
 Paul Fremantle
 Co-Founder and CTO, WSO2
 Apache Synapse PMC Chair
 OASIS WS-RX TC Co-chair

 blog: http://pzf.fremantle.org
 p...@wso2.com

 Oxygenating the Web Service Platform, www.wso2.com




Re: MDB and Axis2

2008-08-05 Thread sumedha rubasinghe
Hi,
Unless you really need the MDB, I do not see any advantage of doing so. You
can easily listen to a topic using Axis2's JMS transport [1].

Is there a specific reason / application level constraint for you to
consider MDB to listen to the topic?
/sumedha

[1] http://ws.apache.org/axis2/1_4/jms-transport.html


On Tue, Aug 5, 2008 at 6:07 PM, [EMAIL PROTECTED] wrote:


 All,

 Anyone has any idea of how to integrate Axis2 with MDB? Here is our
 requirement:

 1. Post a message to a topic.
 2. A MDB will listen to that topic and will take appropriate actions (will
 need the classes in the aar file)

 Regards,
 Saurav Chatterjee
  --
 US IT DS Service Oriented Architecture (SOA) Development Team | *Saurav
 Chatterjee* [EMAIL PROTECTED] |  *PriceWaterhouseCoopers 
 LLP*http://www.pwc.com/| Office: +91-033-2341-3140 | Cell: +91-9830868384 | 
 | SOA Support:
 813-348-7600 |
 _
 The information transmitted is intended only for the person or entity to
 which it is addressed and may contain confidential and/or privileged
 material. Any review, retransmission, dissemination or other use of, or
 taking of any action in reliance upon, this information by persons or
 entities other than the intended recipient is prohibited. If you received
 this in error, please contact the sender and delete the material from any
 computer.


Re: Axis with XSLT

2008-07-29 Thread sumedha rubasinghe
Hi,
Data Services is a mechanism to expose relational database objects as web
services.
It will return data in your database object (eg. table) in XML format.

Checkout following tutorial @ http://wso2.org/library/2617 .
A collection of such tutorials can be found @ http://wso2.org/library/3183 .

/sumedha


On Tue, Jul 29, 2008 at 8:39 PM, samsam007 [EMAIL PROTECTED] wrote:


 Hi,

 I tried to build a AXIS service to return a recordset (from array or
 database) to an AXIS client.
 The client will use the following APIs to request the recordset from the
 AXIS service server:
 CreateCall() - SetTargetEndpointAddress(..) - SetOperationName(...) -
 call.invoke()

 Now, I am not sure how to build the AXIS service to return the recordset to
 the soap client.
 I know xslt can be used to interact between soap/axis service and client.
 Can anybody post an example about how tho use AXIS with XSLT to return
 record(xml data) to the client?

 Thanks
 S
 --
 View this message in context:
 http://www.nabble.com/Axis-with-XSLT-tp18714395p18714395.html
 Sent from the Axis - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




Re: [Axis2] Initialization

2008-07-29 Thread sumedha rubasinghe
Following example might be of help.

http://wso2.org/library/333

And you can find an example on latest axis2 distribution too. Inside
axis2-1.4/samples/servicelifecycle folder. README.txt located there is a
good starting point.

/sumedha



On Tue, Jul 29, 2008 at 10:47 PM, Sameera Jayasoma 
[EMAIL PROTECTED] wrote:

 On Tue, Jul 29, 2008 at 9:53 PM, David [EMAIL PROTECTED] wrote:

 Hi,

 I made my WS in Axis 2 and it's working very well, but I have one last
 think I would like to implement, I need to launch a method when I deploy my
 webservice, like an init phase where I'm loading some stuff.
 In Axis 1.4 I was using an InitServlet with load on startup option, so is
 it possible in Axis 2 when we use .aar deployed in /services ?


 Yes, there is a way to do this. Once you implement the
 org.apache.axis2.engine.ServiceLifeCycle interface in you service class, you
 will get two methods startup() and shutdown().

 public interface ServiceLifeCycle {

 /**
  * this will be called during the deployement time of the service.
 irrespective
  * of the service scope this method will be called
  */
 public void startUp(ConfigurationContext configctx, AxisService
 service);

 /**
  * this will be called during the system shut down time. irrespective
  * of the service scope this method will be called
  */
 public void shutDown(ConfigurationContext configctx, AxisService
 service);
 }


 Hope you got the answer.

 Regards
 Sameera Jayasoma
 WSO2 Inc.
 Oxygenating the Web Service Platform.
 http://wso2.org/

 blog: http://sameera-jayasoma.blogspot.com/

 http://www.flickr.com/photos/sameera-jayasoma



Re: Axis1.4 vs Axis2-1.4

2008-07-11 Thread sumedha rubasinghe
Hi Thamizhannal,
Visit  http://ws.apache.org/axis2/  read the section under topic Why
Apache Axis2:.

In a nutshell, axis2-1.x is a major re-write of axis-1.x (note the missing
'2')  with a new architecture.

Latest release is axis2-1.4 (http://ws.apache.org/axis2/1_4/contents.html).
Since your starting web services with Axis2, I recommend you to follow the
getting start guide @ http://ws.apache.org/axis2/1_4/quickstartguide.html .

/sumedha



*

*On Fri, Jul 11, 2008 at 8:24 PM, Thamizh [EMAIL PROTECTED] wrote:

 Hi All,

 I am new to AXIS web service development.

 Can you please let me what is the difference between axis1.4 vs axis2-1.4

 Regards,
 Thamizhannal P

 --
 Download prohibited? No problem. 
 CHAThttp://in.rd.yahoo.com/tagline_webmessenger_1/*http://in.messenger.yahoo.com/webmessengerpromo.phpfrom
  any browser, without download.


Re: printing request

2008-07-02 Thread sumedha rubasinghe
A tutorial on TCPMon can be found here[2].
/sumedha

[2] http://ws.apache.org/commons/tcpmon/tcpmontutorial.html


On Wed, Jul 2, 2008 at 1:04 PM, Charitha Kankanamge [EMAIL PROTECTED]
wrote:

 Hi,
 You can send your request through Apache tcpmon[1] and view the message
 flow.

 regards
 Charitha

 [1]http://ws.apache.org/commons/tcpmon/

 Rajendra Kumar Miryala wrote:

  Hi,


How can I print request xml for web-services?


I am using Axis2 1.3 framework for web-services implementation
 on glass fish v2 server.



 _

 M V Rajendra Kumar / **Capgemini India ***/* Hyderabad
 GE-UK
 Com1: +040-23125000-25072/ Mobile: 9959811162 www.capgemini.com 
 http://www.capgemini.com/
 #5,Software Units Layout,Madhapur,Hyderabad-82
 ***Together. Free your energies***
 _

 //Capgemini is a trading name used by the Capgemini Group of companies
 which includes Capgemini Country legal, a company registered in Country
 (number x) whose registered office is at insert head office address.//






 This message contains information that may be privileged or confidential
 and is the property of the Capgemini Group. It is intended only for the
 person to whom it is addressed. If you are not the intended recipient, you
 are not authorized to read, print, retain, copy, disseminate, distribute, or
 use this message or any part thereof. If you receive this message in error,
 please notify the sender immediately and delete all copies of this message.

 

 No virus found in this incoming message.
 Checked by AVG. Version: 7.5.524 / Virus Database: 270.4.3/1529 - Release
 Date: 7/1/2008 7:23 PM




 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




Re: Axis2 1.3 to Axis2 1.4

2008-06-27 Thread sumedha rubasinghe
Well... then how about your system classpath?
Open up a new command window and check what jars are in your classpath.

/sumedha

 rubasinghe a écrit :

 Hi,
 I tested axis2-1.4 war with java version 1.5.0_14  Tomcat 6.0.16 .o
 It works fine. So this must be due to an additional jar file in your
 system classpath.

 Try printing contents of classpath variable just before tomcat starts.
 axis2.war contains jaxb-api-2.1.jar file. There must be an older version
 of the same jar file in your classpath, which gets loaded before 2.1 jar.

 /sumedha




 On Fri, Jun 27, 2008 at 1:21 PM, Fabien Couvert [EMAIL PROTECTED]mailto:
 [EMAIL PROTECTED] wrote:

I use Jdk1.5.0-14

Did you think that is the problem ?

keith chapman a écrit :

Should be an issue with the JDK you are using not with Tomcat.
What is your JDK version?

Thanks,
Keith.

On Fri, Jun 27, 2008 at 12:02 PM, Fabien Couvert
[EMAIL PROTECTED] mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED] wrote:

   Thank you for your answer

   I did a mistake in the lib name ...

   But now I have another error, is there an incompatibility
between
   Axis2 1.4 and Tomcat 6.0.16 ?

   The error :
   Impossible to call remote service with url.
   Caused by: org.apache.axis2.AxisFault: java.lang.LinkageError:
   JAXB 2.0 API is being loaded from the bootstrap
classloader, but
   this RI (from

 jar:file:/D:/produits/Tomcat%206.0/webapps/axis2/WEB-INF/lib/jaxb-impl-2.1.6.jar!/com/sun/xml/bind/v2/model/impl/ModelBuilder.class)
   needs 2.1 API. Use the endorsed directory mechanism to place
   jaxb-api.jar in the bootstrap classloader. (See
   http://java.sun.com/j2se/1.5.0/docs/guide/standards/)

   Thank you

   sumedha rubasinghe a écrit :

   Hi,
   Do you have XmlSchema-1.4.2.jar in your classpath?

   /sumedha

   On Thu, Jun 26, 2008 at 5:46 PM, Fabien Couvert
   [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED]
   mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
   mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED] wrote:

  Hi all,

  I try to upgrade Axis2 to 1.4 version but I get this
exception
  when I try to createConfigurationContextFromFileSystem :

  Exception in thread main
java.lang.NoClassDefFoundError:
  org/apache/ws/commons/schema/resolver/URIResolver
at

  
 org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContextFromFileSystem(ConfigurationContextFactory.java:184)


  Anyone have an idea please ?


  -
  To unsubscribe, e-mail:
[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
   mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
  mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
   mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]

  For additional commands, e-mail:
   [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
  mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
   mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]





 -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
   mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
   For additional commands, e-mail:
[EMAIL PROTECTED] mailto:[EMAIL PROTECTED]
   mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]




--Keith Chapman
Senior Software Engineer
WSO2 Inc.
Oxygenating the Web Service Platform.
http://wso2.org/

blog: http://www.keith-chapman.org



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]




 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




Re: Axis2 return name

2008-06-26 Thread sumedha rubasinghe
AFAIK annotations is the only option for this. (i.e if your going through
axis2).

But you have the option of transforming the results from web service before
it reaching your C program.
For example you can transform following response,

ns:queryResponse xmlns:ns=http://foo.bar;
 return
bookIdAxis2 unleashed/bookId
price299.0/price
orderStatusconfirmed/orderStatus
 /return
/ns:queryResponse

Into following,

result xmlns:ns=http://foo.bar;
bookIdAxis2 unleashed/bookId
price299.0/price
orderStatusconfirmed/orderStatus
/result

using the XSLT given bellow.

xsl:stylesheet version=2.0 xmlns:ns=http://foo.bar; xmlns:xsl=
http://www.w3.org/1999/XSL/Transform; 
   xsl:output method=xml omit-xml-declaration=yes indent=yes/
   xsl:template match=//ns:queryResponse
   result
  xsl:for-each select=//ns:queryResponse/return
   xsl:for-each select=./*
xsl:variable name=element-name select=local-name(.)/
xsl:element name={$element-name}
xsl:value-of select=./
/xsl:element
   /xsl:for-each
  /xsl:for-each
   /result
   /xsl:template
/xsl:stylesheet



/sumedha



  Original Message 
 Subject:Re: Axis2 return name
 Date:   Wed, 25 Jun 2008 06:44:42 -0700 (PDT)
 From:   sdr [EMAIL PROTECTED]
 Reply-To:   axis-user@ws.apache.org
 To: axis-user@ws.apache.org
 References: [EMAIL PROTECTED] [EMAIL PROTECTED]
 



 Hi,

 Thanks for the response, but the solution you suggested is only valid for
 incoming parameters, not for responses.


 public class UssdIvrInterface {
   public Common12RingResponse Reload12Ring(Reload12RingRequest in) {
   Common12RingResponse out = new Common12RingResponse();
   out.setMsisdn(in.getMsisdn());
   out.setRequest_id(in.getRequest_id());
   out.setService_id(in.getService_id());
   out.setStatus(new Integer(1000));

   return out;
   }



 I have indeed an element name equal to in in my wsdl, but no element name
 equal to out.



 - xs:element name=Reload12Ring
 - xs:complexType
 - xs:sequence
  xs:element minOccurs=0 name=in nillable=true
 type=ns1:Reload12RingRequest /  /xs:sequence
  /xs:complexType
  /xs:element
 - xs:element name=Reload12RingResponse
 - xs:complexType
 - xs:sequence
  xs:element minOccurs=0 name=return nillable=true
 type=ns1:Common12RingResponse /  /xs:sequence
  /xs:complexType
  /xs:element
  /xs:schema



 Kr,
 Sdr.



 Charitha Kankanamge wrote:


 Hi,
 I think the answer for your question is explained here [1]

 [1] http://wso2.org/library/3743

 regards
 Charitha
 sdr wrote:

  Hi,

 I'm generating a wsdl out of code with following java code:

 public class EmbeddedAxis2Server {
   public static void main(String[] args) throws Exception {
   ConfigurationContext context =

 ConfigurationContextFactory.createConfigurationContextFromFileSystem(null,
 null);
   context.setContextRoot(lmpg-ws);

   AxisService service =
 AxisService.createService(UssdIvrInterface.class.getName(),
   context.getAxisConfiguration());
   context.getAxisConfiguration().addService(service);
 SimpleHTTPServer server = new SimpleHTTPServer(context,
 8080);
   server.start();
   }
 }

 The wsdl that is generated is as follows:


 - wsdl:types
 - xs:schema xmlns:ns=http://ws.apache.org/axis2;
 attributeFormDefault=qualified elementFormDefault=unqualified
 targetNamespace=http://ws.apache.org/axis2;
 - xs:element name=Register12Ring
 - xs:complexType
 - xs:sequence
  xs:element minOccurs=0 name=in nillable=true
 type=ns1:Register12RingRequest /  /xs:sequence
  /xs:complexType
  /xs:element
 - xs:element name=Register12RingResponse
 - xs:complexType
 - xs:sequence
  xs:element minOccurs=0 name=return nillable=true
 type=ns1:Common12RingResponse /  /xs:sequence
  /xs:complexType
  /xs:element
 - xs:element name=Reload12Ring
 - xs:complexType
 - xs:sequence
  xs:element minOccurs=0 name=in nillable=true
 type=ns1:Reload12RingRequest /  /xs:sequence
  /xs:complexType
  /xs:element
 - xs:element name=Reload12RingResponse
 ...etc


 Is there a possibility to change name=return into something else?  We

 have

 troubles creating a c++ client as return is a keyword in c++.  I'm not
 able to use annotations as I have to use java 1.4

 Kind regards,
 Sdr




 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




 --
 View this message in context:
 http://www.nabble.com/Axis2-return-name-tp18112183p18112853.html
 Sent from the Axis - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]






Re: Axis2 1.3 to Axis2 1.4

2008-06-26 Thread sumedha rubasinghe
Hi,
Do you have XmlSchema-1.4.2.jar in your classpath?

/sumedha

On Thu, Jun 26, 2008 at 5:46 PM, Fabien Couvert [EMAIL PROTECTED]
wrote:

 Hi all,

 I try to upgrade Axis2 to 1.4 version but I get this exception when I try
 to createConfigurationContextFromFileSystem :

 Exception in thread main java.lang.NoClassDefFoundError:
 org/apache/ws/commons/schema/resolver/URIResolver
   at
 org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContextFromFileSystem(ConfigurationContextFactory.java:184)


 Anyone have an idea please ?

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




Re: difference b/w bean mapping using SOAPBody

2008-03-15 Thread Sumedha Rubasinghe

Seetha Rama Krishna wrote:

Hi,
 i wanted to know how excatly the difference b/w calling a 
webservice using AXIS and SAAJ. 
Is there any extra features provided by SAAJ, apart from attachements.

Hi Seetha,
No, there aren't any extra features as such. It provides an alternative 
approach to call a web service (with or without attachments).


Actually this is how dev.java.net explains it.

The SOAP with Attachments API for Java^TM (SAAJ) 1.3 provides the API 
for creating and sending SOAP messages by means of the |javax.xml.soap| 
package. It is used for the SOAP messaging that goes on behind the 
scenes in JAX-RPC, and JAXR implementations. SOAP Handlers in JAX-WS use 
SAAJ APIs to access the SOAP Message.  Developers can also use it to 
write SOAP messaging applications directly instead of using 
JAX-RPC/JAX-WS. -

https://saaj.dev.java.net/source/browse/*checkout*/saaj/saaj-ri/docs/index.html

/sumedha

 
In SAAJ, we will call the webservice,like
 
 SOAPConnectionFactory connectionFactory = 
SOAPConnectionFactory.newInstance();

SOAPConnection connection = connectionFactory.createConnection();
MessageFactory messageFactory = MessageFactory.newInstance();
SOAPMessage message =messageFactory.createMessage();
SOAPBody body =message.getSOAPBody();
  SOAPFactory factory = SOAPFactory.newInstance();
 
String endPointURL = http://localhost:8081/axis/services/order;;
 
 
  SOAPMessage response =connection.call(message,endPointURL);

In Axis, we will call, like
 
GeneralItem gi = new GeneralItem();

  gi.setItem(snacks);
  gi.setQuantity(4);

LiquitItem lt = new LiquitItem();

lt.setQuantity(5);
lt.setType(Hot Drinks);
FoodItem fi = new FoodItem();
fi.setLt(lt);
  
  Item it = new Item();

  it.setFi(fi);
  it.setGi(gi);
  
  com.items.Order or = new com.items.Order();
 
 String endPointURL=http://localhost:8081/axis/services/order;;
 
 Service  service = new Service();

  Call call= (Call) service.createCall();
  QNameqn  = new QName( urn:Order, order );
 
 call.registerTypeMapping(com.items.Order.class, qn,
new 
org.apache.axis.encoding.ser.BeanSerializerFactory(com.items.Order.class, 
qn),   
new 
org.apache.axis.encoding.ser.BeanDeserializerFactory(com.items.Order.class, 
qn));
 
 call.setTargetEndpointAddress( new java.net.URL(endPointURL) );

call.setOperationName( new QName(Order, processOrder) );
call.addParameter( arg1, qn, ParameterMode.IN );
call.setReturnType( 
org.apache.axis.encoding.XMLType.XSD_STRING );

result =(String)call.invoke(new Object[] {it});
 
   In the above axis code, we are passing the bean, where 
as using SAAJ, we are constructing the SOAP Request using SOAP API.
 
 

 


*/Martin Gainty [EMAIL PROTECTED]/* wrote:

Didnt see anyone respond so i found this test harness from
org.apache.axis2.saaj.SoapMessageTest.java
 
try {

MessageFactory fac =
MessageFactory.newInstance(SOAPConstants.SOAP_1_2_PROTOCOL);
//MessageFactory fac = MessageFactory.newInstance();
SOAPMessage msg = fac.createMessage();
SOAPPart soapPart = msg.getSOAPPart();
SOAPEnvelope envelope = soapPart.getEnvelope();
SOAPBody body = envelope.getBody();
 
AttachmentPart ap;
 
//replace the fileName here with your attachment

String fileName = System.getProperty(basedir, .) +
/test-resources + File.separator +attach.xml;
 
InputStream inputStream = new FileInputStream(new

File(fileName));
ap = msg.createAttachmentPart(inputStream, text/xml);
DataHandler dh = new DataHandler(new
SAAJDataSource(inputStream, 1000, text/xml, true));
 
StringBuffer sb1 = copyToBuffer(dh.getInputStream());

assertNotNull(ap);
 
//Verify attachment part is not empty and contents are

correct
try {
Object o = ap.getContent();
InputStream is = null;
assertNotNull(o);
if (o instanceof StreamSource)
{
StreamSource ss = (StreamSource)o;
is = ss.getInputStream();
}
else
 {
fail(got object:  + o + , expected object:
javax.xml.transform.stream.StreamSource);
}
}
catch (Exception e)
{
fail(attachment has no content - unexpected);
}
}
catch (Exception e)
 {
fail(Exception:  + e);
}

HTH
Martin

Re: Can't Package Axis2 In EAR with Maven2

2007-12-13 Thread sumedha
Brandon,
This looks like mar plug-in is not being recognized inside your build
environment.
1. Leave out two projects having dependencies to Axis2.
2. Create a dummy project which just uses Axis2 MAR plug-in.
3. See if you can get EAR build run with this dummy project included as a
sub module.

/sumedha

 [INFO]
 
 [ERROR] BUILD ERROR
 [INFO]
 
 [INFO] Failed to initialize ear modules

 Embedded error: Unknown artifact type[mar]
 [INFO]
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [AXIS2] ClassPath problems in JBoss

2007-09-26 Thread sumedha rubasinghe

Hi,
The problem here is both Jboss  Axis have their own SAAJ Implementation.
What is the version of Jboss  Axis2 your using?
Do you intend to run other applications on this server as well?

You do not need to move several jars.The classes you need are located 
inside axis2-saaj-version.jar.


/sumedha

Lorenzo wrote:

Hi all,

i have this problem:

i deployed mi axis2 app on jboss into a .ear

myapp.ear
|- lib
|- mdb.jar
   |- META-INF
  |- manifest.mf
  |- ejb-jar.xml
  |- jboss.xml
|- web.war-- axis2
   |- META-INF
  |- manifest.mf
   |- WEB-INF
  |- modules
 |- mymodule.mar
  |- services
 |- myservice.aar
  |- conf
 |- axis2.xml
  |- web.xml


I tryed to get a org.apache.axis2.saaj.SOAPMessageImpl from a
MessageContext but i get a java.lang.ClassCastException because it use
MessageFactoryImpl of jboss instead of Axis2.saaj one so i get a
org.jboss.ws.soap.SOAPMessageImpl instead
org.apache.axis2.saaj.SOAPMessageImpl.

I can avoid this moving some axis2 lib from myapp.ear/lib to
myapp.ear/web.war/WEB-INF/lib (seems that there jars have higher
priority then others..) but seems that now Axis2 don't get libs
specified into manifest and i need to use the same libs used by mdb.jar


I hope i was clear :) 


Any suggestion is appreciate,
thx Lorenzo



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [Axis2] Problem Installing from Standard Binary Distribution

2007-07-31 Thread sumedha rubasinghe

Hi AJ,
Could you tell me what is the axis2 version your using?
I just tried this using Axis2 1.3-RC2 available from 
http://ws.apache.org/axis2/download.cgi  I could not generate the 
scenario your experiencing.


Please provide us more information on your environment.

/sumedha



AJ Coon wrote:

Hello,

I am new to Axis.  I am trying to get it installed under Tomcat 5.5.  
I am building the .war file using ant, and then copying into the 
webapps directory.  Immediately after I copy axis2.war into webapps, I 
see this in my logs:


== ../../logs/catalina.2007-07-30.log ==
Jul 30, 2007 8:25:20 PM 
org.apache.axis2.deployment.WarBasedAxisConfigurator getAxisConfiguration
SEVERE: java.security.AccessControlException: access denied ( 
java.lang.RuntimePermission createClassLoader): loading repository 
from classpath
Jul 30, 2007 8:25:21 PM org.apache.axis2.deployment.DeploymentEngine 
loadFromClassPath
INFO: Module validation failed: The system is attempting to engage a 
module that is not available: addressing
Jul 30, 2007 8:25:41 PM org.apache.catalina.startup.HostConfig 
checkResources

INFO: Undeploying context [/axis2]


Can someone please help me to resolve this?  I've read FAQ and User 
documentation and I cannot find a solution.




Thanks,
-aj



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [Axis2] Problem Installing from Standard Binary Distribution

2007-07-31 Thread sumedha rubasinghe

AJ Coon wrote:

Thanks!
 
I installed 1.3-RC2 and this issue was resolved.  Sorry for not trying 
that before.  I thought 1.2 was a stable release.

It is a stable version. We do lots of testing before doing a release.
But problems occur due to environmental issues that users have in their 
local machines
and sometimes due to issues related to Axis2. You can report these 
issues using our jira (https://issues.apache.org/jira)


Anyway congratulations for getting started with axis2 :-).


Thank you.
/sumedha

 
 
-aj


 
On 7/31/07, *keith chapman* [EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED] wrote:


In that case its better if you use the 1.3-RC2 release as you are
new to Axis2.

Thanks,
Keith.


On 7/31/07, *sumedha rubasinghe*  [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED] wrote:

Hi AJ,
Could you tell me what is the axis2 version your using?
I just tried this using Axis2 1.3-RC2 available from
http://ws.apache.org/axis2/download.cgi  I could not generate
the
scenario your experiencing.

Please provide us more information on your environment.

/sumedha



AJ Coon wrote:
 Hello,

 I am new to Axis.  I am trying to get it installed under
Tomcat 5.5.
 I am building the .war file using ant, and then copying into the
 webapps directory.  Immediately after I copy axis2.war into
webapps, I
 see this in my logs:

 == ../../logs/catalina.2007- 07-30.log ==
 Jul 30, 2007 8:25:20 PM
 org.apache.axis2.deployment.WarBasedAxisConfigurator
getAxisConfiguration
 SEVERE: java.security.AccessControlException: access denied (
 java.lang.RuntimePermission createClassLoader): loading
repository
 from classpath
 Jul 30, 2007 8:25:21 PM
org.apache.axis2.deployment.DeploymentEngine
 loadFromClassPath
 INFO: Module validation failed: The system is attempting to
engage a
 module that is not available: addressing
 Jul 30, 2007 8:25:41 PM org.apache.catalina.startup.HostConfig
 checkResources
 INFO: Undeploying context [/axis2]


 Can someone please help me to resolve this?  I've read FAQ
and User
 documentation and I cannot find a solution.



 Thanks,
 -aj


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]




-- 
Keith Chapman

WSO2 Inc.
Oxygen for Web Services Developers.
http://wso2.org/ 






-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Axis beginner2

2007-05-28 Thread sumedha rubasinghe

Hi,
Sipungora wrote:

Nobody want me to answer.

  
I replied to your previous mail, inquiring the version of Axis  tomcat 
version your using.

OK I ask it in other words.
What a versions of Tomcat, Axis and JSDK schould I take in order to be
assure, that their setup is without much ado?
  

Use following as your guideline.

http://ws.apache.org/axis2/1_2/installationguide.html




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Axis beginner

2007-05-27 Thread sumedha rubasinghe

Hi,
What is the version of Tomcat  Axis your using?


Sipungora wrote:

I have only newly deal with axis. And I have a problem at the installation.
I have copied xercesImpl.jar and all other jar-files for XML Parser in
TOMCAT\webapps\axis\WEB-INF\lib, but happyaxis.jsp shows me in Examining
Application Server, that XML ParserLocation is unknown.

Moreover I have the same Problem with JAXP.
What should I do? What could I wrong make?

In the axis installation instructions it is mentioned distribution directory
for xml- axis(Step 7:Testing). Where is this directory located?

Thank you very much beforehand.
  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: maven plugin for generating mar files

2007-05-18 Thread sumedha rubasinghe

Yes. There is...
What you need to have in pom.xml is something similar to following...

   plugin
   groupIdorg.apache.axis2/groupId
   artifactIdaxis2-mar-maven-plugin/artifactId
   versionSNAPSHOT/version
   extensionstrue/extensions

   configuration

includeDependenciesfalse/includeDependencies
   moduleXmlFilemodule.xml/moduleXmlFile
   /configuration
  /plugin

/sumedha


Jim Alateras wrote:
Is there a maven plugin for generated 'mar' archives? Can I just use 
the aar-plugin to do the job or maybe the assembly-plugin.


cheers
/jima

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: J2ME Client

2007-04-27 Thread sumedha rubasinghe

Hi Roberto,
Accessing web service from J2ME requires separate client library. Usual 
Axis client library is too heavy for this..

/sumedha

Roberto wrote:
Does anybody knows if there is something that I should pay special 
attention when I use a J2ME application to get a web service installed 
on Axis2? Coz I got a simple web service test installed that works 
properly if I contact via browser with 
localhost:8080/axis2/services/ServiceTest/getStringa but if I try with 
the emulator of J2ME when there is the invocation of the soapAction it 
give me back a java/lang/NullPointerException






-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Axis without SOAP

2007-03-22 Thread sumedha
Hi,
Following might interest you

http://ws.apache.org/axis2/1_1_1/rest-ws.html

http://webservices.xml.com/lpt/a/915

sumedha.


 Hi!

 I have got a special problem using AXIS and i need some help :)
 I would like to make a request without using SOAP envelope. Can i configue
 AXIS to send a request without including SOAP envelope?

 Thanks!
 Armando



 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Timeout setting in Axis2

2007-03-22 Thread sumedha
Hi Jipu,
Following[1] might help you.

[1].http://www.wso2.org/library/230

Read the Introduction section  then do a content search for 'TIMEOUT'. ;-)

/sumedha.


 Hello All,

 New man to the Axis2 community. How can I change the read timeout
 settings in Axis2?

 Many thanks,
 Jipu



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: integrate AXIS with web application

2007-03-22 Thread sumedha
Following article[1] might help you to achieve integration part.

[1] http://wso2.org/library/90

/sumedha


 hi everyone,

 I am very interested in Axis. However, I have no idea
 how to integrate it in my current project. Any help in
 this area will be appreciated.

 My current project is a web application that has one
 single Servlet. This servlet contain a hash of POJO
 (Plain Old Java Objects) called Commands or Services.
 My code look similar to this:

  HashMapString, Command Commands = new HashMap();

 Static {
 Commands.put(addUser, Factory.get ((addUser))
 Commands.put(deleteUser, Factory.get ((deleteUser))
 Commands.put(UpdateUser,Factory.get((UpdateUser))
 }


 In my service method of my servlet I will do the following:

  String CommandName = request.getParamter(Command);

  Commands.get(CommandName).do(request);


  Now my question is how do I integrate Axis with my
 application, I want to expose those Commands as Web
 services.

  Another issue is that some of those Commands require
 that the user login. so how does the user login using
 web services?

 Thank you in advance



 -
 Sucker-punch spam with award-winning protection.
  Try the free Yahoo! Mail Beta.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Axis2 JMS samples?

2007-03-22 Thread sumedha
Hi,
Try the following steps.(All these are mentioned in the url you mentioned,
but check  see if you have missed anything ;-) )

1.Download  start ActiveMQ from apache.(Do not change default ports)

2.Open AXIS2_HOME/conf/axis2.xml

3.Uncomment transport receiver part for JMS.
   i.e. section starting with...
transportReceiver name=jms


4.Uncomment line setting transport sender for JMS.
   i.e. line starting with
transportSender name=jms

5.Start Axis Server by running AXIS2_HOME/bin/axis2server.(bat|sh)
(If you get a binding exception,change the port of axis server)

6.Type 'jconsole' on a new command/shell window. (i.e. assuming your using
jdk 1.5  JAVA_HOME/bin is in your path)

7.This will open up a GUI.

8.On left hand side of the UI check for jms queues created with service
names you have deployed under axis2.

9.Once the queues are there(this means the link between the axis server 
JMS server is established),change you client code with following.

String url =
jms:/ABCDE?transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactoryjava.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactoryjava.naming.provider.url=tcp://localhost:61616;

//Replace ABCDE with you service name.


//and add following property to client
options.setProperty(Constants.Configuration.TRANSPORT_URL, url);


10.Add ACTIVEMQ_HOME/lib/*.jar to classpath  run the client.



Good luck! Happy messaging with JMS ;-)

/sumedha



 Are there any samples for JMS with Axis2. Also can some one point some
 useful
 links on this topic. I could not find anything other than the
 http://ws.apache.org/axis2/1_1_1/jms-transport.html Axis2/Java - JMS
 transport.

 Thanks
 Nishant
 --
 View this message in context:
 http://www.nabble.com/Axis2-JMS-samples--tf3449408.html#a9621016
 Sent from the Axis - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[Axis2] Jibx version for build

2007-03-18 Thread sumedha rubasinghe

Hi devs,
The value for jibx version in etc/project.properties is 1.1.4-SNAPSHOT. 
But with this value, the maven1 Hobuild stops giving following error.


The build cannot continue because of the following unsatisfied dependencies:
jibx-bind-1.1.4-SNAPSHOT.jar
jibx-run-1.1.4-SNAPSHOT.jar


I tried changing this to following  got the build running.
jibx.version=SNAPSHOT

Hope this helps someone
/sumedha


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: SimpleAxisServer on axis2

2007-03-13 Thread sumedha rubasinghe

public class EmbeddSimpleAxisServer {
   public static void main(String[] args) {
   String[] args2 = new 
String[]{-repo,/home/abc/axis2-SNAPSHOT/repository};

   try {
   SimpleAxis2Server.main(args2);
   } catch (Exception e) {
   e.printStackTrace();
   }
   }
}

I do not know how correct this is.. ;-). But it works..

/sumedha




Charles Ambrose wrote:

thanks! will check on it :)

On 3/12/07, *Thilina Gunarathne* [EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED] wrote:


Hi,
I'm not aware of such a tutorial.. But almost all the axis2
integration tests use the simple axis server.. They may be good
reference for you... You can find a simple example at here [1].

Thilina

[1]http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/json/test/org/apache/axis2/json/JSONIntegrationTest.java?view=markup

On 3/9/07, Charles Ambrose [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED] wrote:


 Hi!

 Does anybody have a tutorial on how to created a Embedded
SimpleAxisServer
 on Axis2? The axis2 website does not have one.

 Thanks!

 Jonathan



--
Thilina Gunarathne
WSO2, Inc.; http://www.wso2.com/
Home page: http://webservices.apache.org/~thilina/
http://webservices.apache.org/%7Ethilina/
Blog: http://thilinag.blogspot.com/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: SOAP Attachment not working

2007-03-11 Thread sumedha rubasinghe

Hi,
I tried out the scenario using service  client you provided. With the 
latest source from axis2 trunk  axiom I was able to run the program 
without any complains.


But I had to do following changes to your code.

Client:
// Name bn = soapFactory.createName(getTermSheetFile, ns1, 
http://termsheet.ws.starr.ubs.com/xsd;);
  Name bn = soapFactory.createName(getTermSheetFile, ns1, 
http://termsheet.ws.ssk.com/xsd;);


// Name p = soapFactory.createName(p1, ns1, 
http://termsheet.ws.starr.ubs.com/xsd;);
   Name p = soapFactory.createName(p1, ns1, 
http://termsheet.ws.ssk.com/xsd;);


service.xml:
   messageReceiver  
class=org.apache.axis2.rpc.receivers.RPCMessageReceiver /

!--
   messageReceiver  
class=org.apache.axis2.rpc.receivers.RPCInOutAsyncMessageReceiver /

--

But I did not get the attachment returned to the client end. Looks like 
there is some bug in the POJO implementation when returning a 
DataHandler. Will log a jira after further investigation.


/sumedha


[EMAIL PROTECTED] wrote:

Hi Folks,


I am trying to create a service which servers files. Client is successfully 
making call to service and infact
service is executed successfully. But i am getting exception on server some where after service execution. 
Pls let me know what's the possible cause.


Env: Running Axis2-1.1.1 on tomcat.

Mar 9, 2007 10:00:04 AM 
org.apache.axis2.rpc.receivers.RPCInOutAsyncMessageReceiver invokeBusinessLogic
SEVERE: Exception occurred while trying to invoke service method 
getTermSheetFile
java.lang.NullPointerException
at 
org.apache.axis2.databinding.utils.BeanUtil.getPullParser(BeanUtil.java:197)
at 
org.apache.axis2.rpc.receivers.RPCUtil.processResponse(RPCUtil.java:90)
at 
org.apache.axis2.rpc.receivers.RPCUtil.processResponse(RPCUtil.java:192)
at 
org.apache.axis2.rpc.receivers.RPCInOutAsyncMessageReceiver.invokeBusinessLogic(RPCInOutAsyncMessageReceiver.java:121)
at 
org.apache.axis2.receivers.AbstractInOutAsyncMessageReceiver$2.run(AbstractInOutAsyncMessageReceiver.java:61)
at 
edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:665)
at 
edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:690)
at java.lang.Thread.run(Unknown Source)
Exception in thread Axis2 Task java.lang.NullPointerException
at 
org.apache.coyote.http11.InternalOutputBuffer.realWriteBytes(InternalOutputBuffer.java:746)
at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:433)
at 
org.apache.coyote.http11.InternalOutputBuffer.flush(InternalOutputBuffer.java:304)
at 
org.apache.coyote.http11.Http11Processor.action(Http11Processor.java:991)
at org.apache.coyote.Response.action(Response.java:182)
at 
org.apache.catalina.connector.OutputBuffer.doFlush(OutputBuffer.java:322)
at 
org.apache.catalina.connector.OutputBuffer.flush(OutputBuffer.java:293)
at 
org.apache.catalina.connector.CoyoteOutputStream.flush(CoyoteOutputStream.java:97)
at java.io.BufferedOutputStream.flush(Unknown Source)
at com.ctc.wstx.io.UTF8Writer.flush(UTF8Writer.java:99)
at com.ctc.wstx.sw.BufferingXmlWriter.flush(BufferingXmlWriter.java:184)
at com.ctc.wstx.sw.BaseStreamWriter.flush(BaseStreamWriter.java:311)
at 
org.apache.axiom.om.impl.MTOMXMLStreamWriter.flush(MTOMXMLStreamWriter.java:115)
at 
org.apache.axiom.om.impl.llom.OMNodeImpl.serializeAndConsume(OMNodeImpl.java:420)
at 
org.apache.axis2.transport.http.CommonsHTTPTransportSender.sendUsingOutputStream(CommonsHTTPTransportSender.java:276)
at 
org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:208)
at org.apache.axis2.engine.AxisEngine.sendFault(AxisEngine.java:714)
at 
org.apache.axis2.receivers.AbstractInOutAsyncMessageReceiver$1.handleFault(AbstractInOutAsyncMessageReceiver.java:51)
at 
org.apache.axis2.receivers.AbstractInOutAsyncMessageReceiver$2.run(AbstractInOutAsyncMessageReceiver.java:68)
at 
edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:665)
at 
edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:690)
at java.lang.Thread.run(Unknown Source)



 server-output.txt  TermsheetFileService.java  TermSheetFileClient.java  services.xml 
Thanks all


cheers,
sigirisetti
  



Mar 9, 2007 9:57:31 AM org.apache.catalina.core.AprLifecycleListener 
lifecycleEvent
INFO: The Apache Tomcat Native library which allows optimal performance in 
production environments was not found on the java.library.path: C:\Program 
Files\Java\jre1.5.0_05\bin;.;C:\WINNT\system32;C:\WINNT;C:\Program 
Files\WRQ\Reflection;C:\WINNT

Re: Axis2 deploy on Tomcat

2007-03-05 Thread sumedha rubasinghe

Hi Antonio,
Are you referring to the message The Apache Tomcat Native library which 
allows optimal performance in production environments was not found on 
the java.library.path.. as the problem??
If so, this is not an error. This tells you that Apache Portable Runtime 
is not available in your classpath. Since this library is only 
responsible for production level performance  scalability you can 
safely ignore this.


However if your curious, you will find tomcat-native.tar.gz inside 
TOMCAT-HOME/bin.  Extract  compile this to generate native libraries.


/sumedha


[EMAIL PROTECTED] wrote:
Thank you Charitha. Now i can read 
http://127.0.0.1:8080/axis2page


I still read the proble m starting tomcat...
i putted  
%PATH%;%JAVA_HOME%\bin;%ANT_HOME%\bin;%CATALINA_HOME%\bin;%AXIS2_HOME%\bin


as value of PATH variable.
Is it correct if i have defined correctly the home variables  of the programs?
Thank a lot however!
Antonio








-- Initial Header ---

From  : Charitha Kankanamge [EMAIL PROTECTED]
To  : axis-user@ws.apache.org
Cc  : 
Date  : Mon, 05 Mar 2007 16:44:15 +0530

Subject : Re: Axis2 deploy on Tomcat







  
Hi 

Which axis2 version did you use for deployment? Can you please try with 
Axis2-1.1.1 or latest nightly build? I was able to deploy axis2 nightly 
on tomcat 6.0.10 without getting this error.


regards
Charitha





--
Mutui da 200.000 euro? Tassi ridotti da 4.25% solo per richieste online. 
Mutuionline.it
http://click.libero.it/mutuionline5mar07



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [AXIS2] SOAPMessageImp

2007-03-02 Thread sumedha rubasinghe

Lorenzo,
SAAJ can be used to create a SOAP message  send this message to a web 
service endpoint.
You need to have a code similar to following in your client end. (which 
I believe you already have).


|SOAPConnectionFactory soapConnFactory = SOAPConnectionFactory.newInstance();
SOAPConnection connection = soapConnFactory.createConnection();
|

|SOAPMessage reply = connection.call(soapmessage, endpointUrl);

|

In this case SAAJ is responsible for creating a valid soap message  
transferring it to the endpoint.


Hence you cannot retrieve SAAJ class instances @ axis service level.

/sumedha



Lorenzo wrote:

Hi,

Sry for so many mails, but i'm really stuck in my work ;_; .

I need to retrieve a org.apache.axis2.saaj.SOAPMessageImpl in a
service, so starting from a getCurrentMessageContext... how can i do
this? (there is a way?)

Thx for any help,

Lorenzo


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [AXIS2] MessageContext to SOAPMessage

2007-03-01 Thread sumedha rubasinghe

Hi Lorenzo;
Go through the example located @ axis2-home/samples/soapwithattachments
It demonstrates how to use SwA  to send attachments.

/sumedha

Lorenzo wrote:

Hi,

i have a problem... I have a org.apache.axis2.context.MessageContext and
to work on attachments i should use the SAAJ api, but how can i obtain
an org.apache.axis2.saaj.SOAPMessageImpl from a MessageContext?

Thx!


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Help describing fault

2007-02-05 Thread sumedha rubasinghe

Hi Javier,
I am not quite sure what you meant  by ' describing the following two 
fault messages with WSDL + SOAP1.1'.


But what I gathered from the replies you got is,

1. You have called a web service ( possibly an authentication service) 
with some credentials
2. For this request you got a response (fault response)  saying the user 
name you entered is incorrect.


/sumedha



Javier Kohen wrote:

Hi,

I need help describing the following two fault messages with WSDL + SOAP
1.1. The messages come from a third party webservice running on .Net and
there's no chance of modifying them in any way.

I'm using Axis2 1.1.1 with XmlBeans binding, so it would be a plus if
the result could be handled with it, at least on the client side.

First message:
soap:Fault
  faultcodesoap:Client/faultcode
  faultstringThe user specified is invalid SignInName:
xxx/faultstring
  faultactorhttp://.../MyAction/faultactor
  detail
errorcode xmlns=mynamespaceInvalidUser/errorcode
errorstring xmlns=mynamespaceThe user specified is invalid
SignInName: xxx/errorstring
additionalDetails
  originalExceptionErrorMessageThe user specified is invalid
SignInName: xxx/originalExceptionErrorMessage
/additionalDetails
  /detail
/soap:Fault

Second message:
soap:Fault
  faultcodeAuthenticationFailed/faultcode
  faultstringAuthentication Failed/faultstring
  detail
NewChallenge xmlns=mynamespace2a_cookie/NewChallenge
  /detail
/soap:Fault

If you can't or are not willing to answer this question here, I'd be
grateful if you could at least point me to another list or forum where I
can get more help with this.

Thanks for your time,
  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[Axis2] Re: Proxy setting when using AXIS2's SAAJ APIs

2007-01-29 Thread sumedha rubasinghe

Hi yogen;
I think this has nothing to do with SAAJ. It is just a matter of making 
you java application (which accesses network resources) to be able to 
communicate via network. i.e. by setting


System.setProperty( https.proxyHost, host);
System.setProperty( https.proxyPort, port);

in your client.And there is another way to set this from command options 
to java command, which brings the same result.


The call method in SOAPConnection has the following signature.
   public SOAPMessage call(SOAPMessage request, Object endpoint) throws 
SOAPException

-
Here the endpoint can be any of java.lang.String,java.net.URL, 
javax.xml.messaging.URLEndpoint.


Thanks
/sumedha



Yadav, Yogendra (IT) wrote:

Hi,
Sun's SAAJ implementation reads proxy settings from system properties.
System.setProperty( https.proxyHost, host);
System.setProperty( https.proxyPort, port);
 
I want to use proxy using SAAJ APIs provided by AXIS2. In AXIS2's 
implementation SOAPConnectionImpl.java the Options object is created 
new. The call() method does not provide an ability to set proxy. 
Anybody knows how to do proxy settings while using SAAJ APIs in AXIS2 ?
 
Appreciate it.

[thanx
-yogen
 
 



NOTICE: If received in error, please destroy and notify sender. Sender 
does not intend to waive confidentiality or privilege. Use of this 
email is prohibited when received in error.





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Debugging Axis2 in Tomcat

2007-01-24 Thread sumedha rubasinghe

Hi;
Following article [1] provides step-by-step guide on how to debug a web 
service using either eclipse or idea.


[1] https://www.wso2.org/library/225

/sumedha




Ho, Wen Yue wrote:

Hi,

Any pointers on how to debug Axis2 WebService Application in Tomcat?

Sysdeo turns out to be not working anymore,... with the following error
message:
ERROR: JDWP unable to get necessary JVMTI capabilities.
[debugInit.c,L279]

Thanks in advance,
wen



NOTICE OF CONFIDENTIALITY
This communication including any information transmitted with it is 
intended only for the use of the addressees and is confidential. 
If you are not an intended recipient or responsible for delivering 
the message to an intended recipient, any review, disclosure, 
conversion to hard copy, dissemination, reproduction or other use 
of any part of this communication is strictly prohibited, as is the 
taking or omitting of any action in reliance upon this communication. 
If you receive this communication in error or without authorization 
please notify us immediately by return e-mail or otherwise and 
permanently delete the entire communication from any computer, 
disk drive, or other storage medium.


If the above disclaimer is not properly readable, it can be found at 
www.td.com/legal
   
AVERTISSEMENT DE CONFIDENTIALITE   
Ce courriel, ainsi que tout renseignement ci-inclus, destiné uniquement 
aux destinataires susmentionnés,  est confidentiel.  Si vous 
n’êtes pas le destinataire prévu ou un agent responsable de la 
livraison de ce courriel, tout examen, divulgation, copie, impression, 
reproduction, distribution, ou autre utilisation d’une partie de ce 
courriel est strictement interdit de même que toute intervention ou 
abstraction à cet égard.  Si vous avez reçu ce message par erreur ou 
sans autorisation, veuillez en aviser immédiatement l’expéditeur par 
retour de courriel ou par un autre moyen et supprimer immédiatement 
cette communication entière de tout système électronique.


Si l'avis de non-responsabilité ci-dessus n'est pas lisible, vous 
pouvez le consulter à www.td.com/francais/legale
  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Question about AXIS and tomcat

2006-12-30 Thread sumedha
Hi Frank;
Have you gone through the Axis2 User Guide? I think it would give you more
insight into Axis2. Please find some of my humble thoughts bellow.

 Hi, All,

 I have a general question about tomcat and AXIS. Is
 there any relation or execlusion between the two?

Not that I know of. You can deploy the axis2.war on any other servlet
container (eg.Geronimo)  work as you would work on Tomcat. But there can
be some version compatibility issues.But it works with geronimo for sure.

 I am currently starting to work on a web service
 application which the web server is hosted on TOMCAT
 and the client is using AXIS to parse WSDL and making
 SOAP/http calls et cetera. My web service application
 basically intends to expose some functionalities of
 another application through web serivce (so there is a
 server component), it also try to use thrid party web
 services to integrate with my other applications's
 functionality (so there is a client component).
 The server side is really simple from architectural point
 of view, it basically just a servlet respoding to
 SOAP/http calls (like publish WSDL and handling
 operations as defined in the generated WSDL).

 Now I am trying to expand and enhance the web service
 application, but as a web service novice, I would like
 to seek some expert advices here.

 (1) Can I use AXIS on the server side? can AXIS
 replace the servlet?

Yes you can. Are you using this servlet to anything other than serving
SOAP calls?

 (2) On the client side, currently I am just able to
 make SOAP/http calls. I know AXIS2 offers lots of new
 features. Which of those are more important than
 others from web service perspective? I am trying to
 enhance my web service client so that I can better
 consume third party web services like Google adwords
 et cetera.


Generate stubs for these web services (eg.Google adwords) using Axis2
wsdl2java tool  you can access these services through those stubs.


 (3) Is there such a thing called platform web service?
 What are the essential features of it? Maybe I am
 asking wrong question here, but I am trying to
 understand what I can do to enhance my server side
 compoent, which currently is just a servlet
 structually.

 Well, enough for now, any feedback is really
 appreciated.

 Thanks much in advance.

 Frank

 __
 Do You Yahoo!?
 Tired of spam?  Yahoo! Mail has the best spam protection around
 http://mail.yahoo.com

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: General Axis questions

2006-12-12 Thread sumedha rubasinghe

Hi Ernie;

Jboss has seperate web service implementation  it depends on the 
Application server version too.


Jboss 3.2.x had a one called Jboss.NET  versions bellow 4.0.4 used an 
implementation called JbossWS4EE.  Both of these used modified version 
of Axis. Latest Jboss versions (above 4.0.4) uses another implementation 
called JbossWS.


If you want to use Axis2 on Jboss 4.0.0, just try installing axis.war on 
jboss  deploying web services as explained in Axis2 User manual. 
(http://ws.apache.org/axis2/1_1/installationguide.html#servlet_container)


/sumedha



Ernie Ho wrote:

 Hi Axis folks,

   I'm new to Axis.  And I have the following questions:

1) what version of Axis does Jboss (particulary 4.0) support?

2) I used Axis 1.4 to generate Java classes from my WSDLs.  I re-peated the 
process using Axis 1.1 (since Jboss doesn't seem to support some of the 
libraries my classes need),  however,  I observe the intersting behavior that 
the classes generated by Axis 1.1 seem to make refernces to libaries existing 
only in Axis 1.2 +.   Any ideas?


Thanks,

Ernie 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [Axis2 v1.1]

2006-12-12 Thread sumedha rubasinghe

Hi Rodrigo;

Only errors.properties is avaibale in the binary  this is not a bug. 


If you want to get error messages localized to a locale of you choice, you need to 
add a message file with the format errors_LOCALE.properties to the classpath.

If a message bundle is not available for the locale of user, the application 
(Rampart in this case) should pick the messages from the default bundle (i.e. 
errors.properties) rather than complaining of the missing bundle. This is what 
I suggested here [1].

Just go through [1]  you can get an idea of what to include in your jira.

[1] http://marc.theaimsgroup.com/?l=axis-devm=116583812603458w=2

Thanks,
/sumedha







Rodrigo Ruiz wrote:

Hi Ruchith, Sumedha,

I am searching for some information to write a JIRA report for this problem.

Looking at the source code of RampartException, I have found that:

* It uses the standard java.util.ResourceBundle class
* Only errors.properties is present in the org.apache.rampart package

So, the code should fail for all locales, or for none! There should be
no difference at all for German locales!

The only guesses I can make are:

* The Axis2 binaries Sumedha uses do not include errors.properties
* A extrange ClassLoader issue prevents ResourceBundle from finding the
file.

The first case would be a building/packaging problem, probably very easy
to fix. The second case might be a really difficult one.

Sumedha, could you please verify that
org.apache.rampart.errors.properties is not missing in your binaries?

If it is present, a full stacktrace would be required for tracking the
problem, as the real source will be in a totally different location.

Best regards,
Rodrigo Ruiz

Ruchith Fernando wrote:
  

This seems to be a bug in Rampart. Sumedha also pointed this out here [1].

Please file a JIRA.

Thanks,
Ruchith

[1] http://marc.theaimsgroup.com/?l=axis-devm=116583812603458w=2

On 12/11/06, Rodrigo Ruiz [EMAIL PROTECTED] wrote:


Hi,

I thought ResourceBundles were smart enough to use the default bundle
when a specific one was not found; so, if errors.properties is present
in the classpath, why does Rampart complain at all?

Best regards,
Rodrigo Ruiz

Ruchith Fernando wrote:
  

Hi,

Since your locale is DE you you will have to have
errors_de.properties file available in the classpath in the
org.apache.rampart package.

Simply copy the content of this file [1] into the errors_de.properties
file. Optionally you can translate messages :-)

Thanks,
Ruchith

[1]



https://svn.apache.org/repos/asf/webservices/axis2/branches/java/1_1/modules/security/src/org/apache/rampart/errors.properties

  

On 12/11/06, Daniel Wehrle [EMAIL PROTECTED] wrote:


Hi,

I tried to do a little Axis2 sample on my German Windows. I connect
  

to a
  

.Net  web service using wssecurity,
so I use rampart for the UsernameToken.
But by sending a message I got an stack trace ending with:

Caused by: _java.lang.RuntimeException_: Can't find bundle for base
  

name
  

org.apache.rampart.errors, locale de_DE
at

  

org.apache.rampart.RampartException.clinit(_RampartException.java:36_)
  

What I am doing wrong?


Thanks
-- Daniel Wehrle


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  


--
---
GRID SYSTEMS, S.A. Rodrigo Ruiz
Parc Bit - Edificio 17 Research Coordinator
07121 Palma de Mallorca[EMAIL PROTECTED]
Baleares - Spain   Tel: +34 971 435 085
http://www.gridsystems.com/Fax: +34 971 435 082
---

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  



  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]