Adding Connection Logic Where Required
On this page
In this lesson, you will learn:
- When a connection section is worth adding
- How it finds a dependency
- The archiver’s link to snwr-db-01
π Quick look back: Last time: Populating Attributes and Relationships. You learned how the pattern fills the CI and its Runs on link.
1 The Problem: The Archiver’s Database Isn’t Linked
The archiver stores its index in PostgreSQL on snwr-db-01. If snwr-db-01 goes down:
- The archiver stops.
- Nothing in the CMDB shows that.
π The fix: Add a connection section that reads db_host and links to snwr-db-01.

2 When to add one
- A key dependency affects impact, like a database.
- The connection details are easy to read, like a config value.
- Someone will use the link.
3 How it works
The connection section uses a value, like db_host, to find or create the target and link to it. Keep it simple: one reliable source for the target.
4 Project Clear View: How We Implemented It
π Situation: Mei wanted to see that the archiver depends on snwr-db-01.
π§ Decision: Add a connection section from db_host.
π οΈ Steps we took:
- Added a connection section using the db_host variable.
- Pointed it at the PostgreSQL CI on snwr-db-01.
- Tested in Debug on snwrdev.
- Checked the link in the CMDB.
β What we verified:
- The archiver shows a link to PostgreSQL on snwr-db-01.
- Mei can see the dependency.
π Evidence: The connection section, part of the archiver pattern.
5 Quick recap
- Add connection logic for key dependencies.
- Use one reliable value, like a config setting.
- Check the link appears in the CMDB.
- Only add links someone will use.
6 Check yourself
Think of your answer first. Then tap to check.
1 Which value did the connection section use? Show answer
db_host from archiver.conf.
2 What does the archiver depend on? Show answer
PostgreSQL on snwr-db-01.
3 Who needed this link? Show answer
Mei, for change impact.
Nice work! The archiver’s dependency is visible. π
Next up: Debugging and Validating the Pattern
Was this lesson helpful?
Please log in to share lesson feedback.
Have a question or doubt?
Ask here and get help from instructors and fellow learners.
Only logged-in learners can post.




