Help regarding Scope of Service

2009-10-27 Thread GAURAV TIWARI
Hi,

I created this simple class

public class MyService
{
   int c;
    MyService(){
 c=0;

    }
    public int serviceMethod()
    {
        c++
    return c;
    }
}

And I deployed it into axis using this descriptor

http://xml.apache.org/axis/wsdd/";
    xmlns:java="http://xml.apache.org/axis/wsdd/providers/java";>

 
  
  
  

 



The axis user Guide mentions that scope="Application" implies that all
the request would be served from the singleton object.

"Application" scope will create a singleton shared object to service
all requests"

However every time I call the service the value returned is 1 which
means that a new object is being created every time.
Please suggest.

Thanks and Regards
Gaurav


Re: Problem with two services in a serviceGroup with scope soapsession sharing ServiceGroupContext

2009-04-01 Thread Manuel Lozano Melero
- 



In the service "es.upv.wsasic.app.Autenticacion" class i have a method 
to autenticate a user in my application. This is the first service 
request .


   public byte[] obtieneSessionId(String user,String password){
  do validation and return a String "sessionId" variable if 
autentication success
   ServiceGroupContext 
session=MessageContext.getCurrentMessageContext().getServiceGroupContext();   

  session.setProperty("sessionId", sessionId); // I want to save 
this value

  return AESCipher.encode(sessionId);
 }


And in the other service "es.upv.wsasic.app.Directorio" class i have a 
method, but before to execute the request(this is the second service 
request) i validate that the user is autenticated in the application in 
this way.


  public Person getInfoPerson(String sessionId, String dni) throws 
ServicioException{  
ServiceGroupContext sesion = 
MessageContext.getCurrentMessageContext().getServiceGroupContext();

   String sessionIdAES = (String) sesion.getProperty("sessionId");

   /*
    But in this point "sessionIdAES" is null and "sesion" has a 
diferent ServiceGroupContext, it seems that has two ServiceGroupContext
each for service "Autenticacion" and "Directorio", and i 
only want a ServiceGroupContext for the two services in the 
"soapsession" scope.
This is the problem, how to share a unique 
ServiceGroupContext in this scope!
If i call the same "Atenticacion" service more than one 
time, the ServiceGroupContext for this service is unique.
And then i call "Directorio" more than one time, and the 
new ServiceGroupContext for this service is unique for "Directorio" but 
this

situation is the problem, there are two different contexts.
   */
  ..
 }


AW: scope="soapsession" what causes destroy() to be called

2009-03-24 Thread Stadelmann Josef
Dear axis2 ServiceGroupId and scope="sopasession" community 
 
In absence of support for this my hot hot topic 
 
  In mode scope="soapsession" 
be aware that the ConfigContextTimeoutInterval in axis2.xml is set to a 
value high enougth
as shown i.e. 360 = 1h
 
 
  360

If this value is set to only 3 that means, the user has a maximum 
of 30 seconds
in a long-lasting session to have its client application send the next 
request to the
axis2 server. Even the next request is sent with a a proper 
ServiceGroupId after this time, 
it would not prevent that destroy() is triggered by this time-out; this 
however makes the 
used ServiceGroupId invalid and this is then sent as an exception back 
to the client; 
but the ServiceGroupId is valid only the time-out has occured. 
 
So the falt raised should potentially inform about the true cause, not 
letting users in the dark.
 
Since I have adjusted this time out to 1 hour, a client can suspend a next 
request for that
time and still reach the waiting instance of a service-object and through 
this object potentially
a long waiting process.
 
Josef.Stadelmann
@axa-winterthur.ch
 
 

 
 
 
 
 
 
 

-Ursprüngliche Nachricht-
Von: Stadelmann Josef [mailto:josef.stadelm...@axa-winterthur.ch]
Gesendet: Mittwoch, 18. März 2009 10:39
An: axis-user@ws.apache.org
Betreff: AW: scope="soapsession" what causes destroy() to be called


Hi all
 
It seams that no-one of the axis2 developers, mainly the one introducing 
scope="soapsession" are able
to deliver me an answer to my questions below. a while ago, two years ago in 
fact I run still axis2-1.2 on
OpenVMS, I was 100% confident that I have a thread/session safe configuration 
when I run in 
 
scope="soapsession"; mode
 
however this is only true for java axis2 based service clients; this is the 
out-come of the past months!
 
The various stories say - that one has to return the ServicegroupId's with each 
request, in a soap-header.
 
OK I beleaved this. And I garantee you, all my wcf clients do it.
 
Meanwhile, I am 100% confident, as I am currently struggle arroun to make Vista 
clients using .NET,
C#, WCF work toward an axis2 server running in scope="soapsession"; 
 
THAT THIS IS SIMPLY NOT TRUE!
 
what I learned and have detected so far using tcpmon is
 
Every axis2 java service client accepts cookies and hence the server returns on 
its initial request
(when the sessiion is new) a 
 
Set-Cookie; JSESSIONID=< id > ; Path=/axis2
 
This as a web http header in its reply when a first request is made, which 
calls init() and then my own login() 
(when the session is new:)
 
and with this first response, as said in documentation;  I get the awaited 
ServiceGroupId back.
 
This ServicegroupId is said to be the identifier one has to return with each 
follow-request to the
server to reach the same instance of a service, to talk to the same object; to 
have in fact sessions
/threads implemented; however - that is not true - without the coockie it does 
not work.
 
The quite reader might have assumed that I run via HttpTransport not via 
TcpTransports; We do so.
 
Now; I have 3 Java axis2 service clients running; and each is reaching its own 
object/service, each sends
its own garanteed unique JSESSIONID at the http-request-header-level and its 
own garanteed unique 
ServiceGroupId at the soap-request-header-level
 
And it works;
 
I start my first wcf client and well it works; 
This wcf client sends garanteed unique its JSESSION and its garanteed unique 
ServicveGroupId
with each request; see below; we have init() login() fktmap() fktmap() fktmap() 
init() login() ...
and please take notice the when the ServiceContext ID changes;
 
And it works;
 
I start my second wcf client an well it receives with its initial request (it 
calls init() ( it's garanteed unique JSESSIONID and its 
garanteed unique ServicegroupId; 
 
But when I look at my log in  
AXP1>ty APACHE$SPECIFIC:[00]APACHE$JAKARTA_SERVER_OUTPUT.LOG/out=x.x
 
I can find the following sequence of calls; and as you can see, when my third 
vista wcf client starts destroy() gets called twice for my
two previous still in use ServiceContext, and that is the deadly end of the 
unique services serving wcf client 1 and 2

AXP1>search x.x "-  init()","-  login()","-  fktmap","-  logout()","-  
destroy()"
-  init()called at : Wed Mar 18 08:38:40 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe418d28> 
org.apache.axis2.context.servicecont...@fe418d28 i=0
-  login()   called at : Wed Mar 18 08:38:40 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe418d28> 
org.apache.axis2.context.servicecont...@fe418d28 i=1 and session is NEW
-  fktmap()  called at : Wed Mar 18 08:38:48 MET 2009 usin

AW: scope="soapsession" what causes destroy() to be called

2009-03-18 Thread Stadelmann Josef
Hi all
 
It seams that no-one of the axis2 developers, mainly the one introducing 
scope="soapsession" are able
to deliver me an answer to my questions below. a while ago, two years ago in 
fact I run still axis2-1.2 on
OpenVMS, I was 100% confident that I have a thread/session safe configuration 
when I run in 
 
scope="soapsession"; mode
 
however this is only true for java axis2 based service clients; this is the 
out-come of the past months!
 
The various stories say - that one has to return the ServicegroupId's with each 
request, in a soap-header.
 
OK I beleaved this. And I garantee you, all my wcf clients do it.
 
Meanwhile, I am 100% confident, as I am currently struggle arroun to make Vista 
clients using .NET,
C#, WCF work toward an axis2 server running in scope="soapsession"; 
 
THAT THIS IS SIMPLY NOT TRUE!
 
what I learned and have detected so far using tcpmon is
 
Every axis2 java service client accepts cookies and hence the server returns on 
its initial request
(when the sessiion is new) a 
 
Set-Cookie; JSESSIONID=< id > ; Path=/axis2
 
This as a web http header in its reply when a first request is made, which 
calls init() and then my own login() 
(when the session is new:)
 
and with this first response, as said in documentation;  I get the awaited 
ServiceGroupId back.
 
This ServicegroupId is said to be the identifier one has to return with each 
follow-request to the
server to reach the same instance of a service, to talk to the same object; to 
have in fact sessions
/threads implemented; however - that is not true - without the coockie it does 
not work.
 
The quite reader might have assumed that I run via HttpTransport not via 
TcpTransports; We do so.
 
Now; I have 3 Java axis2 service clients running; and each is reaching its own 
object/service, each sends
its own garanteed unique JSESSIONID at the http-request-header-level and its 
own garanteed unique 
ServiceGroupId at the soap-request-header-level
 
And it works;
 
I start my first wcf client and well it works; 
This wcf client sends garanteed unique its JSESSION and its garanteed unique 
ServicveGroupId
with each request; see below; we have init() login() fktmap() fktmap() fktmap() 
init() login() ...
and please take notice the when the ServiceContext ID changes;
 
And it works;
 
I start my second wcf client an well it receives with its initial request (it 
calls init() ( it's garanteed unique JSESSIONID and its 
garanteed unique ServicegroupId; 
 
But when I look at my log in  
AXP1>ty APACHE$SPECIFIC:[00]APACHE$JAKARTA_SERVER_OUTPUT.LOG/out=x.x
 
I can find the following sequence of calls; and as you can see, when my third 
vista wcf client starts destroy() gets called twice for my
two previous still in use ServiceContext, and that is the deadly end of the 
unique services serving wcf client 1 and 2

AXP1>search x.x "-  init()","-  login()","-  fktmap","-  logout()","-  
destroy()"
-  init()called at : Wed Mar 18 08:38:40 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe418d28> 
org.apache.axis2.context.servicecont...@fe418d28 i=0
-  login()   called at : Wed Mar 18 08:38:40 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe418d28> 
org.apache.axis2.context.servicecont...@fe418d28 i=1 and session is NEW
-  fktmap()  called at : Wed Mar 18 08:38:48 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe418d28> 
org.apache.axis2.context.servicecont...@fe418d28 i=2
-  fktmap()  called at : Wed Mar 18 08:38:50 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe418d28> 
org.apache.axis2.context.servicecont...@fe418d28 i=3
-  fktmap()  called at : Wed Mar 18 08:38:57 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe418d28> 
org.apache.axis2.context.servicecont...@fe418d28 i=4
-  init()called at : Wed Mar 18 08:39:24 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe3c1573> 
org.apache.axis2.context.servicecont...@fe3c1573 i=0
-  login()   called at : Wed Mar 18 08:39:24 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe3c1573> 
org.apache.axis2.context.servicecont...@fe3c1573 i=1 and session is NEW
-  fktmap()  called at : Wed Mar 18 08:39:32 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe3c1573> 
org.apache.axis2.context.servicecont...@fe3c1573 i=2
-  fktmap()  called at : Wed Mar 18 08:39:35 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe3c1573> 
org.apache.axis2.context.servicecont...@fe3c1573 i=3
-  fktmap()  called at : Wed Mar 18 08:39:41 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe3c1573> 
org.apache.axis2.context.servicecont...@fe3c1573 i=4
-  destroy() called at : Wed Mar 18 08:41:05 MET 2009 using  
<mailto:org.apache.axis2.context.servicecont...@fe418d28> 
org

scope="soapsession" what causes destroy() to be called

2009-03-12 Thread Stadelmann Josef
Hi,

my web service runs in scope="soapsession"
up on a client request, call it session 1, the following functions are called 
in sequence for my login cycle
init(), login(), fktmap(), fktmap(), fktmap(),


then I start the next client, calle it session 2) and the following functions 
should becalled
init(), login(), fktmap(), fktmap(), fktmap(),
but the following functions are called in sequence
destroy(), init(), login(), fktmap(), fktmap(), fktmap(),

in bold the axis2 requierd functions one needs to implement for 
scope="soapsession"

destroy() is the bad guy which deletes me the previous created instance;
hence thereafter client 1 / session 1 is inoperable and returns a fault to the 
client telling me that ServicegroupId is invalid
but that is not true, as TcpMonitor proves the opposit for every more session 1 
calls to fktmap()

Question:
under which conditions, httpMessageRequestHeader issue, http protocol 
dependent, is destroy() called?

Note: with the primary call action="urn:login" the server responses with a 
setCooky and passes me the cooky=JSn...

what httpRequestMessageHeader must be there or absent that a first request from 
a new session does not call destry()

Only then will consecutive requests with the same ServiceGroupId in fact reach 
the old service instance to which it belongs;

So a request with action="urn:login" shall hit init(), then login(), in absence 
of a ServicegroupId, but at no time destroy()

Josef





Re: scope="transportsession"

2009-03-04 Thread TomazM
Thx, I find the page and used it.

I have some problem with AxisFault, because instead client get fault response 
it get Tomcat HTTP Status 500 response(client expect XML)

My POJO service:

public boolean start() {
MessageContext messageContext = 
MessageContext.getCurrentMessageContext();
ServiceContext sc = messageContext.getServiceContext();
if((Double) sc.getProperty("sessionID_same") == null){
double sessionID = Math.random();
sc.setProperty("sessionID_same", sessionID);
System.out.print("\n start:: NEW sessionID="+sessionID);
return true;
}
else{
double sessionID = (Double) sc.getProperty("sessionID_same");
System.out.print("\n start:: The same sessionID="+sessionID);
return false;   
}   
}


public boolean commit() throws AxisFault {
MessageContext messageContext = 
MessageContext.getCurrentMessageContext();
ServiceContext sc = messageContext.getServiceContext();
if((Double) sc.getProperty("sessionID_same") != null){  
double sessionID = (Double) sc.getProperty("sessionID_same");
System.out.print("\n commit:: OK old sessionID="+sessionID);
return true;
}
else{
System.out.print("\n commit:: error new sessionID");
throw new AxisFault("You can call commit only in the same 
session");
}   
}

What I'm trying to do:
Client can call 'commit' only in same session, if not in same session commit 
throw AxisFault so that client know what is wrong.

I have this problem whit AxisFault because Tomcat response is HTML internal 
error.

Have I need to configure Tomcat or axis2??

Regards, Tomaz




charitha kankanamge wrote:
> Hi Tomaz,
> Please have a look at [1].
> 
> [1]http://wso2.org/library/3264
> 
> Regards
> Charitha
> 
> http://charithaka.blogspot.com
> 
> TomazM wrote:
> 
>> Is there any example how the service control that the same (cookie)
>> session client invoke this service.
>>
>> Regards, Tomaz
>>  
>>
> 

begin:vcard
fn:Tomaz Majerhold
n:Majerhold;Tomaz
org:ARNES, Slovenian NREN;Development team
adr:;;Jamova 39;Ljubljana;Ljubljana;1000;Slovenia
email;internet:tomaz.majerh...@arnes.si
title:Developer
tel;work:+386 14798930
tel;fax:+386 1 479 88 99
tel;home:+386 1425 38 01
tel;cell:+386 40757229
url:http://www.arnes.si/
version:2.1
end:vcard



Re: scope="transportsession"

2009-03-04 Thread charitha kankanamge

Hi Tomaz,
Please have a look at [1].

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

Regards
Charitha

http://charithaka.blogspot.com

TomazM wrote:


Is there any example how the service control that the same (cookie) session 
client invoke this service.

Regards, Tomaz
 






scope="transportsession"

2009-03-04 Thread TomazM
Is there any example how the service control that the same (cookie) session 
client invoke this service.

Regards, Tomaz
begin:vcard
fn:Tomaz Majerhold
n:Majerhold;Tomaz
org:ARNES, Slovenian NREN;Development team
adr:;;Jamova 39;Ljubljana;Ljubljana;1000;Slovenia
email;internet:tomaz.majerh...@arnes.si
title:Developer
tel;work:+386 14798930
tel;fax:+386 1 479 88 99
tel;home:+386 1425 38 01
tel;cell:+386 40757229
url:http://www.arnes.si/
version:2.1
end:vcard



AW: SCOPE="SOAPSESSION"

2009-02-24 Thread Stadelmann Josef
Dear community;
 
I have found the solution to the problem below.
 
It is that  my Microsoft WCF Client must allow for cookies . Up on a initial 
call ,  via a HTTP transport ,  the client signals that it can accept cookies . 
In turn, the axis2 httptransport will issue a set cookie command with its first 
reply . After that the client will send this cookie, which is JSESSION="  
uuid " string toward the axis2 server. Since I have enabled this by the 
following VB.net code in my WCF client transport binding ,  
 
HttpTransportBindingElement httpTransportBE = new 
HttpTransportBindingElement();
httpTransportBE.AllowCookies = true;
 
the JSESSION cookie is exchanged with each  consecutieve request to the axis2 
server.
 
For sure - I did never expect that multi session capability of axis2 was 
two-fold.
 
a) receiving a ServiceGroupId  up on a frist reply and send it with each 
consecutive request
b) receiving a JSESSION cookie up on a first reply and send it with each 
consecutive request
 
This is a real surprise for me. 
 
Now my VB.net WCF clients work perfect with  the axis2 server, 
and exchanging large junks of nested collections of named value pairs of 
strings as soap xml documents is well done.
 
Sepp


SCOPE="SOAPSESSION"

2009-02-23 Thread Stadelmann Josef
Dear axis2/Java community

my Java Client calls an axis2 service. 
The server runs in scope="soapsession" returning a ServicegroupId up on a 
initial call to init() & login().

I can launch several Java Clients, which reach in a 1 to 1 correspondence each 
his own instance of a service;  call it "a SpezplaService object".

If I start 3 Java Clients, I can observer 3 that init() is called 3 times, and 
each time a different new service context is generated. 
The initial call returns the ServiceGroupId in its reply header, all different.

On consecutive calls to the server, each client has in the addressing header 
its own session specific ServiceGroupId

Using this ServiceGroupId keeps client sessions appart, and yes, each thread 
reaches its unique instance of a web service object.

Below the header used to login(), which calls init() and then login() on the 
server 


Request-Header A: from a axis2 Java Client; it calls init() followed by login() 
(as indicated by action="urn:login"

POST /axis2/services/SpezplaService HTTP/1.1
Content-Type: application/soap+xml; charset=UTF-8; action="urn:login"
User-Agent: Axis2
Host: alpha1:9090
Transfer-Encoding: chunked

65f

   http://www.w3.org/2005/08/addressing"; 
xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope";>
  
 http://localhost:9090/axis2/services/SpezplaService
 urn:uuid:9EA640E011C9B711EC1235380730631
 urn:login
  

each consecutive header used to reach always the proper related service object 
for urn:fktmap looks like


Request-Header B: from an axis2 Java Client; format of consecutive 
request-headers after the initial request to axis2 service took place

POST /axis2/services/SpezplaService HTTP/1.1
Content-Type: application/soap+xml; charset=UTF-8; action="urn:fktmap"
Cookie: JSESSIONID=77A13E81754C5F8BEA52D5A6255BE384
User-Agent: Axis2
Host: alpha1:9090
Transfer-Encoding: chunked

51f

   http://www.w3.org/2005/08/addressing"; 
xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope";>
  
 http://localhost:9090/axis2/services/SpezplaService
 http://ws.apache.org/namespaces/axis2"; 
wsa:IsReferenceParameter="true">urn:uuid:888FAE4966CD02171F1235377217671
 urn:uuid:9EA640E011C9B711EC1235380742946
 urn:fktmap
  

please note the insertion and existence of a ServiceGroupId  urn:uuid:. 
used to reach the proper instance of a service object.


NOW!

I have developed a VB.net client based on WCF (Windows Communication Foundation)
I have managed to receive the ServiceGroupId header from the axis2/Java server 
extract it and insert it with each consecutive next call through a request / 
response inspector, triggered by a behaviour attribute.

The initial sent login request headers reaching the axis2/Java server is

Request-Header C: from a VB.net / WCF Client; this is initial header calling 
init() & login()

POST http://alpha1:8080/axis2/services/SpezplaService HTTP/1.1
Content-Type: application/soap+xml; charset=utf-8
Host: alpha1:9091
Content-Length: 1766
Expect: 100-continue
Proxy-Connection: Keep-Alive

http://www.w3.org/2003/05/soap-envelope"; 
xmlns:a="http://www.w3.org/2005/08/addressing";>
   
  urn:login
  urn:uuid:3012cd1e-af6c-40d2-a5cc-eceffce61f46
  http://alpha1:8080/axis2/services/SpezplaService
   

The reply returns the ServiceGroupId which is then sniffed in to each 
consecutive request header such as

Request-Header D: from VB.net / WCF client; this is the format of each 
consecutive request header calling fktmap() & logout() to terminate session

POST http://alpha1:8080/axis2/services/SpezplaService HTTP/1.1
Content-Type: application/soap+xml; charset=utf-8
Host: alpha1:8080
Content-Length: 1239
Expect: 100-continue

http://www.w3.org/2003/05/soap-envelope"; 
xmlns:a="http://www.w3.org/2005/08/addressing";>
   
  urn:fktmap
  urn:uuid:0d8ef5a4-eb53-43dd-a2aa-d1e3b83a7edd
  http://ws.apache.org/namespaces/axis2";>urn:uuid:888FAE4966CD02171F1235381314775
  http://alpha1:8080/axis2/services/SpezplaService
   


Now comes my problem:

while I can use as many Java Client and have each one reaching its own service 
object instance the VB.net client fails doing so.

When my second VB.net client sends request-header C;  I can observe in the log 
that the destroy() function was called on a previous established service object 
instance. This destroys my previous established session. So VB.net client 1 
fails after starting VB.net client 2. Starting VB.net client 3 makes VB.net 
client 2 failing, and so on.


However I can perfectly run and start in any sequence 3 Java Clients and only 
one 1 VB.net client.

They reach all theire unique instances of service objects and throuhg this 
objects they reach WSIT Beans and behind that, they reach each theire own 
OpenVMS legacy server 

when are files unlocked by Tomcat if a local File variable leaves scope?

2009-02-03 Thread Stadelmann Josef
Hello Axis2 Community,
Hello Apache Tomcat for OpenVMS Experts

how do you explain the following File Locking Situation with my Axis2 web 
service running on top of Apache$Tomcat for Open and JVM 1.4.2? I have run my 
webservice to a successfull end, SCOPE=SOAP-Sessions, and as part of it a 
method login(OMElement e); called a File for
1. read  [wsit.deploy]SPg.wsi;207 then
2. write [wsit.deploy]SPg.wsi;208 then
3. read  [wsit.deploy]SPg.wsi;208

and then via a WSIT toolkit and some JNI's a detached running server 
WSI$MANAGER.EXE should read [wsit.deploy]SPg.wsi;208 unfortunately tis fails as 
the file is under full lock by. How do I release the lock prior to calling wsit 
services to launch an out-of-process server herby with a need to access the 
just patched file?
end login

next call is for fktmap(OMElement) for working


final call is for logout()

next call for login() does same sequence
4. read  [wsit.deploy]SPg.wsi;208 then
5. write [wsit.deploy]SPg.wsi;209 then
6. read  [wsit.deploy]SPg.wsi;209 then

and then via a WSIT toolkit and some JNI's a detached running server 
WSI$MANAGER.EXE should read [wsit.deploy]SPg.wsi;208 unfortunately tis fails as 
the file is under full lock by. How do I release the lock prior to calling wsit 
services to launch an out-of-process server herby with a need to access the 
just patched file?
end login

please watch the OpenVMS versions 

next call is for fktmap(OMElement) for working


final call is for logout()




I did show dev/file and the short list below is the result, this minutes after 
my web service login() has terminated and local variables such as File spg_wsi 
are all out of scope. So I can expect that underlying file resources should be 
freed to allow re-access by another VMS process. But nothing like that happens. 
appacht$tomcat or my code running on top of it keeps its fingers on it ... how 
long, I can just guess, because I went home after I used 
$ show device /files

This morning I returned and the first thing I did was at >>>>

$ show device /files 

and see below, close to end of list they are all gone. Maybe something internal 
to Tomcat has time out, at least apache$tomcat has given them free to allow 
access by other VMS processes such as TYPE.EXE or EDIT.EXE.


can you please tell me how to tell appache$tomcat to free resources ASAP when a 
variable leaves local scope?


This is the reason why my hack, parsing a SPg.wsi (HP WSIT deployment xml file) 
into a dom modell, seeking  tags and patching the  
text from i.e. nothing to SACHB, STADELMA or ADMINP ... to the account of the 
user does not work. i.e. the patching works perfectly but wsi$manager.exe is 
unable to access such a file. 

However this will only work when apache$tomcat releases underlaying resources 
for other processes ASAP when a variable like File spg_wsi leaves the scope of 
the method.

I have found that on such keept files you cant even do a $ TYPE because it ends 
in a % file is locked by another user 



1. 
AXP1>show dev /file

TCPIP$FTPC00108 4421  [STADELMA]TCPIP$FTP_SERVER.LOG;510
TCPIP$FTPC00109 4422  [STADELMA]TCPIP$FTP_SERVER.LOG;511
TCPIP$FTPC0010A 4423  [STADELMA]TCPIP$FTP_SERVER.LOG;512
APACHE$TOMCAT   441A  
[APACHE.JAKARTA.TOMCAT.work.Catalina.localhost.axis2]axis212120SpezplaService.aar;2
APACHE$TOMCAT   441A  
[APACHE.JAKARTA.TOMCAT.work.Catalina.localhost.axis2]axis212121SpezplaService.aar;2
APACHE$TOMCAT   441A  
[APACHE.JAKARTA.TOMCAT.work.Catalina.localhost.axis2]axis212122SpezplaService.aar;2
APACHE$TOMCAT   441A  
[APACHE.JAKARTA.TOMCAT.work.Catalina.localhost.axis2]axis212123SpezplaService.aar;2
APACHE$TOMCAT   441A  
[APACHE.JAKARTA.TOMCAT.work.Catalina.localhost.axis2]axis212124SpezplaService.aar;2
APACHE$TOMCAT   441A  [wsit.deploy]SPg.wsi;201
APACHE$TOMCAT   441A  
[APACHE.JAKARTA.TOMCAT.work.Catalina.localhost.axis2]axis212125SpezplaService.aar;2
APACHE$TOMCAT   441A  
[APACHE.JAKARTA.TOMCAT.work.Catalina.localhost.axis2]axis212126SpezplaService.aar;2
APACHE$TOMCAT   441A  
[APACHE.JAKARTA.TOMCAT.work.Catalina.localhost.axis2]axis212127SpezplaService.aar;2
APACHE$TOMCAT   441A  
[APACHE.JAKARTA.TOMCAT.work.Catalina.localhost.axis2]axis212128SpezplaService.aar;2
APACHE$TOMCAT   441A  
[APACHE.JAKARTA.TOMCAT.work.Catalina.localhost.axis2]axis212129SpezplaService.aar;2
APACHE$TOMCAT   441A  
[APACHE.JAKARTA.TOMCAT.work.Catalina.localhost.axis2]axis212130SpezplaService.aar;2
APACHE$TOMCAT   441A  [wsit.deploy]SPg.wsi;207
APACHE$TOMCAT   441A  [wsit.deploy]SPg.wsi;208
APACHE$TOMCAT   441A  [wsit.deploy]SPg.wsi;208
APACHE$TOMCAT   441A  [wsit.deploy]SPg.wsi;208
APACHE$TOMCAT   441A  [wsit.deploy]SPg.wsi;209
APACHE$TOMCAT   441A  [wsit.deploy]SPg.wsi;209

2. the night after ...
AXP1>show dev /file




Files accessed on device DSA5: on  3-FEB-2009 07:35:26.30

Process name  PID File name
00

Re: Setting service scope on JAXWS service

2008-09-10 Thread Brian De Pradine
Hi Steve,

I do not believe that there is anyway to do this at the moment. Please 
raise a JIRA issue [1] so that the requirement is not lost.

[1] http://issues.apache.org/jira/browse/AXIS2

Cheers

Brian DePradine
Web Services Development
IBM Hursley
External  +44 (0) 1962 816319 Internal 246319

If you can't find the time to do it right the first time, where will you 
find the time to do it again?


<[EMAIL PROTECTED]> wrote on 09/09/2008 20:50:56:

> Hi everyone,
> 
> I?m fairly new to Axis2.  I?m trying to convert a JAX-WS service 
> that originally ran on the Sun JAXWS reference implementation to run
> using the JAX-WS deployer on Axis2.  It?s annotated using JAX-WS and
> JSR-181 annotations.
> 
> Here?s the problem: the service is a stateful service that is 
> intended to run in application scope.  It looks like the services.
> xml file is ignored when deploying an annotated class to the 
> servicejars folder.  Is there an easy way to specify that I want 
> application scope (via annotations) instead of request scope?  Thanks!
> 
> Steve
> 
> Steve Park, CISSP 
> Wells Fargo Auto Finance
> Strategic Workflows Team, Web Developer
> Phone: 801.246.0087
> Fax: 801.246.0180
> Cell: 801.674.9091
> Email: [EMAIL PROTECTED]
> 
> Recognize a TIG/WFFIS/CSSO Team Member today!
> 
> This message may contain confidential and/or privileged information.
> If you are not the addressee or authorized to receive this for the 
> addressee, you must not use, copy, disclose, or take any action 
> based on this message or any information herein. If you have 
> received this message in error, please advise the sender immediately
> by reply email and delete this message. Thank you for your cooperation. 
> 
>  





Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number 
741598. 
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU







Setting service scope on JAXWS service

2008-09-09 Thread Steve.Park
Hi everyone,

 

I'm fairly new to Axis2.  I'm trying to convert a JAX-WS service that
originally ran on the Sun JAXWS reference implementation to run using
the JAX-WS deployer on Axis2.  It's annotated using JAX-WS and JSR-181
annotations.

 

Here's the problem: the service is a stateful service that is intended
to run in application scope.  It looks like the services.xml file is
ignored when deploying an annotated class to the servicejars folder.  Is
there an easy way to specify that I want application scope (via
annotations) instead of request scope?  Thanks!

 

Steve

 

Steve Park, CISSP 

Wells Fargo Auto Finance

Strategic Workflows Team, Web Developer

Phone: 801.246.0087

Fax: 801.246.0180

Cell: 801.674.9091

Email: [EMAIL PROTECTED]

 

Recognize a TIG/WFFIS/CSSO Team Member today!
<http://wfspeopleportal.homestead.wellsfargo.com/portal/site> 

 

This message may contain confidential and/or privileged information. If
you are not the addressee or authorized to receive this for the
addressee, you must not use, copy, disclose, or take any action based on
this message or any information herein. If you have received this
message in error, please advise the sender immediately by reply email
and delete this message. Thank you for your cooperation. 

 

 



Re: [Axis2] scope documentation error?

2008-05-29 Thread Charitha Kankanamge

Hi Lorenzo,
Service scope should be "application", "soapsession", "transportsession" 
and "request". I changed axis2Config.html document with correct names 
and committed.


thanks
Charitha

Lorenzo Bigagli wrote:


Hi,

the documentation of service configuration 
(http://ws.apache.org/axis2/1_4/axis2config.html#Service_Configuration) 
specifies:


*scope*: (Optional Attribute) The time period during which runtime 
information of the deployed services will be available. Scope is of 
several types- "Application", "SOAPSession", "TransportSession", 
"Request". The default value (if you don't enter any value) will be 
"Request"


However, it seems that setting the scope to "Application" doesn't work.
Instead, "application" works as expected.

I don't know about the other scopes: maybe someone can clarify?
  L



No virus found in this incoming message.
Checked by AVG. 
Version: 7.5.524 / Virus Database: 269.24.2/1471 - Release Date: 5/28/2008 5:33 PM
 




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



[Axis2] scope documentation error?

2008-05-29 Thread Lorenzo Bigagli
Hi,

the documentation of service configuration (
http://ws.apache.org/axis2/1_4/axis2config.html#Service_Configuration)
specifies:

*scope*: (Optional Attribute) The time period during which runtime
information of the deployed services will be available. Scope is of several
types- "Application", "SOAPSession", "TransportSession", "Request". The
default value (if you don't enter any value) will be "Request"

However, it seems that setting the scope to "Application" doesn't work.
Instead, "application" works as expected.

I don't know about the other scopes: maybe someone can clarify?
  L


AW: [Axis 2.1.3] Session gets destroyed in soapsession scope

2008-05-28 Thread Matthias.Gaiser
Hi Mikelantonio,

 

Thanks for answering.

I am sending a SOAP message (with a WS-Adressing header) to the server
and it returns me a service group id in the WS-Adressing-SOAP-Header.
That is how I retrieve the service group id and I send it then with the
following messages.

The actual retrieval of the servicegroupid when a message arrives is
done through axis2, but somehow my session always gets destroyed.

 

My timeout in the axis2.xml is configured as you described.. 3ms. I
call the service again right after it has been finished, so it can't be
the usual timeout. Any ideas what I have might forgotten?

 

Thanks,

Matthias.

 

Von: Michelantonio Trizio [mailto:[EMAIL PROTECTED] 
Gesendet: Montag, 19. Mai 2008 17:15
An: axis-user@ws.apache.org
Betreff: Re: [Axis 2.1.3] Session gets destroyed in soapsession scope

 

Hi,

how do you retrieve the servicegroupid?
However you must control the following parameter in axis2.xml
3
The value is in milliseconds.

   Mikelantonio

2008/5/19 <[EMAIL PROTECTED]>:

Hi group,

 

I am currently implementing a stateful web service based on the
soapsession scope configuration.

 

Now, I can call my webservice and it returns a sessionid. When I call
the webservice a second time with this session id. Then at first the
current session (the one I want to get) is destroyed and I get a SOAP
fault, telling me:

"Unable to find corresponding context for the serviceGroupId:
urn:uuid:36645CAA76105FFF541211205513801".

 

Why does it destroy the session at first hand? Does anybody have some
hints about or a solution for this?

 

Thank you,

Matthias.




-- 
It's creepy, but here we are, the Pilgrims, the crackpots of our time,
trying to establish our own alternate reality. To build a world out of
rocks and chaos. What it's going to be, I don't know. Even after all
that rushing around, where we've ended up is the middle of nowhere in
the middle of the night. And maybe knowing isn't the point. Where we're
standing right now, in the ruins in the dark, what we build could be
anything. [Choke - Chuck Palahniuk] 



Re: [Axis 2.1.3] Session gets destroyed in soapsession scope

2008-05-19 Thread Michelantonio Trizio
Hi,

how do you retrieve the servicegroupid?
However you must control the following parameter in axis2.xml
3
The value is in milliseconds.

   Mikelantonio

2008/5/19 <[EMAIL PROTECTED]>:

>  Hi group,
>
>
>
> I am currently implementing a stateful web service based on the soapsession
> scope configuration.
>
>
>
> Now, I can call my webservice and it returns a sessionid. When I call the
> webservice a second time with this session id. Then at first the current
> session (the one I want to get) is destroyed and I get a SOAP fault, telling
> me:
>
> "Unable to find corresponding context for the serviceGroupId:
> urn:uuid:36645CAA76105FFF541211205513801".
>
>
>
> Why does it destroy the session at first hand? Does anybody have some hints
> about or a solution for this?
>
>
>
> Thank you,
>
> Matthias.
>



-- 
It's creepy, but here we are, the Pilgrims, the crackpots of our time,
trying to establish our own alternate reality. To build a world out of rocks
and chaos. What it's going to be, I don't know. Even after all that rushing
around, where we've ended up is the middle of nowhere in the middle of the
night. And maybe knowing isn't the point. Where we're standing right now, in
the ruins in the dark, what we build could be anything. [Choke - Chuck
Palahniuk]


[Axis 2.1.3] Session gets destroyed in soapsession scope

2008-05-19 Thread Matthias.Gaiser
Hi group,

 

I am currently implementing a stateful web service based on the
soapsession scope configuration.

 

Now, I can call my webservice and it returns a sessionid. When I call
the webservice a second time with this session id. Then at first the
current session (the one I want to get) is destroyed and I get a SOAP
fault, telling me:

"Unable to find corresponding context for the serviceGroupId:
urn:uuid:36645CAA76105FFF541211205513801".

 

Why does it destroy the session at first hand? Does anybody have some
hints about or a solution for this?

 

Thank you,

Matthias.



Re: AXIS2 - Application Service Scope Questions

2008-04-02 Thread Jonathan Joseph
Tbanks Deepal for your informative response.  Now I feel confident on 
how to write my 'application' scoped web service (ie, taking care to be 
threadsafe). 



Deepal jayasinghe wrote:

Jonathan Joseph wrote:
I have a couple of questions regarding Axis2 web services configured 
to run with service scope set to 'Application':


1) Is the web service a singleton?

yes

2) Is the web service thread-safe?

yes and no


I think that the answers are 1) Yes, 2) No. I couldn't find an 
explicit answer in the Axis2 documentation.
Once you deploy a service in application scope we create only one 
instance of the service implementation class. And we store the 
instance in the ServiceContext. So each and every request coming to 
that service uses the same service instance. However in web service 
world we have to write our services in a stateless manner , meaning 
write the class so that we do not store any class level variable in 
the service impl class. Then the service invocation would become 
thread safe as well.


Thank you!
Deepal

-
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 - Application Service Scope Questions

2008-04-01 Thread Deepal jayasinghe

Jonathan Joseph wrote:
I have a couple of questions regarding Axis2 web services configured 
to run with service scope set to 'Application':


1) Is the web service a singleton?

yes

2) Is the web service thread-safe?

yes and no


I think that the answers are 1) Yes, 2) No. I couldn't find an 
explicit answer in the Axis2 documentation.
Once you deploy a service in application scope we create only one 
instance of the service implementation class. And we store the instance 
in the ServiceContext. So each and every request coming to that service 
uses the same service instance. However in web service world we have to 
write our services in a stateless manner , meaning write the class so 
that we do not store any class level variable in the service impl class. 
Then the service invocation would become thread safe as well.


Thank you!
Deepal

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



AXIS2 - Application Service Scope Questions

2008-04-01 Thread Jonathan Joseph
I have a couple of questions regarding Axis2 web services configured to 
run with service scope set to 'Application':


1) Is the web service a singleton?
2) Is the web service thread-safe?

I think that the answers are 1) Yes, 2) No. 
I couldn't find an explicit answer in the Axis2 documentation.


Thanks,
Jonathan

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



Re: axis2 with spring and application scope

2007-11-22 Thread Rolando Cuevas
On Nov 22, 2007 9:39 AM, robert lazarski <[EMAIL PROTECTED]> wrote:
> Does your class have "implements ServiceLifeCycle" ?  Basically,
> ServiceLifeCycle is a axis2 supplied way to do init somewhat like what
> HttpServlet and load-on-startup does - mostly for  any type of inside
> the aar init IIRC. So ServiceLifeCycle is just one option.

Yes The class I use to init Spring implements ServiceLifeCycle.
There are no exceptions in the log. I see the startup method is
called. Also the log shows the spring beans are created.
However when the service is called, the needed beans are not there.
When the service has application scope, it seems as if the classes for
the services are obtained by Axis itself (without using spring)
I also tested the exploded version of my service. It shows the same
behavior, the needed bean s are null.

The easiest way to reproduce the situation is to modify the sample
service pojoguidespring (from axis distribution). When services.xml is
modified to use application scope, the service does not work. (the
sample pojoguidespring works when using scope request).

Thanks.

> Perhaps Deepal can comment on application scope with ServiceLifeCycle
> as I've never tried that. Are you seeing any exceptions in the logs?
>
> I know its possible to run spring outside the aar, using the servlet
> container to init spring via putting all the spring jars in
> WEB-INF/lib .
>
> HTH,
> Robert
>
>
> On Nov 22, 2007 8:08 AM, Rolando Cuevas <[EMAIL PROTECTED]> wrote:
> > I'm using axis2 1.3 with spring 2.0.4. Maybe I'm doing something
> > wrong, I have a  and the services inside the group have
> > scope="application". The services are spring beans, and they
> > themselves use other springbeans. I tested that the scope is working.
> > However, the services are not injected with  the beans they need. (the
> > beans that the services use are null)
> >
> > If you modify the sample service pojoguidespring (from axis
> > distribution) to use application scope, it does not work.
> > (from services.xml
> >> scope="application">
> >   
> > )
> > However when not setting scope (which defaults to request) sample
> > service pojoguidespring  works.
> >
> > Is there a way to use Spring with a servicegroup and services with
> > application scope?
> >
> > Thanks in advance.
> >
> > -
> > 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]
>
>

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



Re: axis2 with spring and application scope

2007-11-22 Thread robert lazarski
Does your class have "implements ServiceLifeCycle" ?  Basically,
ServiceLifeCycle is a axis2 supplied way to do init somewhat like what
HttpServlet and load-on-startup does - mostly for  any type of inside
the aar init IIRC. So ServiceLifeCycle is just one option.

Perhaps Deepal can comment on application scope with ServiceLifeCycle
as I've never tried that. Are you seeing any exceptions in the logs?

I know its possible to run spring outside the aar, using the servlet
container to init spring via putting all the spring jars in
WEB-INF/lib .

HTH,
Robert

On Nov 22, 2007 8:08 AM, Rolando Cuevas <[EMAIL PROTECTED]> wrote:
> I'm using axis2 1.3 with spring 2.0.4. Maybe I'm doing something
> wrong, I have a  and the services inside the group have
> scope="application". The services are spring beans, and they
> themselves use other springbeans. I tested that the scope is working.
> However, the services are not injected with  the beans they need. (the
> beans that the services use are null)
>
> If you modify the sample service pojoguidespring (from axis
> distribution) to use application scope, it does not work.
> (from services.xml
>scope="application">
>   
> )
> However when not setting scope (which defaults to request) sample
> service pojoguidespring  works.
>
> Is there a way to use Spring with a servicegroup and services with
> application scope?
>
> Thanks in advance.
>
> -
> 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 with spring and application scope

2007-11-22 Thread Rolando Cuevas
I'm using axis2 1.3 with spring 2.0.4. Maybe I'm doing something
wrong, I have a  and the services inside the group have
scope="application". The services are spring beans, and they
themselves use other springbeans. I tested that the scope is working.
However, the services are not injected with  the beans they need. (the
beans that the services use are null)

If you modify the sample service pojoguidespring (from axis
distribution) to use application scope, it does not work.
(from services.xml
  
  
)
However when not setting scope (which defaults to request) sample
service pojoguidespring  works.

Is there a way to use Spring with a servicegroup and services with
application scope?

Thanks in advance.

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



how many service instances are created in request scope?

2007-10-03 Thread Michele Mazzucco
Hi all,

I know that if a service is deployed in application scope a new object
instance will be created every time the service is called [1]. Others,
instead, create a single instance [2]. 
Isn't it better to use the second approach, especially if the service is
heavily used (if not, it could be possible to "destroy" the object after
a certain time)?

Thanks,
Michele


[1] http://www.developer.com/java/web/article.php/3620661
[2]
http://weblogs.java.net/blog/kohsuke/archive/2006/10/bringing_state.html


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



Re: Possible to specify session scope with WSDL2Java?

2007-09-24 Thread Stella Lok
Hi,

Is it possible to specify a session scope for WSDL2Java-generated stub
files? I could not find a way to do it.

Much thanks,
Stella


Re: [Axis2]Can't use SSL with scope="transportsession"

2007-08-21 Thread Deepal Jayasinghe
Hi Andrew ,
Please create a JIRA , I think this is an issue in Axis2,

Thanks
Deepal
> When I try to invoke my service via https, Axis2 1.2 throws a
> NullPointerException:
>
> Caused by: java.lang.NullPointerException
>   at
> org.apache.axis2.engine.InstanceDispatcher.fillContextsFromSessionContext(InstanceDispatcher.java:123)
>   at
> org.apache.axis2.engine.InstanceDispatcher.invoke(InstanceDispatcher.java:70)
>   at org.apache.axis2.engine.Phase.invoke(Phase.java:383)
>   at org.apache.axis2.engine.AxisEngine.invoke(AxisEngine.java:203)
>   at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:131)
>   at
> org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:279)
>   at 
> org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:116)
>   ... 33 more
>
> I think I found what's causing it.  My service is defined like this in
> services.xml:
> ...
>
> If I remove 'scope="transportsession"', Axis2 no longer throws this
> Exception, and my own code is invoked (though it causes my code to fail,
> since mc.getSessionContext() returns null).
>
> Is there any reason why 'scope="transportsession"' would work via http
> but not https?
>   



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



[Axis2]Can't use SSL with scope="transportsession"

2007-08-21 Thread Andrew Martin
When I try to invoke my service via https, Axis2 1.2 throws a
NullPointerException:

Caused by: java.lang.NullPointerException
at
org.apache.axis2.engine.InstanceDispatcher.fillContextsFromSessionContext(InstanceDispatcher.java:123)
at
org.apache.axis2.engine.InstanceDispatcher.invoke(InstanceDispatcher.java:70)
at org.apache.axis2.engine.Phase.invoke(Phase.java:383)
at org.apache.axis2.engine.AxisEngine.invoke(AxisEngine.java:203)
at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:131)
at
org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:279)
at 
org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:116)
... 33 more

I think I found what's causing it.  My service is defined like this in
services.xml:
...

If I remove 'scope="transportsession"', Axis2 no longer throws this
Exception, and my own code is invoked (though it causes my code to fail,
since mc.getSessionContext() returns null).

Is there any reason why 'scope="transportsession"' would work via http
but not https?
-- 
Andrew Martin
Computer Programmer
Regenstrief Institute, Inc.
410 West 10th Street, Suite 2000
Indianapolis, IN 46202-3012
Phone: (317) 423-5542
Fax: (317) 423-5695
[EMAIL PROTECTED]


Confidentiality Notice: The contents of this message and any files
transmitted with it may contain confidential and/or privileged
information and are intended solely for the use of the named
addressee(s). Additionally, the information contained herein may have
been disclosed to you from medical records with confidentiality
protected by federal and state laws. Federal regulations and State laws
prohibit you from making further disclosure of such information without
the specific written consent of the person to whom the information
pertains or as otherwise permitted by such regulations. A general
authorization for the release of medical or other information is not
sufficient for this purpose.

If you have received this message in error, please notify the sender by
return e-mail and delete the original message. Any retention,
disclosure, copying, distribution or use of this information by anyone
other than the intended recipient is strictly prohibited.

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



Re: sesion managment, scope=soapsession

2007-07-05 Thread fat suze

Hmmm, that works I guess, but for some reason it seems like there should be
a standard way of doing this. If I can start a session I would like to be
able to end it. But, to summarize, these are the two ways to end a session
in Axis2 1.2 (secretly hoping an Axis developer/expert will say "no, you
just use the _ method that already exists, dummy"):

1) Disable sessions (I think that means operate in request scope ?) and then
write your own session handling as described by Robert (pass in a session id
with each request)

or 2) Just let the session expire when it happens to time out (and probably
add an endSession action to your service so that you can wipe your session
data)...




On 7/4/07, robert lazarski <[EMAIL PROTECTED]> wrote:


I've always thought that web service sessions - in any framework - don't
play nice together or even in the same framework. In the axis2 case, I've
seen a lot of confusion in this area and after reading countless emails and
several articles about it, and reading the code, I still don't entirely get
how it would handle what I typically need. This isn't a criticism - I'm just
saying I think sessions need to be tailored to each specific case beyond the
basics.

Therefore I tend to roll my own and just generate the session key - I like
to use java 5 and UUID - and manage it myself on the server side, forcing
the client to manually pass it back in on every request after login. It took
me a mere two days to write the code and I've used it in several projects
since.

Not very standard, but as I said, the standard ways never really worked
for me. It might be worth exploring rolling your own as its not too
difficult.

HTH,
Robert

On 7/4/07, fat suze <[EMAIL PROTECTED]> wrote:
>
> Does anyone know if there is any documentation anywhere on the web that
> explains axis2 sessions?  Specifically the ending of sessions?  I have
> searched all over the web for how to kill a transport session, and I have
> seen many others asking how to end all types of sessions, but nobody seems
> to know :)  Is it impossible?
> Thanx
> Susanne
>
>
>
> On 7/4/07, Stadelmann Josef <[EMAIL PROTECTED] > wrote:
> >
> > Hi developers ... :-)
> >
> > Running multipple clients, each talkes to an instance of
> > MyService5.java ;
> >
> > MyService5.java has init(), login(), map(), logout(), destroy(),
> > implemented;
> >
> > It was said somewhere in this mailing-list that init() and destroy()
> > methods get called at the proper time by axis2 if they are implemented; this
> > hhrough reflection.
> >
> > My simple question is:
> >
> > How do I properly terminate such a session from my Client code
> > (avoiding problems to axis2) when
> >a) MyService5 runs in scope=soapsession and
> >b) has a long timeout set to 86'400'000 milliseconds (=
> > 24hr's)?
> >c) init() and destroy() are ONLY to be called by axis2 itself
> >
> >
> > Josef Stadelmann
> > @axa-winterthur.ch
> >
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>



Re: simple question about request scope

2007-07-04 Thread Deepal Jayasinghe

> Hi,
>
> My question is: using request scope, ServiceGroupContext has the same
> life time as the invocation of the operation???
Yes.
>
> Do I have to use ConfigurationContext if I want to keep something in
> common to all service invocations or do I have another option???
Yes, if you are going to deploy the service in request scope.

Thanks
Deepal


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



Re: sesion managment, scope=soapsession

2007-07-04 Thread robert lazarski

I've always thought that web service sessions - in any framework - don't
play nice together or even in the same framework. In the axis2 case, I've
seen a lot of confusion in this area and after reading countless emails and
several articles about it, and reading the code, I still don't entirely get
how it would handle what I typically need. This isn't a criticism - I'm just
saying I think sessions need to be tailored to each specific case beyond the
basics.

Therefore I tend to roll my own and just generate the session key - I like
to use java 5 and UUID - and manage it myself on the server side, forcing
the client to manually pass it back in on every request after login. It took
me a mere two days to write the code and I've used it in several projects
since.

Not very standard, but as I said, the standard ways never really worked for
me. It might be worth exploring rolling your own as its not too difficult.

HTH,
Robert

On 7/4/07, fat suze <[EMAIL PROTECTED]> wrote:


Does anyone know if there is any documentation anywhere on the web that
explains axis2 sessions?  Specifically the ending of sessions?  I have
searched all over the web for how to kill a transport session, and I have
seen many others asking how to end all types of sessions, but nobody seems
to know :)  Is it impossible?
Thanx
Susanne



On 7/4/07, Stadelmann Josef <[EMAIL PROTECTED]> wrote:
>
> Hi developers ... :-)
>
> Running multipple clients, each talkes to an instance of MyService5.java
> ;
>
> MyService5.java has init(), login(), map(), logout(), destroy(),
> implemented;
>
> It was said somewhere in this mailing-list that init() and destroy()
> methods get called at the proper time by axis2 if they are implemented; this
> hhrough reflection.
>
> My simple question is:
>
> How do I properly terminate such a session from my Client code (avoiding
> problems to axis2) when
>a) MyService5 runs in scope=soapsession and
>b) has a long timeout set to 86'400'000 milliseconds (= 24hr's)?
>c) init() and destroy() are ONLY to be called by axis2 itself
>
>
> Josef Stadelmann
> @axa-winterthur.ch
>
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



Re: sesion managment, scope=soapsession

2007-07-04 Thread fat suze

Does anyone know if there is any documentation anywhere on the web that
explains axis2 sessions?  Specifically the ending of sessions?  I have
searched all over the web for how to kill a transport session, and I have
seen many others asking how to end all types of sessions, but nobody seems
to know :)  Is it impossible?
Thanx
Susanne



On 7/4/07, Stadelmann Josef <[EMAIL PROTECTED]> wrote:


Hi developers ... :-)

Running multipple clients, each talkes to an instance of MyService5.java;

MyService5.java has init(), login(), map(), logout(), destroy(),
implemented;

It was said somewhere in this mailing-list that init() and destroy()
methods get called at the proper time by axis2 if they are implemented; this
hhrough reflection.

My simple question is:

How do I properly terminate such a session from my Client code (avoiding
problems to axis2) when
   a) MyService5 runs in scope=soapsession and
   b) has a long timeout set to 86'400'000 milliseconds (= 24hr's)?
   c) init() and destroy() are ONLY to be called by axis2 itself


Josef Stadelmann
@axa-winterthur.ch



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




simple question about request scope

2007-07-04 Thread Jorge Fernandez
Hi,

My question is: using request scope, ServiceGroupContext has the same life time 
as the invocation of the operation??? 

Do I have to use ConfigurationContext if I want to keep something in common to 
all service invocations or do I have another option???


Thanks in advance,

Jorge Fernández




-

LLama Gratis a cualquier PC del Mundo.
Llamadas a fijos y móviles desde 1 céntimo por minuto.
http://es.voice.yahoo.com

AW: sesion managment, scope=soapsession

2007-07-04 Thread Stadelmann Josef
Hi developers ... :-)

Running multipple clients, each talkes to an instance of MyService5.java; 

MyService5.java has init(), login(), map(), logout(), destroy(), implemented; 

It was said somewhere in this mailing-list that init() and destroy() methods 
get called at the proper time by axis2 if they are implemented; this hhrough 
reflection.

My simple question is: 

How do I properly terminate such a session from my Client code (avoiding 
problems to axis2) when 
a) MyService5 runs in scope=soapsession and 
b) has a long timeout set to 86'400'000 milliseconds (= 24hr's)?
c) init() and destroy() are ONLY to be called by axis2 itself


Josef Stadelmann
@axa-winterthur.ch



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



RE: Simple Axis2 service in transport session scope, which method is called with each request?

2007-06-25 Thread Ebert, Chris
You should be able to get what you want by implementing a Handler and
adding it to the chain. I use Axis 1.2, so maybe it's a little out of
date, but in the ~.wsdd file you can configure handler objects that are
executed in sequence whenever a request comes in. There are a couple of
places, the 'requestFlow' and 'responseFlow' sections seem likely.

Chris 

-Original Message-
From: fat suze [mailto:[EMAIL PROTECTED] 
Sent: Monday, June 25, 2007 10:59
To: axis-user@ws.apache.org
Subject: Simple Axis2 service in transport session scope, which method
is called with each request?

I sent this on Saturday but I'm pretty sure it didn't make it through to
the list.  I'm sorry if this is a repeat post.

-- Forwarded message --
From: fat suze <[EMAIL PROTECTED]>
Date: Jun 23, 2007 9:28 PM
Subject: Simple Axis2 service in transport session scope, which method
is called with each request?
To: axis-user@ws.apache.org <mailto:axis-user@ws.apache.org> 


I'm trying to find a method that is called every time my service is
accessed.  There is init(ServiceContext) and destroy(ServiceContext)
that is called at the start of each session, but that doesn't help (at
least in transport scope - because that is called at the start/end of
each session I believe). 
 
After hours of googling, I've found mention of two things that don't
seem to actually exist anymore (I assume they did at some point in time)
- 
 
1) init(MessageContext), which was mentioned on
http://www.developer.com/open/print.php/10930_3589126_3 
 
and
 
2) public void setOperationContext(OperationContext operationContext)
which is mentioned at
http://www.developer.com/java/web/article.php/3620661
<http://www.developer.com/java/web/article.php/3620661> 
 
Neither of these seem to work, but obviously there is some simple way to
do something before each operation I just can't find the
documentation on it!
 
Please help, thanks
 
Susie

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



Simple Axis2 service in transport session scope, which method is called with each request?

2007-06-25 Thread fat suze

I sent this on Saturday but I'm pretty sure it didn't make it through to the
list.  I'm sorry if this is a repeat post.

-- Forwarded message --
From: fat suze <[EMAIL PROTECTED]>
Date: Jun 23, 2007 9:28 PM
Subject: Simple Axis2 service in transport session scope, which method is
called with each request?
To: axis-user@ws.apache.org

I'm trying to find a method that is called every time my service is
accessed.  There is init(ServiceContext) and destroy(ServiceContext) that is
called at the start of each session, but that doesn't help (at least in
transport scope - because that is called at the start/end of each session I
believe).

After hours of googling, I've found mention of two things that don't seem to
actually exist anymore (I assume they did at some point in time) -

1) init(MessageContext), which was mentioned on
http://www.developer.com/open/print.php/10930_3589126_3

and

2) public void setOperationContext(OperationContext operationContext) which
is mentioned at http://www.developer.com/java/web/article.php/3620661

Neither of these seem to work, but obviously there is some simple way to do
something before each operation I just can't find the documentation on
it!

Please help, thanks

Susie


Simple Axis2 service in transport session scope, which method is called with each request?

2007-06-23 Thread fat suze

I'm trying to find a method that is called every time my service is
accessed.  There is init(ServiceContext) and destroy(ServiceContext) that is
called at the start of each session, but that doesn't help (at least in
transport scope - because that is called at the start/end of each session I
believe).

After hours of googling, I've found mention of two things that don't seem to
actually exist anymore (I assume they did at some point in time) -

1) init(MessageContext), which was mentioned on
http://www.developer.com/open/print.php/10930_3589126_3

and

2) public void setOperationContext(OperationContext operationContext) which
is mentioned at http://www.developer.com/java/web/article.php/3620661

Neither of these seem to work, but obviously there is some simple way to do
something before each operation I just can't find the documentation on
it!

Please help, thanks

Susie


axis application scope

2007-06-19 Thread ikromchik

hey all!
i've been using axis for just a week :) and hope to get some help here!
if i set my service scope to application, will i be able to have a variable
in my application, and use it each time one calls the service (use it in my
impl class)?

The thing is, i want to have an array, holding some connection pools for a
database, and the amount of the connections is limited. And each time an
implementation class is called, i want to get one of those connectionPools,
use it, and release as soon as the implementation is done. So if there are
no connections left, the rest of the requests will be waiting for one to be
released =)
oh and, where can i place this array? ..considering that i'll have to fill
it with connections at the application start. Will the "skeleton" class be a
good place for it??

thanks in advance!! appreciate!
-- 
View this message in context: 
http://www.nabble.com/axis-application-scope-tf3946374.html#a11194610
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: Another thread safety question (server side) for application scope service

2007-06-01 Thread Francesco Leone

Hi Gul,
Yes, In your scenario Axis2 creates two thread , then both thread invokes
the same istance of the class implementing the service,
so if the methods of this class are not synchronized the state of the
service is not thread-safe.
This is the mechanism for every kind of MessageReceivers.

Francesco

2007/6/1, Gul Onural <[EMAIL PROTECTED]>:


 Is Axis2 thread-safe for "application" scope services that use
RawXMLMessageReceivers?

Basically I am wondering what happens if two clients invokes the same
operation on that type
of service. Does Axis2 create 2 different threads to invoke service's
implementation method for that
operation?

Gul




Another thread safety question (server side) for application scope service

2007-06-01 Thread Gul Onural
Is Axis2 thread-safe for "application" scope services that use
RawXMLMessageReceivers?
 
Basically I am wondering what happens if two clients invokes the same
operation on that type
of service. Does Axis2 create 2 different threads to invoke service's
implementation method for that
operation?
 
Gul
 


Re: [Axis2] service with application scope And multithreading

2007-06-01 Thread Michele Mazzucco

On Fri, 2007-06-01 at 12:55 +0200, Francesco Leone wrote:
> Hi Michele,
> 
> In my case, there are different services running on axis2 . So if I
> set
> the thread pool size to 1 , i have a single thread serving every
> request (of anyone of my services) , doesn't it?

Yes.

> If it is the case, this thread becames a bottleneck for the system and
> it is not a feasible solution. 
>  
> Thanks a lot,
> Regards 
> Francesco
> 
> 
> 
> 2007/6/1, Michele Mazzucco <[EMAIL PROTECTED]>:
> Paul,
> 
> what about setting the axis2 thread pool size to 1?, this
> would
> automatically serialize all requests (I'm assuming that only
> that
> service is deployed).
> 
> Michele
> 
> On Fri, 2007-06-01 at 11:08 +0100, Paul Fremantle wrote: 
> > Francesco
> >
> > Two questions!
> >
> > 1) Is this a one-way or a request reply operation.
> > 2) Have you considered using WSRM which provides inOrder
> delivery (in
> > other words, it gives each message a number and ensures they
> get 
> > delivered in the order of the message numbers)
> >
> > Paul
> >
> > On 6/1/07, Francesco Leone <[EMAIL PROTECTED]> wrote:
> > > Hi,
> > > I have a problem with axis2 and its request management.
> The scenario is the 
> > > sequent: there is a service deployed in application scope.
> > > This service make a blocking call to a synchronized queue.
> If I well
> > > understand Axis2 and its application scope,
> > > it creates a thread for every request for this service and
> every 
> > > thread communicate with the same service object. So it is
> possible that many
> > > thread are blocked for the synchronized queue . The
> problem is that i want
> > > to service the request basing on its arrival time, It's
> important for my 
> > > application semantic, so when the
> > > queue is free i want to notify the first thread arrived to
> axis2.
> > > Any suggestion about resolving this problem?
> > > Thanks,
> > > Regards 
> > > Francesco Leone
> > >
> >
> >
> 
> 
> -
> 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] service with application scope And multithreading

2007-06-01 Thread Paul Fremantle

Francesco

Since this is a one-way operation, you should instead do something different.
You should have Axis2 hand off the results to a service implementation
that is properly multi-threaded and also deployed with request scope.
The service implementation should queue up the messages in a singleton
queue that is synchronized. Then a separate thread will pull the
messages off one-by-one from the queue and execute the logic. This is
exactly what Sandesha2 will do for ordered delivery, but you can do
this in your own logic as well if you don't want to change the
clients. This relies on you only having a single instance of Axis2
(i.e. no cluster).

Paul

On 6/1/07, Francesco Leone <[EMAIL PROTECTED]> wrote:


Hi Paul,


>
>
> Two questions!
>
> 1) Is this a one-way or a request reply operation.

  Is a one way request (i.e. a notification compliant with
WS-Notification 1.3 ).

> 2) Have you considered using WSRM which provides inOrder delivery (in
> other words, it gives each message a number and ensures they get
> delivered in the order of the message numbers)


   Do you mean WS-ReliableMessage? I know that is implemented by
  Sandesha project  but i don't know it very well. So i try to take a look!

  Thanks a lot for your interest,
  Regards
  Francesco

> Paul
>
> On 6/1/07, Francesco Leone < [EMAIL PROTECTED]> wrote:
> > Hi,
> > I have a problem with axis2 and its request management. The scenario is
the
> > sequent: there is a service deployed in application scope.
> > This service make a blocking call to a synchronized queue. If I well
> > understand Axis2 and its application scope,
> > it creates a thread for every request for this service and every
> > thread communicate with the same service object. So it is possible that
many
> > thread are blocked for the synchronized queue . The problem is that i
want
> > to service the request basing on its arrival time, It's important for my
> > application semantic, so when the
> > queue is free i want to notify the first thread arrived to axis2.
> > Any suggestion about resolving this problem?
> > Thanks,
> > Regards
> > Francesco Leone
> >
>
>
> --
> Paul Fremantle
> Co-Founder and VP of Technical Sales, WSO2
> OASIS WS-RX TC Co-chair
>
> blog: http://pzf.fremantle.org
> [EMAIL PROTECTED]
>
> "Oxygenating the Web Service Platform", www.wso2.com
>
>
-
> To unsubscribe, e-mail:
[EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>





--
Paul Fremantle
Co-Founder and VP of Technical Sales, WSO2
OASIS WS-RX TC Co-chair

blog: http://pzf.fremantle.org
[EMAIL PROTECTED]

"Oxygenating the Web Service Platform", www.wso2.com

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



Re: [Axis2] service with application scope And multithreading

2007-06-01 Thread Francesco Leone

Hi Michele,

In my case, there are different services running on axis2 . So if I set
the thread pool size to 1 , i have a single thread serving every request (of
anyone of my services) , doesn't it?
If it is the case, this thread becames a bottleneck for the system and it is
not a feasible solution.

Thanks a lot,
Regards
Francesco



2007/6/1, Michele Mazzucco <[EMAIL PROTECTED]>:


Paul,

what about setting the axis2 thread pool size to 1?, this would
automatically serialize all requests (I'm assuming that only that
service is deployed).

Michele

On Fri, 2007-06-01 at 11:08 +0100, Paul Fremantle wrote:
> Francesco
>
> Two questions!
>
> 1) Is this a one-way or a request reply operation.
> 2) Have you considered using WSRM which provides inOrder delivery (in
> other words, it gives each message a number and ensures they get
> delivered in the order of the message numbers)
>
> Paul
>
> On 6/1/07, Francesco Leone <[EMAIL PROTECTED]> wrote:
> > Hi,
> > I have a problem with axis2 and its request management. The scenario
is the
> > sequent: there is a service deployed in application scope.
> > This service make a blocking call to a synchronized queue. If I well
> > understand Axis2 and its application scope,
> > it creates a thread for every request for this service and every
> > thread communicate with the same service object. So it is possible
that many
> > thread are blocked for the synchronized queue . The problem is that i
want
> > to service the request basing on its arrival time, It's important for
my
> > application semantic, so when the
> > queue is free i want to notify the first thread arrived to axis2.
> > Any suggestion about resolving this problem?
> > Thanks,
> > Regards
> > Francesco Leone
> >
>
>


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




Re: [Axis2] service with application scope And multithreading

2007-06-01 Thread Francesco Leone

Hi Paul,




Two questions!

1) Is this a one-way or a request reply operation.



 Is a one way request (i.e. a notification compliant with
WS-Notification 1.3 ).

2) Have you considered using WSRM which provides inOrder delivery (in

other words, it gives each message a number and ensures they get
delivered in the order of the message numbers)




 Do you mean WS-ReliableMessage? I know that is implemented by
 Sandesha project  but i don't know it very well. So i try to take a look!

 Thanks a lot for your interest,
 Regards
 Francesco



Paul

On 6/1/07, Francesco Leone <[EMAIL PROTECTED]> wrote:
> Hi,
> I have a problem with axis2 and its request management. The scenario is
the
> sequent: there is a service deployed in application scope.
> This service make a blocking call to a synchronized queue. If I well
> understand Axis2 and its application scope,
> it creates a thread for every request for this service and every
> thread communicate with the same service object. So it is possible that
many
> thread are blocked for the synchronized queue . The problem is that i
want
> to service the request basing on its arrival time, It's important for my
> application semantic, so when the
> queue is free i want to notify the first thread arrived to axis2.
> Any suggestion about resolving this problem?
> Thanks,
> Regards
> Francesco Leone
>


--
Paul Fremantle
Co-Founder and VP of Technical Sales, WSO2
OASIS WS-RX TC Co-chair

blog: http://pzf.fremantle.org
[EMAIL PROTECTED]

"Oxygenating the Web Service Platform", www.wso2.com

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




Re: [Axis2] service with application scope And multithreading

2007-06-01 Thread Michele Mazzucco
Paul,

what about setting the axis2 thread pool size to 1?, this would
automatically serialize all requests (I'm assuming that only that
service is deployed).

Michele

On Fri, 2007-06-01 at 11:08 +0100, Paul Fremantle wrote:
> Francesco
> 
> Two questions!
> 
> 1) Is this a one-way or a request reply operation.
> 2) Have you considered using WSRM which provides inOrder delivery (in
> other words, it gives each message a number and ensures they get
> delivered in the order of the message numbers)
> 
> Paul
> 
> On 6/1/07, Francesco Leone <[EMAIL PROTECTED]> wrote:
> > Hi,
> > I have a problem with axis2 and its request management. The scenario is the
> > sequent: there is a service deployed in application scope.
> > This service make a blocking call to a synchronized queue. If I well
> > understand Axis2 and its application scope,
> > it creates a thread for every request for this service and every
> > thread communicate with the same service object. So it is possible that many
> > thread are blocked for the synchronized queue . The problem is that i want
> > to service the request basing on its arrival time, It's important for my
> > application semantic, so when the
> > queue is free i want to notify the first thread arrived to axis2.
> > Any suggestion about resolving this problem?
> > Thanks,
> > Regards
> > Francesco Leone
> >
> 
> 


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



Re: [Axis2] service with application scope And multithreading

2007-06-01 Thread Paul Fremantle

Francesco

Two questions!

1) Is this a one-way or a request reply operation.
2) Have you considered using WSRM which provides inOrder delivery (in
other words, it gives each message a number and ensures they get
delivered in the order of the message numbers)

Paul

On 6/1/07, Francesco Leone <[EMAIL PROTECTED]> wrote:

Hi,
I have a problem with axis2 and its request management. The scenario is the
sequent: there is a service deployed in application scope.
This service make a blocking call to a synchronized queue. If I well
understand Axis2 and its application scope,
it creates a thread for every request for this service and every
thread communicate with the same service object. So it is possible that many
thread are blocked for the synchronized queue . The problem is that i want
to service the request basing on its arrival time, It's important for my
application semantic, so when the
queue is free i want to notify the first thread arrived to axis2.
Any suggestion about resolving this problem?
Thanks,
Regards
Francesco Leone




--
Paul Fremantle
Co-Founder and VP of Technical Sales, WSO2
OASIS WS-RX TC Co-chair

blog: http://pzf.fremantle.org
[EMAIL PROTECTED]

"Oxygenating the Web Service Platform", www.wso2.com

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



[Axis2] service with application scope And multithreading

2007-06-01 Thread Francesco Leone

Hi,
I have a problem with axis2 and its request management. The scenario is the
sequent: there is a service deployed in application scope.
This service make a blocking call to a synchronized queue. If I well
understand Axis2 and its application scope,
it creates a thread for every request for this service and every
thread communicate with the same service object. So it is possible that many

thread are blocked for the synchronized queue . The problem is that i want
to service the request basing on its arrival time, It's important for my
application semantic, so when the
queue is free i want to notify the first thread arrived to axis2.
Any suggestion about resolving this problem?
Thanks,
Regards
Francesco Leone


Re: init and destroy functions in an application scope axis2 service

2007-05-29 Thread Deepal Jayasinghe
Hi Gul

>  
> I see init and destroy functions implemented in one of the samples
> (servicelifecycle) in Axis2 distro.
>  
> public void init(ServiceContext serviceContext)
> public void destroy(ServiceContext serviceContext) throws AxisFault
>  
> *When are these functions get invoked for a service that is deployed
> as "application" scope service?*
Servicelifecycle has nothing to do with the service scope , the life
cycle will help you to manage the lifetime of a your service
(description) , not the contexts. 
Service lifecycle will help you to do something like open a DB
connection when you deploy the service and  to close that when system
shutdown.
> *What happens if an "application" scope service doesn't implement
> those functions?*
Nothing will happen.
> ** 
> Gul

-- 
Thanks,
Deepal

"The highest tower is built one brick at a time"



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



init and destroy functions in an application scope axis2 service

2007-05-29 Thread Gul Onural
 
I see init and destroy functions implemented in one of the samples
(servicelifecycle) in Axis2 distro.
 
public void init(ServiceContext serviceContext) 
public void destroy(ServiceContext serviceContext) throws AxisFault
 
When are these functions get invoked for a service that is deployed as
"application" scope service?
What happens if an "application" scope service doesn't implement those
functions?
 
Gul


Re: [axis2 ]soap session scope does not work

2007-05-02 Thread Paul Fremantle

Nencho

Yes, the conversation initiation will happen on the first call - no
matter what operation.
I think there are good samples in Rampart. They are the best approach
to getting started with Rampart.

Paul



On 5/2/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:

Hi Paul,

Do you know if with the Secure conversation i can force the client
to send the username token only the first time without having the login
operation, or
I still need this entry point?

Is there any usefull documentation on the rampart secure conv.
implementation?


Thanks,
Nencho


2007/4/27, Paul Fremantle <[EMAIL PROTECTED]>:
> Nencho
>
> With any third-party users of your service, you do need to give them
> some additional documentation! The WSDL and Policy are a good starting
> point, but the developer still needs to understand the business
> processes behind the services.
>
> However, you are right that secureconversation will also give you the
> pattern you want, where the initial login is used to create a token,
> which is then passed with every request.
>
> Paul
>
> On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> > Hi Paul,
> >
> > Thanks for the constructive idea :).anyway,I can't confirm that  these
> > services will  be invoked only by my client code.
> > Consider some third party client - i cannot force himm to call first the
> > login operation, though it is obvious that
> > the rest of the operations will deny to be executed first.
> >
> > Maybe i am stick with the Ws Secure conv implemented in rampart, does
> > someone has tested it with username token sent only the first time?
> >
> >
> > thanks,
> > Nencho
> >
> >
> > 2007/4/27, Paul Fremantle <[EMAIL PROTECTED]>:
> > > Nencho
> > >
> > > You can specify different policies per operation with Axis2. So you
> > > need to identify a specific operation that is the "login" operation -
> > > i.e. the one that users call first (and only first), and statically
> > > specify a different policy for this one.
> > >
> > > I'm not suggesting changing the policy at runtime. That won't work -
> > > certainly not at the server side.
> > >
> > > Paul
> > >
> > > On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> > > > Hi Paul,
> > > >
> > > > Having different policies includes ex-changing them runtime.
> > > >
> > > > 1. Is that posible with axis2 without redeploying the service?
> > > > 2. How this correlates to the session, because i expect different
> > clients to
> > > > connect to this
> > > > service and i cannot just change the policiy since one of the will
be at
> > the
> > > > login state and another will
> > > > be already loged in.
> > > > 3. does WS secure conversation way overcome those problems?
> > > >
> > > > thanks,
> > > > Nencho
> > > >
> > > >
> > > > 2007/4/27, Paul Fremantle < [EMAIL PROTECTED]>:
> > > > > Nencho
> > > > >
> > > > > If you want to do this, you need to have two different policies.
> > > > >
> > > > > One for the "login" operation/service, which uses UT, and the
other
> > > > > for the rest of the operations, which has encryption (if needed)
but
> > > > > no UT. Obviously you need to write your own logic to ensure that
you
> > > > > check the session is available for those other operations.
> > > > >
> > > > > Paul
> > > > >
> > > > > On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> > > > > > Hi Deepal,
> > > > > >
> > > > > > I have yet another question/issue about the sessions.
> > > > > > I am using UsernameToken in a ws security policy handled by
rampart.
> > > > > > I want to use axis2 sessions so i pass the user/pass only once
and
> > then
> > > > rely
> > > > > > on the
> > > > > > session to recognize me on a subsequent call.the point is that
the
> > > > rampart
> > > > > > policy
> > > > > > is alredy there and will expect a username token in every
request.
> > > > > > Is there any way to overcome this?
> > > > > >
> > > > > > thanks,
> > > > > > Nencho
> > > > > >
> > > > > >
> > > > 

Re: [axis2 ]soap session scope does not work

2007-05-01 Thread Nencho Lupanov

Hi Paul,

Do you know if with the Secure conversation i can force the client
to send the username token only the first time without having the login
operation, or
I still need this entry point?

Is there any usefull documentation on the rampart secure conv.
implementation?

Thanks,
Nencho


2007/4/27, Paul Fremantle <[EMAIL PROTECTED]>:


Nencho

With any third-party users of your service, you do need to give them
some additional documentation! The WSDL and Policy are a good starting
point, but the developer still needs to understand the business
processes behind the services.

However, you are right that secureconversation will also give you the
pattern you want, where the initial login is used to create a token,
which is then passed with every request.

Paul

On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> Hi Paul,
>
> Thanks for the constructive idea :).anyway,I can't confirm that  these
> services will  be invoked only by my client code.
> Consider some third party client - i cannot force himm to call first the
> login operation, though it is obvious that
> the rest of the operations will deny to be executed first.
>
> Maybe i am stick with the Ws Secure conv implemented in rampart, does
> someone has tested it with username token sent only the first time?
>
>
> thanks,
> Nencho
>
>
> 2007/4/27, Paul Fremantle <[EMAIL PROTECTED]>:
> > Nencho
> >
> > You can specify different policies per operation with Axis2. So you
> > need to identify a specific operation that is the "login" operation -
> > i.e. the one that users call first (and only first), and statically
> > specify a different policy for this one.
> >
> > I'm not suggesting changing the policy at runtime. That won't work -
> > certainly not at the server side.
> >
> > Paul
> >
> > On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> > > Hi Paul,
> > >
> > > Having different policies includes ex-changing them runtime.
> > >
> > > 1. Is that posible with axis2 without redeploying the service?
> > > 2. How this correlates to the session, because i expect different
> clients to
> > > connect to this
> > > service and i cannot just change the policiy since one of the will
be at
> the
> > > login state and another will
> > > be already loged in.
> > > 3. does WS secure conversation way overcome those problems?
> > >
> > > thanks,
> > > Nencho
> > >
> > >
> > > 2007/4/27, Paul Fremantle < [EMAIL PROTECTED]>:
> > > > Nencho
> > > >
> > > > If you want to do this, you need to have two different policies.
> > > >
> > > > One for the "login" operation/service, which uses UT, and the
other
> > > > for the rest of the operations, which has encryption (if needed)
but
> > > > no UT. Obviously you need to write your own logic to ensure that
you
> > > > check the session is available for those other operations.
> > > >
> > > > Paul
> > > >
> > > > On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> > > > > Hi Deepal,
> > > > >
> > > > > I have yet another question/issue about the sessions.
> > > > > I am using UsernameToken in a ws security policy handled by
rampart.
> > > > > I want to use axis2 sessions so i pass the user/pass only once
and
> then
> > > rely
> > > > > on the
> > > > > session to recognize me on a subsequent call.the point is that
the
> > > rampart
> > > > > policy
> > > > > is alredy there and will expect a username token in every
request.
> > > > > Is there any way to overcome this?
> > > > >
> > > > > thanks,
> > > > > Nencho
> > > > >
> > > > >
> > > > > 2007/4/26, Deepal Jayasinghe < [EMAIL PROTECTED]>:
> > > > > > Hi Nencho,
> > > > > > Yes we found that issue and we have fixed that in the 1.2branch
> and
> > > the
> > > > > > fixes will be available in 1.2 release.
> > > > > >
> > > > > > Thanks
> > > > > > Deepal
> > > > > >
> > > > > > > Hi Deepal,
> > > > > > >
> > > > > > > I checked the test and yes i was able to run it successfull.
> > > > > > > anyway, when i try to put this in my running enviroment i
get
> this
> > > > > 

Re: [axis2 ]soap session scope does not work

2007-04-27 Thread Paul Fremantle

Nencho

With any third-party users of your service, you do need to give them
some additional documentation! The WSDL and Policy are a good starting
point, but the developer still needs to understand the business
processes behind the services.

However, you are right that secureconversation will also give you the
pattern you want, where the initial login is used to create a token,
which is then passed with every request.

Paul

On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:

Hi Paul,

Thanks for the constructive idea :).anyway,I can't confirm that  these
services will  be invoked only by my client code.
Consider some third party client - i cannot force himm to call first the
login operation, though it is obvious that
the rest of the operations will deny to be executed first.

Maybe i am stick with the Ws Secure conv implemented in rampart, does
someone has tested it with username token sent only the first time?


thanks,
Nencho


2007/4/27, Paul Fremantle <[EMAIL PROTECTED]>:
> Nencho
>
> You can specify different policies per operation with Axis2. So you
> need to identify a specific operation that is the "login" operation -
> i.e. the one that users call first (and only first), and statically
> specify a different policy for this one.
>
> I'm not suggesting changing the policy at runtime. That won't work -
> certainly not at the server side.
>
> Paul
>
> On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> > Hi Paul,
> >
> > Having different policies includes ex-changing them runtime.
> >
> > 1. Is that posible with axis2 without redeploying the service?
> > 2. How this correlates to the session, because i expect different
clients to
> > connect to this
> > service and i cannot just change the policiy since one of the will be at
the
> > login state and another will
> > be already loged in.
> > 3. does WS secure conversation way overcome those problems?
> >
> > thanks,
> > Nencho
> >
> >
> > 2007/4/27, Paul Fremantle < [EMAIL PROTECTED]>:
> > > Nencho
> > >
> > > If you want to do this, you need to have two different policies.
> > >
> > > One for the "login" operation/service, which uses UT, and the other
> > > for the rest of the operations, which has encryption (if needed) but
> > > no UT. Obviously you need to write your own logic to ensure that you
> > > check the session is available for those other operations.
> > >
> > > Paul
> > >
> > > On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> > > > Hi Deepal,
> > > >
> > > > I have yet another question/issue about the sessions.
> > > > I am using UsernameToken in a ws security policy handled by rampart.
> > > > I want to use axis2 sessions so i pass the user/pass only once and
then
> > rely
> > > > on the
> > > > session to recognize me on a subsequent call.the point is that the
> > rampart
> > > > policy
> > > > is alredy there and will expect a username token in every request.
> > > > Is there any way to overcome this?
> > > >
> > > > thanks,
> > > > Nencho
> > > >
> > > >
> > > > 2007/4/26, Deepal Jayasinghe < [EMAIL PROTECTED]>:
> > > > > Hi Nencho,
> > > > > Yes we found that issue and we have fixed that in the 1.2 branch
and
> > the
> > > > > fixes will be available in 1.2 release.
> > > > >
> > > > > Thanks
> > > > > Deepal
> > > > >
> > > > > > Hi Deepal,
> > > > > >
> > > > > > I checked the test and yes i was able to run it successfull.
> > > > > > anyway, when i try to put this in my running enviroment i get
this
> > > > > > strange error:
> > > > > >
> > > > > >  [java] Exception in thread "main"
org.apache.axis2.AxisFault:
> > > > > > Unable to fin
> > > > > > d corresponding context for the serviceGroupId:
> > > > > > urn:uuid:97198317A8B28D4CDF11775
> > > > > > 98325288
> > > > > >
> > > > > > In services.xml on the server side i have the
> > > > > >
> > > > > > scope
> > > > > >
> > > > > > ="soapsession" attribute
> > > > > >
> > > > > > At the client side I have the following code
> > > > > >
> > > > > &g

Re: [axis2 ]soap session scope does not work

2007-04-27 Thread Nencho Lupanov

Hi Paul,

Having different policies includes ex-changing them runtime.

1. Is that posible with axis2 without redeploying the service?
2. How this correlates to the session, because i expect different clients to
connect to this
service and i cannot just change the policiy since one of the will be at the
login state and another will
be already loged in.
3. does WS secure conversation way overcome those problems?

thanks,
Nencho


2007/4/27, Paul Fremantle <[EMAIL PROTECTED]>:


Nencho

If you want to do this, you need to have two different policies.

One for the "login" operation/service, which uses UT, and the other
for the rest of the operations, which has encryption (if needed) but
no UT. Obviously you need to write your own logic to ensure that you
check the session is available for those other operations.

Paul

On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> Hi Deepal,
>
> I have yet another question/issue about the sessions.
> I am using UsernameToken in a ws security policy handled by rampart.
> I want to use axis2 sessions so i pass the user/pass only once and then
rely
> on the
> session to recognize me on a subsequent call.the point is that the
rampart
> policy
> is alredy there and will expect a username token in every request.
> Is there any way to overcome this?
>
> thanks,
> Nencho
>
>
> 2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]>:
> > Hi Nencho,
> > Yes we found that issue and we have fixed that in the 1.2 branch and
the
> > fixes will be available in 1.2 release.
> >
> > Thanks
> > Deepal
> >
> > > Hi Deepal,
> > >
> > > I checked the test and yes i was able to run it successfull.
> > > anyway, when i try to put this in my running enviroment i get this
> > > strange error:
> > >
> > >  [java] Exception in thread "main" org.apache.axis2.AxisFault:
> > > Unable to fin
> > > d corresponding context for the serviceGroupId:
> > > urn:uuid:97198317A8B28D4CDF11775
> > > 98325288
> > >
> > > In services.xml on the server side i have the
> > >
> > > scope
> > >
> > > ="soapsession" attribute
> > >
> > > At the client side I have the following code
> > >
> > > *options.setManageSession (true);   *
> > >
> > > *...*
> > >
> > > client.engageModule(new QName("addressing"));
> > >
> > > Is there anything else to configure?
> > >
> > > Thanks,
> > >
> > > Nencho
> > >
> > >
> > >
> > > 2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]
> > > <mailto:[EMAIL PROTECTED]>>:
> > >
> > > Hi Nencho ,
> > >
> > > Axis2 soap session to be work , you need to engage addressing in
> both
> > > the side.
> > >
> > > It is working , there is a test case in the build so we are
> > > testing that
> > > daily.
> > > org.apache.axis2.engine.ServiceGroupContextTest
> > >
> > > Thanks
> > > Deepal
> > >
> > > > Hi All,
> > > >
> > > > I read this axis2 session management article:
> > > >
> http://www.developer.com/java/web/article.php/3620661
> > > >
> > > > Basically, it says that i can define my services being of a
soap
> > > > session scope,
> > > > then i have to put this option on my client:
> > > > *options.setManageSession(true);*
> > > >
> > > > Therefore it is expected for the service to include
> > > > 
> > > > element as an session identifier in the soap envelope.
> > > >
> > > > I tested this and it does not work - axis2 does not put that
> > > element,
> > > > in order
> > > > to be used as session identifier.Am i missing something or
this
> > > is a bug?
> > > >
> > > > Thanks,
> > > > Nencho
> > > >
> > > >
> > >
> > >
> > > --
> > > Thanks,
> > > Deepal
> > >
> 
> > > "The highest tower is built one brick at a time"
> > >
> > >
> > >
> > >
> -
> > > 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]
> >
> >
>
>


--
Paul Fremantle
VP/Technology, WSO2 and OASIS WS-RX TC Co-chair

http://bloglines.com/blog/paulfremantle
[EMAIL PROTECTED]

"Oxygenating the Web Service Platform", www.wso2.com

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




Re: [axis2 ]soap session scope does not work

2007-04-27 Thread Nencho Lupanov

Hi Paul,

Thanks for the constructive idea :).anyway,I can't confirm that  these
services will  be invoked only by my client code.
Consider some third party client - i cannot force himm to call first the
login operation, though it is obvious that
the rest of the operations will deny to be executed first.

Maybe i am stick with the Ws Secure conv implemented in rampart, does
someone has tested it with username token sent only the first time?

thanks,
Nencho


2007/4/27, Paul Fremantle <[EMAIL PROTECTED]>:


Nencho

You can specify different policies per operation with Axis2. So you
need to identify a specific operation that is the "login" operation -
i.e. the one that users call first (and only first), and statically
specify a different policy for this one.

I'm not suggesting changing the policy at runtime. That won't work -
certainly not at the server side.

Paul

On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> Hi Paul,
>
> Having different policies includes ex-changing them runtime.
>
> 1. Is that posible with axis2 without redeploying the service?
> 2. How this correlates to the session, because i expect different
clients to
> connect to this
> service and i cannot just change the policiy since one of the will be at
the
> login state and another will
> be already loged in.
> 3. does WS secure conversation way overcome those problems?
>
> thanks,
> Nencho
>
>
> 2007/4/27, Paul Fremantle <[EMAIL PROTECTED]>:
> > Nencho
> >
> > If you want to do this, you need to have two different policies.
> >
> > One for the "login" operation/service, which uses UT, and the other
> > for the rest of the operations, which has encryption (if needed) but
> > no UT. Obviously you need to write your own logic to ensure that you
> > check the session is available for those other operations.
> >
> > Paul
> >
> > On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> > > Hi Deepal,
> > >
> > > I have yet another question/issue about the sessions.
> > > I am using UsernameToken in a ws security policy handled by rampart.
> > > I want to use axis2 sessions so i pass the user/pass only once and
then
> rely
> > > on the
> > > session to recognize me on a subsequent call.the point is that the
> rampart
> > > policy
> > > is alredy there and will expect a username token in every request.
> > > Is there any way to overcome this?
> > >
> > > thanks,
> > > Nencho
> > >
> > >
> > > 2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]>:
> > > > Hi Nencho,
> > > > Yes we found that issue and we have fixed that in the 1.2 branch
and
> the
> > > > fixes will be available in 1.2 release.
> > > >
> > > > Thanks
> > > > Deepal
> > > >
> > > > > Hi Deepal,
> > > > >
> > > > > I checked the test and yes i was able to run it successfull.
> > > > > anyway, when i try to put this in my running enviroment i get
this
> > > > > strange error:
> > > > >
> > > > >  [java] Exception in thread "main"
org.apache.axis2.AxisFault:
> > > > > Unable to fin
> > > > > d corresponding context for the serviceGroupId:
> > > > > urn:uuid:97198317A8B28D4CDF11775
> > > > > 98325288
> > > > >
> > > > > In services.xml on the server side i have the
> > > > >
> > > > > scope
> > > > >
> > > > > ="soapsession" attribute
> > > > >
> > > > > At the client side I have the following code
> > > > >
> > > > > *options.setManageSession (true);   *
> > > > >
> > > > > *...*
> > > > >
> > > > > client.engageModule(new QName("addressing"));
> > > > >
> > > > > Is there anything else to configure?
> > > > >
> > > > > Thanks,
> > > > >
> > > > > Nencho
> > > > >
> > > > >
> > > > >
> > > > > 2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]
> > > > > <mailto:[EMAIL PROTECTED] >>:
> > > > >
> > > > > Hi Nencho ,
> > > > >
> > > > > Axis2 soap session to be work , you need to engage
addressing in
> > > both
> > > > > the side.
> > > > >
> > > > > It is worki

Re: [axis2 ]soap session scope does not work

2007-04-27 Thread Paul Fremantle

Nencho

You can specify different policies per operation with Axis2. So you
need to identify a specific operation that is the "login" operation -
i.e. the one that users call first (and only first), and statically
specify a different policy for this one.

I'm not suggesting changing the policy at runtime. That won't work -
certainly not at the server side.

Paul

On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:

Hi Paul,

Having different policies includes ex-changing them runtime.

1. Is that posible with axis2 without redeploying the service?
2. How this correlates to the session, because i expect different clients to
connect to this
service and i cannot just change the policiy since one of the will be at the
login state and another will
be already loged in.
3. does WS secure conversation way overcome those problems?

thanks,
Nencho


2007/4/27, Paul Fremantle <[EMAIL PROTECTED]>:
> Nencho
>
> If you want to do this, you need to have two different policies.
>
> One for the "login" operation/service, which uses UT, and the other
> for the rest of the operations, which has encryption (if needed) but
> no UT. Obviously you need to write your own logic to ensure that you
> check the session is available for those other operations.
>
> Paul
>
> On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> > Hi Deepal,
> >
> > I have yet another question/issue about the sessions.
> > I am using UsernameToken in a ws security policy handled by rampart.
> > I want to use axis2 sessions so i pass the user/pass only once and then
rely
> > on the
> > session to recognize me on a subsequent call.the point is that the
rampart
> > policy
> > is alredy there and will expect a username token in every request.
> > Is there any way to overcome this?
> >
> > thanks,
> > Nencho
> >
> >
> > 2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]>:
> > > Hi Nencho,
> > > Yes we found that issue and we have fixed that in the 1.2 branch and
the
> > > fixes will be available in 1.2 release.
> > >
> > > Thanks
> > > Deepal
> > >
> > > > Hi Deepal,
> > > >
> > > > I checked the test and yes i was able to run it successfull.
> > > > anyway, when i try to put this in my running enviroment i get this
> > > > strange error:
> > > >
> > > >  [java] Exception in thread "main" org.apache.axis2.AxisFault:
> > > > Unable to fin
> > > > d corresponding context for the serviceGroupId:
> > > > urn:uuid:97198317A8B28D4CDF11775
> > > > 98325288
> > > >
> > > > In services.xml on the server side i have the
> > > >
> > > > scope
> > > >
> > > > ="soapsession" attribute
> > > >
> > > > At the client side I have the following code
> > > >
> > > > *options.setManageSession (true);   *
> > > >
> > > > *...*
> > > >
> > > > client.engageModule(new QName("addressing"));
> > > >
> > > > Is there anything else to configure?
> > > >
> > > > Thanks,
> > > >
> > > > Nencho
> > > >
> > > >
> > > >
> > > > 2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]
> > > > <mailto:[EMAIL PROTECTED] >>:
> > > >
> > > > Hi Nencho ,
> > > >
> > > > Axis2 soap session to be work , you need to engage addressing in
> > both
> > > > the side.
> > > >
> > > > It is working , there is a test case in the build so we are
> > > > testing that
> > > > daily.
> > > > org.apache.axis2.engine.ServiceGroupContextTest
> > > >
> > > > Thanks
> > > > Deepal
> > > >
> > > > > Hi All,
> > > > >
> > > > > I read this axis2 session management article:
> > > > >
> > http://www.developer.com/java/web/article.php/3620661
> > > > >
> > > > > Basically, it says that i can define my services being of a
soap
> > > > > session scope,
> > > > > then i have to put this option on my client:
> > > > > *options.setManageSession(true);*
> > > > >
> > > > > Therefore it is expected for the service to include
> > > > > 
> > > > > element a

Re: [axis2 ]soap session scope does not work

2007-04-27 Thread Paul Fremantle

Nencho

If you want to do this, you need to have two different policies.

One for the "login" operation/service, which uses UT, and the other
for the rest of the operations, which has encryption (if needed) but
no UT. Obviously you need to write your own logic to ensure that you
check the session is available for those other operations.

Paul

On 4/27/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:

Hi Deepal,

I have yet another question/issue about the sessions.
I am using UsernameToken in a ws security policy handled by rampart.
I want to use axis2 sessions so i pass the user/pass only once and then rely
on the
session to recognize me on a subsequent call.the point is that the rampart
policy
is alredy there and will expect a username token in every request.
Is there any way to overcome this?

thanks,
Nencho


2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]>:
> Hi Nencho,
> Yes we found that issue and we have fixed that in the 1.2 branch and the
> fixes will be available in 1.2 release.
>
> Thanks
> Deepal
>
> > Hi Deepal,
> >
> > I checked the test and yes i was able to run it successfull.
> > anyway, when i try to put this in my running enviroment i get this
> > strange error:
> >
> >  [java] Exception in thread "main" org.apache.axis2.AxisFault:
> > Unable to fin
> > d corresponding context for the serviceGroupId:
> > urn:uuid:97198317A8B28D4CDF11775
> > 98325288
> >
> > In services.xml on the server side i have the
> >
> > scope
> >
> > ="soapsession" attribute
> >
> > At the client side I have the following code
> >
> > *options.setManageSession (true);   *
> >
> > *...*
> >
> > client.engageModule(new QName("addressing"));
> >
> > Is there anything else to configure?
> >
> > Thanks,
> >
> > Nencho
> >
> >
> >
> > 2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>>:
> >
> > Hi Nencho ,
> >
> > Axis2 soap session to be work , you need to engage addressing in
both
> > the side.
> >
> > It is working , there is a test case in the build so we are
> > testing that
> >     daily.
> > org.apache.axis2.engine.ServiceGroupContextTest
> >
> > Thanks
> > Deepal
> >
> > > Hi All,
> > >
> > > I read this axis2 session management article:
> > >
http://www.developer.com/java/web/article.php/3620661
> > >
> > > Basically, it says that i can define my services being of a soap
> > > session scope,
> > > then i have to put this option on my client:
> > > *options.setManageSession(true);*
> > >
> > > Therefore it is expected for the service to include
> > > 
> > > element as an session identifier in the soap envelope.
> > >
> > > I tested this and it does not work - axis2 does not put that
> > element,
> > > in order
> > > to be used as session identifier.Am i missing something or this
> > is a bug?
> > >
> > > Thanks,
> > > Nencho
> > >
> > >
> >
> >
> > --
> > Thanks,
> > Deepal
> >

> > "The highest tower is built one brick at a time"
> >
> >
> >
> >
-
> > 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]
>
>





--
Paul Fremantle
VP/Technology, WSO2 and OASIS WS-RX TC Co-chair

http://bloglines.com/blog/paulfremantle
[EMAIL PROTECTED]

"Oxygenating the Web Service Platform", www.wso2.com

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



Re: [axis2 ]soap session scope does not work

2007-04-27 Thread Nencho Lupanov

Hi Deepal,

I have yet another question/issue about the sessions.
I am using UsernameToken in a ws security policy handled by rampart.
I want to use axis2 sessions so i pass the user/pass only once and then rely
on the
session to recognize me on a subsequent call.the point is that the rampart
policy
is alredy there and will expect a username token in every request.
Is there any way to overcome this?

thanks,
Nencho


2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]>:


Hi Nencho,
Yes we found that issue and we have fixed that in the 1.2 branch and the
fixes will be available in 1.2 release.

Thanks
Deepal

> Hi Deepal,
>
> I checked the test and yes i was able to run it successfull.
> anyway, when i try to put this in my running enviroment i get this
> strange error:
>
>  [java] Exception in thread "main" org.apache.axis2.AxisFault:
> Unable to fin
> d corresponding context for the serviceGroupId:
> urn:uuid:97198317A8B28D4CDF11775
> 98325288
>
> In services.xml on the server side i have the
>
> scope
>
> ="soapsession" attribute
>
> At the client side I have the following code
>
> *options.setManageSession(true);   *
>
> *...*
>
> client.engageModule(new QName("addressing"));
>
> Is there anything else to configure?
>
> Thanks,
>
> Nencho
>
>
>
> 2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]
> <mailto:[EMAIL PROTECTED]>>:
>
> Hi Nencho ,
>
> Axis2 soap session to be work , you need to engage addressing in
both
> the side.
>
> It is working , there is a test case in the build so we are
> testing that
> daily.
> org.apache.axis2.engine.ServiceGroupContextTest
>
> Thanks
> Deepal
>
> > Hi All,
> >
> > I read this axis2 session management article:
> > http://www.developer.com/java/web/article.php/3620661
> >
> > Basically, it says that i can define my services being of a soap
> > session scope,
> > then i have to put this option on my client:
> > *options.setManageSession(true);*
> >
> > Therefore it is expected for the service to include
> > 
> > element as an session identifier in the soap envelope.
> >
> > I tested this and it does not work - axis2 does not put that
> element,
> > in order
> > to be used as session identifier.Am i missing something or this
> is a bug?
> >
> > Thanks,
> > Nencho
> >
> >
>
>
> --
> Thanks,
> Deepal
> 
> "The highest tower is built one brick at a time"
>
>
>
>
-
> 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 ]soap session scope does not work

2007-04-27 Thread Nencho Lupanov

Hi Deepal,

the sessions are working with axis2-1.1.1, i only cannot find how to
configure the seesions to expire after some time.
I read the Axis2 session management article(
http://www.developer.com/java/web/article.php/10935_3620661_2) and it says
that
they exprire by default within 30 seconds but how do i configure that?
Is that the

30
parameter in axis2.xml?

furthuremore, i made some test with 15 executions with a pause of 4 seconds
and the session doesn't expire.That's 60 seconds.

Thanks,
Nencho


2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]>:


Hi Nencho,
Yes we found that issue and we have fixed that in the 1.2 branch and the
fixes will be available in 1.2 release.

Thanks
Deepal

> Hi Deepal,
>
> I checked the test and yes i was able to run it successfull.
> anyway, when i try to put this in my running enviroment i get this
> strange error:
>
>  [java] Exception in thread "main" org.apache.axis2.AxisFault:
> Unable to fin
> d corresponding context for the serviceGroupId:
> urn:uuid:97198317A8B28D4CDF11775
> 98325288
>
> In services.xml on the server side i have the
>
> scope
>
> ="soapsession" attribute
>
> At the client side I have the following code
>
> *options.setManageSession(true);   *
>
> *...*
>
> client.engageModule(new QName("addressing"));
>
> Is there anything else to configure?
>
> Thanks,
>
> Nencho
>
>
>
> 2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]
> <mailto:[EMAIL PROTECTED]>>:
>
> Hi Nencho ,
>
> Axis2 soap session to be work , you need to engage addressing in
both
> the side.
>
> It is working , there is a test case in the build so we are
> testing that
> daily.
> org.apache.axis2.engine.ServiceGroupContextTest
>
> Thanks
> Deepal
>
> > Hi All,
>     >
> > I read this axis2 session management article:
> > http://www.developer.com/java/web/article.php/3620661
> >
> > Basically, it says that i can define my services being of a soap
> > session scope,
> > then i have to put this option on my client:
> > *options.setManageSession(true);*
> >
> > Therefore it is expected for the service to include
> > 
> > element as an session identifier in the soap envelope.
> >
> > I tested this and it does not work - axis2 does not put that
> element,
> > in order
> > to be used as session identifier.Am i missing something or this
> is a bug?
> >
> > Thanks,
> > Nencho
> >
> >
>
>
> --
> Thanks,
> Deepal
> 
> "The highest tower is built one brick at a time"
>
>
>
>
-
> 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 ]soap session scope does not work

2007-04-26 Thread Deepal Jayasinghe
Hi Nencho,
Yes we found that issue and we have fixed that in the 1.2 branch and the
fixes will be available in 1.2 release.

Thanks
Deepal

> Hi Deepal,
>  
> I checked the test and yes i was able to run it successfull.
> anyway, when i try to put this in my running enviroment i get this
> strange error:
>  
>  [java] Exception in thread "main" org.apache.axis2.AxisFault:
> Unable to fin
> d corresponding context for the serviceGroupId:
> urn:uuid:97198317A8B28D4CDF11775
> 98325288
>  
> In services.xml on the server side i have the
>
> scope
>
> ="soapsession" attribute
>
> At the client side I have the following code
>
> *options.setManageSession(true);   *
>
> *...*
>
> client.engageModule(new QName("addressing"));
>
> Is there anything else to configure?
>
> Thanks,
>
> Nencho
>
>
>
> 2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]
> <mailto:[EMAIL PROTECTED]>>:
>
> Hi Nencho ,
>
> Axis2 soap session to be work , you need to engage addressing in both
> the side.
>
> It is working , there is a test case in the build so we are
> testing that
> daily.
> org.apache.axis2.engine.ServiceGroupContextTest
>
> Thanks
> Deepal
>
> > Hi All,
> >
> > I read this axis2 session management article:
> > http://www.developer.com/java/web/article.php/3620661
> >
> > Basically, it says that i can define my services being of a soap
> > session scope,
> > then i have to put this option on my client:
> > *options.setManageSession(true);*
> >
> > Therefore it is expected for the service to include
> > 
> > element as an session identifier in the soap envelope.
> >
> > I tested this and it does not work - axis2 does not put that
> element,
> > in order
> > to be used as session identifier.Am i missing something or this
> is a bug?
> >
> > Thanks,
> > Nencho
> >
> >
>
>
> --
> Thanks,
> Deepal
> 
> "The highest tower is built one brick at a time"
>
>
>
> -
> 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 ]soap session scope does not work

2007-04-26 Thread Nencho Lupanov

Hi Sanjesh,

I tried with axis1.1.1 and it works.
It fails with axis 1.2.

thaks,
Nencho


2007/4/26, Sanjesh Pathak <[EMAIL PROTECTED]>:


 Hi Nencho,



I am using Axis2 version 1.1.1 and it is working fine in my local
environment here for session scope. What version of Axis2 are you using?



I am hosting a sample service that uses session scope accessible at this
URL: http://82.165.253.192:8081/axis2/services/SessionService



This service takes an OMElement as the parameter and echoes it back. Can
you test your client against this service?



Sanjesh


 --

*From:* Nencho Lupanov [mailto:[EMAIL PROTECTED]
*Sent:* Thursday, April 26, 2007 9:53 AM
*To:* axis-user@ws.apache.org
*Subject:* Re: [axis2 ]soap session scope does not work



Hi Deepal,



what about this jira issue:



https://issues.apache.org/jira/browse/AXIS2-2561



Does it means that we need to wait the issue to be closed in order to use
the soap session scope?



Thanks,

Nencho



2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]>:

Hi Nencho ,

Axis2 soap session to be work , you need to engage addressing in both
the side.

It is working , there is a test case in the build so we are testing that
daily.
org.apache.axis2.engine.ServiceGroupContextTest

Thanks
Deepal

> Hi All,
>
> I read this axis2 session management article:
> http://www.developer.com/java/web/article.php/3620661
>
> Basically, it says that i can define my services being of a soap
> session scope,
> then i have to put this option on my client:
> *options.setManageSession(true);*
>
> Therefore it is expected for the service to include
> 
> element as an session identifier in the soap envelope.
>
> I tested this and it does not work - axis2 does not put that element,
> in order
> to be used as session identifier.Am i missing something or this is a
bug?
>
> Thanks,
> Nencho
>
>


--
Thanks,
Deepal

"The highest tower is built one brick at a time"



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





RE: [axis2 ]soap session scope does not work

2007-04-26 Thread Sanjesh Pathak
Hi Nencho,
 
I am using Axis2 version 1.1.1 and it is working fine in my local
environment here for session scope. What version of Axis2 are you using?
 
I am hosting a sample service that uses session scope accessible at this
URL: http://82.165.253.192:8081/axis2/services/SessionService
 
This service takes an OMElement as the parameter and echoes it back. Can you
test your client against this service?
 
Sanjesh
 
  _  

From: Nencho Lupanov [mailto:[EMAIL PROTECTED] 
Sent: Thursday, April 26, 2007 9:53 AM
To: axis-user@ws.apache.org
Subject: Re: [axis2 ]soap session scope does not work
 
Hi Deepal,
 
what about this jira issue:
 
https://issues.apache.org/jira/browse/AXIS2-2561
 
Does it means that we need to wait the issue to be closed in order to use
the soap session scope?
 
Thanks,
Nencho

 
2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]>: 
Hi Nencho ,

Axis2 soap session to be work , you need to engage addressing in both
the side.

It is working , there is a test case in the build so we are testing that
daily.
org.apache.axis2.engine.ServiceGroupContextTest

Thanks
Deepal

> Hi All,
>
> I read this axis2 session management article: 
> http://www.developer.com/java/web/article.php/3620661
>
> Basically, it says that i can define my services being of a soap
> session scope, 
> then i have to put this option on my client:
> *options.setManageSession(true);*
>
> Therefore it is expected for the service to include
> 
> element as an session identifier in the soap envelope. 
>
> I tested this and it does not work - axis2 does not put that element,
> in order
> to be used as session identifier.Am i missing something or this is a bug?
>
> Thanks,
> Nencho 
>
>


--
Thanks,
Deepal

"The highest tower is built one brick at a time"



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


Re: [axis2 ]soap session scope does not work

2007-04-26 Thread Nencho Lupanov

Hi Deepal,

what about this jira issue:

https://issues.apache.org/jira/browse/AXIS2-2561

Does it means that we need to wait the issue to be closed in order to use
the soap session scope?

Thanks,
Nencho


2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]>:


Hi Nencho ,

Axis2 soap session to be work , you need to engage addressing in both
the side.

It is working , there is a test case in the build so we are testing that
daily.
org.apache.axis2.engine.ServiceGroupContextTest

Thanks
Deepal

> Hi All,
>
> I read this axis2 session management article:
> http://www.developer.com/java/web/article.php/3620661
>
> Basically, it says that i can define my services being of a soap
> session scope,
> then i have to put this option on my client:
> *options.setManageSession(true);*
>
> Therefore it is expected for the service to include
> 
> element as an session identifier in the soap envelope.
>
> I tested this and it does not work - axis2 does not put that element,
> in order
> to be used as session identifier.Am i missing something or this is a
bug?
>
> Thanks,
> Nencho
>
>


--
Thanks,
Deepal

"The highest tower is built one brick at a time"



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




Re: [axis2 ]soap session scope does not work

2007-04-26 Thread Nencho Lupanov

Hi Deepal,

I checked the test and yes i was able to run it successfull.
anyway, when i try to put this in my running enviroment i get this strange
error:

[java] Exception in thread "main" org.apache.axis2.AxisFault: Unable to
fin
d corresponding context for the serviceGroupId:
urn:uuid:97198317A8B28D4CDF11775
98325288

In services.xml on the server side i have the

scope="soapsession" attribute

At the client side I have the following code

*options.setManageSession(true);   *

*...*

client.engageModule(new QName("addressing"));

Is there anything else to configure?

Thanks,

Nencho

2007/4/26, Deepal Jayasinghe <[EMAIL PROTECTED]>:


Hi Nencho ,

Axis2 soap session to be work , you need to engage addressing in both
the side.

It is working , there is a test case in the build so we are testing that
daily.
org.apache.axis2.engine.ServiceGroupContextTest

Thanks
Deepal

> Hi All,
>
> I read this axis2 session management article:
> http://www.developer.com/java/web/article.php/3620661
>
> Basically, it says that i can define my services being of a soap
> session scope,
> then i have to put this option on my client:
> *options.setManageSession(true);*
>
> Therefore it is expected for the service to include
> 
> element as an session identifier in the soap envelope.
>
> I tested this and it does not work - axis2 does not put that element,
> in order
> to be used as session identifier.Am i missing something or this is a
bug?
>
> Thanks,
> Nencho
>
>


--
Thanks,
Deepal

"The highest tower is built one brick at a time"



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




Re: [axis2 ]soap session scope does not work

2007-04-26 Thread Nencho Lupanov

Hi Anil,

Thanks but this is for this but it is
about transport session scope and i need soap session scope,
where ws addressing come to play and sends an identifier(pretty much like a
cookie)
that is passed fforth and back.

Thanks,
Nencho


2007/4/25, Anil Chukkapalli <[EMAIL PROTECTED]>:


You can look at the thread "Axis2 Manage Session Cookie Manually"

On 4/25/07, Paul Fremantle <[EMAIL PROTECTED] > wrote:
>
> Nencho
>
> Think of this as a cookie. The client has to be enabled to respond
> with cookies, but that doesn't create the cookie in the first place.
> To make this work you need to set
>
> 
>
> in services.xml
>
> Now the server will set the ref params in the reply-to header. If you
> have setManageSession(true) now the client will send them back.
>
> Paul
>
> On 4/25/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> > Hi All,
> >
> > I read this axis2 session management article:
> > http://www.developer.com/java/web/article.php/3620661
> >
> > Basically, it says that i can define my services being of a soap
> session
> > scope,
> > then i have to put this option on my client:
> > options.setManageSession(true);
> >
> > Therefore it is expected for the service to include
> > 
> > element as an session identifier in the soap envelope.
> >
> > I tested this and it does not work - axis2 does not put that element,
> in
> > order
> > to be used as session identifier.Am i missing something or this is a
> bug?
> >
> > Thanks,
> > Nencho
> >
> >
>
>
> --
> Paul Fremantle
> VP/Technology, WSO2 and OASIS WS-RX TC Co-chair
>
> http://bloglines.com/blog/paulfremantle
> [EMAIL PROTECTED]
>
> "Oxygenating the Web Service Platform", www.wso2.com
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



Re: [axis2 ]soap session scope does not work

2007-04-26 Thread Nencho Lupanov

Hi Sanjesh,

yes, i have:

client.engageModule(new QName("addressing"));

in my client - you can take a look at this at Client.java that i attached in
my previous post.
Thanks,

Nencho


2007/4/25, Sanjesh Pathak <[EMAIL PROTECTED]>:


 Hi Nencho,



Did you engage addressing module on the client side? This is required for
soap session based communication.



Sanjesh


 --

*From:* Nencho Lupanov [mailto:[EMAIL PROTECTED]
*Sent:* Wednesday, April 25, 2007 11:14 AM
*To:* [EMAIL PROTECTED]; axis-user@ws.apache.org
*Subject:* [axis2 ]soap session scope does not work



Hi All,



I read this axis2 session management article:

http://www.developer.com/java/web/article.php/3620661



Basically, it says that i can define my services being of a soap session
scope,

then i have to put this option on my client:

*options.setManageSession(true);*


Therefore it is expected for the service to include

element as an session identifier in the soap envelope.



I tested this and it does not work - axis2 does not put that element, in
order

to be used as session identifier.Am i missing something or this is a bug?



Thanks,

Nencho







Re: [axis2 ]soap session scope does not work

2007-04-25 Thread Deepal Jayasinghe
Hi Nencho ,

Axis2 soap session to be work , you need to engage addressing in both
the side.

It is working , there is a test case in the build so we are testing that
daily.
org.apache.axis2.engine.ServiceGroupContextTest

Thanks
Deepal

> Hi All,
>  
> I read this axis2 session management article:
> http://www.developer.com/java/web/article.php/3620661
>  
> Basically, it says that i can define my services being of a soap
> session scope,
> then i have to put this option on my client:
> *options.setManageSession(true);*
>  
> Therefore it is expected for the service to include
> 
> element as an session identifier in the soap envelope.
>  
> I tested this and it does not work - axis2 does not put that element,
> in order
> to be used as session identifier.Am i missing something or this is a bug?
>  
> Thanks,
> Nencho
>  
>  


-- 
Thanks,
Deepal

"The highest tower is built one brick at a time"



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



Re: [axis2 ]soap session scope does not work

2007-04-25 Thread Anil Chukkapalli

You can look at the thread "Axis2 Manage Session Cookie Manually"

On 4/25/07, Paul Fremantle <[EMAIL PROTECTED]> wrote:


Nencho

Think of this as a cookie. The client has to be enabled to respond
with cookies, but that doesn't create the cookie in the first place.
To make this work you need to set



in services.xml

Now the server will set the ref params in the reply-to header. If you
have setManageSession(true) now the client will send them back.

Paul

On 4/25/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> Hi All,
>
> I read this axis2 session management article:
> http://www.developer.com/java/web/article.php/3620661
>
> Basically, it says that i can define my services being of a soap session
> scope,
> then i have to put this option on my client:
> options.setManageSession(true);
>
> Therefore it is expected for the service to include
> 
> element as an session identifier in the soap envelope.
>
> I tested this and it does not work - axis2 does not put that element, in
> order
> to be used as session identifier.Am i missing something or this is a
bug?
>
> Thanks,
> Nencho
>
>


--
Paul Fremantle
VP/Technology, WSO2 and OASIS WS-RX TC Co-chair

http://bloglines.com/blog/paulfremantle
[EMAIL PROTECTED]

"Oxygenating the Web Service Platform", www.wso2.com

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




RE: [axis2 ]soap session scope does not work

2007-04-25 Thread Sanjesh Pathak
Hi Nencho,
 
Did you engage addressing module on the client side? This is required for
soap session based communication.
 
Sanjesh
 
  _  

From: Nencho Lupanov [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, April 25, 2007 11:14 AM
To: [EMAIL PROTECTED]; axis-user@ws.apache.org
Subject: [axis2 ]soap session scope does not work
 
Hi All,
 
I read this axis2 session management article:
http://www.developer.com/java/web/article.php/3620661
 
Basically, it says that i can define my services being of a soap session
scope,
then i have to put this option on my client:
options.setManageSession(true);
 
Therefore it is expected for the service to include

element as an session identifier in the soap envelope.
 
I tested this and it does not work - axis2 does not put that element, in
order
to be used as session identifier.Am i missing something or this is a bug?
 
Thanks,
Nencho
 
 


Re: [axis2 ]soap session scope does not work

2007-04-25 Thread Nencho Lupanov

Hi Paul,

I have both scope attribute in services.xml
and the setManageSession(true) call in the client,
but it still does not work.
I attached my service.xml file and my client code.

And here is the response that i get frm the server:


3f2

http://www.w3.org/2005/08/addressing"; xmlns:soapenv="
http://schemas.xmlsoap.org/soap/envelope/";>

http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd
" soapenv:mustUnderstand="1">http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
" wsu:Id="Timestamp-23612966">2007-04-25T14:52:11.265Z2007-04-25T14:57:11.265Zurn:echo<
wsa:RelatesTo>urn:uuid:D6F41230DE1EAB89901177512730877http://sample01.policy.samples.rampart.apache.org";><
soapenv:Body>http://sample/xsd";>Hello
World

0
Thanks,
Nencho


2007/4/25, Paul Fremantle <[EMAIL PROTECTED]>:


Nencho

Think of this as a cookie. The client has to be enabled to respond
with cookies, but that doesn't create the cookie in the first place.
To make this work you need to set



in services.xml

Now the server will set the ref params in the reply-to header. If you
have setManageSession(true) now the client will send them back.

Paul

On 4/25/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:
> Hi All,
>
> I read this axis2 session management article:
> http://www.developer.com/java/web/article.php/3620661
>
> Basically, it says that i can define my services being of a soap session
> scope,
> then i have to put this option on my client:
> options.setManageSession(true);
>
> Therefore it is expected for the service to include
> 
> element as an session identifier in the soap envelope.
>
> I tested this and it does not work - axis2 does not put that element, in
> order
> to be used as session identifier.Am i missing something or this is a
bug?
>
> Thanks,
> Nencho
>
>


--
Paul Fremantle
VP/Technology, WSO2 and OASIS WS-RX TC Co-chair

http://bloglines.com/blog/paulfremantle
[EMAIL PROTECTED]

"Oxygenating the Web Service Platform", www.wso2.com

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







	
		
	
	org.apache.rampart.samples.policy.sample01.SimpleService
	
	
	

	http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"; xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy";>
		
		  
			http://schemas.xmlsoap.org/ws/2005/07/securitypolicy";>
			  

  
	
  


  
	
  


  
	
  


			  
			
			http://schemas.xmlsoap.org/ws/2005/07/securitypolicy";>

	http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"; />
			  
			
			
			http://ws.apache.org/rampart/policy";> 
org.apache.rampart.samples.policy.sample01.PWCBHandler
			
			
		  
		
	




/*
 * Copyright 2004,2005 The Apache Software Foundation.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *  http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package org.apache.rampart.samples.policy.sample01;

import org.apache.axiom.om.OMAbstractFactory;
import org.apache.axiom.om.OMElement;
import org.apache.axiom.om.OMFactory;
import org.apache.axiom.om.OMNamespace;
import org.apache.axiom.om.impl.builder.StAXOMBuilder;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.Options;
import org.apache.axis2.client.ServiceClient;
import org.apache.axis2.context.ConfigurationContext;
import org.apache.axis2.context.ConfigurationContextFactory;
import org.apache.neethi.Policy;
import org.apache.neethi.PolicyEngine;
import org.apache.rampart.RampartMessageData;

import javax.xml.namespace.QName;

public class Client {

public static void main(String[] args) throws Exception {

if(args.length != 3) {
System.out.println("Usage: $java Client endpoint_address 
client_repo_path policy_xml_path");
}

ConfigurationContext ctx = 
ConfigurationContextFactory.createConfigurationContextFromFileSystem(args[1], 
null);

ServiceClient client = new ServiceClient(ctx, null);
Options options = new Options();
options.setAction("urn:echo");
options

Re: [axis2 ]soap session scope does not work

2007-04-25 Thread Paul Fremantle

Nencho

Think of this as a cookie. The client has to be enabled to respond
with cookies, but that doesn't create the cookie in the first place.
To make this work you need to set



in services.xml

Now the server will set the ref params in the reply-to header. If you
have setManageSession(true) now the client will send them back.

Paul

On 4/25/07, Nencho Lupanov <[EMAIL PROTECTED]> wrote:

Hi All,

I read this axis2 session management article:
http://www.developer.com/java/web/article.php/3620661

Basically, it says that i can define my services being of a soap session
scope,
then i have to put this option on my client:
options.setManageSession(true);

Therefore it is expected for the service to include

element as an session identifier in the soap envelope.

I tested this and it does not work - axis2 does not put that element, in
order
to be used as session identifier.Am i missing something or this is a bug?

Thanks,
Nencho





--
Paul Fremantle
VP/Technology, WSO2 and OASIS WS-RX TC Co-chair

http://bloglines.com/blog/paulfremantle
[EMAIL PROTECTED]

"Oxygenating the Web Service Platform", www.wso2.com

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



[axis2 ]soap session scope does not work

2007-04-25 Thread Nencho Lupanov

Hi All,

I read this axis2 session management article:
http://www.developer.com/java/web/article.php/3620661

Basically, it says that i can define my services being of a soap session
scope,
then i have to put this option on my client:
*options.setManageSession(true);*

Therefore it is expected for the service to include

element as an session identifier in the soap envelope.

I tested this and it does not work - axis2 does not put that element, in
order
to be used as session identifier.Am i missing something or this is a bug?

Thanks,
Nencho


RE: [AXIS2] set scope with wsdl2java

2007-04-10 Thread Srinivas Reddy Raya
Hi,

Please refer the axis documentation for setting scope .

 

Thanks 

Srinivas

 



From: Alistair Young [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, April 10, 2007 5:27 PM
To: axis-user@ws.apache.org
Subject: [AXIS2] set scope with wsdl2java

 

Is there any way to specify the service scope when using wsdl2java? or
is it just a case of adding scope="transportsession" after build.xml has
been created?

 

Alistair

 





--

mov eax,1

mov ebx,0

int 80h

 

 





 



[AXIS2] set scope with wsdl2java

2007-04-10 Thread Alistair Young
Is there any way to specify the service scope when using wsdl2java?  
or is it just a case of adding scope="transportsession" after  
build.xml has been created?


Alistair


--
mov eax,1
mov ebx,0
int 80h






Re: AW: sesion managment, scope=soapsession

2007-03-06 Thread Davanum Srinivas

Thanks a ton Rob for tracking this problem down. Thanks Josef for your
patience :) I fixed the default axis2.xml and updated the comment
there.

thanks,
dims

On 3/6/07, Stadelmann Josef <[EMAIL PROTECTED]> wrote:

Hi Rob,
Hi Deepal

Thank you very much Rob, what you write below is the solution to my problem.
JIRA AXIS2-1991 must remain open until this is fixed in documentation and in 
AXIS2.XML or in code or both or vice versa.

I have adjusted AXIS2.XML ConfigContextTimeoutInterval to 3 (now expresing 
a timeout in milliseconds) and all clients running in
parallel threads are now working very fine in scope=soapsession.

This error has costed me weeks of work including communication and 
missunderstandings with others. Rob, thank you very much again.

Josef Stadelmann




-Ursprüngliche Nachricht-
Von: Rasile, Rob [mailto:[EMAIL PROTECTED]
Gesendet: Montag, 5. März 2007 20:34
An: axis-user@ws.apache.org
Betreff: RE: AW: sesion managment, scope=soapsession


I've been having the same issue.  I traced through the axis2 source and found 
the following:

1) Axis2 has a ConfigContextTimeoutInterval parameter in axis2.xml that by 
default is set to 30 with a comment stating this is in seconds.
2) Whenever the axis2.apache.axis2.context.ConfigurationContext registers a new 
ServiceGroupContext (resgisterServiceGroupContext), it adds the servicegroupid to a 
hashmap (serviceGroupContextMap), then "cleans-up" the hashmap using the 
following logic:

A timeout has occurred if currentTime - serviceGroupContext.getLastTouchedTime() 
> ConfigContextTimeoutInterval

The issue is that currentTime and lastTouchedTime are measured in millisecs 
(they are longs), whereas ConfigContextTimeout is treated as seconds (simply 
because the value in the axis2.xml is entered as secs). Therefore axis2 always 
thinks that context has timed-out and removes it.

My solution was to modify the axis2.xml ConfigContextTimeoutInterval
(ie. multiply it by 1000).  Looks like this was intended to be millisecs based 
on these lines of code from ConfigurationContext:

// current time out interval is 30 secs. Need to make this configurable
private long serviceGroupContextTimoutInterval = 30 * 1000;

I think that in the implementation of the configurable timeout the 
documentation just didn't get updated.


-Original Message-
From: Stadelmann Josef [mailto:[EMAIL PROTECTED]
Sent: Monday, March 05, 2007 11:28 AM
To: axis-user@ws.apache.org
Subject: AW: AW: sesion managment, scope=soapsession

Hi Deepal,

See my coment below +++>

-Ursprüngliche Nachricht-
Von: Deepal Jayasinghe [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 12. Dezember 2006 06:37
An: axis-user@ws.apache.org
Betreff: Re: AW: sesion managment, scope=soapsession


Hi  Stadelmann ;

>
>My client #1 runs continously, and sends arround 40 msg a second to the server.
>When the second client starts, cline t#1 is still sending messages and so we do
>not have a time-out condition. client #1 never times out.
>
>BUT as I decribe, using the code shown, when client #2 starts 
MyService.destroy()
>is called followed by MyService.init() which has the effect that client #1 
fails
>thereafter with an "invalid group context id exception"
>
>
hmmm, can you please help me to re-create the problem. If you can send
me the sample services and clients that will be very helpful for me to
fix the issue.

>
>I would appreciate an example on how to have a scenario as I describe.
>When I read literature about tomcat, retriving a session object from the
>clients request object, it seems that internals are figuring out which client
>is calling and the rigth session object which acts as data store for the
>session is returned/created.
>
>How is that with AXIS2-1.1?
>
>
Will write a sample soon .
+++> Do you have an example now showing how to maintain statefull session 
objects?




>When the MyService Object gets created I store the creation time for the
>instance in a instance variable. And when multiple clients run without
>scope=soapsession set, all clients return the same time stamp. So that
>means for me! client #1 makes axis2 creating a first instance of a class,
>and places the creation timestamp.
>
>
That can not happen , there should be a separate service impl class for
each client, Im 100% sure about that since I have tested that. :)

+++> and what happens if the service class or variables such as the
time stamp are defined static. I have just now read a book about the Java Nativ 
Interface


The Java programming language supports two kinds of fields. Each instance of a
class has its own copy of instance fields of the class, whereas all instances of
a class share the static fields of a class.


I think this answers why my time stamp, which was implemented as a static field,
returnes to each client the same date/time, the time it was la

AW: AW: sesion managment, scope=soapsession

2007-03-05 Thread Stadelmann Josef
Hi Rob,
Hi Deepal

Thank you very much Rob, what you write below is the solution to my problem.
JIRA AXIS2-1991 must remain open until this is fixed in documentation and in 
AXIS2.XML or in code or both or vice versa.

I have adjusted AXIS2.XML ConfigContextTimeoutInterval to 3 (now expresing 
a timeout in milliseconds) and all clients running in
parallel threads are now working very fine in scope=soapsession.

This error has costed me weeks of work including communication and 
missunderstandings with others. Rob, thank you very much again.

Josef Stadelmann




-Ursprüngliche Nachricht-
Von: Rasile, Rob [mailto:[EMAIL PROTECTED]
Gesendet: Montag, 5. März 2007 20:34
An: axis-user@ws.apache.org
Betreff: RE: AW: sesion managment, scope=soapsession


I've been having the same issue.  I traced through the axis2 source and found 
the following:

1) Axis2 has a ConfigContextTimeoutInterval parameter in axis2.xml that by 
default is set to 30 with a comment stating this is in seconds.
2) Whenever the axis2.apache.axis2.context.ConfigurationContext registers a new 
ServiceGroupContext (resgisterServiceGroupContext), it adds the servicegroupid 
to a hashmap (serviceGroupContextMap), then "cleans-up" the hashmap using the 
following logic:

A timeout has occurred if currentTime - 
serviceGroupContext.getLastTouchedTime() > ConfigContextTimeoutInterval

The issue is that currentTime and lastTouchedTime are measured in millisecs 
(they are longs), whereas ConfigContextTimeout is treated as seconds (simply 
because the value in the axis2.xml is entered as secs). Therefore axis2 always 
thinks that context has timed-out and removes it.  

My solution was to modify the axis2.xml ConfigContextTimeoutInterval 
(ie. multiply it by 1000).  Looks like this was intended to be millisecs based 
on these lines of code from ConfigurationContext:

// current time out interval is 30 secs. Need to make this configurable
private long serviceGroupContextTimoutInterval = 30 * 1000;

I think that in the implementation of the configurable timeout the 
documentation just didn't get updated.


-Original Message-
From: Stadelmann Josef [mailto:[EMAIL PROTECTED] 
Sent: Monday, March 05, 2007 11:28 AM
To: axis-user@ws.apache.org
Subject: AW: AW: sesion managment, scope=soapsession

Hi Deepal,

See my coment below +++>

-Ursprüngliche Nachricht-
Von: Deepal Jayasinghe [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 12. Dezember 2006 06:37
An: axis-user@ws.apache.org
Betreff: Re: AW: sesion managment, scope=soapsession


Hi  Stadelmann ;

>
>My client #1 runs continously, and sends arround 40 msg a second to the 
>server. 
>When the second client starts, cline t#1 is still sending messages and so we 
>do 
>not have a time-out condition. client #1 never times out.
>
>BUT as I decribe, using the code shown, when client #2 starts 
>MyService.destroy() 
>is called followed by MyService.init() which has the effect that client #1 
>fails 
>thereafter with an "invalid group context id exception"
>  
>
hmmm, can you please help me to re-create the problem. If you can send
me the sample services and clients that will be very helpful for me to
fix the issue.

>
>I would appreciate an example on how to have a scenario as I describe.
>When I read literature about tomcat, retriving a session object from the 
>clients request object, it seems that internals are figuring out which client 
>is calling and the rigth session object which acts as data store for the
>session is returned/created. 
>
>How is that with AXIS2-1.1?
>  
>
Will write a sample soon .
+++> Do you have an example now showing how to maintain statefull session 
objects?




>When the MyService Object gets created I store the creation time for the
>instance in a instance variable. And when multiple clients run without
>scope=soapsession set, all clients return the same time stamp. So that
>means for me! client #1 makes axis2 creating a first instance of a class,
>and places the creation timestamp.
>  
>
That can not happen , there should be a separate service impl class for
each client, Im 100% sure about that since I have tested that. :)

+++> and what happens if the service class or variables such as the 
time stamp are defined static. I have just now read a book about the Java Nativ 
Interface


The Java programming language supports two kinds of fields. Each instance of a
class has its own copy of instance fields of the class, whereas all instances 
of 
a class share the static fields of a class.


I think this answers why my time stamp, which was implemented as a static field,
returnes to each client the same date/time, the time it was last overwritten
when a instance gets created.


NOTE: Instances migth still be separate and be running in different threads but
as long as the time stamp field is static, each class r

RE: AW: sesion managment, scope=soapsession

2007-03-05 Thread Rasile, Rob
I've been having the same issue.  I traced through the axis2 source and found 
the following:

1) Axis2 has a ConfigContextTimeoutInterval parameter in axis2.xml that by 
default is set to 30 with a comment stating this is in seconds.
2) Whenever the axis2.apache.axis2.context.ConfigurationContext registers a new 
ServiceGroupContext (resgisterServiceGroupContext), it adds the servicegroupid 
to a hashmap (serviceGroupContextMap), then "cleans-up" the hashmap using the 
following logic:

A timeout has occurred if currentTime - 
serviceGroupContext.getLastTouchedTime() > ConfigContextTimeoutInterval

The issue is that currentTime and lastTouchedTime are measured in millisecs 
(they are longs), whereas ConfigContextTimeout is treated as seconds (simply 
because the value in the axis2.xml is entered as secs). Therefore axis2 always 
thinks that context has timed-out and removes it.  

My solution was to modify the axis2.xml ConfigContextTimeoutInterval 
(ie. multiply it by 1000).  Looks like this was intended to be millisecs based 
on these lines of code from ConfigurationContext:

// current time out interval is 30 secs. Need to make this configurable
private long serviceGroupContextTimoutInterval = 30 * 1000;

I think that in the implementation of the configurable timeout the 
documentation just didn't get updated.


-Original Message-
From: Stadelmann Josef [mailto:[EMAIL PROTECTED] 
Sent: Monday, March 05, 2007 11:28 AM
To: axis-user@ws.apache.org
Subject: AW: AW: sesion managment, scope=soapsession

Hi Deepal,

See my coment below +++>

-Ursprüngliche Nachricht-
Von: Deepal Jayasinghe [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 12. Dezember 2006 06:37
An: axis-user@ws.apache.org
Betreff: Re: AW: sesion managment, scope=soapsession


Hi  Stadelmann ;

>
>My client #1 runs continously, and sends arround 40 msg a second to the 
>server. 
>When the second client starts, cline t#1 is still sending messages and so we 
>do 
>not have a time-out condition. client #1 never times out.
>
>BUT as I decribe, using the code shown, when client #2 starts 
>MyService.destroy() 
>is called followed by MyService.init() which has the effect that client #1 
>fails 
>thereafter with an "invalid group context id exception"
>  
>
hmmm, can you please help me to re-create the problem. If you can send
me the sample services and clients that will be very helpful for me to
fix the issue.

>
>I would appreciate an example on how to have a scenario as I describe.
>When I read literature about tomcat, retriving a session object from the 
>clients request object, it seems that internals are figuring out which client 
>is calling and the rigth session object which acts as data store for the
>session is returned/created. 
>
>How is that with AXIS2-1.1?
>  
>
Will write a sample soon .
+++> Do you have an example now showing how to maintain statefull session 
objects?




>When the MyService Object gets created I store the creation time for the
>instance in a instance variable. And when multiple clients run without
>scope=soapsession set, all clients return the same time stamp. So that
>means for me! client #1 makes axis2 creating a first instance of a class,
>and places the creation timestamp.
>  
>
That can not happen , there should be a separate service impl class for
each client, Im 100% sure about that since I have tested that. :)

+++> and what happens if the service class or variables such as the 
time stamp are defined static. I have just now read a book about the Java Nativ 
Interface


The Java programming language supports two kinds of fields. Each instance of a
class has its own copy of instance fields of the class, whereas all instances 
of 
a class share the static fields of a class.


I think this answers why my time stamp, which was implemented as a static field,
returnes to each client the same date/time, the time it was last overwritten
when a instance gets created.


NOTE: Instances migth still be separate and be running in different threads but
as long as the time stamp field is static, each class returns to each related
client the same time stamp what ever value it is.
<










>This is called an object, and client #2 sends his message to the same instance
>the same object. When the call to client 2 returns, client #2 finds the same 
>time stamp as client #1 has. But when client #2 starts 10 seconds after client 
>#1,
>I would expect that client #2 has a different object-creation-timestamp
>then client #1 unless we talk to the same instance (which I cant use).
>Josef
>  
>
Are u keeping your value as a static ? I mean are u storing your value
in a static variable  ?

+++> I have answered this question with yes, but I did not realise until now
the difference of private static and private fields of a class.
<+++




AW: AW: sesion managment, scope=soapsession

2007-03-05 Thread Stadelmann Josef
Hi Deepal,

See my coment below +++>

-Ursprüngliche Nachricht-
Von: Deepal Jayasinghe [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 12. Dezember 2006 06:37
An: axis-user@ws.apache.org
Betreff: Re: AW: sesion managment, scope=soapsession


Hi  Stadelmann ;

>
>My client #1 runs continously, and sends arround 40 msg a second to the 
>server. 
>When the second client starts, cline t#1 is still sending messages and so we 
>do 
>not have a time-out condition. client #1 never times out.
>
>BUT as I decribe, using the code shown, when client #2 starts 
>MyService.destroy() 
>is called followed by MyService.init() which has the effect that client #1 
>fails 
>thereafter with an "invalid group context id exception"
>  
>
hmmm, can you please help me to re-create the problem. If you can send
me the sample services and clients that will be very helpful for me to
fix the issue.

>
>I would appreciate an example on how to have a scenario as I describe.
>When I read literature about tomcat, retriving a session object from the 
>clients request object, it seems that internals are figuring out which client 
>is calling and the rigth session object which acts as data store for the
>session is returned/created. 
>
>How is that with AXIS2-1.1?
>  
>
Will write a sample soon .
+++> Do you have an example now showing how to maintain statefull session 
objects?




>When the MyService Object gets created I store the creation time for the
>instance in a instance variable. And when multiple clients run without
>scope=soapsession set, all clients return the same time stamp. So that
>means for me! client #1 makes axis2 creating a first instance of a class,
>and places the creation timestamp.
>  
>
That can not happen , there should be a separate service impl class for
each client, Im 100% sure about that since I have tested that. :)

+++> and what happens if the service class or variables such as the 
time stamp are defined static. I have just now read a book about the Java Nativ 
Interface


The Java programming language supports two kinds of fields. Each instance of a
class has its own copy of instance fields of the class, whereas all instances 
of 
a class share the static fields of a class.


I think this answers why my time stamp, which was implemented as a static field,
returnes to each client the same date/time, the time it was last overwritten
when a instance gets created.


NOTE: Instances migth still be separate and be running in different threads but
as long as the time stamp field is static, each class returns to each related
client the same time stamp what ever value it is.
<










>This is called an object, and client #2 sends his message to the same instance
>the same object. When the call to client 2 returns, client #2 finds the same 
>time stamp as client #1 has. But when client #2 starts 10 seconds after client 
>#1,
>I would expect that client #2 has a different object-creation-timestamp
>then client #1 unless we talk to the same instance (which I cant use).
>Josef
>  
>
Are u keeping your value as a static ? I mean are u storing your value
in a static variable  ?

+++> I have answered this question with yes, but I did not realise until now
the difference of private static and private fields of a class.
<+++



>Again - my clients 1 to 20 do continously send messages, each client in
>its thread - I am using NetBeans and I am just launching more then one
>client. So each client is fully busy sending. But each client gets 
>responses from the same server object instance. And we have not a time-out
>condition as each client continously sends. Once we come to real clients
>where usesers invoke messages we wil care about timeouts. But as long as
>client code jsut loops in a for() we do not have time-outs, even not with
>20 sessions, but in our example using scope=soapsession, we do not get that
>far, as client #1 runs until client #2 starts, which makes client #1 fail
>with "invalid service group context id"
>Josef
>  
>
Are you sending service group id in each request , or you juts send as
new req ?
If you want to go into same soapsession , then you need to send the
serviceGroupID


+++> I logged thisi as JIRA AXIS2-1991 - if we share somehow the location 
where the ServiceGroupContextID is taken from or stored, then, when a second 
client calls and Axis2 does not check somehow that a ServiceGroupContextID is
already created, it will override the existing one. I do not know if that
is true, but if the ID gets overridden, then we ghave at least the mentioned 
effect. 

As simple as have an ID it in a static field. This migth be true for a larger 
object modells as well as simple variables ... sharing versus non sharing 
wether this is happen in the same thread or in different threads, 
makes it just mor

Re: AW: AW: AW: [axis2] problem with service deployed in application scope

2007-03-05 Thread Michele Mazzucco
On Mon, 2007-03-05 at 14:43 +0100, Stadelmann Josef wrote:
> Hi Michele
> 
> To your problem:
> Again, I am saying you need to implement init() and destroy() because that is 
> what your exception states. doesn't it?

Yes, that's the reason. I've found this old "article"
http://wso2.org/library/163 , however more recent documentation doesn't
mention this "requirement". 
> 
> If ServiceLifeCycle does not need it, why does your service then rais an 
> exception 
> which referes to init() and destroy()? I don't know.

I don't know:
a - when the ServiceLifeCycle interface was introduced some code was not
updated :( (and in fact the error is logged at INFO level).
b - if those methods are really needed it would be much better to create
an interface declaring those 2 methods instead of using reflection.

> 
> 
> 
> What I want:
> I would need an instance of class MyService, for each client session starting 
> in 
> a thread a state full object. I would need this instance to maintain session 
> state 
> from login to logout.
> 
> for that I can not use scope=request and have MyService maintain session 
> state.
> 
> for that I can not use scope=application, MyService would be singelton an 
> hence
> not maintain session state by itself.
> 
> for that I migth use scope=transport or scope=soapsession, but I have the
> mentioned side effects for scope=soapsession.
> 
> 
> So what can I do? I go to use scope=application and do the caching of 
> statefull
> session beans myself using ehcache or the like. 
> 
> 
> Maybe you know how LifeCycleService can help me on that?
> 
> An instance, of a class an object must connect to a legacy server process on 
> a 1 to 1
> relation. Each client (user) thread must hit in a 1 to 1 relation its related 
> OpenVMS 
> server process with each call inbetween login() and logout(). 
> 
> 
> A new session must create an instance, maintaining the state of an OpenVMS 
> application.
> 
> In application scope I have only one instance of MyService.class maybe call 
> it a singelton. 
> 
> The instance of MyService.class is therefor used to detect new incomming 
> session request, 
> then create a UUID based session ID and a related Java Bean object and cache 
> it under its 
> UUID key in a ehcache. Through the Java Bean, talk via WSIT toolkit from HP 
> to my OpenVMS 
> Legacy Server Process.
> 
> This Java Beans are used as place- and state-holders for the OpenVMS process 
> from
> login to logout.
> 
> 
> If you know how the LifeCycle Interface can realise and help on what I want 
> then please 
> explain? 

>From the APIs I read: "When you want to initialize database
connections , starting threads and etc.. at the time you deploy  service
(similar to loadonstartup). You need to implement this interface and add
additional (optional) attribute into services.xml "

Furthermore, here http://wso2.org/library/333 they say:
"Do not confuse service life cycle with session management. A session
itself has its own life cycle but the service life cycle is different
from that."

Try to see http://wso2.org/library/334  as well.
> 
> For your help, thank you very much
> Josef
> 
> 
> 
> 
Best,
Michele
> 
> 
> 
> 
> 
> 
> -Ursprüngliche Nachricht-
> Von: Michele Mazzucco [mailto:[EMAIL PROTECTED]
> Gesendet: Montag, 5. März 2007 13:05
> An: axis-user@ws.apache.org
> Betreff: Re: AW: AW: [axis2] problem with service deployed in
> application scope
> 
> 
> Josef,
> 
> this is an old article indeed. As far as I know those two methods are
> not required any more because of the use of the ServiceLifeCycle
> interface.
> 
> For what concerns life cycle management, I've been using it since it was
> first made available and it works fine for me (my service is deployed in
> application scope).
> 
> Finally, are you sure your service does not throw any unchecked
> exception? I'm just asking because it it does a new service instance is
> created.
> 
> 
> Best,
> Michele
> 
> On Mon, 2007-03-05 at 12:32 +0100, Stadelmann Josef wrote:
> > I am not
> > happy too with this somehow outdated articel 
> 
> 
> -
> 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]
> 


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



AW: AW: AW: [axis2] problem with service deployed in application scope

2007-03-05 Thread Stadelmann Josef
Hi Michele

To your problem:
Again, I am saying you need to implement init() and destroy() because that is 
what your exception states. doesn't it?

If ServiceLifeCycle does not need it, why does your service then rais an 
exception 
which referes to init() and destroy()? I don't know.



What I want:
I would need an instance of class MyService, for each client session starting 
in 
a thread a state full object. I would need this instance to maintain session 
state 
from login to logout.

for that I can not use scope=request and have MyService maintain session state.

for that I can not use scope=application, MyService would be singelton an hence
not maintain session state by itself.

for that I migth use scope=transport or scope=soapsession, but I have the
mentioned side effects for scope=soapsession.


So what can I do? I go to use scope=application and do the caching of statefull
session beans myself using ehcache or the like. 


Maybe you know how LifeCycleService can help me on that?


An instance, of a class an object must connect to a legacy server process on a 
1 to 1
relation. Each client (user) thread must hit in a 1 to 1 relation its related 
OpenVMS 
server process with each call inbetween login() and logout(). 


A new session must create an instance, maintaining the state of an OpenVMS 
application.

In application scope I have only one instance of MyService.class maybe call it 
a singelton. 

The instance of MyService.class is therefor used to detect new incomming 
session request, 
then create a UUID based session ID and a related Java Bean object and cache it 
under its 
UUID key in a ehcache. Through the Java Bean, talk via WSIT toolkit from HP to 
my OpenVMS 
Legacy Server Process.

This Java Beans are used as place- and state-holders for the OpenVMS process 
from
login to logout.


If you know how the LifeCycle Interface can realise and help on what I want 
then please 
explain? 

For your help, thank you very much
Josef










-Ursprüngliche Nachricht-
Von: Michele Mazzucco [mailto:[EMAIL PROTECTED]
Gesendet: Montag, 5. März 2007 13:05
An: axis-user@ws.apache.org
Betreff: Re: AW: AW: [axis2] problem with service deployed in
application scope


Josef,

this is an old article indeed. As far as I know those two methods are
not required any more because of the use of the ServiceLifeCycle
interface.

For what concerns life cycle management, I've been using it since it was
first made available and it works fine for me (my service is deployed in
application scope).

Finally, are you sure your service does not throw any unchecked
exception? I'm just asking because it it does a new service instance is
created.


Best,
Michele

On Mon, 2007-03-05 at 12:32 +0100, Stadelmann Josef wrote:
> I am not
> happy too with this somehow outdated articel 


-
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: AW: AW: [axis2] problem with service deployed in application scope

2007-03-05 Thread Michele Mazzucco
Josef,

this is an old article indeed. As far as I know those two methods are
not required any more because of the use of the ServiceLifeCycle
interface.

For what concerns life cycle management, I've been using it since it was
first made available and it works fine for me (my service is deployed in
application scope).

Finally, are you sure your service does not throw any unchecked
exception? I'm just asking because it it does a new service instance is
created.


Best,
Michele

On Mon, 2007-03-05 at 12:32 +0100, Stadelmann Josef wrote:
> I am not
> happy too with this somehow outdated articel 


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



AW: AW: [axis2] problem with service deployed in application scope

2007-03-05 Thread Stadelmann Josef
Hi Michele

I am saying you need to implement init() and destroy() because that is 
what your exception states. isn't it?


But to be more precise, please read an articel at 
http://www.developer.com/java/web/print.php/3620661
then you should know the aim of the two methods a bit better. Be not
surprised if iot does not match your expectation to 100%, I am not
happy too with this somehow outdated articel. But it is given for
refrence in many places in all the previous e-mails.


On my atempt to implement user/client sessions I struggled and after
all I give up because statefull sessions seams to be an axis2-dream 
and are not fully understand by the team, and lifecycle is not what I 
can use. Also, I got the advise to do it myself, now that is what I do.


Depending on your session scope which can be one of

    scope={request|soapsession|transport|application}

init() and destroy() are called at different times in relation to
the session scope established.

in application scope init() is called and if not there and exception
is triggerd, is called when your service is deployed, when axis2 starts.
And destroy() is called when your service is stopped or when axis2 is
stopped or when tomcat is stopped.

in scope=sopasession it is erratic!

on the first call to any method the ServiceClient makes init(9 is called
followed by the call to your intended method such as MyService.start();

But when the second client does the same in this scope, then MyService.destroy()
is called followed by MyService.init() followed by MyService.start();

This has a very negative efect to client#1 as the ServiceGroupContextID gets
killed and reestablished with a new value, of which client#2 is informed but
client#1 not, and hence makes it fail. And so on for each consecutive client
starting up in its thread in this scope- BUT THIS SEAMS TO BE MY PROBLEM. -




the article 
http://www.developer.com/java/web/print.php/3620661
will give you some insigth.

The aim of init() depends on your sessions scope, AFAIK.

In scope=application init() is called when the service is deployed
i.e. when tomcat starts, axis2 starts and hence all registered servies
are deployed.


init() can then be used to establish i.e. an ehcache into which you
can store your session beans under lets say a UUID and mange yourself 
user sessions. 


destroy() is called when such a service shuts down or when axis2 is shut
or tomcat. In this case destroy() is called and can be used to call i.e.
a logout() on each session bean to indicate to a legacy server that a 
particular user session has logged out.



I hope it helps you.
Rregards

Josef



-Ursprüngliche Nachricht-
Von: Michele Mazzucco [mailto:[EMAIL PROTECTED]
Gesendet: Montag, 5. März 2007 11:01
An: axis-user@ws.apache.org
Betreff: Re: AW: [axis2] problem with service deployed in application
scope


Hi Josef,

do I need those methods? The service uses lifecycle management (it's
supplied by another class) which provides the methods defined by
org.apache.axis2.engine.ServiceLifeCycle (namely startUp() and
shutDown()).

What's the aim of the init() and destroy methods()?


Thanks,
Michele

On Mon, 2007-03-05 at 10:12 +0100, Stadelmann Josef wrote:
> Did you add the init() and the destroy() method to your i.e.
> MyService.java ?


-
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: AW: [axis2] problem with service deployed in application scope

2007-03-05 Thread Michele Mazzucco
Hi Josef,

do I need those methods? The service uses lifecycle management (it's
supplied by another class) which provides the methods defined by
org.apache.axis2.engine.ServiceLifeCycle (namely startUp() and
shutDown()).

What's the aim of the init() and destroy methods()?


Thanks,
Michele

On Mon, 2007-03-05 at 10:12 +0100, Stadelmann Josef wrote:
> Did you add the init() and the destroy() method to your i.e.
> MyService.java ?


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



AW: [axis2] problem with service deployed in application scope

2007-03-05 Thread Stadelmann Josef
Hi Michele

Did you add the init() and the destroy() method to your i.e. MyService.java ?



public void init(ServiceContext sCtx) {
this.sc = sCtx;
this.log.info(this.sc.toString()+" init() called 
*");
}


public void destroy(ServiceContext sCtx) {
if(!this.sc.toString().equals(sCtx.toString())){
this.log.error("ServiceContext on init() and destroy() not equal in 
");
}

this.log.info(this.sc.toString()+" destroy() called 
*");
this.sc = null;
}

init() is called once when the service is deployed/started and 
destroy() is called once when the service is shutdown.

Josef Stadelmann


-Ursprüngliche Nachricht-
Von: Michele Mazzucco [mailto:[EMAIL PROTECTED]
Gesendet: Freitag, 16. Februar 2007 10:49
An: axis2
Betreff: [axis2] problem with service deployed in application scope


Hi all,

I'm running a service deployed in application scope, enabled for life
cycle management (the environment is tomcat 5.5.20, axis2 snapshot,
linux and sun jdk 1.5.0_10). 
>From the tomcat logs I see the following error


INFO  [09:35:27,716] LifecycleManager:start - Controller started
ncl.qosp.controller.scheduler.LifecycleManager.start(LifecycleManager.java:193) 
INFO  [main] - Controller started
org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:66)
 DEBUG [main] - Exception trying to call init
java.lang.NoSuchMethodException:
ncl.qosp.controller.RoutingService.init(org.apache.axis2.context.ServiceContext)
at java.lang.Class.getMethod(Class.java:1581)
at
org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:53)
at
org.apache.axis2.engine.DependencyManager.initService(DependencyManager.java:93)
at
org.apache.axis2.context.ConfigurationContextFactory.initApplicationScopeServices(ConfigurationContextFactory.java:84)
at
org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:70)
at
org.apache.axis2.transport.http.AxisServlet.initConfigContext(AxisServlet.java:545)
at
org.apache.axis2.transport.http.AxisServlet.init(AxisServlet.java:491)
at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1105)
at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:932)
at
org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3951)
at
org.apache.catalina.core.StandardContext.start(StandardContext.java:4225)
at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
at
org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:809)
at
org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:698)
at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:472)
at
org.apache.catalina.startup.HostConfig.start(HostConfig.java:1122)
at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
at
org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
at
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
at
org.apache.catalina.core.StandardService.start(StandardService.java:450)
at
org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294)
at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432)
org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:66)
 DEBUG [main] - Exception trying to call init
java.lang.NoSuchMethodException:
ncl.qosp.controller.RoutingService.init(org.apache.axis2.context.ServiceContext)
at java.lang.Class.getMethod(Class.java:1581)
at
org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:53)
at
org.apache.axis2.engine.DependencyManager.initService(DependencyManager.java:93)
at
org.apache.axis2.context.ConfigurationConte

Re: [axis2] problem with service deployed in application scope

2007-02-16 Thread Michele Mazzucco
AXIS2-2200 created


Michele

On Fri, 2007-02-16 at 15:30 +0530, Deepal Jayasinghe wrote:
> Hi  Michele ;
> 
> Pls create a JIRA attaching your service aar file (if possible source
> code too).
> 
> Thanks
> Deepal
> 
> >Hi all,
> >
> >I'm running a service deployed in application scope, enabled for life
> >cycle management (the environment is tomcat 5.5.20, axis2 snapshot,
> >linux and sun jdk 1.5.0_10). 
> >>From the tomcat logs I see the following error
> >
> >
> >INFO  [09:35:27,716] LifecycleManager:start - Controller started
> >ncl.qosp.controller.scheduler.LifecycleManager.start(LifecycleManager.java:193)
> > INFO  [main] - Controller started
> >org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:66)
> > DEBUG [main] - Exception trying to call init
> >java.lang.NoSuchMethodException:
> >ncl.qosp.controller.RoutingService.init(org.apache.axis2.context.ServiceContext)
> >at java.lang.Class.getMethod(Class.java:1581)
> >at
> >org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:53)
> >at
> >org.apache.axis2.engine.DependencyManager.initService(DependencyManager.java:93)
> >at
> >org.apache.axis2.context.ConfigurationContextFactory.initApplicationScopeServices(ConfigurationContextFactory.java:84)
> >at
> >org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:70)
> >at
> >org.apache.axis2.transport.http.AxisServlet.initConfigContext(AxisServlet.java:545)
> >at
> >org.apache.axis2.transport.http.AxisServlet.init(AxisServlet.java:491)
> >at
> >org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1105)
> >at
> >org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:932)
> >at
> >org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3951)
> >at
> >org.apache.catalina.core.StandardContext.start(StandardContext.java:4225)
> >at
> >org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
> >at
> >org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
> >at
> >org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
> >at
> >org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:809)
> >at
> >org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:698)
> >at
> >org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:472)
> >at
> >org.apache.catalina.startup.HostConfig.start(HostConfig.java:1122)
> >at
> >org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
> >at
> >org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
> >at
> >org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
> >at
> >org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
> >at
> >org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
> >at
> >org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
> >at
> >org.apache.catalina.core.StandardService.start(StandardService.java:450)
> >at
> >org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
> >at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
> >at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> >at
> >sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> >at
> >sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> >at java.lang.reflect.Method.invoke(Method.java:585)
> >at
> >org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294)
> >at
> >org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432)
> >org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:66)
> > DEBUG [main] - Exception trying to call init
> >java.lang.NoSuchMethodException:
> >ncl.qosp.controller.RoutingService.init(org.apache.axis2.context.ServiceContext)
> >at java.lang.Class.getMethod(Class.java:1581)
> >at
> >org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:53)
> >at
> >org.apache.axis2.engine.DependencyManager.initService(DependencyManager.java:93)
> &

Re: [axis2] problem with service deployed in application scope

2007-02-16 Thread Deepal Jayasinghe
Hi  Michele ;

Pls create a JIRA attaching your service aar file (if possible source
code too).

Thanks
Deepal

>Hi all,
>
>I'm running a service deployed in application scope, enabled for life
>cycle management (the environment is tomcat 5.5.20, axis2 snapshot,
>linux and sun jdk 1.5.0_10). 
>>From the tomcat logs I see the following error
>
>
>INFO  [09:35:27,716] LifecycleManager:start - Controller started
>ncl.qosp.controller.scheduler.LifecycleManager.start(LifecycleManager.java:193)
> INFO  [main] - Controller started
>org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:66)
> DEBUG [main] - Exception trying to call init
>java.lang.NoSuchMethodException:
>ncl.qosp.controller.RoutingService.init(org.apache.axis2.context.ServiceContext)
>at java.lang.Class.getMethod(Class.java:1581)
>at
>org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:53)
>at
>org.apache.axis2.engine.DependencyManager.initService(DependencyManager.java:93)
>at
>org.apache.axis2.context.ConfigurationContextFactory.initApplicationScopeServices(ConfigurationContextFactory.java:84)
>at
>org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:70)
>at
>org.apache.axis2.transport.http.AxisServlet.initConfigContext(AxisServlet.java:545)
>at
>org.apache.axis2.transport.http.AxisServlet.init(AxisServlet.java:491)
>at
>org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1105)
>at
>org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:932)
>at
>org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3951)
>at
>org.apache.catalina.core.StandardContext.start(StandardContext.java:4225)
>at
>org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
>at
>org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
>at
>org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
>at
>org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:809)
>at
>org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:698)
>at
>org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:472)
>at
>org.apache.catalina.startup.HostConfig.start(HostConfig.java:1122)
>at
>org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
>at
>org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
>at
>org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
>at
>org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
>at
>org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
>at
>org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
>at
>org.apache.catalina.core.StandardService.start(StandardService.java:450)
>at
>org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
>at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
>at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>at
>sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>at
>sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>at java.lang.reflect.Method.invoke(Method.java:585)
>at
>org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294)
>at
>org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432)
>org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:66)
> DEBUG [main] - Exception trying to call init
>java.lang.NoSuchMethodException:
>ncl.qosp.controller.RoutingService.init(org.apache.axis2.context.ServiceContext)
>at java.lang.Class.getMethod(Class.java:1581)
>at
>org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:53)
>at
>org.apache.axis2.engine.DependencyManager.initService(DependencyManager.java:93)
>at
>org.apache.axis2.context.ConfigurationContextFactory.initApplicationScopeServices(ConfigurationContextFactory.java:84)
>at
>org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:70)
>at
>org.apache.axis2.transport.http.AxisServlet.initConfigContext(AxisServlet.java:545)
>at
>org.apache.axis2.transport.http.AxisServlet.init(AxisServlet.java:491)
>at
>org.apache.catalina.core.StandardWrapper.loadServlet(StandardW

[axis2] problem with service deployed in application scope

2007-02-16 Thread Michele Mazzucco
Hi all,

I'm running a service deployed in application scope, enabled for life
cycle management (the environment is tomcat 5.5.20, axis2 snapshot,
linux and sun jdk 1.5.0_10). 
>From the tomcat logs I see the following error


INFO  [09:35:27,716] LifecycleManager:start - Controller started
ncl.qosp.controller.scheduler.LifecycleManager.start(LifecycleManager.java:193) 
INFO  [main] - Controller started
org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:66)
 DEBUG [main] - Exception trying to call init
java.lang.NoSuchMethodException:
ncl.qosp.controller.RoutingService.init(org.apache.axis2.context.ServiceContext)
at java.lang.Class.getMethod(Class.java:1581)
at
org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:53)
at
org.apache.axis2.engine.DependencyManager.initService(DependencyManager.java:93)
at
org.apache.axis2.context.ConfigurationContextFactory.initApplicationScopeServices(ConfigurationContextFactory.java:84)
at
org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:70)
at
org.apache.axis2.transport.http.AxisServlet.initConfigContext(AxisServlet.java:545)
at
org.apache.axis2.transport.http.AxisServlet.init(AxisServlet.java:491)
at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1105)
at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:932)
at
org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3951)
at
org.apache.catalina.core.StandardContext.start(StandardContext.java:4225)
at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
at
org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:809)
at
org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:698)
at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:472)
at
org.apache.catalina.startup.HostConfig.start(HostConfig.java:1122)
at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
at
org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
at
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
at
org.apache.catalina.core.StandardService.start(StandardService.java:450)
at
org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294)
at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432)
org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:66)
 DEBUG [main] - Exception trying to call init
java.lang.NoSuchMethodException:
ncl.qosp.controller.RoutingService.init(org.apache.axis2.context.ServiceContext)
at java.lang.Class.getMethod(Class.java:1581)
at
org.apache.axis2.engine.DependencyManager.initServiceClass(DependencyManager.java:53)
at
org.apache.axis2.engine.DependencyManager.initService(DependencyManager.java:93)
at
org.apache.axis2.context.ConfigurationContextFactory.initApplicationScopeServices(ConfigurationContextFactory.java:84)
at
org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:70)
at
org.apache.axis2.transport.http.AxisServlet.initConfigContext(AxisServlet.java:545)
at
org.apache.axis2.transport.http.AxisServlet.init(AxisServlet.java:491)
at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1105)
at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:932)
at
org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3951)
at
org.apache.catalina.core.StandardContext.start(StandardContext.java:4225)
at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
at
org.apache.catalina.core.StandardHost.addChild(StandardH

Transportsession scope example(s)

2007-01-04 Thread Martin Brown

I'd just like to prompt again for some (an) examples of using the
transportsession scope. I've configured a basic, dummy service with this scope
but it's behaving as an "application" scope (even after changing axis2.xml to
allow the transportsession scope).

Thanks,
Martin

Martin Brown wrote:
I'm really struggling trying to implement a transport session Axis2 
service. Maybe I'm trying to go about it the wrong way...


I need a service that will present a login operation which will 
authenticate the user against a third party authentication system and 
store the resulting credentials against the user's Axis2 session for 
future operation requests. Storing these credentials in a parameter with 
an application scope seems very clunky and possibly not very secure so a 
transport session scope sounds more appropriate.


I really need a complete, simple example of such a service as a starting 
point though. Just setting the services.xml scope to transportsession 
(and modifying the axis2.xml) doesn't seem to be enough.


Any pointers would be appreciated.

Thanks,
Martin

-
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]



AW: AW: sesion managment, scope=soapsession

2006-12-19 Thread Stadelmann Josef
Hi Deepal

I am back to work, hopefully joint, on this burning issue.

To say is, that when we setup service.xml according to documentation at
http : //www.developer.com/java/web/print.php/3620661 and
that scope=" sopasession" does not bring back the serviceGroupContextID
but  scope="soapsession"  will bring you bak the  serviceGroupContextID

Just 3 days to figure out that.

Now, I am ready and send you the code and the .xml's to help you re-create the 
problem.



After the initial call, SOAPClient #1 uses the same sender in thread 
SOAPClient-#1 for each subsequent call and axis2 passes the 
serviceGroupContextId.

After the 2. initial call, sent by SOAPClient #2 running in thread 
SOAPClinet-#2, it uses the same sender in the thread SOPAClient-#2 for each 
subsequent call. BUT axis2 THEN calles destroy() and init() on MyService and 
axis2 has created a new serviceGroupContextId AND this makes obviously 
SOAPClient-#1 fail with an exception.

See files attached as first working examples using scope="soapsession" but 
second, raising an exception when client no 2 starts in its thread.





Diving into axis2 code: the "serviceimpl" object created by 
RawXMLInOutMessageReceiver.makeNewServiceObject( mc ), creates an instance of 
"CODE" (MyService) including some "STATE" keept at MyService, in a private 
static "sDate" variable, beeing an example for the creation time stamp. As far 
as I can figure out, this instance of "CODE", the implservice object, once 
created, is stored in an instance of "serviceContext" under a property 
"ServiceContext.SERVICE_OBJECT".

In short I like to say: the LINK (COMBINATION) of an instance of 
"ServiceContext" to an instance of "implservice" can bee seen as an OBJECT in 
the traditional sense where implservce keeps the CODE and ServiceContext stores 
the STATE. As such the TWO should have a lifecycle and we should be able to 
reference each of it by a session.


The question is then: 
How can I create multiple instances of this "COMBINATION"?

Where are REFERENCES to this "COMBINATIONS" stored?

How do I retreive a key, a reference, the OBJECT with CODE and STATE from 
AXIS2? 


I need for every SESSION, better for every CLIENT IN A THREAD an instance of a 
"CODE"/"STATE" COMBINATION where the STATE for every session, better ever 
thread must be unique?



I am new to axis2 and please tell us what I have to see differently from the 
traditional object world, in particular, how is the state stiored and retreived 
among sessions or better client threads?




Deepal, I like to answer your questions and comment embedded in++   ++ .



-Ursprüngliche Nachricht-
Von: Deepal Jayasinghe [mailto : [EMAIL PROTECTED]
Gesendet: Dienstag, 12. Dezember 2006 06:37
An: axis-user@ws.apache.org
Betreff: Re: AW: sesion managment, scope=soapsession


Hi  Stadelmann ;

>
>My client #1 runs continously, and sends arround 40 msg a second to the 
>server. 
>When the second client starts, cline t#1 is still sending messages and so we 
>do 
>not have a time-out condition. client #1 never times out.
>
>BUT as I decribe, using the code shown, when client #2 starts 
>MyService.destroy() 
>is called followed by MyService.init() which has the effect that client #1 
>fails 
>thereafter with an "invalid group context id exception"
>  
>
hmmm, can you please help me to re-create the problem. If you can send
me the sample services and clients that will be very helpful for me to
fix the issue.

++ YES, attached below ++

>
>I would appreciate an example on how to have a scenario as I describe.
>When I read literature about tomcat, retriving a session object from the 
>clients request object, it seems that internals are figuring out which client 
>is calling and the rigth session object which acts as data store for the
>session is returned/created. 
>
>How is that with AXIS2-1.1?
>  
>
Will write a sample soon .


++ OK, that would be fine, because I am still not certain that 
scope="soapsession"
is what I need for a login, ..., ..., ..., logout, for a long lasting seesions, 
where 
each session has it's own instance of a service object. ++



>When the MyService Object gets created I store the creation time for the
>instance in a instance variable. And when multiple clients run without
>scope=soapsession set, all clients return the same time stamp. So that
>means for me! client #1 makes axis2 creating a first instance of a class,
>and places the creation timestamp.
>  
>
That can not happen , there should be a separate service impl class for
each client, Im 100% sure about that since I have tested that. :)

++ Maybe after using my code, you can see this differently. ++


>This is called an object, and client

Re: AW: sesion managment, scope=soapsession

2006-12-11 Thread Deepal Jayasinghe
Hi  Stadelmann ;

>
>My client #1 runs continously, and sends arround 40 msg a second to the 
>server. 
>When the second client starts, cline t#1 is still sending messages and so we 
>do 
>not have a time-out condition. client #1 never times out.
>
>BUT as I decribe, using the code shown, when client #2 starts 
>MyService.destroy() 
>is called followed by MyService.init() which has the effect that client #1 
>fails 
>thereafter with an "invalid group context id exception"
>  
>
hmmm, can you please help me to re-create the problem. If you can send
me the sample services and clients that will be very helpful for me to
fix the issue.

>
>I would appreciate an example on how to have a scenario as I describe.
>When I read literature about tomcat, retriving a session object from the 
>clients request object, it seems that internals are figuring out which client 
>is calling and the rigth session object which acts as data store for the
>session is returned/created. 
>
>How is that with AXIS2-1.1?
>  
>
Will write a sample soon .

>When the MyService Object gets created I store the creation time for the
>instance in a instance variable. And when multiple clients run without
>scope=soapsession set, all clients return the same time stamp. So that
>means for me! client #1 makes axis2 creating a first instance of a class,
>and places the creation timestamp.
>  
>
That can not happen , there should be a separate service impl class for
each client, Im 100% sure about that since I have tested that. :)

>This is called an object, and client #2 sends his message to the same instance
>the same object. When the call to client 2 returns, client #2 finds the same 
>time stamp as client #1 has. But when client #2 starts 10 seconds after client 
>#1,
>I would expect that client #2 has a different object-creation-timestamp
>then client #1 unless we talk to the same instance (which I cant use).
>Josef
>  
>
Are u keeping your value as a static ? I mean are u storing your value
in a static variable  ?

>Again - my clients 1 to 20 do continously send messages, each client in
>its thread - I am using NetBeans and I am just launching more then one
>client. So each client is fully busy sending. But each client gets 
>responses from the same server object instance. And we have not a time-out
>condition as each client continously sends. Once we come to real clients
>where usesers invoke messages we wil care about timeouts. But as long as
>client code jsut loops in a for() we do not have time-outs, even not with
>20 sessions, but in our example using scope=soapsession, we do not get that
>far, as client #1 runs until client #2 starts, which makes client #1 fail
>with "invalid service group context id"
>Josef
>  
>
Are you sending service group id in each request , or you juts send as
new req ?
If you want to go into same soapsession , then you need to send the
serviceGroupID

>>I have read in a dcoument about axis session managment @
>>http://www.developer.com/java/web/print.php/3620661 "that axis2 is
>>meant to be an enterprise web service engine, so it has to support
>>session management."
>>
>>
>>
>The article is little bit out dated , since we had few changes from
>Axis2 1.0 to 1.1
>
>
>
>So where is a new articel reflecting the same topic?
>What values does this articel have among well undestood generics when
>I can not count on the little code fragments given. Also a previous
>mail has lead me to this articel. So how far is it outdated?
>Josef
>
>  
>
I will update that and publish soon.

Thanks
Deepal



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



AW: sesion managment, scope=soapsession

2006-12-11 Thread Stadelmann Josef
Hi Robert
 
I really like axis2-1.1 managing my sessions if this is foreseen and works. But 
as you know, my sessions must each talk in a 1:1 relationship to a unique 
instance of a service object. A service object which wraps my external server 
and has a CORBA IOR to it, wheras CORBA IOR's are unique to each server 
instantiated. A server is in this case an OpenVMS process serving exact 1 
client session.
 
If axis2-1.1 can manage that, what session scope to I need? If as as said in a 
reply to my problems, scope=soapsession fals short.
 
Given I am desiding to do it mysef as you recommend, a good idee if axis2 fails 
to support such sessions correctly, would you then please be so kind and tell 
me what you mean with "ehcache"? Maybe you can paste in a working client and a 
working server code example for the sack of the community? Or maybe plaste that 
into the official axis2-1.1 documentation. I am missing that working example 
and I am running now some weeks behind project schedule.
 
In any case, thank you for your help.
 
Josef
 

-Ursprüngliche Nachricht-
Von: robert lazarski [mailto:[EMAIL PROTECTED]
Gesendet: Donnerstag, 30. November 2006 13:12
An: axis-user@ws.apache.org
Betreff: Re: sesion managment, scope=soapsession


Stadelmann, Deepal describes well what Axis2 does and my recommendation is to 
use axis2 for your session management if possible. You may find, however, that 
it does not match your business case. 

If it does not, you may consider rolling your own via something like UUID - 
which WS-Addressing does in its own way - and your own ehcache or the like 
storage. Its pretty easy and I've done it for many clients. The idea is simple: 
you login, pass back a UUID, pass it back in for subsequent calls and use it as 
the key to put / get your objects out of ehcache. Logout would invalidate the 
session which ehcache can do itself after a choosen timeout. ehcache is used 
with Hibernate and is simple and effective. Oh yeah - just ignore the idea if 
that doesn't fit what you need. 

HTH,
Robert 


On 11/29/06, Deepal Jayasinghe < [EMAIL PROTECTED]> wrote: 

Hi Stadelmann ;
pls see my comments below;

> Hi session-managers,
>
>
> I'm running my client and server with modules addressing-1.1, logging,
> soapmonitor-1.1 engaged and have set scope=soapsession 
>
> MyService.java got the additional methods
>
>public void init(ServiceContext sCtx) {
> this.sc = sCtx;
> this.log.info(sc.toString()+" init() called "); 
> }
>
> public void destroy(ServiceContext sCtx) {
> if(!this.sc.toString().equals(sCtx.toString())){
> this.log.error("ServiceContext on init() and destroy() not
> equal in ");
> }
> this.log.info(sc.toString()+" destroy() called ");
> }
>
> public void setOperationContext(OperationContext oCtx) { 
> this.oc = oCtx;
> this.log.info(oc.toString()+" setOperationContext() called
> ");
> }
>
We have removed this method (it was there in Axis2 1.0 , but we removed 
that from Axis2 1.1), so we are no longer going to call this method . If
you want to get access to operation context , then you can do that as
follows;
MessageContext msgCtx = MessageContext.getCurrentContext ();

from msgCtx you can access any of the contexts you want .

>
>
> I start client #1 which has the effect that MyService.init() is
> called; so far so right!
> Client #1 then loops and sends continously messages to MyService.echo()
> I start client #2 which has the effect that MyService.destroy() is
> called followed by MyService.init()
> This has the effect that client #1 fails with an "invalid group
> context id exception" 
>
> Is this a bug?
>
Nope. That is not a bug , soapsession has concept of time out , so once
it gets time out you will get that exception.

>
>
> I have studied the architecture of axis2 and have drilled down in code 
> and I came down to where alle the service objects are finally called
> at "invokeBusinessLogic" (inCtx, outCtx)  with it's call to
> "method.invoke" ( . . . )
>
good .

> All reading in code and documentation did not answer my questions ***
> How does Axis2 manage / support long-lasting-sessions to
> server-objects bound to this session ? ***
>
> Do I have to implement this myself on top of Axis2? 
>
No , you can get support from Axis2 session management. If you have
Axis2 1.1 distribution there you can find a sample called Library sample
, which help you to understand most of the important factors.

>
> 1. I want to have a client-object exchanging OMElements with it's
> service-class-object.
>
yes , doable

> 2. when the client starts the session, up on receiving the first
> message, a unique in

AW: sesion managment, scope=soapsession

2006-12-11 Thread Stadelmann Josef
Hi Deepal
pls see my coment below

-Ursprüngliche Nachricht-
Von: Deepal Jayasinghe [mailto:[EMAIL PROTECTED]
Gesendet: Mittwoch, 29. November 2006 17:27
An: axis-user@ws.apache.org
Betreff: Re: sesion managment, scope=soapsession


Hi Stadelmann ;
pls see my comments below;

> Hi session-managers,
>
>
> I'm running my client and server with modules addressing-1.1, logging,
> soapmonitor-1.1 engaged and have set scope=soapsession
>
> MyService.java got the additional methods
>  
>public void init(ServiceContext sCtx) {
> this.sc = sCtx;
> this.log.info(sc.toString()+" init() called ");
> }
>
> public void destroy(ServiceContext sCtx) {
> if(!this.sc.toString().equals(sCtx.toString())){
> this.log.error("ServiceContext on init() and destroy() not
> equal in ");
> }
> this.log.info(sc.toString()+" destroy() called ");
> }
>
> public void setOperationContext(OperationContext oCtx) {
> this.oc = oCtx;
> this.log.info(oc.toString()+" setOperationContext() called
> ");   
> }
>
We have removed this method (it was there in Axis2 1.0 , but we removed
that from Axis2 1.1), so we are no longer going to call this method . If
you want to get access to operation context , then you can do that as
follows;
MessageContext msgCtx = MessageContext.getCurrentContext();

from msgCtx you can access any of the contexts you want .

OK - i take this into consideration



>  
>
> I start client #1 which has the effect that MyService.init() is
> called; so far so right!
> Client #1 then loops and sends continously messages to MyService.echo()
> I start client #2 which has the effect that MyService.destroy() is
> called followed by MyService.init()
> This has the effect that client #1 fails with an "invalid group
> context id exception"
>
> Is this a bug?
>
Nope. That is not a bug , soapsession has concept of time out , so once
it gets time out you will get that exception.


My client #1 runs continously, and sends arround 40 msg a second to the server. 
When the second client starts, cline t#1 is still sending messages and so we do 
not have a time-out condition. client #1 never times out.

BUT as I decribe, using the code shown, when client #2 starts 
MyService.destroy() 
is called followed by MyService.init() which has the effect that client #1 
fails 
thereafter with an "invalid group context id exception"


>
>
> I have studied the architecture of axis2 and have drilled down in code
> and I came down to where alle the service objects are finally called
> at "invokeBusinessLogic" (inCtx, outCtx)  with it's call to
> "method.invoke" ( . . . )
>
good .

> All reading in code and documentation did not answer my questions ***
> How does Axis2 manage / support long-lasting-sessions to
> server-objects bound to this session ? ***
>
> Do I have to implement this myself on top of Axis2?
>
No , you can get support from Axis2 session management. If you have
Axis2 1.1 distribution there you can find a sample called Library sample
, which help you to understand most of the important factors.


I would appreciate an example on how to have a scenario as I describe.
When I read literature about tomcat, retriving a session object from the 
clients request object, it seems that internals are figuring out which client 
is calling and the rigth session object which acts as data store for the
session is returned/created. 

How is that with AXIS2-1.1?




 

>
> 1. I want to have a client-object exchanging OMElements with it's
> service-class-object.
>
yes , doable

> 2. when the client starts the session, up on receiving the first
> message, a unique instance of the service-class-object shall be
> created at the server.
>
yes , that is what happen.

When the MyService Object gets created I store the creation time for the
instance in a instance variable. And when multiple clients run without
scope=soapsession set, all clients return the same time stamp. So that
means for me! client #1 makes axis2 creating a first instance of a class,
and places the creation timestamp.

This is called an object, and client #2 sends his message to the same instance
the same object. When the call to client 2 returns, client #2 finds the same 
time stamp as client #1 has. But when client #2 starts 10 seconds after client 
#1,
I would expect that client #2 has a different object-creation-timestamp
then client #1 unless we talk to the same instance (which I cant use).
Josef





> 2a) 20 client objects shall mean we have instantiated 20
> dedicated-server-objects
>
yes.

> 3. as long as this 20 service-class-object exists, in fact 20
> wrapper-object to 20 external server proc

AW: sesion managment, scope=soapsession

2006-12-11 Thread Stadelmann Josef
Hi Robert
 
But when I have to implement finding the correswponding instance of a class (an 
object) myself, belonging to the incoming session request object, then I would 
consider axis2-1.1 not beeing able to keep sessions appart from each other. And 
again back to what I write. Why is the service group context id destroyed when 
a second client calls MyService in scope=soapsession? Which makes in gact 
client #1 fail with "invalid service group context id"
 
When I read literatur about tomcat, the session object is where instance data 
can be stored, and it is up to tomcat to return the correct session object from 
request.getSession(true). Does axis2-1.1 not support that?
 
Also, where can I learn about how WS-addressing supports sessions? Or is 
WS-addressing not supporting sessions? Does WS-addressing not supporting the 
addressing to unique session based instances of a service class object? (where 
each session has its unique instance of a service class object).
 
What is the correct approach/code to have for each session exactly one instance 
of a service class object established?  
 
Josef
 
 
 
 
 
 

-Ursprüngliche Nachricht-
Von: robert lazarski [mailto:[EMAIL PROTECTED]
Gesendet: Donnerstag, 30. November 2006 13:12
An: axis-user@ws.apache.org
Betreff: Re: sesion managment, scope=soapsession


Stadelmann, Deepal describes well what Axis2 does and my recommendation is to 
use axis2 for your session management if possible. You may find, however, that 
it does not match your business case. 

If it does not, you may consider rolling your own via something like UUID - 
which WS-Addressing does in its own way - and your own ehcache or the like 
storage. Its pretty easy and I've done it for many clients. The idea is simple: 
you login, pass back a UUID, pass it back in for subsequent calls and use it as 
the key to put / get your objects out of ehcache. Logout would invalidate the 
session which ehcache can do itself after a choosen timeout. ehcache is used 
with Hibernate and is simple and effective. Oh yeah - just ignore the idea if 
that doesn't fit what you need. 

HTH,
Robert 


On 11/29/06, Deepal Jayasinghe < [EMAIL PROTECTED]> wrote: 

Hi Stadelmann ;
pls see my comments below;

> Hi session-managers,
>
>
> I'm running my client and server with modules addressing-1.1, logging,
> soapmonitor-1.1 engaged and have set scope=soapsession 
>
> MyService.java got the additional methods
>
>public void init(ServiceContext sCtx) {
> this.sc = sCtx;
> this.log.info(sc.toString()+" init() called "); 
> }
>
> public void destroy(ServiceContext sCtx) {
> if(!this.sc.toString().equals(sCtx.toString())){
> this.log.error("ServiceContext on init() and destroy() not
> equal in ");
> }
> this.log.info(sc.toString()+" destroy() called ");
> }
>
> public void setOperationContext(OperationContext oCtx) { 
> this.oc = oCtx;
> this.log.info(oc.toString()+" setOperationContext() called
> ");
> }
>
We have removed this method (it was there in Axis2 1.0 , but we removed 
that from Axis2 1.1), so we are no longer going to call this method . If
you want to get access to operation context , then you can do that as
follows;
MessageContext msgCtx = MessageContext.getCurrentContext ();

from msgCtx you can access any of the contexts you want .

>
>
> I start client #1 which has the effect that MyService.init() is
> called; so far so right!
> Client #1 then loops and sends continously messages to MyService.echo()
> I start client #2 which has the effect that MyService.destroy() is
> called followed by MyService.init()
> This has the effect that client #1 fails with an "invalid group
> context id exception" 
>
> Is this a bug?
>
Nope. That is not a bug , soapsession has concept of time out , so once
it gets time out you will get that exception.

>
>
> I have studied the architecture of axis2 and have drilled down in code 
> and I came down to where alle the service objects are finally called
> at "invokeBusinessLogic" (inCtx, outCtx)  with it's call to
> "method.invoke" ( . . . )
>
good .

> All reading in code and documentation did not answer my questions ***
> How does Axis2 manage / support long-lasting-sessions to
> server-objects bound to this session ? ***
>
> Do I have to implement this myself on top of Axis2? 
>
No , you can get support from Axis2 session management. If you have
Axis2 1.1 distribution there you can find a sample called Library sample
, which help you to understand most of the important factors.

>
> 1. I want to have a client-object exchanging OMElements with it's
> service-class-object.
>
yes , doable

> 2. when the client sta

Re: sesion managment, scope=soapsession

2006-11-30 Thread robert lazarski

Stadelmann, Deepal describes well what Axis2 does and my recommendation is
to use axis2 for your session management if possible. You may find, however,
that it does not match your business case.

If it does not, you may consider rolling your own via something like UUID -
which WS-Addressing does in its own way - and your own ehcache or the like
storage. Its pretty easy and I've done it for many clients. The idea is
simple: you login, pass back a UUID, pass it back in for subsequent calls
and use it as the key to put / get your objects out of ehcache. Logout would
invalidate the session which ehcache can do itself after a choosen timeout.
ehcache is used with Hibernate and is simple and effective. Oh yeah - just
ignore the idea if that doesn't fit what you need.

HTH,
Robert

On 11/29/06, Deepal Jayasinghe <[EMAIL PROTECTED]> wrote:


Hi Stadelmann ;
pls see my comments below;

> Hi session-managers,
>
>
> I'm running my client and server with modules addressing-1.1, logging,
> soapmonitor-1.1 engaged and have set scope=soapsession
>
> MyService.java got the additional methods
>
>public void init(ServiceContext sCtx) {
> this.sc = sCtx;
> this.log.info(sc.toString()+" init() called ");
> }
>
> public void destroy(ServiceContext sCtx) {
> if(!this.sc.toString().equals(sCtx.toString())){
> this.log.error("ServiceContext on init() and destroy() not
> equal in ");
> }
> this.log.info(sc.toString()+" destroy() called ");
> }
>
> public void setOperationContext(OperationContext oCtx) {
> this.oc = oCtx;
> this.log.info(oc.toString()+" setOperationContext() called
> ");
> }
>
We have removed this method (it was there in Axis2 1.0 , but we removed
that from Axis2 1.1), so we are no longer going to call this method . If
you want to get access to operation context , then you can do that as
follows;
MessageContext msgCtx = MessageContext.getCurrentContext();

from msgCtx you can access any of the contexts you want .

>
>
> I start client #1 which has the effect that MyService.init() is
> called; so far so right!
> Client #1 then loops and sends continously messages to MyService.echo()
> I start client #2 which has the effect that MyService.destroy() is
> called followed by MyService.init()
> This has the effect that client #1 fails with an "invalid group
> context id exception"
>
> Is this a bug?
>
Nope. That is not a bug , soapsession has concept of time out , so once
it gets time out you will get that exception.

>
>
> I have studied the architecture of axis2 and have drilled down in code
> and I came down to where alle the service objects are finally called
> at "invokeBusinessLogic" (inCtx, outCtx)  with it's call to
> "method.invoke" ( . . . )
>
good .

> All reading in code and documentation did not answer my questions ***
> How does Axis2 manage / support long-lasting-sessions to
> server-objects bound to this session ? ***
>
> Do I have to implement this myself on top of Axis2?
>
No , you can get support from Axis2 session management. If you have
Axis2 1.1 distribution there you can find a sample called Library sample
, which help you to understand most of the important factors.

>
> 1. I want to have a client-object exchanging OMElements with it's
> service-class-object.
>
yes , doable

> 2. when the client starts the session, up on receiving the first
> message, a unique instance of the service-class-object shall be
> created at the server.
>
yes , that is what happen.

> 2a) 20 client objects shall mean we have instantiated 20
> dedicated-server-objects
>
yes.

> 3. as long as this 20 service-class-object exists, in fact 20
> wrapper-object to 20 external server process, and as long as this 20
> external process exist it shall not be allowed that one single
> service-class-object dies. for that reasioon the server-objects must
> exist until it's dedicated client terminates the session esplicitly by
> calling logout() on the server-object.
>
Nope , the behavior of soapsession is not like that. It has a notion of
time out. If the user does not touch the service for about 30s (time
interval is configurable) , then the session will be automatically
terminated.

> 4. every message sent by a client has to reach exact the same instance
> of the service-class-object as the previous message did, anything else
> would be considerd a security risk, a fault, an error.
>
yes , we are mapping to the same session using special header parameter
called "ServiceGroupID"

>
>
> I have read in a dcoument about axis session managment @
> http://www.developer.com/java/web/print.php/362066

Re: sesion managment, scope=soapsession

2006-11-29 Thread Deepal Jayasinghe
Hi Stadelmann ;
pls see my comments below;

> Hi session-managers,
>
>
> I'm running my client and server with modules addressing-1.1, logging,
> soapmonitor-1.1 engaged and have set scope=soapsession
>
> MyService.java got the additional methods
>  
>public void init(ServiceContext sCtx) {
> this.sc = sCtx;
> this.log.info(sc.toString()+" init() called ");
> }
>
> public void destroy(ServiceContext sCtx) {
> if(!this.sc.toString().equals(sCtx.toString())){
> this.log.error("ServiceContext on init() and destroy() not
> equal in ");
> }
> this.log.info(sc.toString()+" destroy() called ");
> }
>
> public void setOperationContext(OperationContext oCtx) {
> this.oc = oCtx;
> this.log.info(oc.toString()+" setOperationContext() called
> ");   
> }
>
We have removed this method (it was there in Axis2 1.0 , but we removed
that from Axis2 1.1), so we are no longer going to call this method . If
you want to get access to operation context , then you can do that as
follows;
MessageContext msgCtx = MessageContext.getCurrentContext();

from msgCtx you can access any of the contexts you want .

>  
>
> I start client #1 which has the effect that MyService.init() is
> called; so far so right!
> Client #1 then loops and sends continously messages to MyService.echo()
> I start client #2 which has the effect that MyService.destroy() is
> called followed by MyService.init()
> This has the effect that client #1 fails with an "invalid group
> context id exception"
>
> Is this a bug?
>
Nope. That is not a bug , soapsession has concept of time out , so once
it gets time out you will get that exception.

>
>
> I have studied the architecture of axis2 and have drilled down in code
> and I came down to where alle the service objects are finally called
> at "invokeBusinessLogic" (inCtx, outCtx)  with it's call to
> "method.invoke" ( . . . )
>
good .

> All reading in code and documentation did not answer my questions ***
> How does Axis2 manage / support long-lasting-sessions to
> server-objects bound to this session ? ***
>
> Do I have to implement this myself on top of Axis2?
>
No , you can get support from Axis2 session management. If you have
Axis2 1.1 distribution there you can find a sample called Library sample
, which help you to understand most of the important factors.

>
> 1. I want to have a client-object exchanging OMElements with it's
> service-class-object.
>
yes , doable

> 2. when the client starts the session, up on receiving the first
> message, a unique instance of the service-class-object shall be
> created at the server.
>
yes , that is what happen.

> 2a) 20 client objects shall mean we have instantiated 20
> dedicated-server-objects
>
yes.

> 3. as long as this 20 service-class-object exists, in fact 20
> wrapper-object to 20 external server process, and as long as this 20
> external process exist it shall not be allowed that one single
> service-class-object dies. for that reasioon the server-objects must
> exist until it's dedicated client terminates the session esplicitly by
> calling logout() on the server-object.
>
Nope , the behavior of soapsession is not like that. It has a notion of
time out. If the user does not touch the service for about 30s (time
interval is configurable) , then the session will be automatically
terminated.

> 4. every message sent by a client has to reach exact the same instance
> of the service-class-object as the previous message did, anything else
> would be considerd a security risk, a fault, an error.
>
yes , we are mapping to the same session using special header parameter
called "ServiceGroupID"

>
>
> I have read in a dcoument about axis session managment @
> http://www.developer.com/java/web/print.php/3620661 "that axis2 is
> meant to be an enterprise web service engine, so it has to support
> session management."
>
The article is little bit out dated , since we had few changes from
Axis2 1.0 to 1.1

> I have read all related e-mails and implemented soap-sessions which
> work nicely with one client and one server. But they die when the
> second client starts as descibed above. the second client creates a
> new service-group-id when and the old one gets lost. THis happens in
> my mind because destry is called implicit. So client-1 then fails as
> it's known service-group-id does no longer exist.
>
>
>
> I have not found in all the e-mail of the past 3 months a clear idea
> or an answer to this often asked questions about "how to implement
> ses

sesion managment, scope=soapsession

2006-11-29 Thread Stadelmann Josef
Hi session-managers,


I'm running my client and server with modules addressing-1.1, logging, 
soapmonitor-1.1 engaged and have set scope=soapsession

MyService.java got the additional methods
 
   public void init(ServiceContext sCtx) {
this.sc = sCtx;
this.log.info(sc.toString()+" init() called ");
}

public void destroy(ServiceContext sCtx) {
if(!this.sc.toString().equals(sCtx.toString())){
this.log.error("ServiceContext on init() and destroy() not equal in 
");
}
this.log.info(sc.toString()+" destroy() called ");
}

public void setOperationContext(OperationContext oCtx) {
this.oc = oCtx;
this.log.info(oc.toString()+" setOperationContext() called ");
}
 

I start client #1 which has the effect that MyService.init() is called; so far 
so right!
Client #1 then loops and sends continously messages to MyService.echo()
I start client #2 which has the effect that MyService.destroy() is called 
followed by MyService.init()
This has the effect that client #1 fails with an "invalid group context id 
exception" 

Is this a bug?



I have studied the architecture of axis2 and have drilled down in code and I 
came down to where alle the service objects are finally called at 
"invokeBusinessLogic" (inCtx, outCtx)  with it's call to "method.invoke" ( . . 
. )

All reading in code and documentation did not answer my questions *** How does 
Axis2 manage / support long-lasting-sessions to server-objects bound to this 
session ? ***

Do I have to implement this myself on top of Axis2?


1. I want to have a client-object exchanging OMElements with it's 
service-class-object.

2. when the client starts the session, up on receiving the first message, a 
unique instance of the service-class-object shall be created at the server.
2a) 20 client objects shall mean we have instantiated 20 
dedicated-server-objects

3. as long as this 20 service-class-object exists, in fact 20 wrapper-object to 
20 external server process, and as long as this 20 external process exist it 
shall not be allowed that one single service-class-object dies. for that 
reasioon the server-objects must exist until it's dedicated client terminates 
the session esplicitly by calling logout() on the server-object.

4. every message sent by a client has to reach exact the same instance of the 
service-class-object as the previous message did, anything else would be 
considerd a security risk, a fault, an error.



I have read in a dcoument about axis session managment @ 
http://www.developer.com/java/web/print.php/3620661 "that axis2 is meant to be 
an enterprise web service engine, so it has to support session management."

I have read all related e-mails and implemented soap-sessions which work nicely 
with one client and one server. But they die when the second client starts as 
descibed above. the second client creates a new service-group-id when and the 
old one gets lost. THis happens in my mind because destry is called implicit. 
So client-1 then fails as it's known service-group-id does no longer exist. 



I have not found in all the e-mail of the past 3 months a clear idea or an 
answer to this often asked questions about "how to implement sessions to such 
server side obejcts".

I must admit, I do not understand how ws-addressing supports my demand.

Can I managment my sessions with axis2 in an elegant way or do I have to 
fall-back to servlets and tomcat?

I would really appreciate any answers and thank you very much to answer my 
burning question not only for my own satisfaction. Thank you.
Josef



Re: [Axis2] application scope problem (several service instance created)

2006-11-08 Thread Deepal Jayasinghe
Hi Michele ;

Good to here that :)

>I'm sorry,
>
>please ignore this message. The service was reinitialized because of an
>initialization error.
>
>Michele
>
>Michele Mazzucco wrote:
>  
>
>>Hi all,
>>
>>I'm very stuck with this problem. The service is configured in
>>application scope, but several instances are created (I'm running the
>>latest nightly build).
>>
>>I though the problem was related with the ServiceLifecycle inteface (see
>> jira AXIS2-1604), but I was wrong.
>>
>>This is my services.xml, while below you can see the tomcat output (3
>>service instances are created)
>>
>>
>>  >   "org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/>
>>  
>>  >"org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/>
>>
>>  
>>  ncl.qosp.controller.RoutingService
>>  
>>
>>  
>>
>>
>>
>>
>>
>>
>>08-Nov-2006 11:59:56 org.apache.catalina.core.AprLifecycleListener
>>lifecycleEven
>>t
>>INFO: The Apache Tomcat Native library which allows optimal performance
>>in produ
>>ction environments was not found on the java.library.path: C:\Program
>>Files\Java
>>\jdk1.5.0_08\bin;.;C:\WINDOWS\system32;C:\WINDOWS;C:\Program
>>Files\Java\jdk1.5.0
>>_08\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program
>>Files
>>\QuickTime\QTSystem\;C:\Other\Subversion\bin;C:\Other\WinSCP3\;D:\Programs\Apach
>>e\maven-1.1-beta-2\bin;D:\Programs\Apache\apache-ant-1.6.5\bin;C:\Program
>>Files\
>>SSH Communications Security\SSH Secure Shell;C:\Program
>>Files\Java\jdk1.5.0_03\b
>>in;;D:\Programs\gnupg-w32cli-1.2.2;C:\Other\Subversion\bin;C:\Program
>>Files\Java
>>\jdk1.5.0_08\bin
>>08-Nov-2006 11:59:56 org.apache.coyote.http11.Http11BaseProtocol init
>>INFO: Initializing Coyote HTTP/1.1 on http-8081
>>08-Nov-2006 11:59:56 org.apache.catalina.startup.Catalina load
>>INFO: Initialization processed in 750 ms
>>08-Nov-2006 11:59:56 org.apache.catalina.core.StandardService start
>>INFO: Starting service Catalina
>>08-Nov-2006 11:59:56 org.apache.catalina.core.StandardEngine start
>>INFO: Starting Servlet Engine: Apache Tomcat/5.5.15
>>08-Nov-2006 11:59:56 org.apache.catalina.core.StandardHost start
>>INFO: XML validation disabled
>>08-Nov-2006 11:59:57 org.apache.catalina.startup.HostConfig deployWAR
>>INFO: Deploying web application archive axis2.war
>>2006-11-08 11:59:58,349 INFO
>>org.apache.axis2.deployment.DeploymentEngine - Dep
>>loying module : addressing-1.1
>>2006-11-08 11:59:58,365 INFO
>>org.apache.axis2.deployment.DeploymentEngine - Dep
>>loying module : managerInterceptor
>>2006-11-08 11:59:58,380 INFO
>>org.apache.axis2.deployment.DeploymentEngine - Dep
>>loying module : soapmonitor-1.1
>>2006-11-08 11:59:58,818 INFO  ncl.qosp.controller.LifecycleSupport -
>>Server connector started at service:jmx:rmi:///jndi/rmi://eskdale:10099/qosp
>>
>>
>>
>>This is called by the static block of the stateful service since I've
>>removed lifecycle management from the services.xml file
>>
>>
>>static {
>>   //.
>>   new LifecycleSupport().method()
>>}
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>2006-11-08 11:59:59,114 INFO
>>org.apache.axis2.deployment.DeploymentEngine - Dep
>>loying Web service  RoutingService.aar
>>2006-11-08 11:59:59,130 INFO
>>org.apache.axis2.deployment.DeploymentEngine - Dep
>>loying Web service  version.aar
>>2006-11-08 11:59:59,146 INFO  ncl.qosp.controller.RoutingService - --
>>Constructo
>>r
>>08-Nov-2006 11:59:59 org.apache.coyote.http11.Http11BaseProtocol start
>>INFO: Starting Coyote HTTP/1.1 on http-8081
>>08-Nov-2006 12:00:00 org.apache.jk.common.ChannelSocket init
>>INFO: JK: ajp13 listening on /0.0.0.0:8009
>>08-Nov-2006 12:00:00 org.apache.jk.server.JkMain start
>>INFO: Jk running ID=0 time=16/46  config=null
>>08-Nov-2006 12:00:00 org.apache.catalina.storeconfig.StoreLoader load
>>INFO: Find registry server-registry.xml at classpath resource
>>08-Nov-2006 12:00:00 org.apache.catalina.startup.Catalina start
>>INFO: Server startup in 3515 ms
>>2006-11-08 12:00:19,237 INFO  ncl.qosp.controller.RoutingService - --
>>Constructor
>>2006-11-08 12:00:29,392 INFO  ncl.qosp.controller.RoutingService - --
>>Constructor
>>
>>
>>
>>
>>Michele
>>
>>-
>>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]
>
>
>
>  
>

-- 
Thanks,
Deepal

"The highest tower is built one brick at a time"



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



Re: [Axis2] application scope problem (several service instance created)

2006-11-08 Thread Michele Mazzucco
I'm sorry,

please ignore this message. The service was reinitialized because of an
initialization error.

Michele

Michele Mazzucco wrote:
> Hi all,
> 
> I'm very stuck with this problem. The service is configured in
> application scope, but several instances are created (I'm running the
> latest nightly build).
> 
> I though the problem was related with the ServiceLifecycle inteface (see
>  jira AXIS2-1604), but I was wrong.
> 
> This is my services.xml, while below you can see the tomcat output (3
> service instances are created)
> 
> 
>   "org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/>
>   
>"org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/>
> 
>   
>   ncl.qosp.controller.RoutingService
>   
> 
>   
> 
> 
> 
> 
> 
> 
> 08-Nov-2006 11:59:56 org.apache.catalina.core.AprLifecycleListener
> lifecycleEven
> t
> INFO: The Apache Tomcat Native library which allows optimal performance
> in produ
> ction environments was not found on the java.library.path: C:\Program
> Files\Java
> \jdk1.5.0_08\bin;.;C:\WINDOWS\system32;C:\WINDOWS;C:\Program
> Files\Java\jdk1.5.0
> _08\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program
> Files
> \QuickTime\QTSystem\;C:\Other\Subversion\bin;C:\Other\WinSCP3\;D:\Programs\Apach
> e\maven-1.1-beta-2\bin;D:\Programs\Apache\apache-ant-1.6.5\bin;C:\Program
> Files\
> SSH Communications Security\SSH Secure Shell;C:\Program
> Files\Java\jdk1.5.0_03\b
> in;;D:\Programs\gnupg-w32cli-1.2.2;C:\Other\Subversion\bin;C:\Program
> Files\Java
> \jdk1.5.0_08\bin
> 08-Nov-2006 11:59:56 org.apache.coyote.http11.Http11BaseProtocol init
> INFO: Initializing Coyote HTTP/1.1 on http-8081
> 08-Nov-2006 11:59:56 org.apache.catalina.startup.Catalina load
> INFO: Initialization processed in 750 ms
> 08-Nov-2006 11:59:56 org.apache.catalina.core.StandardService start
> INFO: Starting service Catalina
> 08-Nov-2006 11:59:56 org.apache.catalina.core.StandardEngine start
> INFO: Starting Servlet Engine: Apache Tomcat/5.5.15
> 08-Nov-2006 11:59:56 org.apache.catalina.core.StandardHost start
> INFO: XML validation disabled
> 08-Nov-2006 11:59:57 org.apache.catalina.startup.HostConfig deployWAR
> INFO: Deploying web application archive axis2.war
> 2006-11-08 11:59:58,349 INFO
> org.apache.axis2.deployment.DeploymentEngine - Dep
> loying module : addressing-1.1
> 2006-11-08 11:59:58,365 INFO
> org.apache.axis2.deployment.DeploymentEngine - Dep
> loying module : managerInterceptor
> 2006-11-08 11:59:58,380 INFO
> org.apache.axis2.deployment.DeploymentEngine - Dep
> loying module : soapmonitor-1.1
> 2006-11-08 11:59:58,818 INFO  ncl.qosp.controller.LifecycleSupport -
> Server connector started at service:jmx:rmi:///jndi/rmi://eskdale:10099/qosp
> 
> 
> 
> This is called by the static block of the stateful service since I've
> removed lifecycle management from the services.xml file
> 
> 
> static {
>//.
>new LifecycleSupport().method()
> }
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 2006-11-08 11:59:59,114 INFO
> org.apache.axis2.deployment.DeploymentEngine - Dep
> loying Web service  RoutingService.aar
> 2006-11-08 11:59:59,130 INFO
> org.apache.axis2.deployment.DeploymentEngine - Dep
> loying Web service  version.aar
> 2006-11-08 11:59:59,146 INFO  ncl.qosp.controller.RoutingService - --
> Constructo
> r
> 08-Nov-2006 11:59:59 org.apache.coyote.http11.Http11BaseProtocol start
> INFO: Starting Coyote HTTP/1.1 on http-8081
> 08-Nov-2006 12:00:00 org.apache.jk.common.ChannelSocket init
> INFO: JK: ajp13 listening on /0.0.0.0:8009
> 08-Nov-2006 12:00:00 org.apache.jk.server.JkMain start
> INFO: Jk running ID=0 time=16/46  config=null
> 08-Nov-2006 12:00:00 org.apache.catalina.storeconfig.StoreLoader load
> INFO: Find registry server-registry.xml at classpath resource
> 08-Nov-2006 12:00:00 org.apache.catalina.startup.Catalina start
> INFO: Server startup in 3515 ms
> 2006-11-08 12:00:19,237 INFO  ncl.qosp.controller.RoutingService - --
> Constructor
> 2006-11-08 12:00:29,392 INFO  ncl.qosp.controller.RoutingService - --
> Constructor
> 
> 
> 
> 
> Michele
> 
> -
> 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] application scope problem (several service instance created)

2006-11-08 Thread Michele Mazzucco
Hi all,

I'm very stuck with this problem. The service is configured in
application scope, but several instances are created (I'm running the
latest nightly build).

I though the problem was related with the ServiceLifecycle inteface (see
 jira AXIS2-1604), but I was wrong.

This is my services.xml, while below you can see the tomcat output (3
service instances are created)







ncl.qosp.controller.RoutingService









08-Nov-2006 11:59:56 org.apache.catalina.core.AprLifecycleListener
lifecycleEven
t
INFO: The Apache Tomcat Native library which allows optimal performance
in produ
ction environments was not found on the java.library.path: C:\Program
Files\Java
\jdk1.5.0_08\bin;.;C:\WINDOWS\system32;C:\WINDOWS;C:\Program
Files\Java\jdk1.5.0
_08\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program
Files
\QuickTime\QTSystem\;C:\Other\Subversion\bin;C:\Other\WinSCP3\;D:\Programs\Apach
e\maven-1.1-beta-2\bin;D:\Programs\Apache\apache-ant-1.6.5\bin;C:\Program
Files\
SSH Communications Security\SSH Secure Shell;C:\Program
Files\Java\jdk1.5.0_03\b
in;;D:\Programs\gnupg-w32cli-1.2.2;C:\Other\Subversion\bin;C:\Program
Files\Java
\jdk1.5.0_08\bin
08-Nov-2006 11:59:56 org.apache.coyote.http11.Http11BaseProtocol init
INFO: Initializing Coyote HTTP/1.1 on http-8081
08-Nov-2006 11:59:56 org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 750 ms
08-Nov-2006 11:59:56 org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
08-Nov-2006 11:59:56 org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/5.5.15
08-Nov-2006 11:59:56 org.apache.catalina.core.StandardHost start
INFO: XML validation disabled
08-Nov-2006 11:59:57 org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive axis2.war
2006-11-08 11:59:58,349 INFO
org.apache.axis2.deployment.DeploymentEngine - Dep
loying module : addressing-1.1
2006-11-08 11:59:58,365 INFO
org.apache.axis2.deployment.DeploymentEngine - Dep
loying module : managerInterceptor
2006-11-08 11:59:58,380 INFO
org.apache.axis2.deployment.DeploymentEngine - Dep
loying module : soapmonitor-1.1
2006-11-08 11:59:58,818 INFO  ncl.qosp.controller.LifecycleSupport -
Server connector started at service:jmx:rmi:///jndi/rmi://eskdale:10099/qosp



This is called by the static block of the stateful service since I've
removed lifecycle management from the services.xml file


static {
   //.
   new LifecycleSupport().method()
}









2006-11-08 11:59:59,114 INFO
org.apache.axis2.deployment.DeploymentEngine - Dep
loying Web service  RoutingService.aar
2006-11-08 11:59:59,130 INFO
org.apache.axis2.deployment.DeploymentEngine - Dep
loying Web service  version.aar
2006-11-08 11:59:59,146 INFO  ncl.qosp.controller.RoutingService - --
Constructo
r
08-Nov-2006 11:59:59 org.apache.coyote.http11.Http11BaseProtocol start
INFO: Starting Coyote HTTP/1.1 on http-8081
08-Nov-2006 12:00:00 org.apache.jk.common.ChannelSocket init
INFO: JK: ajp13 listening on /0.0.0.0:8009
08-Nov-2006 12:00:00 org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=16/46  config=null
08-Nov-2006 12:00:00 org.apache.catalina.storeconfig.StoreLoader load
INFO: Find registry server-registry.xml at classpath resource
08-Nov-2006 12:00:00 org.apache.catalina.startup.Catalina start
INFO: Server startup in 3515 ms
2006-11-08 12:00:19,237 INFO  ncl.qosp.controller.RoutingService - --
Constructor
2006-11-08 12:00:29,392 INFO  ncl.qosp.controller.RoutingService - --
Constructor




Michele

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



Re: [axis2] global initialization with 'request scope'

2006-09-29 Thread robert lazarski

You can do this with the latest nightlies and implementing
org.apache.axis2.engine.Service , but there is some changes about to
be made. See this discussion:

http://marc.theaimsgroup.com/?l=axis-dev&m=115892585214583&w=2

Robert

On 9/29/06, Jan Bauer Nielsen <[EMAIL PROTECTED]> wrote:




Hi.

 I would like to keep my service in 'request scope', but I would also like
to be able to do some sort of startup initialization once and for all (for
example to create a JAXBContext object) and to be able to access this in
each service invocation. Is this at all possible using Axis2?

 Kind regards,
 Jan Bauer Nielsen
 Center of Knowledge Technology, Technical Knowledge Center of Denmark
 Anker Engelunds Vej 1, Postboks 777, 2800 Kongens Lyngby, Denmark
 Direct: (+45) 4525 7221, [EMAIL PROTECTED]


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



[axis2] global initialization with 'request scope'

2006-09-29 Thread Jan Bauer Nielsen
Title: [axis2] global initialization with 'request scope'






Hi.

I would like to keep my service in 'request scope', but I would also like to be able to do some sort of startup initialization once and for all (for example to create a JAXBContext object) and to be able to access this in each service invocation. Is this at all possible using Axis2?

Kind regards,
Jan Bauer Nielsen
Center of Knowledge Technology, Technical Knowledge Center of Denmark
Anker Engelunds Vej 1, Postboks 777, 2800 Kongens Lyngby, Denmark
Direct: (+45) 4525 7221, [EMAIL PROTECTED] 





  1   2   >