Workers

JFrog Platform Administration Documentation

Content Type
Administration / Platform
ft:sourceType
Paligo

JFrog Workers is a service in the JFrog Platform that provides a serverless execution environment. You can create workers that react to events in the JFrog Platform similar to AWS Lambda services.

Workers service provides more flexibility to accomplish your use cases. You can use these workers to perform certain tasks that extend the capabilities of the JFrog Platform according to your requirements. 

Warning

JFrog Workers Service is only available for JFrog Cloud customers to use free of charge during the beta period. The API may not be backward compatible after the beta period is over. Be aware of this caveat when you create workers during this period.

Currently, you can create the following workers with the Workers service.

Event

Using Platform UI

Description

Sample Code

Before downloading artifact in Artifactory

Before Download

Before Download events are executed before the download request is executed by Artifactory.

For example, you can run initiate an Xray scan before the actual download of the artifact from Artifactory.

Before Download Worker Code Sample

After downloading artifact in Artifactory

After Download

After Download events are executed after the download request is executed by Artifactory and the Artifact is downloaded by client.

After Download Worker Code Sample

Before upload request is run in Artifactory

Before Upload

Before Upload events are executed before the upload request is executed by Artifactory.

Before Upload Worker Code Sample

After create in Artifactory, available to customers with both Artifactory and Xray licenses, when Workers Service moves from Beta to General Availability

After Create

After Create events are executed when an artifact is created in the Artifactory storage. For example, you can add a property value to the artifact immediately after it is created.

Warning

After Create event is slated to be available only for those customers who have both Artifactory and Xray licenses when Workers Service moves from Beta to General Availability.

After Create Worker Code Sample

After moving artifact from one repository to another in Artifactory

After Move

After Move events are executed when an artifact is moved from one repository to another.

After Move Worker Code Sample

After build info has been saved in Artifactory storage

After Build Info Save

After Build Info Save events are executed after a build info has been saved in the Artifactory storage.

After Build Info Save Worker Code Sample

Runs custom code independent of any events in the JFrog Platform, can create generic event

Generic Event Worker

Generic event workers can execute custom code independent of any events in the JFrog Platform.

Execute Worker for Generic Event Code Sample

-

The Workers UI provides a direct feedback system that enables you to provide feedback regarding the Workers Service. You can also provide your requests for different types of workers through the feedback system.

The following sections explain how you can use Workers.