Challenge - 5 Problems
CI/CD Mastery - Spring Boot
Get all challenges correct to earn this badge!
Test your skills under time pressure!
💻 Command Output
intermediate2:00remaining
What is the output of this Jenkins pipeline stage?
Consider this Jenkins pipeline snippet for a Spring Boot project build stage. What will be the output after running the 'Build' stage?
Spring Boot
pipeline {
agent any
stages {
stage('Build') {
steps {
sh 'mvn clean package'
}
}
}
}Attempts:
2 left
💡 Hint
Maven's 'clean package' command compiles and packages the Spring Boot app.
✗ Incorrect
The 'mvn clean package' command cleans previous builds and packages the app, producing a JAR file in the target directory if successful.
🧠 Conceptual
intermediate1:30remaining
Which step is essential in a CI/CD pipeline for Spring Boot to ensure code quality?
In a typical CI/CD pipeline for a Spring Boot application, which step is crucial to catch bugs early before deployment?
Attempts:
2 left
💡 Hint
Automated tests help catch errors early in the pipeline.
✗ Incorrect
Running automated tests after building ensures code quality and prevents faulty code from progressing to deployment.
❓ Troubleshoot
advanced2:30remaining
Why does this Jenkins pipeline fail at the deploy stage?
Given this Jenkins pipeline snippet, why does the deploy stage fail?
Spring Boot
pipeline {
agent any
stages {
stage('Build') {
steps {
sh 'mvn clean package'
}
}
stage('Deploy') {
steps {
sh 'docker build -t springboot-app .'
sh 'docker push springboot-app'
}
}
}
}Attempts:
2 left
💡 Hint
Docker images usually require a full tag including registry or repository before push.
✗ Incorrect
The 'docker push springboot-app' command fails because the image tag lacks registry or repository info, so Docker doesn't know where to push.
🔀 Workflow
advanced2:00remaining
What is the correct order of stages in a CI/CD pipeline for Spring Boot?
Arrange these stages in the correct order for a typical CI/CD pipeline:
Attempts:
2 left
💡 Hint
Tests should run after build and before deployment.
✗ Incorrect
The pipeline builds the app first, then runs tests to verify it, then deploys to staging for validation, and finally to production.
✅ Best Practice
expert3:00remaining
Which practice improves CI/CD pipeline reliability for Spring Boot microservices?
To improve reliability and reduce downtime in CI/CD pipelines for Spring Boot microservices, which practice is best?
Attempts:
2 left
💡 Hint
Blue-green deployment allows safe switching between versions.
✗ Incorrect
Blue-green deployment reduces downtime by running two identical environments and switching traffic only after successful deployment.