Re: WebServer: WRB vs CGI

From: Eric Byrnes <LNUSMCD.NZJDDV_at_eds.com>
Date: 1996/10/25
Message-ID: <32716BE0.1562_at_eds.com>#1/1


Steve_Kilbane_at_cegelecproj.co.uk wrote:
>
> I've been having a look at the WRB config form, trying to suss out
> what makes a URL get handled by a cartridge, rather than as a
> plain CGI program. And I'm thinking specifically of the PL/SQL
> Agent here...

I've been fiddling with this myself. All the cartridge selection is done based on the URL path. This is set up in the WRB virtual directory area.
Say you've set up a DCD called devtest with user orauser/orapwd in database instance dev, in which you have a stored PL/SQL procedure (called myproc) that you want to run. You need to set up a virtual path to it in the Web Request Broker configuration page under the section "Applications and Directories". The entry has the form:

VIRTUAL PATH       APP     PHYSICAL PATH
/<dcd_name>/owa    OWA     $ORACLE_HOME/ows2/bin

so you would enter (assuming $ORACLE_HOME is /user/oracle):

/devtest/owa OWA /user/oracle/ows2/bin

From the URL, the procedure would be called as:

http://myhost/devtest/owa/myproc

No MIME type changes, extensions or other stuff is required. The WRB sees a virtual path in the URL that maps to the OWA cartridge, and redirects the request accordingly. The cartridge assumes that the last part of the path is the function, the middle part is the executable (which should always be owa for PL/SQL stuff), and the part before that is the DCD name. If the function is not in this DCD, it will attempt the default DCD next, then the cartridge will fail. The WRB will then attempt to find a real path with this name (i.e. as subdirectories on disk, before it fails).
The Web Server install creates a DCD called owa_dba which is properly set up in the default settings, if you need a reference model.

Hope that helps...

PS - Would you happen to know if Oracle has fixed the bug (after Webserver 2.0) which prevents it from parsing the two-line header of a CGI program? This is driving me crazy!

Eric Received on Fri Oct 25 1996 - 00:00:00 CEST

Original text of this message