Skip to content
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

Add middleware abstraction #62

Merged
merged 17 commits into from
Jul 7, 2023
Merged

Conversation

BjoernAtBosch
Copy link
Member

@BjoernAtBosch BjoernAtBosch commented Jun 23, 2023

Describe your changes

Add first version of middleware abstraction to get rid of C++ specific configuration (e.g. environment variables)

Issue ticket number and link

tbd

Checklist - Manual tasks

  • Examples are executing successfully
  • Created/updated unit tests. Code Coverage percentage on new code shall be >= 80%.
  • Created/updated integration tests.
  • Devcontainer can be opened successfully
  • Devcontainer can be opened successfully behind a corporate proxy
  • Devcontainer can be re-built successfully
  • Extended the documentation (e.g. README.md, CONTRIBUTING.md, Velocitas)

Copy link
Contributor

@kse3hi kse3hi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

General question: who is responsible for ENV_VARIABLE definition?
What about launch.json and tasks.json, is any modification is required?
Shall SDK get values not from ENV_VARIABLES directly, but by getting them out of the application context?

sdk/include/sdk/Config.h Outdated Show resolved Hide resolved
sdk/src/sdk/middleware/DaprMiddleware.cpp Show resolved Hide resolved
sdk/src/sdk/middleware/DaprMiddleware.cpp Outdated Show resolved Hide resolved
sdk/src/sdk/middleware/DaprMiddleware.cpp Outdated Show resolved Hide resolved
@BjoernAtBosch BjoernAtBosch marked this pull request as ready for review June 30, 2023 08:42
@BjoernAtBosch BjoernAtBosch requested a review from doosuu July 3, 2023 16:28
@BjoernAtBosch
Copy link
Member Author

Answer to Serhii`s (kse3hi) general questions:

  • Who is responsible for ENV_VARIABLE definition?
    -> The definer of the runtime.
  • What about launch.json and tasks.json, is any modification is required?
    -> No modification required
  • Shall SDK get values not from ENV_VARIABLES directly, but by getting them out of the application context?
    -> You mean the app context should parse the env vars? That would mean, that every app has to take care for it and need to handle middleware specifics.
    -> We do it "same" (from user perspective) way in Python SDK.

README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
sdk/include/sdk/Config.h Outdated Show resolved Hide resolved
sdk/include/sdk/IPubSubClient.h Show resolved Hide resolved
sdk/src/sdk/middleware/DaprMiddleware.cpp Outdated Show resolved Hide resolved
sdk/src/sdk/middleware/DaprMiddleware.cpp Outdated Show resolved Hide resolved
sdk/src/sdk/middleware/NativeMiddleware.cpp Outdated Show resolved Hide resolved
sdk/tests/unit/DaprMiddleware_tests.cpp Outdated Show resolved Hide resolved
sdk/tests/unit/NativeMiddleware_tests.cpp Outdated Show resolved Hide resolved
sdk/include/sdk/IPubSubClient.h Outdated Show resolved Hide resolved
sdk/include/sdk/Utils.h Outdated Show resolved Hide resolved
sdk/include/sdk/Utils.h Outdated Show resolved Hide resolved
sdk/tests/unit/Middleware_tests.cpp Outdated Show resolved Hide resolved
sdk/tests/unit/Middleware_tests.cpp Outdated Show resolved Hide resolved
sdk/tests/unit/TestBaseUsingEnvVars.cpp Outdated Show resolved Hide resolved
sdk/tests/unit/NativeMiddleware_tests.cpp Outdated Show resolved Hide resolved
sdk/tests/unit/DaprMiddleware_tests.cpp Outdated Show resolved Hide resolved
sdk/tests/unit/DaprMiddleware_tests.cpp Outdated Show resolved Hide resolved
sdk/include/sdk/middleware/Middleware.h Outdated Show resolved Hide resolved
Copy link
Member

@doosuu doosuu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@BjoernAtBosch BjoernAtBosch merged commit 59d1bd4 into main Jul 7, 2023
@BjoernAtBosch BjoernAtBosch deleted the feature/add_middlware_abstraction branch July 7, 2023 12:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants