Docs/singleton comparison#3529
Conversation
PR SummaryAdded a comparison table in the Singleton README contrasting Eager Initialization and Thread-Safe Lazy Initialization, highlighting object creation timing, thread safety, synchronization, memory usage, performance, and complexity. Also added a notification service example to the Factory Method README to improve readability for beginners learning design patterns. Changes
autogenerated by presubmit.ai |
There was a problem hiding this comment.
✅ LGTM!
Review Summary
Commits Considered (2)
Files Processed (2)
- factory-method/README.md (1 hunk)
- singleton/README.md (1 hunk)
Actionable Comments (0)
Skipped Comments (2)
-
factory-method/README.md [34-36]
readability: "Clarify Factory Method documentation example."
-
singleton/README.md [40-49]
readability: "Add explanatory context to the singleton comparison table."
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #3529 +/- ##
=========================================
Coverage ? 83.25%
Complexity ? 4028
=========================================
Files ? 1060
Lines ? 14246
Branches ? 686
=========================================
Hits ? 11860
Misses ? 2102
Partials ? 284 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
What does this PR do?
Adds a comparison table to the Singleton pattern documentation to help readers understand the differences between Eager Initialization and Thread-Safe Lazy Initialization implementations.
Changes