Skip to content

Commit b8096f8

Browse files
committed
Showcase demonstrating nu 1.18 with flink 1.18
1 parent 97596a4 commit b8096f8

File tree

4 files changed

+40
-6
lines changed

4 files changed

+40
-6
lines changed

.env

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
NUSSKNACKER_VERSION=staging-latest
1+
NUSSKNACKER_VERSION=1.18.0-release_1.18-2024-11-06-21370-1f1b39575-SNAPSHOT
2+
NU_COMPAT_VERSION=1.0.0-nu1.18-SNAPSHOT

designer/Dockerfile

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
ARG NUSSKNACKER_VERSION="NUSSKNACKER_VERSION_IS_UNDEFINED"
2+
3+
FROM touk/nussknacker:${NUSSKNACKER_VERSION}_scala-2.12
4+
5+
ARG NU_COMPAT_VERSION="NU_COMPAT_VERSION_IS_UNDEFINED"
6+
7+
USER root
8+
9+
# flink-compatibility-model and flink-compatibility-kafka-components have to be added
10+
RUN curl -L https://oss.sonatype.org/content/repositories/snapshots/pl/touk/nussknacker/nussknacker-flink-compatibility-1-18-model_2.12/${NU_COMPAT_VERSION}/nussknacker-flink-compatibility-1-18-model_2.12-${NU_COMPAT_VERSION}.jar \
11+
-o /opt/nussknacker/components/flink/extra/nussknacker-flink-compatibility-1-18-model_2.12-${NU_COMPAT_VERSION}.jar
12+
13+
RUN curl -L https://oss.sonatype.org/content/repositories/snapshots/pl/touk/nussknacker/nussknacker-flink-compatibility-1-18-kafka-components_2.12/${NU_COMPAT_VERSION}/nussknacker-flink-compatibility-1-18-kafka-components_2.12-${NU_COMPAT_VERSION}-assembly.jar \
14+
-o /opt/nussknacker/components/flink/extra/nussknacker-flink-compatibility-1-18-kafka-components_2.12-${NU_COMPAT_VERSION}-assembly.jar
15+
16+
RUN chown -R demiourgos728:root /opt/nussknacker
17+
18+
USER demiourgos728

designer/application-customizations.conf

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,12 @@
22

33
scenarioTypes {
44
"streaming" {
5-
# customize Flink streaming scenario type
5+
modelConfig {
6+
# classPath have to be overriden in order to remove flinkKafka.jar
7+
classPath: ["components/flink/extra", "model/defaultModel.jar", "model/flinkExecutor.jar",
8+
"components/flink/flinkBase.jar", "components/flink/flinkBaseUnbounded.jar",
9+
"components/common", "flink-dropwizard-metrics-deps/"]
10+
}
611
}
712
"streaming-lite-embedded" {
813
# customize Lite streaming scenario type

docker-compose.yml

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,11 @@ services:
5555
### Nussknacker designer service
5656

5757
designer:
58-
image: touk/nussknacker:${NUSSKNACKER_VERSION:?NUSSKNACKER_VERSION must be defined}_scala-2.12
58+
build:
59+
context: ./designer/
60+
args:
61+
NUSSKNACKER_VERSION: ${NUSSKNACKER_VERSION:?NUSSKNACKER_VERSION must be defined}
62+
NU_COMPAT_VERSION: ${NU_COMPAT_VERSION:?NU_COMPAT_VERSION must be defined}
5963
restart: unless-stopped
6064
environment:
6165
EXAMPLE_SCENARIOS_LIBRARY_SERVICE_NAME: quickstart-setup
@@ -70,7 +74,9 @@ services:
7074
INFLUXDB_URL: "http://influxdb:8086"
7175
FLINK_REST_URL: "http://flink-jobmanager:8081"
7276
JDK_JAVA_OPTIONS: "-Xmx1024M"
73-
USAGE_REPORTS_SOURCE: "quickstart-docker-compose"
77+
USAGE_REPORTS_SOURCE: "flink-compat-docker-compose"
78+
# Flink TypeInfo registration have to be disabled as it is supported from version 1.19 on
79+
NU_DISABLE_FLINK_TYPE_INFO_REGISTRATION: true
7480
depends_on:
7581
postgres:
7682
condition: service_healthy
@@ -229,12 +235,14 @@ services:
229235
build:
230236
context: ./flink/
231237
args:
232-
FLINK_VERSION: "1.19.1-scala_2.12-java11"
238+
FLINK_VERSION: "1.18.1-scala_2.12-java11"
233239
no_cache: true
234240
restart: unless-stopped
235241
command: jobmanager
236242
environment:
237243
JOB_MANAGER_RPC_ADDRESS: "flink-jobmanager"
244+
# Flink TypeInfo registration have to be disabled as it is supported from version 1.19 on
245+
NU_DISABLE_FLINK_TYPE_INFO_REGISTRATION: true
238246
healthcheck:
239247
test: [ "CMD-SHELL", "curl -f http://localhost:8081/jobs/overview" ]
240248
interval: 10s
@@ -246,12 +254,14 @@ services:
246254
build:
247255
context: ./flink/
248256
args:
249-
FLINK_VERSION: "1.19.1-scala_2.12-java11"
257+
FLINK_VERSION: "1.18.1-scala_2.12-java11"
250258
no_cache: true
251259
restart: unless-stopped
252260
command: taskmanager
253261
environment:
254262
JOB_MANAGER_RPC_ADDRESS: "flink-jobmanager"
263+
# Flink TypeInfo registration have to be disabled as it is supported from version 1.19 on
264+
NU_DISABLE_FLINK_TYPE_INFO_REGISTRATION: true
255265
depends_on:
256266
flink-jobmanager:
257267
condition: service_healthy

0 commit comments

Comments
 (0)