Use the following procedure to create an SDK client in conjunction with the sample Java code (see Interface ClientAgent):
Create ClientAgent instance:
// example zos server host is "myserver" ClientAgent clientAgent = ClientAgentFactory.newClientAgent("myserver");
Use the following user and password example to log in to the Orchestrate Server (see Walkthrough: Logging In to the PlateSpin Orchestrate Server
in the PlateSpin Orchestrate 2.5 Installation and Configuration Guide):
Credential credential = CredentialFactory.newPasswordCredential(username,password); clientAgent.login(credential);
Run the server operations. In this case, it is the quickie.jdl example job (which must have been previously deployed) with no job arguments:
String jobID = clientAgent.runJob("quickie",null)
(Optional) Listen for server events using the AgentListener interface:
clientAgent.addAgentListener(this);
Register with the PlateSpin Orchestrate Server to receive job events for the job you started.
clientAgent.getMessages(jobID);
Log out of the server:
clientAgent.logout()