Some quick Axis2C help required

2008-11-03 Thread ramesh Gopal
Hi,

I am new to Axis2C forum.
I am working on Web-Services project using Axis2C framework. Infact, the fi=
rst time I am working on Web-Services.

I have written a skeleton which will read thru an xml request and return an=
xml response.

Sample xml request:
---

operation
in11/in1
in22/in2
/operation

My sample code :


if (node) { --- This is the entire xml
parent_node =3D axiom_node_get_first_element(node, env); --- Here, I though=
I will get operation as the first element, but I get in11/in1 ...

If this is wrong pls point out the exact function that I ought to be using.

{
if (!parent_node)
{ // throw error;
}
request_node =3D axiom_node_get_first_child(parent_node, env);
if (!request_node)
{ // throw error;
}
if (request_node  axiom_node_get_node_type(request_node, env) =3D=3D AXIO=
M_TEXT)
{ // Get value of TEXT --- Here we get value 1
}
}
sibling_node =3D axiom_node_get_next_sibling(parent_node, env); --- Here I =
get in22/in2, which is a sibling to in11/in1

if (!sibling_node) { // throw error ; }
request_node =3D axiom_node_get_first_child(sibling_node, env);
if (!request_node)
{ // throw error;
}
if (request_node  axiom_node_get_node_type(request_node, env) =3D=3D AXIO=
M_TEXT)
{ // Get value of TEXT --- Here we get value 2
}=20
}


I am running into some issues


Below is some error which I get :
-

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1208951888 (LWP 19071)]
axiom_node_free_detached_subtree (om_node=3D0x8927758, env=3D0x8920e60)
at om_node.c:105
105 next_sibling =3D child_node-next_sibling;

#0 axiom_node_free_detached_subtree (om_node=3D0x81d9758, env=3D0x81d2e60)
at om_node.c:105
#1 0x006005a2 in axiom_node_free_detached_subtree (om_node=3D0x81d96d0,=20
env=3D0x81d2e60) at om_node.c:106
#2 0x006005a2 in axiom_node_free_detached_subtree (om_node=3D0x81d9528,=20
env=3D0x81d2e60) at om_node.c:106
#3 0x006005a2 in axiom_node_free_detached_subtree (om_node=3D0x81d9478,=20
env=3D0x81d2e60) at om_node.c:106
#4 0x006005a2 in axiom_node_free_detached_subtree (om_node=3D0x81d9198,=20
env=3D0x81d2e60) at om_node.c:106
#5 0x0060026e in axiom_document_free (document=3D0x81d50b8, env=3D0x81d2e60=
)
at om_document.c:87
#6 0x00607b6e in axiom_stax_builder_free (om_builder=3D0x81d5010, env=3D0x8=
1d2e60)
at om_stax_builder.c:897
#7 0x0060e7ad in axiom_soap_builder_free (soap_builder=3D0x81d50d8,=20
env=3D0x81d2e60) at soap_builder.c:188
#8 0x0060dd25 in axiom_soap_envelope_free (soap_envelope=3D0x81d9338,=20
env=3D0x81d2e60) at soap_envelope.c:178
#9 0x0806b2be in axis2_msg_ctx_free (msg_ctx=3D0x81d45f8, env=3D0x81d2e60)
at msg_ctx.c:410
#10 0x00c60b43 in axis2_http_worker_process_request (http_worker=3D0x81d0d3=
8,=20
env=3D0x81d2e60, svr_conn=3D0x81d2e80, simple_request=3D0x81d2f48)
at http_worker.c:1952

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1208378448 (LWP 18971)]
axiom_node_create (env=3D0x20202020) at om_node.c:75
75 node =3D (axiom_node_t *) AXIS2_MALLOC(env-allocator, sizeof(axiom_node=
_t));

#0 axiom_node_create (env=3D0x20202020) at om_node.c:75
#1 0x00f250fa in axiom_element_create (env=3D0x20202020, parent=3D0x0,=20
localname=3D0x4e9f8c outparam0, ns=3D0x0, node=3D0xb7f98f30) at om_elemen=
t.c:78
#2 0x004e9a0f in build_res_text_response ()
from ..//services/ws_test_demo/libws_test_demo.so
#3 0x004e99ac in axis2_skel_ws_test_demo_test_demo ()
from ..//services/ws_test_demo/libws_test_demo.so
#4 0x20202020 in ?? ()
#5 0x20202020 in ?? ()
#6 0x20202020 in ?? ()
#7 0xb7f99000 in ?? ()
#8 0x004e9b62 in axis2_svc_skel_ws_test_demo_invoke ()
from ..//services/ws_test_demo/libws_test_demo.so


Pls let me know, if I am missing something ...

Also, pls let me know if you need more info.
I need some help on an urgent basis.

Rgds,
Ramesh


  Add more friends to your messenger and enjoy! Go to 
http://messenger.yahoo.com/invite/


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



Re: Some quick Axis2C help required

2008-11-03 Thread Uthaiyashankar

Hi Ramesh,

See the comments.



Sample xml request:
---

operation
in11/in1
in22/in2
/operation

My sample code :


if (node) { --- This is the entire xml
parent_node =3D axiom_node_get_first_element(node, env); --- Here, I though=
I will get operation as the first element, but I get in11/in1 ...
  


You have to do axiom_node_get_data_element to get operation as the 
element. When you do axiom_node_get_first_element, it will return first 
child whose type is om element.




If this is wrong pls point out the exact function that I ought to be using.

{
if (!parent_node)
{ // throw error;
}
request_node =3D axiom_node_get_first_child(parent_node, env);
if (!request_node)
{ // throw error;
}
if (request_node  axiom_node_get_node_type(request_node, env) =3D=3D AXIO=
M_TEXT)
{ // Get value of TEXT --- Here we get value 1
}
}
sibling_node =3D axiom_node_get_next_sibling(parent_node, env); --- Here I =
get in22/in2, which is a sibling to in11/in1

if (!sibling_node) { // throw error ; }
request_node =3D axiom_node_get_first_child(sibling_node, env);
if (!request_node)
{ // throw error;
}
if (request_node  axiom_node_get_node_type(request_node, env) =3D=3D AXIO=
M_TEXT)
{ // Get value of TEXT --- Here we get value 2
}=20
}


I am running into some issues
  


First error is caused by axiom_node_free_detached_subtree, which I 
could not find in the code you have sent. Can you send the correct code 
which causes these errors?


Regards,
Shankar



Below is some error which I get :
-

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1208951888 (LWP 19071)]
axiom_node_free_detached_subtree (om_node=3D0x8927758, env=3D0x8920e60)
at om_node.c:105
105 next_sibling =3D child_node-next_sibling;

#0 axiom_node_free_detached_subtree (om_node=3D0x81d9758, env=3D0x81d2e60)
at om_node.c:105
#1 0x006005a2 in axiom_node_free_detached_subtree (om_node=3D0x81d96d0,=20
env=3D0x81d2e60) at om_node.c:106
#2 0x006005a2 in axiom_node_free_detached_subtree (om_node=3D0x81d9528,=20
env=3D0x81d2e60) at om_node.c:106
#3 0x006005a2 in axiom_node_free_detached_subtree (om_node=3D0x81d9478,=20
env=3D0x81d2e60) at om_node.c:106
#4 0x006005a2 in axiom_node_free_detached_subtree (om_node=3D0x81d9198,=20
env=3D0x81d2e60) at om_node.c:106
#5 0x0060026e in axiom_document_free (document=3D0x81d50b8, env=3D0x81d2e60=
)
at om_document.c:87
#6 0x00607b6e in axiom_stax_builder_free (om_builder=3D0x81d5010, env=3D0x8=
1d2e60)
at om_stax_builder.c:897
#7 0x0060e7ad in axiom_soap_builder_free (soap_builder=3D0x81d50d8,=20
env=3D0x81d2e60) at soap_builder.c:188
#8 0x0060dd25 in axiom_soap_envelope_free (soap_envelope=3D0x81d9338,=20
env=3D0x81d2e60) at soap_envelope.c:178
#9 0x0806b2be in axis2_msg_ctx_free (msg_ctx=3D0x81d45f8, env=3D0x81d2e60)
at msg_ctx.c:410
#10 0x00c60b43 in axis2_http_worker_process_request (http_worker=3D0x81d0d3=
8,=20
env=3D0x81d2e60, svr_conn=3D0x81d2e80, simple_request=3D0x81d2f48)
at http_worker.c:1952

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1208378448 (LWP 18971)]
axiom_node_create (env=3D0x20202020) at om_node.c:75
75 node =3D (axiom_node_t *) AXIS2_MALLOC(env-allocator, sizeof(axiom_node=
_t));

#0 axiom_node_create (env=3D0x20202020) at om_node.c:75
#1 0x00f250fa in axiom_element_create (env=3D0x20202020, parent=3D0x0,=20
localname=3D0x4e9f8c outparam0, ns=3D0x0, node=3D0xb7f98f30) at om_elemen=
t.c:78
#2 0x004e9a0f in build_res_text_response ()
from ..//services/ws_test_demo/libws_test_demo.so
#3 0x004e99ac in axis2_skel_ws_test_demo_test_demo ()
from ..//services/ws_test_demo/libws_test_demo.so
#4 0x20202020 in ?? ()
#5 0x20202020 in ?? ()
#6 0x20202020 in ?? ()
#7 0xb7f99000 in ?? ()
#8 0x004e9b62 in axis2_svc_skel_ws_test_demo_invoke ()
from ..//services/ws_test_demo/libws_test_demo.so


Pls let me know, if I am missing something ...

Also, pls let me know if you need more info.
I need some help on an urgent basis.

Rgds,
Ramesh


  Add more friends to your messenger and enjoy! Go to 
http://messenger.yahoo.com/invite/


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



  



--
S.Uthaiyashankar
Software Architect
WSO2 Inc. 
http://wso2.com/ - The Open Source SOA Company 



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



axis2 - eclipse web service wizard error

2008-11-03 Thread Yoav Naveh
Hello,

When I use the eclipse (GUI) wizard to generate code from my wsdl file
(right clicking on the wsdl file, choosing Web Services and then Generate
Java bean Skeleton) when I press the next button and get to the Axis2 Web
Service Skeleton Java Bean Configuration screen the service name, port name
and any other field (except databinding which is set to ADB) appears empty.
Pressing Next (or Finish) generates the error message below

Two notes:
1. using the command prompt wsdl2java script works.
2. using the GUI wizard on a different WSDL file works. I could not find any
difference between the files (e.g. missing fields) other than the amount of
functions and the use of custom object types.

Any idea anyone?

Thanks!
Yoav

-
Exception occurred during code generation for the WSDL  : null
java.lang.ArrayIndexOutOfBoundsException: 68
at
org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.visitAllFiles(ClassLoad
ingUtil.java:114)
at
org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.visitAllFiles(ClassLoad
ingUtil.java:110)
at
org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.visitAllFiles(ClassLoad
ingUtil.java:110)
at
org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.visitAllFiles(ClassLoad
ingUtil.java:110)
at
org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.getAxis2Libs(ClassLoadi
ngUtil.java:99)
at
org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.init(ClassLoadingUtil.j
ava:50)
at
org.eclipse.jst.ws.axis2.creation.core.command.Axis2WSDL2JavaCommand.execute
(Axis2WSDL2JavaCommand.java:99)
at
org.eclipse.wst.command.internal.env.core.fragment.CommandFragmentEngine.run
Command(CommandFragmentEngine.java:419)
at
org.eclipse.wst.command.internal.env.core.fragment.CommandFragmentEngine.vis
itTop(CommandFragmentEngine.java:359)
at
org.eclipse.wst.command.internal.env.core.fragment.CommandFragmentEngine.mov
eForwardToNextStop(CommandFragmentEngine.java:254)
at
org.eclipse.wst.command.internal.env.ui.widgets.SimpleCommandEngineManager$6
.run(SimpleCommandEngineManager.java:294)
at
org.eclipse.jface.operation.ModalContext.runInCurrentThread(ModalContext.jav
a:458)
at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:366)
at org.eclipse.jface.wizard.WizardDialog.run(WizardDialog.java:934)
at
org.eclipse.wst.command.internal.env.ui.widgets.SimpleCommandEngineManager.r
unForwardToNextStop(SimpleCommandEngineManager.java:264)
at
org.eclipse.wst.command.internal.env.ui.widgets.WizardPageManager.runForward
ToNextStop(WizardPageManager.java:91)
at
org.eclipse.wst.command.internal.env.ui.widgets.WizardPageManager.getNextPag
e(WizardPageManager.java:154)
at
org.eclipse.wst.command.internal.env.ui.widgets.SimpleWizardPage.getNextPage
(SimpleWizardPage.java:136)
at
org.eclipse.jface.wizard.WizardDialog.nextPressed(WizardDialog.java:813)
at
org.eclipse.jface.wizard.WizardDialog.buttonPressed(WizardDialog.java:369)
at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:624)
at
org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:228)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3823)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3422)
at org.eclipse.jface.window.Window.runEventLoop(Window.java:825)
at org.eclipse.jface.window.Window.open(Window.java:801)
at
org.eclipse.ui.internal.handlers.WizardHandler$New.executeHandler(WizardHand
ler.java:253)
at
org.eclipse.ui.internal.handlers.WizardHandler.execute(WizardHandler.java:27
3)
at
org.eclipse.ui.internal.handlers.HandlerProxy.execute(HandlerProxy.java:281)
at org.eclipse.core.commands.Command.executeWithChecks(Command.java:476)
at
org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(Parameteriz
edCommand.java:508)
at
org.eclipse.ui.internal.handlers.HandlerService.executeCommand(HandlerServic
e.java:169)
at
org.eclipse.ui.internal.handlers.SlaveHandlerService.executeCommand(SlaveHan
dlerService.java:247)
at
org.eclipse.ui.internal.actions.CommandAction.runWithEvent(CommandAction.jav
a:157)
at
org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(Action
ContributionItem.java:583)
at
org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionI
tem.java:500)
at
org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContribu
tionItem.java:411)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3823)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3422)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2382)
at 

Issue in WSDL2Java Generation

2008-11-03 Thread Meenakshisundaram, Pattabiraman

Hi,




I have problem in using the generated stub as I am getting compilation error 
(param0 not defined) as shown below. I also understand that many others have 
asked but I could not see any solution.
   // add the children only if the 
parameter is not null
if (param0!=null){

I am attaching the wsdl with this mail. Please note that I checked for WS-I 
compliance using SoapScope product and it complained only about the header and 
rest are fine.


Please note that I had to rewrite this wsdl as it was using SOAP-ENC and 
XmlBeans was not generating the array elements as expected.

Could anyone provide me the directions to resolve this?

Thanks






SentrySOAP_new.dll.wsdl
Description: SentrySOAP_new.dll.wsdl
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

[AXIS2] Problem with HTTPS transport

2008-11-03 Thread Sagara Gunathunga
Hi,
We use Axis2-1.4 within a Spring application , and we have a requirement to
expose web service only for HTTPS transport. So I did the following
procedure .

1.) Enable the transportReceiver name=https . in axis2.xml file .
(Initially I got an error but once I add HttpCore and HttpCore -nio  as
Maven dependencies it solved.)

2.) Then add transports transporthttps/transport /transports in to
service.xml file .

We have configured a JBOSS server for  SSL  certificates and it works fine
for web application , but when it deploy web service I got following error
message .

org.apache.axis2.deployment.DeploymentException: Service [ PayfoneService]
is trying to expose in a transport : transports
transporthttps/transport
   /transports and which is not available in Axis2
at
org.apache.axis2.deployment.ServiceGroupBuilder.populateServiceGroup(ServiceGroupBuilder.java:106)
at
org.apache.axis2.deployment.repository.util.ArchiveReader.buildServiceGroup(ArchiveReader.java:110)
at
org.apache.axis2.deployment.repository.util.ArchiveReader.processServiceGroup(ArchiveReader.java:179)
at
org.apache.axis2.deployment.ServiceDeployer.deploy(ServiceDeployer.java:81)



In our development environment we use Jetty embedded server  with M2 and we
got same exception with Jetty too,
Is there any way to solve  this with Axis 2 without using security module
(Rampart)..?


Thanks ,


Sagara Gunathunga

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


Re: axis2 - eclipse web service wizard error

2008-11-03 Thread Lahiru Sandakith Gallege
Hi Yoav,

This is surely due to a issue ..

I would be very happy if you can log an issue either on Apache Axis2[1]
under tools or Eclipse WTP[2] under web services or both. Please mention the
version combinations that you are using on this scenario. (Axis2 version,
Eclipse WTP version etc.. ) on  Please attach the wsdl file also if
possible.

Thanks
Lahiru Sandakith

[1] http://issues.apache.org/jira/browse/AXIS2
[2]https://bugs.eclipse.org/bugs/

On Mon, Nov 3, 2008 at 3:35 AM, Yoav Naveh [EMAIL PROTECTED] wrote:

 Hello,

 When I use the eclipse (GUI) wizard to generate code from my wsdl file
 (right clicking on the wsdl file, choosing Web Services and then Generate
 Java bean Skeleton) when I press the next button and get to the Axis2 Web
 Service Skeleton Java Bean Configuration screen the service name, port name
 and any other field (except databinding which is set to ADB) appears empty.
 Pressing Next (or Finish) generates the error message below

 Two notes:
 1. using the command prompt wsdl2java script works.
 2. using the GUI wizard on a different WSDL file works. I could not find
 any
 difference between the files (e.g. missing fields) other than the amount of
 functions and the use of custom object types.

 Any idea anyone?

 Thanks!
 Yoav

 -
 Exception occurred during code generation for the WSDL  : null
java.lang.ArrayIndexOutOfBoundsException: 68
at

 org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.visitAllFiles(ClassLoad
 ingUtil.java:114)
at

 org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.visitAllFiles(ClassLoad
 ingUtil.java:110)
at

 org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.visitAllFiles(ClassLoad
 ingUtil.java:110)
at

 org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.visitAllFiles(ClassLoad
 ingUtil.java:110)
at

 org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.getAxis2Libs(ClassLoadi
 ngUtil.java:99)
at

 org.eclipse.jst.ws.axis2.core.utils.ClassLoadingUtil.init(ClassLoadingUtil.j
 ava:50)
at

 org.eclipse.jst.ws.axis2.creation.core.command.Axis2WSDL2JavaCommand.execute
 (Axis2WSDL2JavaCommand.java:99)
at

 org.eclipse.wst.command.internal.env.core.fragment.CommandFragmentEngine.run
 Command(CommandFragmentEngine.java:419)
at

 org.eclipse.wst.command.internal.env.core.fragment.CommandFragmentEngine.vis
 itTop(CommandFragmentEngine.java:359)
at

 org.eclipse.wst.command.internal.env.core.fragment.CommandFragmentEngine.mov
 eForwardToNextStop(CommandFragmentEngine.java:254)
at

 org.eclipse.wst.command.internal.env.ui.widgets.SimpleCommandEngineManager$6
 .run(SimpleCommandEngineManager.java:294)
at

 org.eclipse.jface.operation.ModalContext.runInCurrentThread(ModalContext.jav
 a:458)
at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:366)
at org.eclipse.jface.wizard.WizardDialog.run(WizardDialog.java:934)
at

 org.eclipse.wst.command.internal.env.ui.widgets.SimpleCommandEngineManager.r
 unForwardToNextStop(SimpleCommandEngineManager.java:264)
at

 org.eclipse.wst.command.internal.env.ui.widgets.WizardPageManager.runForward
 ToNextStop(WizardPageManager.java:91)
at

 org.eclipse.wst.command.internal.env.ui.widgets.WizardPageManager.getNextPag
 e(WizardPageManager.java:154)
at

 org.eclipse.wst.command.internal.env.ui.widgets.SimpleWizardPage.getNextPage
 (SimpleWizardPage.java:136)
at
 org.eclipse.jface.wizard.WizardDialog.nextPressed(WizardDialog.java:813)
at
 org.eclipse.jface.wizard.WizardDialog.buttonPressed(WizardDialog.java:369)
at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:624)
at
 org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:228)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3823)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3422)
at org.eclipse.jface.window.Window.runEventLoop(Window.java:825)
at org.eclipse.jface.window.Window.open(Window.java:801)
at

 org.eclipse.ui.internal.handlers.WizardHandler$New.executeHandler(WizardHand
 ler.java:253)
at

 org.eclipse.ui.internal.handlers.WizardHandler.execute(WizardHandler.java:27
 3)
at

 org.eclipse.ui.internal.handlers.HandlerProxy.execute(HandlerProxy.java:281)
at org.eclipse.core.commands.Command.executeWithChecks(Command.java:476)
at

 org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(Parameteriz
 edCommand.java:508)
at

 org.eclipse.ui.internal.handlers.HandlerService.executeCommand(HandlerServic
 e.java:169)
at

 org.eclipse.ui.internal.handlers.SlaveHandlerService.executeCommand(SlaveHan
 dlerService.java:247)
at

 org.eclipse.ui.internal.actions.CommandAction.runWithEvent(CommandAction.jav
 a:157)
at

 org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(Action
 

GZIP Response not work on Axis2

2008-11-03 Thread juliocest

Hi everybody!

I made an application that send attachments on soap message using SWA and
MTOM. The client and server works properly. Now, I am trying to use GZIP in
order to compress/decompress SOAP messages.

My Service code:

public OMElement downloadFileSWA(OMElement element) throws Exception {
FileDataSource binaryDataSource;
DataHandler binaryDataHandler;
String vectorFileType[] =
{file10KB,file100KB,file1MB,file10MB,file100MB};

// Checking if the resources folder is available
File file =  new File(filePath);
if (!file.isDirectory() || !file.exists()){
throw new AxisFault(File not available in the service 
provider...);
}

// Obtain the request (incoming) from the MessageContext as 
follows
MessageContext inMessageContext =
MessageContext.getCurrentMessageContext();

// Obtain the operation context from the request message context
OperationContext operationContext =
inMessageContext.getOperationContext();

// Obtain the response (outgoing) message context from the 
operation
context
MessageContext outMessageContext =
operationContext.getMessageContext(WSDLConstants.MESSAGE_LABEL_OUT_VALUE);

outMessageContext.setProperty(HTTPConstants.MC_GZIP_RESPONSE, 
true);
outMessageContext.setProperty(HTTPConstants.MC_ACCEPT_GZIP, 
true);

// Get the first element from the received message
String firstElem = element.getFirstElement().getText();
OMElement result = null;

for (int i = 0; i  vectorFileType.length; i++) {
if (vectorFileType[i].equalsIgnoreCase(firstElem)) {
binaryDataSource = new FileDataSource(filePath 
+File.separator+
vectorFileType[i]);
binaryDataHandler = new 
DataHandler(binaryDataSource);
// Add the created data handler as an 
attachment to the outgoing
message.
String binaryID = 
outMessageContext.addAttachment(binaryDataHandler);
result = 
buildDownloadFileSWAEnvelope(vectorFileType[i],binaryID);
break;
}
}   
return result;  
}


My Client code:

public void donwloadBinarySWA(String binaryName) throws Exception {

System.out.println(Download Binary with SWA);
Options options = new Options(); 
options.setProperty(HTTPConstants.MC_GZIP_REQUEST,
Boolean.TRUE);
options.setProperty(HTTPConstants.MC_GZIP_RESPONSE, 
Boolean.TRUE);  
 
ServiceClient sender = new ServiceClient();
sender.setOptions(options);
OperationClient mepClient =
sender.createClient(ServiceClient.ANON_OUT_IN_OP);

MessageContext mc = new MessageContext();
SOAPEnvelope env = buildEnvelopeDownloadBinarySWA(binaryName);
mc.setEnvelope(env);

mepClient.addMessageContext(mc);
mepClient.execute(true);

// Get the message context for the response
MessageContext response =
mepClient.getMessageContext(WSDLConstants.MESSAGE_LABEL_IN_VALUE);
SOAPBody body = response.getEnvelope().getBody();
OMElement element = body.getFirstChildWithName(new
QName(http://service.sample/xsd;, donwloadResponse));

if (element != null) {
processDownloadBinarySWA(response, element);
} else {
throw new Exception(Malformed response.);
}
}

I am also using TCPMon to monitor all soap messages that are sent to my
service. What I can see is that all requests are compressed with GZIP but
responses are not. My tests are being made using both Axis2 1.3 (as a
server) and Tomcat 6.0.18 with this options in server.xml:

   port=8080 protocol=HTTP/1.1
   connectionTimeout=2
   redirectPort=8443
   compression=on
   compressionMinSize=2048
   noCompressionUserAgents=gozilla, traviata
   compressableMimeType=text/html,text/xml

Both in Axis2 and Tomcat the responses are not compressed.

Is it a bug on Axis2?

Someone had the same problem?

I hope some help.

Thanks.

Julio Cezar Estrella (São Carlos - SP - Brazil)

-- 
View this message in context: 
http://www.nabble.com/GZIP-Response-not-work-on-Axis2-tp20304607p20304607.html
Sent from the 

Re: GZIP Response not work on Axis2

2008-11-03 Thread Davanum Srinivas
did you edit tomcat server.xml?
http://www.cubicleman.com/2007/04/06/enabling-gzip-compression-with-tomcat-and-flex/

thanks,
dims

On Mon, Nov 3, 2008 at 10:20 AM, juliocest [EMAIL PROTECTED] wrote:

 Hi everybody!

 I made an application that send attachments on soap message using SWA and
 MTOM. The client and server works properly. Now, I am trying to use GZIP in
 order to compress/decompress SOAP messages.

 My Service code:

public OMElement downloadFileSWA(OMElement element) throws Exception {
FileDataSource binaryDataSource;
DataHandler binaryDataHandler;
String vectorFileType[] =
 {file10KB,file100KB,file1MB,file10MB,file100MB};

// Checking if the resources folder is available
File file =  new File(filePath);
if (!file.isDirectory() || !file.exists()){
throw new AxisFault(File not available in the service 
 provider...);
}

// Obtain the request (incoming) from the MessageContext as 
 follows
MessageContext inMessageContext =
 MessageContext.getCurrentMessageContext();

// Obtain the operation context from the request message 
 context
OperationContext operationContext =
 inMessageContext.getOperationContext();

// Obtain the response (outgoing) message context from the 
 operation
 context
MessageContext outMessageContext =
 operationContext.getMessageContext(WSDLConstants.MESSAGE_LABEL_OUT_VALUE);

outMessageContext.setProperty(HTTPConstants.MC_GZIP_RESPONSE, 
 true);
outMessageContext.setProperty(HTTPConstants.MC_ACCEPT_GZIP, 
 true);

// Get the first element from the received message
String firstElem = element.getFirstElement().getText();
OMElement result = null;

for (int i = 0; i  vectorFileType.length; i++) {
if (vectorFileType[i].equalsIgnoreCase(firstElem)) {
binaryDataSource = new FileDataSource(filePath 
 +File.separator+
 vectorFileType[i]);
binaryDataHandler = new 
 DataHandler(binaryDataSource);
// Add the created data handler as an 
 attachment to the outgoing
 message.
String binaryID = 
 outMessageContext.addAttachment(binaryDataHandler);
result = 
 buildDownloadFileSWAEnvelope(vectorFileType[i],binaryID);
break;
}
}
return result;
}


 My Client code:

public void donwloadBinarySWA(String binaryName) throws Exception {

System.out.println(Download Binary with SWA);
Options options = new Options();
options.setProperty(HTTPConstants.MC_GZIP_REQUEST,
 Boolean.TRUE);
options.setProperty(HTTPConstants.MC_GZIP_RESPONSE, 
 Boolean.TRUE);

ServiceClient sender = new ServiceClient();
sender.setOptions(options);
OperationClient mepClient =
 sender.createClient(ServiceClient.ANON_OUT_IN_OP);

MessageContext mc = new MessageContext();
SOAPEnvelope env = buildEnvelopeDownloadBinarySWA(binaryName);
mc.setEnvelope(env);

mepClient.addMessageContext(mc);
mepClient.execute(true);

// Get the message context for the response
MessageContext response =
 mepClient.getMessageContext(WSDLConstants.MESSAGE_LABEL_IN_VALUE);
SOAPBody body = response.getEnvelope().getBody();
OMElement element = body.getFirstChildWithName(new
 QName(http://service.sample/xsd;, donwloadResponse));

if (element != null) {
processDownloadBinarySWA(response, element);
} else {
throw new Exception(Malformed response.);
}
}

 I am also using TCPMon to monitor all soap messages that are sent to my
 service. What I can see is that all requests are compressed with GZIP but
 responses are not. My tests are being made using both Axis2 1.3 (as a
 server) and Tomcat 6.0.18 with this options in server.xml:

   port=8080 protocol=HTTP/1.1
   connectionTimeout=2
   redirectPort=8443
   compression=on
   compressionMinSize=2048
   noCompressionUserAgents=gozilla, traviata
   compressableMimeType=text/html,text/xml

 Both in Axis2 and Tomcat the responses are not compressed.

 Is it a bug on Axis2?

 Someone had the same problem?

 I hope some help.

 Thanks.

 Julio Cezar Estrella (São Carlos - SP - Brazil)

 --
 View this message in context: 
 

Intercepting HTTP status code in Transport

2008-11-03 Thread Arien Kock
Hi mailinglist,

When my ws client has trouble connecting to the service due to errors at
the transport level, I'd like for there to be a way to detect HTTP status
codes. Right now all I can do is catch an AxisFault that gets thrown when
StAXSOAPModelBuilder stumbles on something it can't parse correctly 
which then doesn't tell me what the status code was. 

thanks,
-Arien
===
The information contained in this message and its attachments, if any, is 
confidential and privileged. It may be read, copied and used only by the 
intended recipient.  If you have received this message in error, please contact 
the sender immediately by return e-mail and please in that case delete this 
message and its attachments, if any, without disclosure  to any third 
party/person. 
The company does not accept liability for any errors or omissions in this 
message or its attachments, if any. The company does not guarantee that the 
integrity of this message or its attachments, if any, has been maintained or 
that this message or its attachments, if any, are free of viruses, 
interceptions or interference. Any recipient of this message or of its 
attachments, if any, is responsible for maintaining adequate 
protection-measures of its own systems against any incidents.
===



Which client for Axis2

2008-11-03 Thread ibrahim demir
Hi All.;

I have a question. Now I want to call some web services that will be published 
from a .NET side and will be based on WCF. 

So for not having so much trouble which axis2 client type I must use. Do you 
prefer RPCServiceClient or something diffrent. there wont be much non-primitive 
data types that will be transfered over the web service so RPC seems easy to 
me. But for starting from a goog point I want to learn your choices.

Thanks for your help

Yours.

 Ibrahim DEMIR
CyberSoft Yazilim Muh.
http://www.ibrahimdemir.org


  

Re: GZIP Response not work on Axis2

2008-11-03 Thread juliocest

Hi,

Yes. I edited server.xml in order to enable compression. Don't work yet.

I need discover the problem.

Thanks.

Julio


dims wrote:
 
 did you edit tomcat server.xml?
 http://www.cubicleman.com/2007/04/06/enabling-gzip-compression-with-tomcat-and-flex/
 
 thanks,
 dims
 
 On Mon, Nov 3, 2008 at 10:20 AM, juliocest [EMAIL PROTECTED] wrote:

 Hi everybody!

 I made an application that send attachments on soap message using SWA and
 MTOM. The client and server works properly. Now, I am trying to use GZIP
 in
 order to compress/decompress SOAP messages.

 My Service code:

public OMElement downloadFileSWA(OMElement element) throws
 Exception {
FileDataSource binaryDataSource;
DataHandler binaryDataHandler;
String vectorFileType[] =
 {file10KB,file100KB,file1MB,file10MB,file100MB};

// Checking if the resources folder is available
File file =  new File(filePath);
if (!file.isDirectory() || !file.exists()){
throw new AxisFault(File not available in the service
 provider...);
}

// Obtain the request (incoming) from the MessageContext
 as follows
MessageContext inMessageContext =
 MessageContext.getCurrentMessageContext();

// Obtain the operation context from the request message
 context
OperationContext operationContext =
 inMessageContext.getOperationContext();

// Obtain the response (outgoing) message context from the
 operation
 context
MessageContext outMessageContext =
 operationContext.getMessageContext(WSDLConstants.MESSAGE_LABEL_OUT_VALUE);

   
 outMessageContext.setProperty(HTTPConstants.MC_GZIP_RESPONSE, true);
   
 outMessageContext.setProperty(HTTPConstants.MC_ACCEPT_GZIP, true);

// Get the first element from the received message
String firstElem = element.getFirstElement().getText();
OMElement result = null;

for (int i = 0; i  vectorFileType.length; i++) {
if (vectorFileType[i].equalsIgnoreCase(firstElem))
 {
binaryDataSource = new
 FileDataSource(filePath +File.separator+
 vectorFileType[i]);
binaryDataHandler = new
 DataHandler(binaryDataSource);
// Add the created data handler as an
 attachment to the outgoing
 message.
String binaryID =
 outMessageContext.addAttachment(binaryDataHandler);
result =
 buildDownloadFileSWAEnvelope(vectorFileType[i],binaryID);
break;
}
}
return result;
}


 My Client code:

public void donwloadBinarySWA(String binaryName) throws Exception
 {

System.out.println(Download Binary with SWA);
Options options = new Options();
options.setProperty(HTTPConstants.MC_GZIP_REQUEST,
 Boolean.TRUE);
options.setProperty(HTTPConstants.MC_GZIP_RESPONSE,
 Boolean.TRUE);

ServiceClient sender = new ServiceClient();
sender.setOptions(options);
OperationClient mepClient =
 sender.createClient(ServiceClient.ANON_OUT_IN_OP);

MessageContext mc = new MessageContext();
SOAPEnvelope env =
 buildEnvelopeDownloadBinarySWA(binaryName);
mc.setEnvelope(env);

mepClient.addMessageContext(mc);
mepClient.execute(true);

// Get the message context for the response
MessageContext response =
 mepClient.getMessageContext(WSDLConstants.MESSAGE_LABEL_IN_VALUE);
SOAPBody body = response.getEnvelope().getBody();
OMElement element = body.getFirstChildWithName(new
 QName(http://service.sample/xsd;, donwloadResponse));

if (element != null) {
processDownloadBinarySWA(response, element);
} else {
throw new Exception(Malformed response.);
}
}

 I am also using TCPMon to monitor all soap messages that are sent to my
 service. What I can see is that all requests are compressed with GZIP but
 responses are not. My tests are being made using both Axis2 1.3 (as a
 server) and Tomcat 6.0.18 with this options in server.xml:

   port=8080 protocol=HTTP/1.1
   connectionTimeout=2
   redirectPort=8443
   compression=on
   compressionMinSize=2048
   noCompressionUserAgents=gozilla, traviata
   compressableMimeType=text/html,text/xml

 Both in Axis2 and Tomcat the responses are not compressed.

 Is it a bug on Axis2?

 Someone had the same problem?

 I hope some help.

 

axis2: TemporaryTemplate not found

2008-11-03 Thread Shen, Chunxia
Hi all,

my project is built on axis2 , with weblogic jms as transport .
 weblogic version 8.1
 jdk version 1.4
 axis2 version 2.1.4
I have changed the axis2.xml to suit for jms transport both on client and 
server. 
unluckily , still got the error of temporary queue can not be created for 
response.

so I use the below tesing code to test whether I can create temporary queue.

import javax.jms.*;
import javax.naming.Context;
import javax.naming.InitialContext;
import java.util.Hashtable;

public class TempQueueTester {
public static void main(String[] args) throws Exception {
try {
new TempQueueTester().sendWLS();
} catch (Exception e) {
e.printStackTrace();
}
}

private void sendWLS() throws Exception {
Hashtable props = new Hashtable();
props.put(java.naming.factory.initial, 
weblogic.jndi.WLInitialContextFactory);
props.put(java.naming.provider.url, t3://169.181.236.80:80);
Context jndiContext = new InitialContext(props);

ConnectionFactory connectionFactory = (ConnectionFactory) 
jndiContext.lookup(weblogic.jms.ConnectionFactory);
Destination dest = (Destination) jndiContext.lookup(myjmsqueue);

Connection connection = connectionFactory.createConnection();
Session session = connection.createSession(false, 
Session.AUTO_ACKNOWLEDGE);

 session.createTemporaryQueue();
 
 
  //  co.createTemporaryDestination();

MessageProducer producer = session.createProducer(dest);

for (int i=0; i10; i++) {
System.out.println(Sending message :  + i);
TextMessage m = session.createTextMessage();
m.setText(Message :  + i);
producer.send(m);
}

connection.close();
}
}


got  this error:

weblogic.jms.common.JMSException: TemporaryTemplate not found.
Please make sure that you have configured a TemporaryTemplate for your 
JMSServer(s).
at 
weblogic.rjvm.BasicOutboundRequest.sendReceive(BasicOutboundRequest.java:108)
at weblogic.rmi.internal.BasicRemoteRef.invoke(BasicRemoteRef.java:164)
at 
weblogic.jms.dispatcher.DispatcherImpl_815_WLStub.dispatchSyncFuture(Unknown 
Source)
at 
weblogic.jms.dispatcher.DispatcherWrapperState.dispatchSync(DispatcherWrapperState.java:345)
at 
weblogic.jms.client.JMSSession.createTemporaryDestination(JMSSession.java:2077)
at 
weblogic.jms.client.JMSSession.createTemporaryQueue(JMSSession.java:1767)
at webserviceSample.TempQueueTester.sendWLS(TempQueueTester.java:49)
at webserviceSample.TempQueueTester.main(TempQueueTester.java:31)
Caused by: weblogic.jms.common.JMSException: TemporaryTemplate not found.
Please make sure that you have configured a TemporaryTemplate for your 
JMSServer(s).
at 
weblogic.jms.frontend.FEManager.getTemporaryDestinationFactory(FEManager.java:129)
at 
weblogic.jms.frontend.FEConnection.createTemporaryDestination(FEConnection.java:1537)
at weblogic.jms.frontend.FEConnection.invoke(FEConnection.java:1698)
at 
weblogic.jms.dispatcher.Request.wrappedFiniteStateMachine(Request.java:643)
at 
weblogic.jms.dispatcher.DispatcherImpl.dispatchAsyncInternal(DispatcherImpl.java:132)
at 
weblogic.jms.dispatcher.DispatcherImpl.dispatchSyncFuture(DispatcherImpl.java:211)
at weblogic.jms.dispatcher.DispatcherImpl_WLSkel.invoke(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:492)
at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:435)
at 
weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
at 
weblogic.security.service.SecurityManager.runAs(SecurityManager.java:147)
at 
weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:430)
at 
weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest.java:35)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:224)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:183)



Although I created a TemporaryTemplate to bind to my jms server. still got this 
error.








He Jinda(Black)
Citicorp Software and Technology Services(Shanghai) Limited
E-mail: [EMAIL PROTECTED]
Tel: (86 21)38954626-61246  


Thanks  Regards


Shen Chunxia (Jennie)
ReBT
Tel: 86-21-38954626 ext. 61104
[EMAIL PROTECTED] 


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



axis2 wsdl2java problem

2008-11-03 Thread varala

Hi, 
I am trying to build stubs for the given hi5 wsdl using the following : 
wsdl2java -uri http://api.hi5.com/ns6.wsdl -o hicnd 

but i am unable to create it because of the following exception: 

Retrieving document at 'http://api.hi5.com/ns6.wsdl'. 
Retrieving schema at 'hi5.xsd', relative to 'http://api.hi5.com/ns6.wsdl'. 
Retrieving schema at 'default-types.xsd', relative to
'http://api.hi5.com/hi5.xs 
d'. 
Exception in thread main
org.apache.axis2.wsdl.codegen.CodeGenerationException 
: java.lang.RuntimeException: java.lang.reflect.InvocationTargetException 
at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGener 
ationEngine.java:271) 
at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:35) 
at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:24) 
Caused by: java.lang.RuntimeException:
java.lang.reflect.InvocationTargetExcepti 
on 
at org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(Simp 
leDBExtension.java:53) 
at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGener 
ationEngine.java:224) 
... 2 more 
Caused by: java.lang.reflect.InvocationTargetException 
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. 
java:39) 
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces 
sorImpl.java:25) 
at java.lang.reflect.Method.invoke(Method.java:585) 
at org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(Simp 
leDBExtension.java:50) 
... 3 more 
Caused by: org.apache.axis2.schema.SchemaCompilationException:
java.lang.NullPoi 
nterException 
at org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:28 
9) 
at org.apache.axis2.schema.ExtensionUtility.invoke(ExtensionUtility.java 
:103) 
... 8 more 
Caused by: java.lang.NullPointerException 
at org.apache.axis2.schema.SchemaCompiler.isComponetExists(SchemaCompile 
r.java:2723) 
at org.apache.axis2.schema.SchemaCompiler.getParentSchemaFromIncludes(Sc 
hemaCompiler.java:2670) 
at org.apache.axis2.schema.SchemaCompiler.getParentSchemaFromIncludes(Sc 
hemaCompiler.java:2704) 
at org.apache.axis2.schema.SchemaCompiler.getParentSchema(SchemaCompiler 
.java:2644) 
at org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler. 
java:758) 
at org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler. 
java:552) 
at org.apache.axis2.schema.SchemaCompiler.process(SchemaCompiler.java:19 
91) 
at org.apache.axis2.schema.SchemaCompiler.processParticle(SchemaCompiler 
.java:1874) 
at org.apache.axis2.schema.SchemaCompiler.processComplexType(SchemaCompi 
ler.java:1081) 
at org.apache.axis2.schema.SchemaCompiler.processAnonymousComplexSchemaT 
ype(SchemaCompiler.java:980) 
at org.apache.axis2.schema.SchemaCompiler.processSchema(SchemaCompiler.j 
ava:934) 
at org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler. 
java:592) 
at org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler. 
java:563) 
at org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:37 
0) 
at org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:35 
2) 
at org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:28 
0) 
... 9 more 

Can anyone help me to solve this, 
Thanks for your time, 
'varala' 
-- 
View this message in context: 
http://www.nabble.com/axis2-wsdl2java-problem-tp20304033p20304033.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]



about receive different types of attachment

2008-11-03 Thread th
hi,
 i'm using axis 1.3 to deploy a service to get request soap message with 
attachment using mtom,but i found the service can only receive .txt file.if 
receive another type file,for example test.rar which is 2M ,the attachment is 
in SOAP message,but when i get the attachment from a element that contains the 
attachment,i can only get 1K data.i do not know why .hope some help. thanks. 
the code that get attachment is follow:
OMText binaryNode = (OMText) content.getFirstOMChild();
binaryNode.setOptimize(true);
DataHandler actualDH = (DataHandler) binaryNode.getDataHandler();
FileOutputStream textOutStream = new FileOutputStream(c:\\th.txt);
InputStream is = actualDH.getInputStream();
textOutStream.write(IOUtils.getStreamAsByteArray(is));

Axis2 communication between web services

2008-11-03 Thread erlloyd

Hi everyone,

I'm new to Axis2, and I'm wondering about something I'm seeing when I call
one web service from another.

I have two web services for a school project, one a 'SensorService' and one
a 'SchoolService'. When I call method 'a()' on SensorService, it in turn
calls method 'b()' on the SchoolService. 

I'm using Axis2 and Java, generating stub classes using wsdl2java and ADB
data binding. 

I don't get any errors during the calls, but after the SensorService calls
the SchoolService, and I point my browser to
http://localhost:8080/axis2/services/listServices, I see a new Service
listed that wasn't there before, that looks something like this:

SchoolProfileService1225728541483_1
Service EPR :
http://localhost:8080/axis2/services/SchoolProfileService1225728541483_1
Service Description : No description available for this service
Service Status : Active
Available Operations

* getLocation
* anonOutonlyOp
* anonRobustOp
* hasActiveWaterSprinklers
* getSensors
* getNumStudents
* getHoursOfOperation
* setAdminDetails
* getName
* setLocation
* smokeDetectorDeactivated
* addSensor
* setNumStudents
* waterSprinklerActivated
* smokeDetectorActivated
* getNumSensors
* setSensors
* hasActiveSmokeDetectors
* setName
* anonOutInOp
* waterSprinklerDeactivated
* setHoursOfOperation

This is in addition to a service that already existed that looked like this:

SchoolProfileService
Service EPR : http://localhost:8080/axis2/services/SchoolProfileService
Service Description : School Profile Service
Service Status : Active
Available Operations

* getName
* getLocation
* waterSprinklerDeactivated
* hasActiveSmokeDetectors
* getNumStudents
* getNumSensors
* setNumStudents
* smokeDetectorDeactivated
* setLocation
* setAdminDetails
* setName
* hasActiveWaterSprinklers
* setHoursOfOperation
* smokeDetectorActivated
* getHoursOfOperation
* addSensor
* setSensors
* waterSprinklerActivated
* getSensors


What I'm wondering, is this expected behavior? The
'SchoolProfileService1225728541483_1' obviously isn't a real web service,
but why is it being created? If I write just a simple java executable
calling 'b()' on the School Service, the new
SchoolProfileService1225728541483_1 doesn't show up. It only seems to show
up when one web service calls another. 

Can anyone explain why this is happening?

Thanks,
Eric

-- 
View this message in context: 
http://www.nabble.com/Axis2-communication-between-web-services-tp20305538p20305538.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: XMLBeans customization parameters in Maven

2008-11-03 Thread Benjamin.Shrom
Can you be more specific?

From: Amila Suriarachchi [mailto:[EMAIL PROTECTED]
Sent: Friday, October 31, 2008 7:31 AM
To: axis-user@ws.apache.org
Subject: Re: XMLBeans customization parameters in Maven

you can use xc (ie. -Exc) option to specify the xmlbeans config file with 
wsdl2java command line tool.
check whether you can set an option like that.

thanks,
Amila.
On Thu, Oct 30, 2008 at 10:49 PM, [EMAIL PROTECTED]mailto:[EMAIL PROTECTED] 
wrote:
Hello,

Anybody knows how to provide external XMLBeans configuration file as a 
parameter in
axis2-wsdl2code-maven-plugin ?

Plug-in has namespaceURIs, however it's doesn't allow external customization 
file.

Regards,

Benjamin.

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



--
Amila Suriarachchi
WSO2 Inc.
blog: http://amilachinthaka.blogspot.com/


[Axis2] WSDL2Java ignores wsdl:documentation tag

2008-11-03 Thread Leif Olson
Hi,
We would like to add comments that appear as javadoc comments in the source 
generated when we run WSDL2Java on our wsdl file.  Currently, the only javadoc 
comments that appear are auto generated.  Any wsdl:documentation tagged 
comments I add to our axis2 wsdl file do not appear in the generated source. 
For example:

  wsdl:operation name=acceptRatePlan
wsdl:documentationcomment1 is ignored/wsdl:documentation
  soap:operation 
soapAction=urn:ws.unity.trilliantnetworks.com:Soap:acceptRatePlan /
  wsdl:documentationcomment2 is ignored/wsdl:documentation
  wsdl:input
  wsdl:documentationcomment3 is ignored/wsdl:documentation
soap:body parts=parameters use=literal /
  /wsdl:input
  wsdl:output
soap:body use=literal /
  /wsdl:output
  wsdl:fault name=InvalidFieldFault
soap:fault name=InvalidFieldFault use=literal /
  /wsdl:fault
  wsdl:fault name=AccessDeniedFault
soap:fault name=AccessDeniedFault use=literal /
  /wsdl:fault
  wsdl:fault name=UnexpectedErrorFault
soap:fault name=UnexpectedErrorFault use=literal /
  /wsdl:fault
/wsdl:operation

Is there another tag we should be using or certain option argument that should 
also be used when running WSDL2Java?

Thanks,
Leif


  

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



Re: axis2: TemporaryTemplate not found

2008-11-03 Thread Asankha
Hi Shen
 unluckily , still got the error of temporary queue can not be created for 
 response.
 ...
 weblogic.jms.common.JMSException: TemporaryTemplate not found.
 Please make sure that you have configured a TemporaryTemplate for your 
 JMSServer(s).
 ...

 Although I created a TemporaryTemplate to bind to my jms server. still got 
 this error.
   
The problem is NOT related at all to Axis2 or the JDK, but proper
configuration of WLS JMS. Is your environment clustered? You could also
check with BEA if you have support.. also check the folllowing:

http://www.theserverside.com/discussions/thread.tss?thread_id=24432
http://forums.bea.com/search.jspa?q=TemporaryTemplate%20not%20foundobjID=c1defOp=1rankBy=10001threadID=27415

asankha

-- 
Asankha C. Perera
http://adroitlogic.org

http://esbmagic.blogspot.com


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



Necessary libraries for running Axis2 integrated with another webapp running under Tomcat?

2008-11-03 Thread Andrew Thorburn
I've got Axis2 running as part of another WebApp, which is in turn
being run under Tomcat 5.5, and I'm wondering if anyone has a list of
the absolute minimum set of libraries necessary for it to run without
getting 'ClassNotFound' errors or similar. In order to get it working,
I just grabbed all the libraries from the 'lib' directory of the Axis2
binary distribution. That worked fine, but I've been asked to see if I
can make it smaller.

I've got a feeling that the answer is No, but I need to ask :).

Hope what I'm asking makes sense.

Thanks,

- Andrew Thorburn

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



Obtain the SOAP envelope as DOM document or String

2008-11-03 Thread Matt Friedman
I'm writing some code to produce xml files that contain the XML SOAP envelope.

I'm doing this because I'm creating random search requests for part of
our testing/benchmarking etc...

I can create the client stub, configure it, and execute the search
request, but I need to grab the SOAP envelope somehow.

Is there a bit of the API that I can hook into so that I can do this?

-- 
-- Matt Friedman

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



Re: about receive different types of attachment

2008-11-03 Thread th
i changed the axis to 1.4, and the problem was sovled,but another problem 
occrus.that is ,use axis 1.4 to send request soap message with a 10M attachment 
to a .net services ,there was a exception,as follow:
WstxEOFException: Unexpected EOF in prolog error
i wonder if the problem is happen in .net services or in the axis 1.4 client

  - Original Message - 
  From: th 
  To: axis-user@ws.apache.org 
  Sent: Monday, November 03, 2008 11:48 PM
  Subject: about receive different types of attachment


  hi,
   i'm using axis 1.3 to deploy a service to get request soap message with 
attachment using mtom,but i found the service can only receive .txt file.if 
receive another type file,for example test.rar which is 2M ,the attachment is 
in SOAP message,but when i get the attachment from a element that contains the 
attachment,i can only get 1K data.i do not know why .hope some help. thanks. 
the code that get attachment is follow:
  OMText binaryNode = (OMText) content.getFirstOMChild();
  binaryNode.setOptimize(true);
  DataHandler actualDH = (DataHandler) binaryNode.getDataHandler();
  FileOutputStream textOutStream = new FileOutputStream(c:\\th.txt);
  InputStream is = actualDH.getInputStream();
  textOutStream.write(IOUtils.getStreamAsByteArray(is));

Re: [AXIS2] Problem with HTTPS transport

2008-11-03 Thread Sagara Gunathunga
HI,
Is there any way to expose  a Endpoint binding with HTTPS only using AXIS2
..?
something like


https://host:port/web/services/PayfoneService.PayfoneServiceHttpsEndpoint


Thanks ,

On Mon, Nov 3, 2008 at 5:53 PM, Sagara Gunathunga 
[EMAIL PROTECTED] wrote:


 Hi,
 We use Axis2-1.4 within a Spring application , and we have a requirement to
 expose web service only for HTTPS transport. So I did the following
 procedure .

 1.) Enable the transportReceiver name=https . in axis2.xml file .
 (Initially I got an error but once I add HttpCore and HttpCore -nio  as
 Maven dependencies it solved.)

 2.) Then add transports transporthttps/transport /transports in to
 service.xml file .

 We have configured a JBOSS server for  SSL  certificates and it works fine
 for web application , but when it deploy web service I got following error
 message .

 org.apache.axis2.deployment.DeploymentException: Service [ PayfoneService]
 is trying to expose in a transport : transports
 transporthttps/transport
/transports and which is not available in Axis2
 at
 org.apache.axis2.deployment.ServiceGroupBuilder.populateServiceGroup(ServiceGroupBuilder.java:106)
 at
 org.apache.axis2.deployment.repository.util.ArchiveReader.buildServiceGroup(ArchiveReader.java:110)
 at
 org.apache.axis2.deployment.repository.util.ArchiveReader.processServiceGroup(ArchiveReader.java:179)
 at
 org.apache.axis2.deployment.ServiceDeployer.deploy(ServiceDeployer.java:81)



 In our development environment we use Jetty embedded server  with M2 and we
 got same exception with Jetty too,
 Is there any way to solve  this with Axis 2 without using security module
 (Rampart)..?


 Thanks ,


 Sagara Gunathunga

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




-- 
Sagara Gunathunga

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


Betr.: Obtain the SOAP envelope as DOM document or String

2008-11-03 Thread Arien Kock
 I'm writing some code to produce xml files that contain the XML 
SOAPenvelope.
 ...
 Is there a bit of the API that I can hook into so that I can do this?

You can create a handler and add it to a desired Phase in the axis2.xml
Using the calling getEnvelope().toString() on the MessageContext will
get you the what you want. Check out the sample application
axis2-1.4\samples\userguide\src\userguide\loggingmodule which does 
the same thing.

-Arien
===
The information contained in this message and its attachments, if any, is 
confidential and privileged. It may be read, copied and used only by the 
intended recipient.  If you have received this message in error, please contact 
the sender immediately by return e-mail and please in that case delete this 
message and its attachments, if any, without disclosure  to any third 
party/person. 
The company does not accept liability for any errors or omissions in this 
message or its attachments, if any. The company does not guarantee that the 
integrity of this message or its attachments, if any, has been maintained or 
that this message or its attachments, if any, are free of viruses, 
interceptions or interference. Any recipient of this message or of its 
attachments, if any, is responsible for maintaining adequate 
protection-measures of its own systems against any incidents.
===



Re: Obtain the SOAP envelope as DOM document or String

2008-11-03 Thread Amila Suriarachchi
use toString method.

thanks,
Amila.

On Tue, Nov 4, 2008 at 6:42 AM, Matt Friedman [EMAIL PROTECTED]wrote:

 I'm writing some code to produce xml files that contain the XML SOAP
 envelope.

 I'm doing this because I'm creating random search requests for part of
 our testing/benchmarking etc...

 I can create the client stub, configure it, and execute the search
 request, but I need to grab the SOAP envelope somehow.

 Is there a bit of the API that I can hook into so that I can do this?

 --
 -- Matt Friedman

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




-- 
Amila Suriarachchi
WSO2 Inc.
blog: http://amilachinthaka.blogspot.com/