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 optional name to payload of thing created message #888

Merged

Conversation

AmmarBikic
Copy link
Contributor

@AmmarBikic AmmarBikic commented Sep 19, 2019

A new optional filed "name" was added to the THING_CREATED message. It can also be used to update the name of an existing thing. Hence to that the documentation also needed to be updated.

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
…CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
…_ATTRIBUTES

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
…RIBUTES

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
…ATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
@hawkbit
Copy link

hawkbit bot commented Sep 19, 2019

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.
Please make sure you read the contribution guide and signed the Eclipse Contributor Agreement (ECA).

@schabdo schabdo added this to the 0.3.0M6 milestone Sep 19, 2019
@AmmarBikic AmmarBikic force-pushed the feature_add_optional_name_to_thing_created branch 3 times, most recently from 52e35af to 158f442 Compare September 19, 2019 09:43
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
…ATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
@Nkyn
Copy link
Contributor

Nkyn commented Oct 1, 2019

👍

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
@schabdo
Copy link
Member

schabdo commented Oct 7, 2019

The purpose of UPDATE_ATTRIBUTES message is only for updating attributes. Name is not an attribute. I would rather use THING_CREATED message for updating/changing the name by means if thingId already exists update given name. This will support both cases (name update and insert)

…ting the name property in THING_CREATED message

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
…l_name_to_thing_created

# Conflicts:
#	docs/content/apis/dmf_api.md
#	hawkbit-dmf/hawkbit-dmf-amqp/src/main/java/org/eclipse/hawkbit/amqp/AmqpMessageHandlerService.java
#	hawkbit-dmf/hawkbit-dmf-amqp/src/test/java/org/eclipse/hawkbit/amqp/AmqpMessageHandlerServiceTest.java
#	hawkbit-repository/hawkbit-repository-api/src/main/java/org/eclipse/hawkbit/repository/ControllerManagement.java
#	hawkbit-repository/hawkbit-repository-jpa/src/main/java/org/eclipse/hawkbit/repository/jpa/JpaControllerManagement.java
#	hawkbit-repository/hawkbit-repository-jpa/src/test/java/org/eclipse/hawkbit/repository/jpa/ControllerManagementTest.java
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Copy link
Contributor

@bogdan-bondar bogdan-bondar left a comment

Choose a reason for hiding this comment

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

Looks Good!

@schabdo schabdo merged commit af0f7ce into eclipse:master Oct 24, 2019
@schabdo schabdo deleted the feature_add_optional_name_to_thing_created branch October 24, 2019 10:13
@schabdo schabdo changed the title Feature add optional name to thing created Add optional name to payload of thing created message Jan 16, 2020
AmmarBikic added a commit to bosch-io/hawkbit that referenced this pull request Oct 2, 2020
* First implementation pushed because of debugging purpose

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Add name field and tests regarding name field functionality in THING_CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* SonarQube realted changes in name field functionality in THING_CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Add name field and tests regarding name field functionality in UPDATE_ATTRIBUTES

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Adapt documentation due to name field in THING_CREATED and UPDATE_ATTRIBUTES

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Add integration tests regarding name field functionality in THING_CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Reformat after finding format bug regarding THING_CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Reformat after finding the real format bug regarding THING_CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Reformat regarding THING_CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Use constant in THING_CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Format in THING_CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Resolving peer review comments regarding THING_CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Resolving peer review comments (organize imports) regarding THING_CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Refactoring regarding THING_CREATED

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Refactoring due to peer review

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Refactoring due to peer review

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Excluding UPDATE_ATTRIBUTES changes and provide functionality of updating the name property in THING_CREATED message

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Refactoring due to peer review

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Refactoring due to peer review

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Fix SonarQube finding

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Merge master into current branch

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>

* Fix peer review findings

Signed-off-by: Ammar Bikic <ammar.bikic@bosch-si.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants