-
-
Notifications
You must be signed in to change notification settings - Fork 669
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add fundamental concepts for future improvements #1385
Merged
lgrossi
merged 4 commits into
main
from
lucas/add-fundamental-concepts-for-future-improvements
Aug 13, 2023
Merged
feat: add fundamental concepts for future improvements #1385
lgrossi
merged 4 commits into
main
from
lucas/add-fundamental-concepts-for-future-improvements
Aug 13, 2023
Conversation
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
f778ca0
to
dc3e8e6
Compare
5 tasks
c822e50
to
0c63d7a
Compare
Messaging is a powerful concept that can be used to encapsulate and isolate code behaviors as commands and events. This commit introduces the concept of messaging using the eventpp library. For now the events/commands are not used, the concept will be explored further in future PRs.
Dependency Injection (DI) is a powerful technique used to decouple classes from its dependencies. This improves our ability to isolate and encapsulate code, as well as centralise and standardise the definition of dependencies. This commit introduces dependency injection using the BoostDI library and an empty template of a container, to be extended and used in future commits.
032bd42
to
1677d22
Compare
Currently we use SPDLOG for logging. However, we use SPDLOG macros directly all over the place. Although it's quite handy, it makes our code very attached to SPDLOG and hard to abstract logging away for tests and others. Aiming to improve that, we are abstracting logging into an interface ILogger and adding a SpdLog implementation of this interface. We are also defining SpdLog as the default implementation of ILogger in our DI, so that everything using DI to inject logger will always get SpdLog as default.
1677d22
to
7648476
Compare
Kudos, SonarCloud Quality Gate passed! |
beats-dh
approved these changes
Aug 13, 2023
luan
approved these changes
Aug 13, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
We have a long term plan to improve Canary code quality, including decoupling, refactoring and addition of tests. For that we could leverage some interesting concepts like dependency injection and messaging (command/events).
This PR introduces some fundaments that will be valuable for our long term plans.
Checklist