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

feat!: replace REST device validation callback with MessageBus #1325

Merged
merged 1 commit into from
Feb 22, 2023

Conversation

chr1shung
Copy link
Member

@chr1shung chr1shung commented Feb 15, 2023

BREAKING CHANGE: remove /validate/device REST endpoint

closes #1260

Signed-off-by: Chris Hung chris@iotechsys.com

If your build fails due to your commit message not passing the build checks, please review the guidelines here: https://github.com/edgexfoundry/device-sdk-go/blob/main/.github/Contributing.md

PR Checklist

Please check if your PR fulfills the following requirements:

  • I am not introducing a breaking change (if you are, flag in conventional commit message with BREAKING CHANGE: describing the break)
  • I am not introducing a new dependency (add notes below if you are)
  • I have added unit tests for the new feature or bug fix (if not, why?)
  • I have fully tested (add details below) this the new feature or bug fix (if not, why?)
  • I have opened a PR for the related docs change (if not, why?)

Testing Instructions

  1. Run metadata from feat(metadata)!: replace REST device validation callback with MessageBus edgex-go#4366 branch
  2. Run device-simple from this branch with DEBUG log
  3. Verify logs contains messages like:
level=INFO ts=2023-02-15T17:11:54.626303Z app=device-simple source=validation.go:29 msg="Subscribing to device validation requests on topic: edgex/device-simple/validate/device"
level=INFO ts=2023-02-15T17:11:54.626311Z app=device-simple source=validation.go:32 msg="Responses to device validation requests will be published on topic: edgex/response/device-simple/<requestId>"
level=DEBUG ts=2023-02-15T17:11:54.650768Z app=device-simple source=validation.go:58 msg="Device validation request received on message queue. Topic: edgex/device-simple/validate/device, Correlation-id: d62b5ef3-df40-47a3-a4c0-f9a33183477b"
level=DEBUG ts=2023-02-15T17:11:54.653205Z app=device-simple source=validation.go:100 msg="Device validation response published on message queue. Topic: edgex/response/device-simple/27f210de-2e8d-464f-9ea9-f00efbb3c219, Correlation-id: d62b5ef3-df40-47a3-a4c0-f9a33183477b"

New Dependency Instructions (If applicable)

@lenny-goodell
Copy link
Member

lenny-goodell commented Feb 15, 2023

@hahattan , this PR #1316 needs to be merged first so yours doesn't have all the changes that it takes care of.

@chr1shung chr1shung marked this pull request as ready for review February 15, 2023 17:17
internal/controller/messaging/validation.go Outdated Show resolved Hide resolved
pkg/service/main.go Show resolved Hide resolved
internal/controller/messaging/validation_test.go Outdated Show resolved Hide resolved
lenny-goodell
lenny-goodell previously approved these changes Feb 21, 2023
Copy link
Member

@lenny-goodell lenny-goodell left a comment

Choose a reason for hiding this comment

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

LGTM

BREAKING CHANGE: remove /validate/device REST endpoint

closes edgexfoundry#1260

Signed-off-by: Chris Hung <chris@iotechsys.com>
Copy link
Member

@lenny-goodell lenny-goodell left a comment

Choose a reason for hiding this comment

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

LGTM

@lenny-goodell lenny-goodell merged commit b7afc2a into edgexfoundry:main Feb 22, 2023
weichou1229 pushed a commit to weichou1229/device-sdk-go that referenced this pull request Mar 20, 2023
…foundry#1325)

BREAKING CHANGE: remove /validate/device REST endpoint

closes edgexfoundry#1260

Signed-off-by: Chris Hung <chris@iotechsys.com>
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.

Replace Device Validation callback with MessageBus Request/Response
2 participants