Skip to content

Latest commit

 

History

History
116 lines (77 loc) · 3.07 KB

README.md

File metadata and controls

116 lines (77 loc) · 3.07 KB

wstrack/Client

Client application for setting workstation statuse to the Workstation Tracking server application.

Development Prerequisites

  • Java 8
  • Apache Maven 3.8.1 or later

Java Versions

Java 8 is used for compilation, because Java 7 is no longer capable of downloading the Maven dependencies from the canonical on-line repositories (it lacks the necessary TLS protocols).

The compiliation process is configured (in the "pom.xml" file) to generate Java 7 bytecode, and so should be compatible with Java 7 or later runtimes.

Build Instructions

To build the client (from the "client/" subdirectory):

$ mvn clean install

This will create a .jar file in

./target/wstrack-client-{VERSION}-jar-with-dependencies.jar

where {VERSION} is the current version (from the pom.xml file).

Deploying to the Nexus

To deploy the client package used by the workstations to Nexus (from the "client/" subdirectory):

$ mvn clean install
$ mvn deploy

The deployment to the Nexus will include a "dist" Zip file, containing the scripts and jar file needed on the workstation. The URL for the Zip file will have the format:

https://maven.lib.umd.edu/nexus/repository/releases/edu/umd/lib/wstrack/client/wstrack-client/<VERSION>/wstrack-client-<VERSION>-dist.zip

where <VERSION> is the version of the distribution.

Note: Snapshot distributions will has an additional timestamp as part of the Zip filename. Access the Nexus to determine the Zip file name, if needed.

Usage Instructions (for Development)

  1. Build the client application:

    $ mvn clean install
  2. Switch into the "script" directory:

    $ cd script
  3. Replace the "wstrack-client.jar" symbolic link with a link to the jar file generated by Maven:

    $ rm wstrack-client.jar
    $ ln -s ../target/wstrack-client-{VERSION}-jar-with-dependencies.jar wstrack-client.jar

where {VERSION} is the current version (from the pom.xml file).

  1. To trigger an update to the local "wstrack" server application:

    $ ./wstrack-client.sh login local true

script/wstrack-client.sh Script

The "script/wstrack-client.sh" is used in local develoment to trigger an update on the "wstrack" server application.

The script takes three arguments:

$ wstrack-client <status> [environment] [debug]

The "status" argument is required, indicates whether the workstation status is either of the following values:

  • login
  • logout

The "environment" argument is optional, and indicates the server to contact, with the default value being "local", to contact a "wstrack" server running on the current host. The list of allowed values at:

The "debug" argument is optional, and supports two values:

  • true - prints diagnostic information
  • false - does not print diagnostic information