StreamServe
Job Gateway
User Guide
StreamServe Job Gateway User Guide 4.1.2 SP2 Rev A
© 2007 StreamServe, Inc.
StreamServe is a trademark of StreamServe, Inc.
No part of this document may be reproduced or transmitted in any form or by any means, electronic or mechanical, for any purpose, without the express written permission of StreamServe, Inc. Information in this document is subject to change without notice. StreamServe Inc. assumes no responsibility or liability for any errors or inaccuracies that may appear in this book. All registered names, product names and trademarks of other companies mentioned in this documentation are used for identification purposes only and are acknowledged as property of the respective company. Companies, names and data used in examples in this document are fictitious unless otherwise noted.
StreamServe, Inc. offers no guarantees and assumes no responsibility or liability of any type with respect to third party products and services, including any liability resulting from incompatibility between the third party products and services and the products and services offered by StreamServe, Inc. By using StreamServe and the third party products mentioned in this document, you agree that you will not hold StreamServe, Inc. responsible or liable with respect to the third party products and services or seek to do so.
The trademarks, logos, and service marks in this document are the property of StreamServe, Inc. or other third parties. You are not permitted to use the marks without the prior written consent of StreamServe, Inc. or the third party that owns the marks.
Use of the StreamServe product with third party products not mentioned in this document is entirely at your own risk, also as regards the StreamServe products.
StreamServe Web Site
1
StreamServe Job Gateway User Guide 4.1.2 SP2 Rev A
Contents
Introducing the Job Gateway ...3
Configuring the Communication Server and repositories...5
Enabling access to the queue repository...6
Creating job identifiers...7
Specifying Job ID repositories ...8
Configuring and running the Job Gateway ...11
Administering repository connection properties...12
Running the Job Gateway...14
Job Gateway examples ...17
Configuring a Communication Server and a Job Gateway...17
Configure the input and output queues ... 18
Configure the interface to the Job Gateway... 18
Specify where to store the job identifiers ... 18
Configure queue repository connection properties ... 19
Configure Job ID repository connection properties ... 20
Adding a new Communication Server to the Job Gateway ...21
3
Introducing the Job GatewayStreamServe Job Gateway User Guide 4.1.2 SP2 Rev A
Introducing the Job Gateway
The Job Gateway is a web site with job information from one or more
Communication Servers. In the Job Gateway you can search for specific jobs, view the contents of a job, resend a job from a queue, and delete a job from a queue.
The search criteria (job identifiers) and the actual jobs are stored in separate repositories. When you configure the Communication Server you specify in which repositories to store the information, and when you configure the Job Gateway you must make sure to access the same repositories.
4
5
Configuring the Communication Server and repositoriesStreamServe Job Gateway User Guide 4.1.2 SP2 Rev A
Configuring the Communication
Server and repositories
Queue
configuration The Job Gateway can only access queued jobs. When you configure a queue you must set the job storage option to Store information and job if you want to be
able to resend jobs. This applies to both successful jobs and failed jobs. See the Design Center documentation for information about how to configure queues.
Job Gateway
interface You must specify whether or not to allow clients to access the information in the queue repositories. To enable access to this information you must also specify
which port, protocol, and password to use.
See Enabling access to the queue repository on page 6.
Job ID repositories
You must create the job identifiers that will be used as search criteria in the Job Gateway. You must also specify where to store the job identifiers.
See Creating job identifiers on page 7 and Specifying Job ID repositories on page 8.
6
Enabling access to the queue repositoryConfiguring the Communication Server and repositories
Enabling access to the queue repository
1 Right-click the Platform window and select Configure Platform. The Configure Platform dialog box opens.
2 Select the Gateway tab and edit the settings.
Gateway settings Allow remote client to connect to gateway
Allow clients to access the queue repositories.
Protocol HTTP or HTTPS.
TCP/IP Port Port on the Communication Server host assigned to the Job Gateway. The same port must be defined as port in
the queue repository connection properties for the Job Gateway (see Queue repository connection properties
on page 12.)
This port must be unique for each Communication Server running on the same host.
Password Password to access the queue repositories.
The same password must be defined as GwPassword in
the queue repository connection properties for the Job Gateway (see Queue repository connection properties
on page 12.)
Gateway URL URL to use to access the Job Gateway. Use the following syntax:
http://job_gateway_host:tomcat_port/ jobgateway/Access
For example:
http://198.232.9.23:8080/jobgateway/Access
Note:Keep jobgateway/Access in the URL exactly
Creating job identifiers
7
Configuring the Communication Server and repositories
StreamServe Job Gateway User Guide 4.1.2 SP2 Rev A
Creating job identifiers
To create job identifiers via Event tools
Each field in the Event tool has a Job ID switch that you can turn on or off. See the corresponding Event tool documentation for information.
To create job identifiers using scripts
You can use the following scripting functions in After Process scripts to create job identifiers: • GetJobIDAttribute • GetJobIDDateAttribute • GetJobIDJob • GetJobIDNumAttribute • StoreJobIDAttribute • StoreJobIDDateAttribute • StoreJobIDNumAttribute • ReplaceJobIDAttribute • ReplaceJobIDDateAttribute • ReplaceJobIDNumAttribute
See the Scripting reference for information.
Example 1 After Process script $currDate = getdate();
8
Specifying Job ID repositoriesConfiguring the Communication Server and repositories
Specifying Job ID repositories
Job identifiers can be stored in one or more repositories.
To specify the default Job ID repository
1 Right-click the Platform window and select Configure Platform. The Configure Platform dialog box opens.
2 On the Job ID tab, edit the settings.
To specify multiple repositories
If you use scripts to specify job identifiers, you can define multiple repositories.
1 Right-click the Platform window and select Configure Platform. The Configure Platform dialog box opens.
Settings Use Job ID
repository Enable the Job ID repository.
Alias/Path An alias or path that points to the location of the repository. The repository is created the first time you run the Project.
Path
An absolute path, or a path relative to
<installation_directory>/Server.
%(PlatformName)
The suggested path is %(PlatformName)/
<repository>. The string %(PlatformName) will be
replaced with the name of the Platform. For example:
C:/Strs41/Server/PLT22/jobid
Alias
You can use the Repository Tool to create aliases for repositories.
Server The repository server host. For example, localhost, 134.132.137.145, wkbg01, etc.
Authentication
required Select if the repository server requires authentication. User name User name to access the repository.
Specifying Job ID repositories
9
Configuring the Communication Server and repositories
StreamServe Job Gateway User Guide 4.1.2 SP2 Rev A 2 On the Custom tab, specify one or more repositories according to the
following syntax:
Example 2 Custom repository
//Job Identification repository JobIdRepository "jobid2"
Repository "whtrs09" "data/jobid/jobid2" "" "" END END
JobIdRepository "repositoryID"
Repository "server" "alias/path" "username" "password" END END
10
Specifying Job ID repositories11
Configuring and running the Job GatewayStreamServe Job Gateway User Guide 4.1.2 SP2 Rev A
Configuring and running the Job
Gateway
The Job Gateway has one queue repository connection configuration and one Job ID repository connection configuration by default. You can modify the properties for these existing configurations, and also add new connection configurations to the Job Gateway. See Administering repository connection properties on page 12.
Web server port settings
When you install the Job Gateway, you install an Apache and Tomcat web server. By default, Apache will be assigned port 80, and Tomcat will be assigned port 8080. You must change these settings if you want to use the same ports for any other purpose.
12
Administering repository connection propertiesConfiguring and running the Job Gateway
Administering repository connection
properties
You can administer the repository connection properties via the following URL:
http://job_gateway_host:tomcat_port/jobgateway/Admin
Via this interface you can edit the properties for existing repository connection configurations, add new configurations (copy and edit), and delete
configurations.
Queue repository connection properties
The Job Gateway accesses a queue repository via the corresponding
Communication Server. This means the you must create one queue repository connection configuration per Communication Server.
Job ID repository connection properties
The Job Gateway accesses a Job ID repository directly, and not via a specific Communication Server. This means the Job Gateway can have one Job ID repository connection configuration for multiple Communication Servers.
Queue repository connection properties
GwPassword Password to access job information.
Must be the same as Password specified for the Communication Server. See Enabling access to the queue repository on page 6.
Host The Communication Server host.
Port Port on the Communication Server host. The Job Gateway will access job information via this port. Must be the same as TCP/IP Port specified for the Communication Server. See Enabling access to the queue repository on page 6.
GwName The Communication Server’s name displayed in the Job Gateway.
GwUserName Username to access job information. Always use admin.
Job ID repository connection properties
Host The Job ID repository server host. Corresponds to the
Server specified for the Job ID repository. See
Specifying Job ID repositories on page 8.
Administering repository connection properties
13
Configuring and running the Job Gateway
StreamServe Job Gateway User Guide 4.1.2 SP2 Rev A
RootSuffix Path to the Job ID repository. Corresponds to the Alias/ Path specified for the Job ID repository. See Specifying Job ID repositories on page 8.
14
Running the Job GatewayConfiguring and running the Job Gateway
Running the Job Gateway
To log on via StreamServe Web Center
1 From Windows Start menu, select Programs > StreamServe > Web Center. The StreamServe Web Center Portal opens.
2 Select Job Gateway. The Job Gateway web site opens.
3 Log on to the Job Gateway website.
4 Select a gateway. Each gateway corresponds to a specific Communication Server.
5 Log on to the selected gateway. Use the username and password specified in the queue repository connection configuration.
To log on via a web browser
1 Enter the Job Gateway URL. The Job Gateway web site opens.
2 Log on to the Job Gateway website.
3 Select a gateway. Each gateway corresponds to a specific Communication Server.
4 Log on to the selected gateway. Use the username and password specified in the queue repository connection configuration.
Job Gateway parameter reference
The following parameters are presented in the Job Gateway:
Name Name of the job. Usually set by the input connector that received the job, but can also be set via scripting functions, custom java and COM connectors. The name is currently only updated before the job is created.
Scripting function
setjobdescr()
Java connector class
setJobName()
COM connector
Running the Job Gateway
15
Configuring and running the Job Gateway
StreamServe Job Gateway User Guide 4.1.2 SP2 Rev A
State State of the job.
Pending
The job will soon be processed or delivered.
Pending Held
The job is temporarily held, but will soon be processed or delivered.
Processing
The job is being processed.
Processing Stopped
The processing has stopped.
Cancelled
The job was cancelled by an administrator.
Aborted
The job had errors. It is aborted until an administrator either resends or removes the job.
Completed
The job is completed.
Priority Only applicable to jobs in Pending state.
A number (0 - 255), where 255 is the highest priority. Jobs with high priority will be processed before jobs with low priority. Can be set via custom java and COM input connectors.
Note:Jobs received via StdIn input connectors will have priority 255. The Communication Server will not stop until all “Priority 255 jobs” have been processed.
Java connector class
setJobPriority()
COM connector
SetJobPriority()
Created The time the job was created.
Send Time The time, at the earliest, the job will be sent from the queue. If empty, the job will not be sent.
Job Type Type of job, In or Out. Out jobs will be processed by the kernel, In jobs will only be delivered via output
16
Running the Job GatewayConfiguring and running the Job Gateway
ID The queue item ID. The first job that enters the queue gets ID=1, the second gets ID=2, and so on.
Strs ID Internal job id that corresponds to a specific External ID. The GetIntJobId() scripting function can fetch Strs ID
during job processing.
External ID ID set by the external application that created job. Each unique External IDs has a corresponding Strs ID.
External ID is normally set at input connector level, but
can also be set via scripting functions, custom java and COM connectors. External ID is currently only updated before the job is created.
Scripting function
SetExtJobId()
Java connector class
setExtJobId()
COM connector
SetExternalJobId()
Original ID The ID of the job that created this job.
Original Strs ID The Strs ID of the job that created this job.
Error A textual description of an error that occurred when the job was processed.
User The name of the user that created this job. Might be set by the corresponding connector (depending on the type of connector). Can also be set via scripting functions, custom java and COM connectors.
Scripting function
setjobowner()
Java connector class
setJobOwner()
COM connector
SetJobOwner()
Accessed The number of times the job has been processed.
Connector Name given to the connector at design time.
Configuring a Communication Server and a Job Gateway
17
Job Gateway examples
StreamServe Job Gateway User Guide 4.1.2 SP2 Rev A
Job Gateway examples
Configuring a Communication Server and a
Job Gateway
In this example there is one Communication Server that uses two Repository queues for the input and output jobs. In the Job Gateway it should be possible to resend both successful and failed jobs from the queues, and to search for specific jobs.
The Communication Server and the Job ID repository server runs on the host
CS_HOST_01, and the Job Gateway runs on the host JG_HOST_01. The display
name of the Communication Server is Estragon CS, and the display name of the
Job ID repository is Estragon DB. Clients will access the Job Gateway via port
8080.
Communication Server configuration
• Configure the queues
Configure the queues to store both successful and failed jobs. See Configure the input and output queues on page 18.
• Configure the Job Gateway interface
Enable access to the job data via the Communication Server. See Configure the interface to the Job Gateway on page 18.
• Specify the Job ID repository
Specify where the Communication Server should store the job identifiers. See Specify where to store the job identifiers on page 18.
Job Gateway configuration
• Configure queue repository connection properties
Set up the connection to the Communication Server and the corresponding queue repositories. See Configure queue repository connection properties on page 19.
• Configure Job ID repository connection properties
Set up the connection to the Job ID repository. See Configure Job ID repository connection properties on page 20.
18
Configuring a Communication Server and a Job GatewayJob Gateway examples
Configure the input and output queues
1 Right-click the Platform window and select Manage Queues. The Manage Queues dialog box opens.
2 Select the queue.
3 Select the Queuing tab.
4 From the Store successful jobs drop-down list, select Store information and job.
5 From the Store failed jobs drop-down list, select Store information and job.
6 Click OK.
Configure the interface to the Job Gateway
You must use the same TCP/IP Port and Password that you specify here when you edit the queue repository connection properties for the Job Gateway. See
Configure queue repository connection properties on page 19.
1 Right-click the Platform window and select Configure Platform. The Configure Platform dialog box opens.
2 Select the Gateway tab.
3 Select Allow remote client to connect to gateway.
4 Set TCP/IP Port to 8334 (corresponds to port in the queue repository
connection properties).
5 Set Password to qwerty (corresponds to GwPassword in the queue
repository connection properties).
6 Set Gateway URL to http://JG_HOST_01:8080/jobgateway/Access. 7 Click OK.
Specify where to store the job identifiers
You must use the same Path and Server that you specify here when you edit the Job ID repository connection properties for the Job Gateway. See Configure Job ID repository connection properties on page 20.
1 Right-click the Platform window and select Configure Platform. The Configure Platform dialog box opens.
2 Select the Job ID tab.
3 Set Alias/Path to data/jobid/default. 4 Set Server to CS_HOST_01.
Configuring a Communication Server and a Job Gateway
19
Job Gateway examples
StreamServe Job Gateway User Guide 4.1.2 SP2 Rev A
Configure queue repository connection properties
Edit the queue repository connection properties via the following URL:
http://JG_HOST_01:8080/jobgateway/Admin
Comments
Port must be the same as TCP/IP Port, and GwPassword must be the same as
Password, specified for the Communication Server. See Configure the interface to the Job Gateway on page 18.
Queue repository connection properties
Host CS_HOST_01
Port 8334
GwName Estragon CS
20
Configuring a Communication Server and a Job GatewayJob Gateway examples
Configure Job ID repository connection properties
Edit the Job ID repository connection properties via the following URL:
http://JG_HOST_01:8080/jobgateway/Admin
Job ID repository connection properties
Host CS_HOST_01
DBAliasName Estragon ID
Adding a new Communication Server to the Job Gateway
21
Job Gateway examples
StreamServe Job Gateway User Guide 4.1.2 SP2 Rev A
Adding a new Communication Server to the
Job Gateway
In this example we will add a Communication Server to the Job Gateway that we configured in the previous example. The new Communication Server runs on the same host as the Communication Server in the previous example, and must therefore have a different TCP/IP Port. The new Communication Server will also have a new Password and a new display name in the Job Gateway.
Communication Server configuration
The configuration is similar to the Communication Server in the previous example. Only the following parameters are different:
• TCP/IP Port. This Communication Server uses 8335.
• Password. This Communication Server uses asdfg. Job Gateway configuration
Create a queue repository connection configuration for the new Communication Server. See Create a new queue repository connection configuration on page 21
Create a new queue repository connection
configuration
Add a new (copy and edit) queue repository connection configuration via the following URL:
http://JG_HOST_01:8080/jobgateway/Admin
Queue repository connection properties
Host CS_HOST_01
Port 8335
GwName Garlic CS