Getting Started with WDK
The Workflow Developer Kit (WDK) accelerates building of workflows using a low-code environment with an optional graphical interface
WDK offers a number of deployment options depending on your organization requirements and preferences:
The easiest way to get started is by using the WDK Docker image. This will require Docker Desktop to be installed but no other tooling is necessary.
If you wish to run WDK Studio, the graphical interface for WDK, then the WDK Studio Docker image is the only deployment option supported.
You can also download the latest JAR from the Releases page on the WDK repository. This will require a local Java runtime (11+) to be installed for launching the JAR, but no compilation is necessary.
The last option involves a complete project where gradle is used to obtain the JAR and also to build custom activities. This approach is only for advanced use where WDK needs to be extended with custom behaviour.
$ npm i -g yo @finos/generator-symphony
$ mkdir wdk-bot && cd $_
$ yo @finos/symphony
This will prompt you with a number of questions about your bot and pod configuration. Type in your bot's information, using arrow keys to scroll and press enter to move on to the next prompt.
Docker
JAR
Project
__ __ ___ _
\ \ / /__ / __|_ _ _ __ _ __| |_ ___ _ _ _ _
\ V / _ \ \__ \ || | ' \| '_ \ ' \/ _ \ ' \ || |
|_|\___/ |___/\_, |_|_|_| .__/_||_\___/_||_\_, |
|__/ |_| |__/
https://developers.symphony.com
Welcome to Symphony Generator v2.7.1
Application files will be generated in folder: /home/user/code/wdk-bot
______________________________________________________________________________________________________
? Enter your pod host mycompany.symphony.com
? Enter your bot username wdk-bot
? Select your type of application Workflow Application (WDK) Docker
Generating RSA keys...
create symphony/publickey.pem
create symphony/privatekey.pem
create symphony/application.yaml
create startup.sh
No change to package.json was detected. No package manager install will be executed.
You can now update the service account wdk-bot with the following public key on https://mycompany.symphony.com/admin-console :
-----BEGIN RSA PUBLIC KEY-----
MIICCgKCAgEA7wBwCGQm30vU7krseefqhwRkENQFk6dtL12pmxZ91d+IIBwVioUj
...
LqPq1P4cmTqyKeVphuQ3B2vPpEJoqr1XTykg2B/k67+nat+gEGFZVbkCAwEAAQ==
-----END RSA PUBLIC KEY-----
Your workflow bot has been successfully generated !
- 1.Use Docker instructions
- 2.
__ __ ___ _
\ \ / /__ / __|_ _ _ __ _ __| |_ ___ _ _ _ _
\ V / _ \ \__ \ || | ' \| '_ \ ' \/ _ \ ' \ || |
|_|\___/ |___/\_, |_|_|_| .__/_||_\___/_||_\_, |
|__/ |_| |__/
https://developers.symphony.com
Welcome to Symphony Generator v2.7.1
Application files will be generated in folder: /home/user/code/wdk-bot
______________________________________________________________________________________________________
? Enter your pod host mycompany.symphony.com
? Enter your bot username wdk-bot
? Select your type of application Workflow Application (WDK)
Generating RSA keys...
create rsa/publickey.pem
create rsa/privatekey.pem
create gradle/wrapper/gradle-wrapper.jar
create gradle/wrapper/gradle-wrapper.properties
create lib/Readme.txt
create src/main/java/org/acme/workflow/MyActivity.java
create src/main/java/org/acme/workflow/MyActivityExecutor.java
create gradlew
create gradlew.bat
create README.md
create workflows/Readme.txt
create workflows/ping.swadl.yaml
create build.gradle
create application.yaml
Running ./gradlew botJar in your project
> Task :botJar
BUILD SUCCESSFUL in 992ms
1 actionable task: 1 executed
You can now update the service account wdk-bot with the following public key:
-----BEGIN RSA PUBLIC KEY-----
MIICCgKCAgEA2bwlI1o0RI4Kl4hEicZlQcaxWOqTCc/K7+YGVYl8x/HA2wrqYuAI
..
SDiOiG6q7NK1h7e3/sMrh4U/sf5SO9CFzYHcQP3M38XPfn8UMn0ovi0CAwEAAQ==
-----END RSA PUBLIC KEY-----
Please submit these details to your pod administrator.
If you are a pod administrator, visit https://mycompany.symphony.com/admin-console
Your workflow bot has been successfully generated !
The WDK is built on top of the BDK for Java Spring Starter, so the BDK configuration options will all still apply to WDK instances.
There is also WDK-specific configuration:
wdk:
workflows.path: .
encrypt.passphrase: my-secret-passphrase
properties:
monitoring-token: my-monitoring-token
management-token: my-management-token
studio:
github-token: my-github-token
admins: 123456789,234567890
spring:
datasource:
camunda.jdbc-url: jdbc:h2:file:./data/camunda;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE
wdk.jdbc-url: jdbc:h2:file:./data/wdk;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE
WDK Property | Description |
---|---|
workflows.path | Path to directory where SWADL files are stored |
encrypt.passphrase | Passphrase used to encrypt secrets |
properties.monitoring-token | Token used to make calls to the Monitoring APIs |
properties.management-token | Token used to make calls to the Management APIs |
studio.github-token | |
studio.admins | Comma-separated list of user IDs who will have administrative permissions in WDK Studio |
Spring Property | Description |
---|---|
datasource.camunda.jdbc-url | Connection string for workflow engine database |
datasource.wdk.jdbc-url | Connection string for metadata database |
For any bot to work, it requires a service account with a matching username and public key. The Symphony Generator creates a configuration file based on the answers supplied, including the bot username and the path to the generated key pair. These can be changed by modifying the
config.yaml
file. If you do not already have a service account set up, follow the instructions on this page to continue.Create a sample workflow in
./workflows/ping.swadl.yaml
id: ping
activities:
- send-message:
id: pong
on:
message-received:
content: /ping
content: Pong
Launch the WDK bot using the respective command and wait for startup to complete
Docker
JAR
Project
$ ./startup.sh
$ java -jar workflow-bot-app-1.6.3.jar # Update to acquired version
$ ./gradlew botJar
$ java -jar workflow-bot-app.jar
Launch Symphony, send a
/ping
message to the bot and ensure it replies with Pong
.Now that you have a basic workflow project ready, you can proceed to find out more about building workflows using the WDK:
Last modified 2mo ago