Practice
1. What is the main purpose of configuring dashboard views in Jenkins?
easy
Solution
Step 1: Understand dashboard views role
Dashboard views help group and display jobs clearly.Step 2: Identify main benefit
This organization makes monitoring easier for users.Final Answer:
To organize jobs for easy monitoring -> Option AQuick Check:
Dashboard views = organize jobs [OK]
Hint: Dashboard views group jobs visually for monitoring [OK]
Common Mistakes:
- Confusing dashboard views with build scripts
- Thinking views manage permissions
- Assuming views deploy apps automatically
2. Which syntax correctly filters jobs by name pattern in a Jenkins dashboard view?
easy
Solution
Step 1: Recognize regex pattern for filtering
Jenkins uses regular expressions to filter job names.Step 2: Identify correct regex for 'test' anywhere
.*test.*matches any job name containing 'test'.Final Answer:
.*test.*-> Option DQuick Check:
Regex pattern for contains 'test' =.*test.*[OK]
Hint: Use .*pattern.* to match substring in job names [OK]
Common Mistakes:
- Using wildcard * without dot in regex
- Confusing ? with * in regex
- Using end anchor $ incorrectly
3. Given a dashboard view configured to show columns: Job Name, Last Success, and Build Duration, what will be displayed?
medium
Solution
Step 1: Analyze configured columns
The columns are Job Name, Last Success, and Build Duration.Step 2: Understand what each column shows
Job Name shows job titles, Last Success shows last successful build time, Build Duration shows how long builds took.Final Answer:
Job names, last successful build time, and how long builds took -> Option AQuick Check:
Columns = Job Name + Last Success + Build Duration [OK]
Hint: Columns show exactly the info you select in view config [OK]
Common Mistakes:
- Ignoring Build Duration column
- Assuming build status is shown without selecting
- Confusing Last Success with build status
4. You configured a dashboard view to filter jobs with pattern
build.* but no jobs appear. What is the likely error?medium
Solution
Step 1: Check regex pattern and job names
The patternbuild.*matches lowercase 'build' at start.Step 2: Consider case sensitivity
Jenkins regex is case-sensitive by default; jobs starting with 'Build' (uppercase) won't match.Final Answer:
The pattern is case-sensitive and jobs start with uppercase 'Build' -> Option CQuick Check:
Regex case sensitivity causes no matches [OK]
Hint: Regex is case-sensitive; match exact case or use (?i) [OK]
Common Mistakes:
- Removing dot from regex incorrectly
- Believing Jenkins needs restart for view changes
- Thinking regex filtering is unsupported
5. You want a dashboard view that shows only jobs with names containing 'deploy' or 'release' and displays columns: Job Name, Last Build Status, and Duration. Which configuration achieves this?
hard
Solution
Step 1: Create regex for 'deploy' or 'release'
The regex.*(deploy|release).*matches job names containing either word anywhere.Step 2: Select correct columns
Columns needed are Job Name, Last Build Status, and Duration exactly as named.Final Answer:
Use regex.*(deploy|release).*and select columns Job Name, Last Build Status, Duration -> Option BQuick Check:
Regex with (deploy|release) and correct columns [OK]
Hint: Use (a|b) in regex for OR conditions [OK]
Common Mistakes:
- Using regex without .* to match anywhere
- Selecting wrong column names
- Assuming simple 'deploy|release' matches anywhere
