Skip to content

Commit 5e5cb9d

Browse files
committed
chore(version): update to version 'v0.4.3'.
2 parents ba9ac34 + b71923b commit 5e5cb9d

File tree

31 files changed

+734
-114
lines changed

31 files changed

+734
-114
lines changed

.github/CONTRIBUTING.md

+12-6
Original file line numberDiff line numberDiff line change
@@ -48,18 +48,24 @@ cd kestra
4848
#### Develop backend
4949
Open the cloned repository in your favorite IDE. In most of decent IDE, gradle build will be detected and all dependencies will be downloaded.
5050

51-
- You may need to enable java annotation processors since we have using it a lot.
52-
- The main class is `io.kestra.cli.App`
53-
- pass as program arguments the server you want to develop, for example `server standalone` will the [standalone server](https://kestra.io/docs/administrator-guide/servers/#kestra-standalone-development-environment-servers)
54-
- There is also a lot of unit test that will help you to validate your code (and you must provide unit test for any pull request).
51+
- You may need to enable java annotation processors since we are using it a lot.
52+
- The main class is `io.kestra.cli.App` from module `kestra.cli.main`
53+
- Pass as program arguments the server you want to develop, for example `server standalone` will the [standalone server](https://kestra.io/docs/administrator-guide/servers/#kestra-standalone-development-environment-servers)
54+
- ![Intellij Idea Configuration ](https://user-images.githubusercontent.com/2064609/161399626-1b681add-cfa8-4e0e-a843-2631cc59758d.png) Intellij Idea configuration can be found in screenshot below.
55+
- `MICRONAUT_ENVIRONMENTS`: can be set any string and will load a custom configuration file in `cli/src/main/resources/application-{env}.yml`
56+
- `KESTRA_PLUGINS_PATH`: is the path where you will save plugins as Jar and will be load on the startup.
57+
- You can also use the gradle task `./gradlew runStandalone` that will run a standalone server with `MICRONAUT_ENVIRONMENTS=override` and plugins path `local/plugins`
58+
- The server start by default on port 8080 and is reachable on `http://localhost:8080`
59+
5560

5661
#### Develop frontend
5762
The frontend is located on `/ui` folder.
5863

5964
- `npm install`
6065
- create a files `ui/.env.development.local` with content `VUE_APP_API_URL=http://localhost:8080` (or your actual server url)
61-
- `npm run server` will start the development server with hot reload.
62-
66+
- `npm run serve` will start the development server with hot reload.
67+
- The server start by default on port 8090 and is reachable on `http://localhost:8090`
68+
- You can run `npm run build` in order to build the front-end that will be delivered from the backend (without running the `npm serve`) above.
6369

6470
#### Develop plugins
6571
A complete documentation for developing plugin can be found [here](https://kestra.io/docs/plugin-developer-guide/).

.github/workflows/main.yml

+121-67
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@ jobs:
2424
name: Check & Publish
2525
runs-on: ubuntu-latest
2626
timeout-minutes: 45
27-
env:
28-
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
2927
steps:
3028
- uses: actions/checkout@v3
3129
- uses: actions/setup-python@v3
@@ -43,7 +41,7 @@ jobs:
4341

4442
# Caches
4543
- name: Gradle cache
46-
uses: actions/cache@v2
44+
uses: actions/cache@v3
4745
with:
4846
path: |
4947
~/.gradle/caches
@@ -53,15 +51,15 @@ jobs:
5351
${{ runner.os }}-gradle-
5452
5553
- name: Npm cache
56-
uses: actions/cache@v2
54+
uses: actions/cache@v3
5755
with:
5856
path: ~/.npm
5957
key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
6058
restore-keys: |
6159
${{ runner.os }}-npm-
6260
6361
- name: Node cache
64-
uses: actions/cache@v2
62+
uses: actions/cache@v3
6563
with:
6664
path: node
6765
key: ${{ runner.os }}-node-${{ hashFiles('ui/*.gradle') }}
@@ -98,38 +96,6 @@ jobs:
9896
- name: Build jars
9997
run: ./gradlew executableJar --no-daemon
10098

101-
# Publish
102-
- name: Publish package to Sonatype
103-
if: github.ref == 'refs/heads/develop'
104-
env:
105-
ORG_GRADLE_PROJECT_sonatypeUsername: ${{ secrets.SONATYPE_USER }}
106-
ORG_GRADLE_PROJECT_sonatypePassword: ${{ secrets.SONATYPE_PASSWORD }}
107-
SONATYPE_GPG_KEYID: ${{ secrets.SONATYPE_GPG_KEYID }}
108-
SONATYPE_GPG_PASSWORD: ${{ secrets.SONATYPE_GPG_PASSWORD }}
109-
SONATYPE_GPG_FILE: ${{ secrets.SONATYPE_GPG_FILE }}
110-
run: |
111-
echo "signing.keyId=${SONATYPE_GPG_KEYID}" > ~/.gradle/gradle.properties
112-
echo "signing.password=${SONATYPE_GPG_PASSWORD}" >> ~/.gradle/gradle.properties
113-
echo "signing.secretKeyRingFile=${HOME}/.gradle/secring.gpg" >> ~/.gradle/gradle.properties
114-
echo ${SONATYPE_GPG_FILE} | base64 -d > ~/.gradle/secring.gpg
115-
./gradlew publishToSonatype --parallel --no-daemon
116-
117-
# Release
118-
- name: Release package to Maven Central
119-
if: startsWith(github.ref, 'refs/tags/v')
120-
env:
121-
ORG_GRADLE_PROJECT_sonatypeUsername: ${{ secrets.SONATYPE_USER }}
122-
ORG_GRADLE_PROJECT_sonatypePassword: ${{ secrets.SONATYPE_PASSWORD }}
123-
SONATYPE_GPG_KEYID: ${{ secrets.SONATYPE_GPG_KEYID }}
124-
SONATYPE_GPG_PASSWORD: ${{ secrets.SONATYPE_GPG_PASSWORD }}
125-
SONATYPE_GPG_FILE: ${{ secrets.SONATYPE_GPG_FILE }}
126-
run: |
127-
echo "signing.keyId=${SONATYPE_GPG_KEYID}" > ~/.gradle/gradle.properties
128-
echo "signing.password=${SONATYPE_GPG_PASSWORD}" >> ~/.gradle/gradle.properties
129-
echo "signing.secretKeyRingFile=${HOME}/.gradle/secring.gpg" >> ~/.gradle/gradle.properties
130-
echo ${SONATYPE_GPG_FILE} | base64 -d > ~/.gradle/secring.gpg
131-
./gradlew publishToSonatype closeAndReleaseSonatypeStagingRepository --no-daemon
132-
13399
# Upload artifacts
134100
- name: Upload jar
135101
uses: actions/upload-artifact@v2
@@ -143,10 +109,42 @@ jobs:
143109
name: exe
144110
path: build/executable/
145111

112+
# GitHub Release
113+
- name: Create GitHub release
114+
uses: "marvinpinto/action-automatic-releases@latest"
115+
if: startsWith(github.ref, 'refs/tags/v')
116+
with:
117+
repo_token: "${{ secrets.GITHUB_TOKEN }}"
118+
files: |
119+
build/executable/*
120+
121+
docker:
122+
name: Publish docker
123+
runs-on: ubuntu-latest
124+
needs: check
125+
if: github.ref == 'refs/heads/master' || github.ref == 'refs/heads/develop' || github.ref == 'refs/heads/release' || startsWith(github.ref, 'refs/tags/v')
126+
strategy:
127+
matrix:
128+
image:
129+
- name: ""
130+
plugins: ""
131+
packages: ""
132+
- name: "-full"
133+
plugins: io.kestra.storage:storage-gcs:LATEST io.kestra.storage:storage-minio:LATEST io.kestra.plugin:plugin-aws:LATEST io.kestra.plugin:plugin-compress:LATEST io.kestra.plugin:plugin-crypto:LATEST io.kestra.plugin:plugin-debezium-mysql:LATEST io.kestra.plugin:plugin-debezium-postgres:LATEST io.kestra.plugin:plugin-elasticsearch:LATEST io.kestra.plugin:plugin-fs:LATEST io.kestra.plugin:plugin-gcp:LATEST io.kestra.plugin:plugin-googleworkspace:LATEST io.kestra.plugin:plugin-jdbc-clickhouse:LATEST io.kestra.plugin:plugin-jdbc-mysql:LATEST io.kestra.plugin:plugin-jdbc-oracle:LATEST io.kestra.plugin:plugin-jdbc-postgres:LATEST io.kestra.plugin:plugin-jdbc-redshift:LATEST io.kestra.plugin:plugin-jdbc-snowflake:LATEST io.kestra.plugin:plugin-jdbc-sqlserver:LATEST io.kestra.plugin:plugin-jdbc-vertica:LATEST io.kestra.plugin:plugin-jdbc-vectorwise:LATEST io.kestra.plugin:plugin-kafka:LATEST io.kestra.plugin:plugin-kubernetes:LATEST io.kestra.plugin:plugin-mongodb:LATEST io.kestra.plugin:plugin-notifications:LATEST io.kestra.plugin:plugin-script-groovy:LATEST io.kestra.plugin:plugin-script-jython:LATEST io.kestra.plugin:plugin-script-nashorn:LATEST io.kestra.plugin:plugin-serdes:LATEST io.kestra.plugin:plugin-singer:LATEST io.kestra.plugin:plugin-spark:LATEST
134+
packages: python3-pip python3-wheel python3-setuptools python3-virtualenv nodejs curl wait-for-it zip unzip
135+
steps:
136+
- uses: actions/checkout@v2
137+
138+
# Artifact
139+
- name: Download executable
140+
uses: actions/download-artifact@v3
141+
with:
142+
name: exe
143+
path: build/executable
144+
146145
- name: Copy exe to image
147146
run: |
148147
cp build/executable/* docker/app/kestra && chmod +x docker/app/kestra
149-
find docker
150148
151149
# Vars
152150
- name: Set image name
@@ -159,7 +157,7 @@ jobs:
159157
echo ::set-output name=plugins::
160158
else
161159
echo ::set-output name=tag::${TAG}
162-
echo ::set-output name=plugins::--repositories=https://s01.oss.sonatype.org/content/repositories/snapshots
160+
echo ::set-output name=plugins::--repositories=https://s01.oss.sonatype.org/content/repositories/snapshots ${{ matrix.image.plugins }}
163161
fi
164162
165163
# Docker setup
@@ -179,48 +177,104 @@ jobs:
179177
username: ${{ secrets.DOCKERHUB_USERNAME }}
180178
password: ${{ secrets.DOCKERHUB_PASSWORD }}
181179

180+
# Docker Build and push
182181
- name: Push to Docker Hub
183182
if: github.ref == 'refs/heads/master' || github.ref == 'refs/heads/develop' || github.ref == 'refs/heads/release' || startsWith(github.ref, 'refs/tags/v')
184183
uses: docker/build-push-action@v2
185184
with:
186185
context: .
187186
push: true
188-
tags: ${{ format('kestra/kestra:{0}', steps.vars.outputs.tag) }}
187+
tags: ${{ format('kestra/kestra:{0}{1}', steps.vars.outputs.tag, matrix.image.name) }}
189188
platforms: linux/amd64,linux/arm64
189+
build-args: |
190+
KESTRA_PLUGINS=${{ steps.vars.outputs.plugins }}
191+
APT_PACKAGES=${{ matrix.image.packages }}
190192
191-
- name: Push to Docker Hub Full
192-
if: github.ref == 'refs/heads/master' || github.ref == 'refs/heads/develop' || github.ref == 'refs/heads/release' || startsWith(github.ref, 'refs/tags/v')
193-
uses: docker/build-push-action@v2
193+
maven:
194+
name: Publish to Maven
195+
runs-on: ubuntu-latest
196+
needs: check
197+
if: github.ref == 'refs/heads/develop' || startsWith(github.ref, 'refs/tags/v')
198+
steps:
199+
- uses: actions/checkout@v2
200+
201+
# Caches
202+
- name: Gradle cache
203+
uses: actions/cache@v3
194204
with:
195-
context: .
196-
push: true
197-
tags: ${{ format('kestra/kestra:{0}-full', steps.vars.outputs.tag) }}
198-
platforms: linux/amd64,linux/arm64
199-
build-args: |
200-
KESTRA_PLUGINS=${{ steps.vars.outputs.plugins }} io.kestra.storage:storage-gcs:LATEST io.kestra.storage:storage-minio:LATEST io.kestra.plugin:plugin-aws:LATEST io.kestra.plugin:plugin-compress:LATEST io.kestra.plugin:plugin-crypto:LATEST io.kestra.plugin:plugin-elasticsearch:LATEST io.kestra.plugin:plugin-fs:LATEST io.kestra.plugin:plugin-gcp:LATEST io.kestra.plugin:plugin-googleworkspace:LATEST io.kestra.plugin:plugin-jdbc-clickhouse:LATEST io.kestra.plugin:plugin-jdbc-mysql:LATEST io.kestra.plugin:plugin-jdbc-oracle:LATEST io.kestra.plugin:plugin-jdbc-postgres:LATEST io.kestra.plugin:plugin-jdbc-redshift:LATEST io.kestra.plugin:plugin-jdbc-sqlserver:LATEST io.kestra.plugin:plugin-jdbc-vertica:LATEST io.kestra.plugin:plugin-jdbc-vectorwise:LATEST io.kestra.plugin:plugin-kafka:LATEST io.kestra.plugin:plugin-kubernetes:LATEST io.kestra.plugin:plugin-mongodb:LATEST io.kestra.plugin:plugin-notifications:LATEST io.kestra.plugin:plugin-script-groovy:LATEST io.kestra.plugin:plugin-script-jython:LATEST io.kestra.plugin:plugin-script-nashorn:LATEST io.kestra.plugin:plugin-serdes:LATEST io.kestra.plugin:plugin-singer:LATEST
201-
APT_PACKAGES=python3-pip python3-wheel python3-setuptools python3-virtualenv nodejs curl wait-for-it zip unzip
205+
path: |
206+
~/.gradle/caches
207+
~/.gradle/wrapper
208+
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle*.properties') }}
209+
restore-keys: |
210+
${{ runner.os }}-gradle-
202211
203-
# GitHub Release
204-
- name: Create GitHub release
205-
uses: "marvinpinto/action-automatic-releases@latest"
206-
if: startsWith(github.ref, 'refs/tags/v')
212+
- name: Npm cache
213+
uses: actions/cache@v3
207214
with:
208-
repo_token: "${{ secrets.GITHUB_TOKEN }}"
209-
draft: true
210-
files: |
211-
build/executable/*
215+
path: ~/.npm
216+
key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
217+
restore-keys: |
218+
${{ runner.os }}-npm-
219+
220+
- name: Node cache
221+
uses: actions/cache@v3
222+
with:
223+
path: node
224+
key: ${{ runner.os }}-node-${{ hashFiles('ui/*.gradle') }}
225+
restore-keys: |
226+
${{ runner.os }}-node-
227+
228+
# Publish
229+
- name: Publish package to Sonatype
230+
if: github.ref == 'refs/heads/develop'
231+
env:
232+
ORG_GRADLE_PROJECT_sonatypeUsername: ${{ secrets.SONATYPE_USER }}
233+
ORG_GRADLE_PROJECT_sonatypePassword: ${{ secrets.SONATYPE_PASSWORD }}
234+
SONATYPE_GPG_KEYID: ${{ secrets.SONATYPE_GPG_KEYID }}
235+
SONATYPE_GPG_PASSWORD: ${{ secrets.SONATYPE_GPG_PASSWORD }}
236+
SONATYPE_GPG_FILE: ${{ secrets.SONATYPE_GPG_FILE }}
237+
run: |
238+
mkdir -p ~/.gradle/
239+
echo "signing.keyId=${SONATYPE_GPG_KEYID}" > ~/.gradle/gradle.properties
240+
echo "signing.password=${SONATYPE_GPG_PASSWORD}" >> ~/.gradle/gradle.properties
241+
echo "signing.secretKeyRingFile=${HOME}/.gradle/secring.gpg" >> ~/.gradle/gradle.properties
242+
echo ${SONATYPE_GPG_FILE} | base64 -d > ~/.gradle/secring.gpg
243+
./gradlew publishToSonatype --parallel --no-daemon
212244
245+
# Release
246+
- name: Release package to Maven Central
247+
if: startsWith(github.ref, 'refs/tags/v')
248+
env:
249+
ORG_GRADLE_PROJECT_sonatypeUsername: ${{ secrets.SONATYPE_USER }}
250+
ORG_GRADLE_PROJECT_sonatypePassword: ${{ secrets.SONATYPE_PASSWORD }}
251+
SONATYPE_GPG_KEYID: ${{ secrets.SONATYPE_GPG_KEYID }}
252+
SONATYPE_GPG_PASSWORD: ${{ secrets.SONATYPE_GPG_PASSWORD }}
253+
SONATYPE_GPG_FILE: ${{ secrets.SONATYPE_GPG_FILE }}
254+
run: |
255+
echo "signing.keyId=${SONATYPE_GPG_KEYID}" > ~/.gradle/gradle.properties
256+
echo "signing.password=${SONATYPE_GPG_PASSWORD}" >> ~/.gradle/gradle.properties
257+
echo "signing.secretKeyRingFile=${HOME}/.gradle/secring.gpg" >> ~/.gradle/gradle.properties
258+
echo ${SONATYPE_GPG_FILE} | base64 -d > ~/.gradle/secring.gpg
259+
./gradlew publishToSonatype closeAndReleaseSonatypeStagingRepository --no-daemon
260+
261+
end:
262+
runs-on: ubuntu-latest
263+
needs:
264+
- check
265+
- maven
266+
- docker
267+
if: always()
268+
env:
269+
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
270+
steps:
213271
# Slack
214272
- name: Slack notification
215-
uses: 8398a7/action-slack@v3
273+
uses: Gamesight/slack-workflow-status@master
216274
if: ${{ always() && env.SLACK_WEBHOOK_URL != 0 }}
217275
with:
218-
status: ${{ job.status }}
219-
job_name: Check & Publish
220-
fields: repo,commit,action,ref,job,took
221-
username: GitHub Actions
222-
icon_emoji: ':github-actions:'
276+
repo_token: ${{ secrets.GITHUB_TOKEN }}
277+
slack_webhook_url: ${{ secrets.SLACK_WEBHOOK_URL }}
223278
channel: '#git'
224-
env:
225-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
226-
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
279+
name: GitHub Actions
280+
icon_emoji: ':github-actions:'

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ Play with our [demo app](https://demo.kestra.io)!
4646
Kestra is an infinitely scalable orchestration and scheduling platform, creating, running, scheduling, and monitoring millions of complex pipelines.
4747

4848
- 🔀 **Any kind of workflow**: Workflows can start simple and progress to more complex systems with branching, parallel, dynamic tasks, flow dependencies
49-
- 🎓‍ **Easy to learn**: Flows are in simple, descriptive language defined in YAML;u don't need to be a developer to create a new flow.
49+
- 🎓‍ **Easy to learn**: Flows are in simple, descriptive language defined in YAML—you don't need to be a developer to create a new flow.
5050
- 🔣 **Easy to extend**: Plugins are everywhere in Kestra, many are available from the Kestra core team, but you can create one easily.
5151
- 🆙 **Any triggers**: Kestra is event-based at heart—you can trigger an execution from API, schedule, detection, events
5252
- 💻 **A rich user interface**: The built-in web interface allows you to create, run, and monitor all your flows—no need to deploy your flows, just edit them.

build.gradle

+3-2
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ allprojects {
9797

9898
// logs
9999
implementation "org.slf4j:slf4j-api:1.7.36"
100-
implementation "ch.qos.logback:logback-classic:1.2.10"
100+
implementation "ch.qos.logback:logback-classic:1.2.11"
101101
implementation group: 'org.apache.logging.log4j', name: 'log4j-to-slf4j', version: '2.17.2'
102102
implementation group: 'org.slf4j', name: 'jul-to-slf4j', version: '1.7.36'
103103

@@ -305,7 +305,8 @@ task runStandalone(type: JavaExec) {
305305
group = "application"
306306
classpath = project(":cli").sourceSets.main.runtimeClasspath
307307
mainClass = mainClassName
308-
args 'server', 'standalone'
308+
environment 'MICRONAUT_ENVIRONMENTS', 'override'
309+
args 'server', 'standalone', '--plugins', 'local/plugins'
309310
}
310311

311312
/**********************************************************************************************************************\

cli/src/main/java/io/kestra/cli/commands/servers/StandAloneCommand.java

+9
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@ public class StandAloneCommand extends AbstractCommand {
3030
@CommandLine.Option(names = {"-f", "--flow-path"}, description = "the flow path containing flow to inject at startup (when running with a memory flow repository)")
3131
private File flowPath;
3232

33+
34+
@CommandLine.Option(names = {"--worker-thread"}, description = "the number of worker thread")
35+
private Integer workerThread;
36+
3337
public StandAloneCommand() {
3438
super(true);
3539
}
@@ -55,6 +59,11 @@ public Integer call() throws Exception {
5559
}
5660

5761
StandAloneRunner standAloneRunner = applicationContext.getBean(StandAloneRunner.class);
62+
63+
if (this.workerThread != null) {
64+
standAloneRunner.setWorkerThread(this.workerThread);
65+
}
66+
5867
standAloneRunner.run();
5968

6069
this.shutdownHook(standAloneRunner::close);

core/build.gradle

+7-7
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,14 @@ processResources.dependsOn copyGradleProperties
1313

1414
dependencies {
1515
// log
16-
implementation group: 'ch.qos.logback', name: 'logback-classic', version: '1.2.10'
16+
implementation group: 'ch.qos.logback', name: 'logback-classic', version: '1.2.11'
1717

1818
// serializers
1919
implementation group: 'com.fasterxml.jackson.dataformat', name: 'jackson-dataformat-ion'
2020

2121
// utils
2222
implementation group: 'net.jodah', name: 'failsafe', version: '2.4.4'
23-
implementation 'com.github.oshi:oshi-core:6.1.4'
23+
implementation 'com.github.oshi:oshi-core:6.1.5'
2424
implementation 'io.pebbletemplates:pebble:3.1.5'
2525

2626
// scheduler
@@ -33,17 +33,17 @@ dependencies {
3333
implementation 'com.github.docker-java:docker-java-transport-httpclient5:3.2.13'
3434

3535
// schema
36-
implementation group: 'com.github.victools', name: 'jsonschema-generator', version: '4.22.0'
37-
implementation group: 'com.github.victools', name: 'jsonschema-module-javax-validation', version: '4.22.0'
38-
implementation group: 'com.github.victools', name: 'jsonschema-module-jackson', version: '4.22.0'
39-
implementation group: 'com.github.victools', name: 'jsonschema-module-swagger-2', version: '4.22.0'
36+
implementation group: 'com.github.victools', name: 'jsonschema-generator', version: '4.23.0'
37+
implementation group: 'com.github.victools', name: 'jsonschema-module-javax-validation', version: '4.23.0'
38+
implementation group: 'com.github.victools', name: 'jsonschema-module-jackson', version: '4.23.0'
39+
implementation group: 'com.github.victools', name: 'jsonschema-module-swagger-2', version: '4.23.0'
4040

4141
// test
4242
testImplementation project(':repository-memory')
4343
testImplementation project(':runner-memory')
4444
testImplementation project(':storage-local')
4545

46-
testImplementation 'org.mockito:mockito-junit-jupiter:4.3.1'
46+
testImplementation 'org.mockito:mockito-junit-jupiter:4.4.0'
4747
testImplementation "io.micronaut:micronaut-http-client"
4848
testImplementation "io.micronaut.rxjava2:micronaut-rxjava2-http-client"
4949
testImplementation "io.micronaut:micronaut-http-server-netty"

0 commit comments

Comments
 (0)