forked from Azure/azure-sdk-for-java
-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[SB/EH] Fix stress CI runs (Azure#35804)
* fix ci runs * minimize dockerfile and use fat jar
- Loading branch information
Showing
10 changed files
with
79 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
42 changes: 29 additions & 13 deletions
42
sdk/eventhubs/azure-messaging-eventhubs-stress/Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,34 @@ | ||
FROM mcr.microsoft.com/openjdk/jdk:11-mariner as builder | ||
WORKDIR application | ||
ARG JAR_FILE=target/*.jar | ||
COPY ${JAR_FILE} application.jar | ||
RUN java -Djarmode=layertools -jar application.jar extract | ||
FROM maven:3.8.6-openjdk-11 as builder | ||
|
||
RUN mkdir /stress-eh | ||
WORKDIR /stress-eh | ||
|
||
ADD ./sdk/tools /stress-eh/sdk/tools | ||
ADD ./sdk/parents /stress-eh/sdk/parents | ||
ADD ./sdk/core /stress-eh/sdk/core | ||
ADD ./sdk/eventhubs /stress-eh/sdk/eventhubs | ||
ADD ./eng /stress-eh/eng | ||
|
||
RUN --mount=type=cache,target=/root/.m2 \ | ||
mvn -f /stress-eh/eng/code-quality-reports/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-eh/sdk/tools/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-eh/sdk/core/azure-core/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-eh/sdk/core/azure-core-test/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-eh/sdk/core/azure-core-amqp/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-eh/sdk/core/azure-core-http-netty/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-eh/sdk/eventhubs/azure-messaging-eventhubs/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-eh/sdk/eventhubs/azure-messaging-eventhubs-checkpointstore-blob/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-eh/sdk/eventhubs/azure-messaging-eventhubs-stress/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests | ||
|
||
FROM mcr.microsoft.com/openjdk/jdk:11-mariner | ||
WORKDIR application | ||
COPY --from=builder application/dependencies/ ./ | ||
COPY --from=builder application/spring-boot-loader/ ./ | ||
COPY --from=builder application/snapshot-dependencies/ ./ | ||
COPY --from=builder application/application/ ./ | ||
ARG AGENT_URL=https://github.com/microsoft/ApplicationInsights-Java/releases/download/3.4.1/applicationinsights-agent-3.4.1.jar | ||
|
||
WORKDIR /app | ||
COPY --from=builder /stress-eh/sdk/eventhubs/azure-messaging-eventhubs-stress/target . | ||
|
||
ARG AGENT_URL=https://github.com/microsoft/ApplicationInsights-Java/releases/download/3.4.13/applicationinsights-agent-3.4.13.jar | ||
ADD ${AGENT_URL} ./BOOT-INF/classes/ | ||
ENTRYPOINT ["java","org.springframework.boot.loader.JarLauncher", \ | ||
"-javaagent:BOOT-INF/classes/applicationinsights-agent-3.4.1.jar", \ | ||
|
||
ENTRYPOINT ["java", "-javaagent:BOOT-INF/classes/applicationinsights-agent-3.4.13.jar", \ | ||
"-jar", "/app/azure-messaging-eventhubs-stress/target/azure-messaging-eventhubs-stress-1.0.0-beta.1.jar", \ | ||
"--TEST_CLASS=EventSender"] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 6 additions & 2 deletions
8
sdk/eventhubs/azure-messaging-eventhubs-stress/scenarios-matrix.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
matrix: | ||
scenarios: | ||
- longrunning | ||
image: | ||
- Dockerfile | ||
scenarios: | ||
send-process: | ||
chaos: "false" | ||
imageBuildDir: ..\..\..\ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
39 changes: 26 additions & 13 deletions
39
sdk/servicebus/azure-messaging-servicebus-stress/Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,31 @@ | ||
FROM mcr.microsoft.com/openjdk/jdk:11-mariner as builder | ||
WORKDIR application | ||
ARG JAR_FILE=target/*.jar | ||
COPY ${JAR_FILE} application.jar | ||
RUN java -Djarmode=layertools -jar application.jar extract | ||
FROM maven:3.8.6-openjdk-11 as builder | ||
|
||
RUN mkdir /stress-sb | ||
WORKDIR /stress-sb | ||
|
||
ADD ./sdk/tools /stress-eh/sdk/tools | ||
ADD ./sdk/parents /stress-eh/sdk/parents | ||
ADD ./sdk/core /stress-sb/sdk/core | ||
ADD ./sdk/servicebus /stress-sb/sdk/servicebus | ||
ADD ./eng /stress-eh/eng | ||
|
||
RUN --mount=type=cache,target=/root/.m2 \ | ||
mvn -f /stress-eh/eng/code-quality-reports/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-eh/sdk/tools/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-sb/sdk/core/azure-core/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-sb/sdk/core/azure-core-test/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-sb/sdk/core/azure-core-amqp/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-sb/sdk/core/azure-core-http-netty/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-sb/sdk/servicebus/azure-messaging-servicebus/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests && \ | ||
mvn -f /stress-sb/sdk/servicebus/azure-messaging-servicebus-stress/pom.xml clean install -Dcheckstyle.skip -Dgpg.skip -Dmaven.javadoc.skip -Drevapi.skip -Dspotbugs.skip -Djacoco.skip -DskipTests | ||
|
||
FROM mcr.microsoft.com/openjdk/jdk:11-mariner | ||
WORKDIR application | ||
COPY --from=builder application/dependencies/ ./ | ||
COPY --from=builder application/spring-boot-loader/ ./ | ||
COPY --from=builder application/snapshot-dependencies/ ./ | ||
COPY --from=builder application/application/ ./ | ||
|
||
WORKDIR /app | ||
COPY --from=builder /stress-sb/sdk/servicebus/azure-messaging-servicebus-stress/target . | ||
|
||
ARG AGENT_URL=https://github.com/microsoft/ApplicationInsights-Java/releases/download/3.4.13/applicationinsights-agent-3.4.13.jar | ||
ADD ${AGENT_URL} ./BOOT-INF/classes/ | ||
ENTRYPOINT ["java","org.springframework.boot.loader.JarLauncher", \ | ||
"-javaagent:BOOT-INF/classes/applicationinsights-agent-3.4.13.jar", \ | ||
ENTRYPOINT ["java", "-javaagent:BOOT-INF/classes/applicationinsights-agent-3.4.13.jar", \ | ||
"-jar", "/app/azure-messaging-servicebus-stress/target/azure-messaging-servicebus-stress-1.0.0-beta.1.jar", \ | ||
"--TEST_CLASS=MessageSender"] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 4 additions & 1 deletion
5
sdk/servicebus/azure-messaging-servicebus-stress/scenarios-matrix.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,7 @@ | ||
matrix: | ||
image: | ||
- Dockerfile | ||
scenarios: | ||
longrunning: | ||
send-process: | ||
chaos: "true" | ||
imageBuildDir: ..\..\..\ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters