|
 |
|
| |
 |
|
|
|
|
SGI
- Web-server and more. |
SGI (Stratus Gateway Interface) is designed to provide TCP/IP
connectivity to Stratus VOS platform. |
It
can be used as a web-server conforming to the HTTP/1.0 specifications
or as a gateway to a wide range of VOS applications, such
as online e-commerce, order processing, database access or
any other client/server applications. |
If
used as a web-server it supports all well-known web browsers
and can work with them to transfer text/html or gif/jpeg graphic
files. SGI also supports gateway script (CGI). |
Apart
from using web-browsers as clients for SGI,
any other application can be used to access VOS platform.
The protocol used to communicate with SGI is a simplified
HTTP/1.0 protocol. See specs below. |
|
Here
is a summary list of the features that are supported by SGI
version 1.0: |
|
|
|
Below
are the basic protocol specs for SGI depending on the requester
type. |
|
|
|
| .................................................................................................................................................... |
.
| |
Examples: |
| 1. |
A custom application
sends a request to run a macro my_macro.cm
on Stratus and get the output of the macro. The request
message should look like this: |
| |
POST
/my_macro.cm<new_line><new_line> |
| |
If you want, for example,
to pass a parameter "-my_parm" to the macro, the
message would be: |
| |
POST /my_macro.cm<new_line>
Content-Length: 8<new_line> <new_line>
-my_parm |
| |
The
reply will look like: |
| |
dbqg_command=start
Output of the macro here.
.
.
/dbqg_command=end |
| |
|
| 2. |
A custom application sends
a message "1234567890abcd" to
a VOS application my_app and is expecting
a reply message. |
| |
|
| |
| / =identifier |
SGI |
| =app_name |
my_app |
| =queue |
%module#m1_d02>my_app>server_queue |
| =timeout |
4000 |
|
| |
Request message layout: |
| |
POST /queue/my_app<new_line>
Content-Length: 14<new_line> <new_line>
1234567890abcd |
| |
Reply layout example: |
| |
Content-Length: 10<new_line>
<new_line>
1234567890 |
| |
In order for SGI to process
this requests there should be a corresponding record in
the sgi_parms.table configuration file |
| |
| / =identifier |
SGI |
| =app_name |
my_app |
| =queue |
%module#m1_d02>my_app>server_queue |
| =timeout |
4000 |
|
| |
Since in this example <b>retr_file</b>
is not set - SGI returns the application reply message.
If retr_file is set to 1 - SGI will expect the application
to create a results file and will return it in file reply
format. |
| |
|
| |
Examples: |
| |
|
| |
| / =identifier |
SGI |
| =app_name |
my_other_app |
| =retr_file |
1 |
| =results_dir |
%module#m1_d02>my_other_app>tmp |
| =results_prefix |
tmp_out |
| =delete_res |
0 |
| =queue |
%module#m1_d02>my_other_app>server_queue |
| =timeout |
4000 |
|
| |
In this case SGI will expect
the application to create a results file named "tmp_out_X" |
| |
|
| |
Where X is a unique number
set by SGI. The file should be created in the "results_dir"
directory. The name of the file will be passed to the
application in the first 35 characters of the input buffer. |
|
|
|
|
| Copyright
(c) 2007 Application Resources, Inc.
|
| |