-
Notifications
You must be signed in to change notification settings - Fork 191
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
External reference for actions and status-update events #830
External reference for actions and status-update events #830
Conversation
Thanks for taking the time to contribute to hawkBit! We really appreciate this. Make yourself comfortable while I'm looking for a committer to help you with your contribution. |
...a/src/test/java/org/eclipse/hawkbit/repository/jpa/ActionStatusUpdateHandlerServiceTest.java
Outdated
Show resolved
Hide resolved
...a/src/test/java/org/eclipse/hawkbit/repository/jpa/ActionStatusUpdateHandlerServiceTest.java
Outdated
Show resolved
Hide resolved
...a/src/test/java/org/eclipse/hawkbit/repository/jpa/ActionStatusUpdateHandlerServiceTest.java
Outdated
Show resolved
Hide resolved
...a/src/test/java/org/eclipse/hawkbit/repository/jpa/ActionStatusUpdateHandlerServiceTest.java
Outdated
Show resolved
Hide resolved
...a/src/test/java/org/eclipse/hawkbit/repository/jpa/ActionStatusUpdateHandlerServiceTest.java
Outdated
Show resolved
Hide resolved
...y-jpa/src/main/java/org/eclipse/hawkbit/repository/jpa/ActionStatusUpdateHandlerService.java
Outdated
Show resolved
Hide resolved
...awkbit-repository-jpa/src/main/java/org/eclipse/hawkbit/repository/jpa/ActionRepository.java
Outdated
Show resolved
Hide resolved
...awkbit-repository-jpa/src/main/java/org/eclipse/hawkbit/repository/jpa/ActionRepository.java
Outdated
Show resolved
Hide resolved
...y-jpa/src/main/java/org/eclipse/hawkbit/repository/jpa/ActionStatusUpdateHandlerService.java
Outdated
Show resolved
Hide resolved
0952b73
to
208f894
Compare
...y-jpa/src/main/java/org/eclipse/hawkbit/repository/jpa/ActionStatusUpdateHandlerService.java
Outdated
Show resolved
Hide resolved
...a/src/test/java/org/eclipse/hawkbit/repository/jpa/ActionStatusUpdateHandlerServiceTest.java
Outdated
Show resolved
Hide resolved
...a/src/test/java/org/eclipse/hawkbit/repository/jpa/ActionStatusUpdateHandlerServiceTest.java
Outdated
Show resolved
Hide resolved
...jpa/src/main/java/org/eclipse/hawkbit/repository/jpa/RepositoryApplicationConfiguration.java
Outdated
Show resolved
Hide resolved
1a11caf
to
1bf67ae
Compare
e4d392a
to
4427214
Compare
...repository-jpa/src/main/java/org/eclipse/hawkbit/repository/jpa/JpaControllerManagement.java
Show resolved
Hide resolved
4de15b8
to
fb2a60a
Compare
It would be great if you could add the missing database migration scripts. Thanks 👍 |
ee7adfc
to
275b03d
Compare
@hawkbit-bot verify please |
@hawkbit-bot and @schabdo we have no done any changes from our previous discussion yet. |
No worries! I just consulted @hawkbit-bot for an update on this PR |
externalref will be much longer than 256 chars if controllerId is as long as 256 chars Signed-off-by: Ravindranath Sandeep (INST-IOT/ESW-Imb) <[email protected]>
Signed-off-by: Ravindranath Sandeep (INST-IOT/ESW-Imb) <[email protected]>
Signed-off-by: Ravindranath Sandeep (INST-IOT/ESW-Imb) <[email protected]>
229e259
to
3e15988
Compare
Signed-off-by: Ravindranath Sandeep (INST-IOT/ESW-Imb) <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- I have verified the migration scripts in all databases. There was an issue for sql-server which is now fixed.
- Have now added the index for externalRef.
- Added few tests in ControllerManagementTest
- Increased the size of externalRef from 256 to 512. This is because the externalRef is controllerId + ruleId-of-iot-manager. There will be cases which string is very long.
...-repository-jpa/src/main/resources/db/migration/H2/V1_12_13__add_action_external_id___H2.sql
Outdated
Show resolved
Hide resolved
...itory-jpa/src/main/resources/db/migration/MYSQL/V1_12_13__add_action_external_id___MYSQL.sql
Outdated
Show resolved
Hide resolved
...src/main/resources/db/migration/SQL_SERVER/V1_12_13__add_action_external_id___SQL_SERVER.sql
Outdated
Show resolved
Hide resolved
...awkbit-repository-api/src/main/java/org/eclipse/hawkbit/repository/ControllerManagement.java
Show resolved
Hide resolved
...awkbit-repository-api/src/main/java/org/eclipse/hawkbit/repository/ControllerManagement.java
Show resolved
Hide resolved
hawkbit-security-core/src/main/java/org/eclipse/hawkbit/security/SystemSecurityContext.java
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. Thanks Sandeep!
hawkbit-security-core/src/main/java/org/eclipse/hawkbit/security/SystemSecurityContext.java
Outdated
Show resolved
Hide resolved
hawkbit-security-core/src/main/java/org/eclipse/hawkbit/security/SystemSecurityContext.java
Outdated
Show resolved
Hide resolved
hawkbit-security-core/src/main/java/org/eclipse/hawkbit/security/SystemSecurityContext.java
Show resolved
Hide resolved
hawkbit-security-core/src/main/java/org/eclipse/hawkbit/security/SystemSecurityContext.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Ravindranath Sandeep (INST-IOT/ESW-Imb) <[email protected]>
* Add feature to listen to rollout status update * With this feature, extensions can update back the status of a given rollout using an event(containing distributionSetId and targetId). * In future, AmqpMessageHandlerService can make use of this feature and de-couple its own implementation from performing status update of an action. * Implement ActionStatusUpdateHandlerService using actionId * Extend actions to support externalRef * Update the action status using externalRef. * Update securityContext to support running a callable under specific authorities. * Fixing the review comments * Increase length of externalRef to 128 chars * Remove actionStatusUpdateEvent and the handler service * Use 256 chars for externalRef * Increment the version for migration script * Another feature had use v1_12_12 in a recent PR. So incrementing the version. * Create length limit for externalRef and add it to index * Externalref will be much longer than 256 chars if controllerId is as long as 256 chars * Adding tests for verifying externalRef in controllerManagement * Improve test to consider multiple externalRefs * Fix issue in migration script for mssql server * Fix documentation Signed-off-by: Ravindranath Sandeep (INST-IOT/ESW-Imb) <[email protected]>
This PR contains following changes:
PS:
JpaControllerManagement in master was not formatted when this PR was being created. Hence we see more differences on this file.