Tuesday Jul 30, 2013

Using Tuxedo application service version with Oracle SALT

To expand on this previous entry, here are some more details on how to use application service version with Web Services through the Oracle SALT gateway.

Using Tuxedo application service version in conjunction with Tuxedo services exposed as web services

  • The GWWS gateway gets REQUEST_VERSION and VERSION_RANGE from UBBCONFIG,
  • calls to actual Tuxedo service are made with REQUEST_VERSION inherited from configuration,
  • if different settings are needed, such as specific traffic from specific gateway to be routed to specific services, another gateway instance can be configured in a group with different REQUEST_VERSION value and started 

Example (UBBCONFIG excerpt): 


... 

*GROUPS 

GROUP1 

        LMID=L1 GRPNO=2 VERSION_RANGE="1-2" 

GROUP2 

        LMID=L1 GRPNO=2 VERSION_RANGE="3-4" 

GWWS_GRPV1 

        LMID=L1 GRPNO=3 REQUEST_VERSION=1 

GWWS_GRPV2 

        LMID=L1 GRPNO=3 REQUEST_VERSION=2

... 

*SERVERS 

mySERVER SRVGRP=GROUP2 SRVID=30 

... 

GWWS SRVGRP=GWWS_GRPV1 SRVID=30 CLOPT="-A -- -i GW1"

GWWS  SRVGRP=GWWS_GRPV2 SRVID=30 CLOPT="-A -- -i GW2"

...

 


In the example above GWWS in group GWWS_GRPV1 inherits request version "1" from its UBBCONFIG settings, and therefore exposes services that are advertised by Tuxedo application servers which include "1" in their VERSION_RANGE settings, such as GROUP1 here. If a service exposed by GWWS is actually performed by a server in GROUP2 the result will be a TPENOENT error forwarded to the remote Web Services client.

Using this mechanism, it is possible to map different endpoints to services with different versions. Since versions are per-group, this is done by placing GWWS servers in their own group, and either use proxy mapping in front of GWWS (via Apache server or other), or by directly accessing the endpoints of the Web Services. For example, these settings would be added to the UBBCONFIG above:

SALTDEP:


...

    <GWInstance id="GW1">

       <Inbound>

           <Endpoint use="http_port_v1"/>

        <Inbound>

    </GWInstance> 

    <GWInstance id="GW2">

        <Inbound>

            <Endpoint use="http_port_v2"/>

        <Inbound>

    </GWInstance> 

... 


Service WSDF: 


<wsdf:Definition>

    <wsdf:WSBinding id="svc_binding">

        <wsdf:Servicegroup id="svc_PortType">

            <wsdf:Service name="STOCK_QUOTE"/>

        </wsdf:Servicegroup>

        <wsdf:SOAP>

            <wsdf:AccessingPoints>

                <wsdf:Endpoint address="http://my.server:3331/quote" id="http_port_v1"/>

                <wsdf:Endpoint address="http://my.server:3332/quote" id="http_port_v2"/>

            </wsdf:AccessingPoints>

...


Using Tuxedo application service version in conjunction with External web services imported into Tuxedo using SALT

  • Since 1 GWWS instance cannot advertise more than 1 service with same name, that same service would have to be in different instance,
  • for that reason, the existing mechanism can simply be used: configure multiple GWWS instances with VERSION_RANGE in its *GROUP settings accordingly.

Example (UBBCONFIG excerpt): 


... 

*GROUPS 

GROUP2 

        LMID=L1 GRPNO=2 VERSION_RANGE="1-2" 

GROUP3 

        LMID=L1 GRPNO=3 REQUEST_VERSION=1 VERSION_RANGE="3-4" 

... 

*SERVERS 

GWWS SRVGRP=GROUP2 SRVID=30 

... 

GWWS SRVGRP=GROUP3 SRVID=30 

... 


In the above example, Tuxedo programs (client or server) call an external Web Service exposed by both GWWS in groups GROUP2 and GROUP3. Programs using version 1 or 2 will be routed to the service exposed by GWWS in GROUP2 which may connect to endpoint 1, and programs using version 3 or 4 will be routed to the service exposed by GWWS in GROUP3 which may connect to a different endpoint than GWWS in GROUP2. 

Stay Connected

Follow Tuxedo on:
LinkedIn
YouTube
Tuxedo Blog

Follow Cloud Application Foundation (CAF):

Twitter

  Blog

About

This is the Tuxedo product team blog.

Search

Categories
Archives
« July 2013 »
SunMonTueWedThuFriSat
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
31
   
       
Today