Restful Services with Axis 2

2009-06-23 Thread Suchitha Koneru (sukoneru)
Hello Axis 2 Users ,
   Has anybody tried out developing Restful Services
using Axis 2 ?
 I have followed the instructions as given in the link
http://www.webmonkey.com/tutorial/RESTful_Web_Services_with_Apache_Axis2
http://www.webmonkey.com/tutorial/RESTful_Web_Services_with_Apache_Axis
2 
 
I get an EPR not found error when I try to access an end point in a
restful manner using thr url 
 
http://localhost:8080/Axis2Demo/services/UserMgmtServiceImpl/User/1 
 
ERROR] The service cannot be found for the endpoint reference (EPR)
/Axis2Demo/services/User/1

org.apache.axis2.AxisFault: The service cannot be found for the endpoint
reference (EPR) /Axis2Demo/services/User/1

The wsdl has the following http bindings 

wsdl2:binding name=UserMgmtServiceImplHttpBinding
interface=tns:ServiceInterface whttp:methodDefault=GET
type=http://www.w3.org/ns/wsdl/http;
wsdl2:fault ref=tns:Exception/
  
   wsdl2:operation ref=tns:getAllUsers whttp:location=Users
whttp:method=GET /

wsdl2:operation ref=tns:createUser whttp:location=User
whttp:method=POST
wsdl2:outfault ref=tns:Exception/
/wsdl2:operation
   
   wsdl2:operation ref=tns:getUser whttp:location=User/{userId}
whttp:method=GET
wsdl2:outfault ref=tns:Exception/
/wsdl2:operation
   
   wsdl2:operation ref=tns:updateUser whttp:location=User
whttp:method=PUT
wsdl2:outfault ref=tns:Exception/
/wsdl2:operation

/wsdl2:binding

We are evaluating Axis 2 and for us choose it over other webservice
offerings, it is very important that we should be able to develop
Restful Services with Axis 2. I have googled this up ,but could not find
a solution.

Could you please provide any pointers in debugging this issue ? 

Appreciate your time and effort

thank you,

Suchitha.

 

 

 



how to open a JIRA issue for Axis 2 Version 1.5

2009-06-23 Thread Suchitha Koneru (sukoneru)
Hello Axis Users,
 I think I have found a bug in Axis2 Version 1.5 in
regard to Restful Services. I would like to open a bug for the same.
Could you please provide information on the procedure to be followed for
opening bugs
 
thank you,
Suchitha.


RE: how to open a JIRA issue for Axis 2 Version 1.5

2009-06-23 Thread Suchitha Koneru (sukoneru)

 Thanks Deepal for the prompt response. Do we need to verify if it is
bug before opening a JIRA issue? Anyways briefly specifying the issue
here for your reference

In Axis 2 Version 1.5 .Even when we add the parameter below to
services.xml,the customized/modified wsdl cannot be fetched using the
url http://localhost:8080/Axis2Demo/services/UserMgmtServiceImpl?wsdl2

parameter name=useOriginalwsdl locked=truetrue/parameter 

We will need wsdl2.0 for restful services to work, and in this scenario
we get wsdl2.0 without any of the httpbindings which were added to the
modified wsdl. 

Thanks,
Suchitha.

-Original Message-
From: Deepal jayasinghe [mailto:deep...@gmail.com] 
Sent: Tuesday, June 23, 2009 6:16 PM
To: axis-user@ws.apache.org
Subject: Re: how to open a JIRA issue for Axis 2 Version 1.5

Go to
https://issues.apache.org/jira/browse/AXIS2

And then create a new issues,

Thanks,
Deepal
 Hello Axis Users,
  I think I have found a bug in Axis2 Version 1.5 in 
 regard to Restful Services. I would like to open a bug for the same.
 Could you please provide information on the procedure to be followed 
 for opening bugs
  
 thank you,
 Suchitha.


--
Thank you!


http://blogs.deepal.org
http://deepal.org



package to namespace mapping

2009-06-22 Thread Suchitha Koneru (sukoneru)
Hello All , 
I am using axis 2 version 1.4.  The command line tool (java 2 wsdl)
is used with the following options.
 
java2wsdl  -wv 2.0 -cp ./classes -of UsermgmtService.wsdl -sn
UserMgmtServiceImpl  -p2n com.cisco.webservices.beans,usermgmt
com.cisco.webservices.impl,usermgmt
com.cisco.webservices.interfaces,usermgmt -cn
com.cisco.webservices.impl.UserMgmtServiceImpl
 
I am trying to associate the same namespace to all the packages used by
the usermgmt service. I have tried the option  -p2n all,usermgt as
well, but it did not work either.
 
 The generated wsdl  is attached. In this wsdl the namespace usermgmt
is not used at all. The src code UserMgmtServiceImpl.java is also
attached
 
Is this a bug in Axis or is my usage not correct ? Could you please help
me out
 
thank you,
suchitha
 
 


UsermgmtService.wsdl
Description: UsermgmtService.wsdl


UserMgmtServiceImpl.java
Description: UserMgmtServiceImpl.java


Restful Service issues

2009-06-22 Thread Suchitha Koneru (sukoneru)
Hello All,
   I have implemented a user management restful service as
per the tutorial given in 
http://www.webmonkey.com/tutorial/RESTful_Web_Services_with_Apache_Axis2
http://www.webmonkey.com/tutorial/RESTful_Web_Services_with_Apache_Axis
2 .
Configuration details
Tomcat server 5.5
Java 1.6
Axis 2 1.4 version
 
 As per the instructions in the tutorial I have manually tweaked the
wsdl2.0 file to accomplish the following 
a) add whttp location and methods
b) Move all the beans/exceptions/complextypes under one namespace
 
The modifed wsdl is placed in the service archive. However, I have
landed into the following issues 
 
1)  when I access the url  
http://localhost:8080/Axis2Demo/services/UserMgmtServiceImpl?wsdl2 I do
not get 
the modified wsdl
 
2) when I try to access an existing user using the url  
http://localhost:8080/Axis2Demo/services/UserMgmtServiceImpl/User/1 , It
leads to End point reference not found error  as shown below.
ERROR] The service cannot be found for the endpoint reference (EPR)
/Axis2Demo/services/User/1

org.apache.axis2.AxisFault: The service cannot be found for the endpoint
reference (EPR) /Axis2Demo/services/User/1

 
I have attached the java code and wsdl2.0 for ready reference. I can
also provide additional details if needed. 
 
Do we need to explicitly pass the manually tweaked wsdl to services.xml
? I did not find any element/parameter in services.xml which can be used
for this purpose
 
 
Could you please let me know as to what could be the issue here? 
 
 
Thank you , 
Suchitha.


UserMgmtServiceImpl.java
Description: UserMgmtServiceImpl.java


UserMgmtServiceImpl.wsdl
Description: UserMgmtServiceImpl.wsdl


Axis 2 version 1.5 (Restful Services)

2009-06-17 Thread Suchitha Koneru (sukoneru)
Hello All , 
 Does Axis2  Version 1.5 have any enhancements/differences
in regard to developing  Restful services when compared to its
predecessor (Axis 2 Version 1.4)? is there a link which talks about
these enhancements
 
When Axis 2  Version 1.4 is used  for developing Restful Services using
WSDL 2.0 , we have to manually tweak the WSDL for name space changes. Do
we still need to make these name space changes manually in Axis 2
Version  1.5?
 
Could you please let me know
 
thank you,
suchitha
 


Java doc for Axis2 Version 1.4

2009-06-17 Thread Suchitha Koneru (sukoneru)
Hello Axis Users , 
   The link for Axis 2 Version 1.4 java doc is broken
(http://ws.apache.org/1_4/api/index.html
http://ws.apache.org/1_4/api/index.html ). Could you please forward me
to the correct link.
thanks,
Suchitha.


RE: Axis 2.0 support for Restful services

2009-05-28 Thread Suchitha Koneru (sukoneru)
Thank you Sagara and Chinmoy for your response. I have gone through the links 
which are helpful.
Hello Axis Developers.
I have observed that HTTP Post is done through OMElement (which is custom class 
in axis).  This is specified in the link 
http://ws.apache.org/axis2/1_1/rest-ws.html.
If I want to post simple xml Payload to Axis2 Service in a RESTFUL manner from 
a .NET or a Flex client(cross platform client) How do I do it? I cannot use 
OMElement here as It is not present in .NET framework or Flex. 
Any pointers are greatly appreciated. All of us use web services for cross 
platform communication, so we might stumble upon this issue sooner or later.

Thanks,
suchitha



-Original Message-
From: Sagara Gunathunga [mailto:sagara.gunathu...@gmail.com] 
Sent: Wednesday, May 27, 2009 11:29 PM
To: axis-user@ws.apache.org
Subject: Re: Axis 2.0 support for Restful services

Hi Suchitha,
Axis2 Supported for REST from its early releases ,you can refer following links 
[1] [2] for more details ,but at the moment Axis2 does not supports for JAX-RS 
(JSR 311) annotation based RESTFUL service model.

[1] - http://wso2.org/blog/keith/958
[2]- http://wso2.org/library/175

Thanks ,

On Thu, May 28, 2009 at 9:45 AM, Chinmoy Chakraborty cch...@gmail.com wrote:
 try this: http://ws.apache.org/axis2/0_94/rest-ws.html

 Chinmoy

 On Thu, May 28, 2009 at 3:39 AM, Suchitha Koneru (sukoneru) 
 sukon...@cisco.com wrote:

 Hello all ,
   Does Axis 2.0 support JAX-RS and JSR 331 ? Could you 
 please provide information in regard to the support provided by Axis 
 2.0 for developing RESTFUL services.
 thanks,
 suchitha.




--
Sagara Gunathunga

Blog - http://ssagara.blogspot.com
Web - http://sagaras.awardspace.com/


RE: Axis 2.0 support for Restful services

2009-05-28 Thread Suchitha Koneru (sukoneru)
Thanks Andreas for the clarification. So we can post any xml payload in a 
restful manner to  axis 2 webservice  from any webservice client. Will Axis 2 
web service engine treat the request as restful request and send the response 
as xml?

Thanks,
Suchitha.
-Original Message-
From: Andreas Veithen [mailto:andreas.veit...@gmail.com] 
Sent: Thursday, May 28, 2009 2:43 PM
To: axis-user@ws.apache.org
Subject: Re: Axis 2.0 support for Restful services

OMElement is Axis2's internal representation of an XML element. Cross platform 
communication has nothing to do with how the wire format is represented 
internally.

Andreas

On Thu, May 28, 2009 at 23:06, Suchitha Koneru (sukoneru) sukon...@cisco.com 
wrote:
 Thank you Sagara and Chinmoy for your response. I have gone through the links 
 which are helpful.
 Hello Axis Developers.
 I have observed that HTTP Post is done through OMElement (which is 
 custom class in axis).  This is specified in the link 
 http://ws.apache.org/axis2/1_1/rest-ws.html.
 If I want to post simple xml Payload to Axis2 Service in a RESTFUL manner 
 from a .NET or a Flex client(cross platform client) How do I do it? I cannot 
 use OMElement here as It is not present in .NET framework or Flex.
 Any pointers are greatly appreciated. All of us use web services for cross 
 platform communication, so we might stumble upon this issue sooner or later.

 Thanks,
 suchitha



 -Original Message-
 From: Sagara Gunathunga [mailto:sagara.gunathu...@gmail.com]
 Sent: Wednesday, May 27, 2009 11:29 PM
 To: axis-user@ws.apache.org
 Subject: Re: Axis 2.0 support for Restful services

 Hi Suchitha,
 Axis2 Supported for REST from its early releases ,you can refer following 
 links [1] [2] for more details ,but at the moment Axis2 does not supports for 
 JAX-RS (JSR 311) annotation based RESTFUL service model.

 [1] - http://wso2.org/blog/keith/958
 [2]- http://wso2.org/library/175

 Thanks ,

 On Thu, May 28, 2009 at 9:45 AM, Chinmoy Chakraborty cch...@gmail.com wrote:
 try this: http://ws.apache.org/axis2/0_94/rest-ws.html

 Chinmoy

 On Thu, May 28, 2009 at 3:39 AM, Suchitha Koneru (sukoneru) 
 sukon...@cisco.com wrote:

 Hello all ,
   Does Axis 2.0 support JAX-RS and JSR 331 ? Could you 
 please provide information in regard to the support provided by Axis 
 2.0 for developing RESTFUL services.
 thanks,
 suchitha.




 --
 Sagara Gunathunga

 Blog - http://ssagara.blogspot.com
 Web - http://sagaras.awardspace.com/



Axis 2.0 support for Restful services

2009-05-27 Thread Suchitha Koneru (sukoneru)
Hello all , 
  Does Axis 2.0 support JAX-RS and JSR 331 ? Could you
please provide information in regard to the support provided by Axis 2.0
for developing RESTFUL services. 
thanks,
suchitha.


WS - Reliable Messaging

2009-05-01 Thread Suchitha Koneru (sukoneru)
Hello Axis Users , 
   Axis 1.4  and Axis 2.0 both the
implementations support WS - Reliable Messaging. I am trying to get an
idea as to what is improved/different in Axis 2.0 when compared to Axis
1.4 in regard to WS - Reliable Messaging. I tried looking up this
information online , but could not get any useful pointers.
 
Thank you,
suchitha.