" /> Retrieve GIS Session ID - Genesys CTI User Forum

Author Topic: Retrieve GIS Session ID  (Read 4461 times)

Antevirus

  • Guest
Retrieve GIS Session ID
« on: November 29, 2007, 02:38:23 PM »
Advertisement
Hello.

I am looking for a way to restore a GIS Session after a client crash.

I am using this function to create a service factory and establish a GIS session:
[color=blue]ServiceFactory.createServiceFactory(string serviceFactory, HashTable context)[/color]

Example contexts:
[color=blue]gis.username
gis.password
gis.tenant[/color]
etc

When I read through the API documentation i found another interested context, [color=blue]gis.sessinId[/color].
With this you can connect direcly to a session instead of using the contexts above.

So... My question...

Is there a way to retrieve the GIS Session ID for:
(1) a service factory created with [color=blue]ServiceFactory.createServiceFactory(...).[/color]
(2) a configuration service created with the class [color=blue]CFGService(url, port).[/color]

References: AilLibrary.dll and CFGService.dll

Best regards,
Andreas




Antevirus

  • Guest
Re: Retrieve GIS Session ID
« Reply #1 on: January 10, 2008, 03:04:10 PM »
  • Best Answer
  • Well...

    It seems i've found the solution for a part of the problem on my own. This forum popped into my mind and i thought i'd post the partial-solution here. As some of you already know, a session is created for each ServiceFactory and for each Config Server license.

    This is how you get the GID Session ID from a ServiceFactory instance.

    First you cast the ServiceFactory instance to a WebServicesFactory:
    [color=blue]WebServicesFactory factory = serviceFactory.ServiceFactoryImpl as WebServicesFactory;
    factory.GisSessionId[/color] now contains the GIS Session ID.

    You reconnect to this session by passing [color=blue]gis.sessionId[/color] in the [color=blue]context[/color].
    When doing this you must exclude [color=blue]gis.username[/color], [color=blue]gis.password[/color] and [color=blue]gis.tenant[/color] from the context.

    And thats it.

    //Antevirus