Getting workflows up and running faster with a JSON file

Allie Hajian
  • Updated

Avoid manually typing in workflow inputs and outputs - and get your WDL up and running in record time - by using a JSON file for setup. JSONs help with reproducibility and are especially useful when you want to quickly test that a WDL workflow can run successfully on Terra without setting up a workspace data table from scratch. 

What's a JSON?

A JSON is a text-based, human-readable file that stores simple data structures and objects in JavaScript Object Notation (JSON) format. In Terra, the open standard JSON format transmits the WDL configuration to the VM server that runs the WDL. JSON files can be edited using a text editor.

Uploading a JSON file to set up the workflow inputs

You can find the link to upload or download a JSON on the setup form that appears when you click a workflow card. 
Configure_with_JSON_Screen_Shot.png

JSON is the format most commonly used to specify inputs for a WDL workflow outside of Terra, and is especially useful for workflows developed and tested on a different platform that already comes with a JSON file of inputs. For example, it is usually easier to run a WDL from Dockstore if it is accompanied by a JSON file, as is usually the case (see the Test file section in the Dockstore repository of interest).

Using a JSON from a different platform?Note that if you are trying to use a WDL with a JSON file that was tailored for a different platform, you'll need to make sure you update the paths to any files to point to locations in Google Cloud storage that Terra can access. 

To learn more, see Accessing data from an external bucket.

Downloading a JSON file to re-use input files and parameters

You can download your JSON file in the same way, which comes in handy when you want to use the same inputs across workflow configurations. For example, if you create a new configuration, normally you’d have to enter all of the inputs manually every time, even if this new configuration will use many of the same inputs as an existing one. Now you can download the inputs from the prior configuration as a JSON and upload that to populate the new configuration.

Admittedly it would be even better to be able to copy inputs from one configuration to the other within Terra itself - and we're looking at ways to make that happen in the future. But the ability to save inputs to file and re-upload is a big step up from having to fill out each field one by one manually!

 

Was this article helpful?

0 out of 0 found this helpful

Have more questions? Submit a request

Comments

0 comments

Please sign in to leave a comment.