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 /iot/groups routes to manager #270

Closed
mapedraza opened this issue Feb 23, 2022 · 1 comment · Fixed by #342
Closed

Add /iot/groups routes to manager #270

mapedraza opened this issue Feb 23, 2022 · 1 comment · Fixed by #342

Comments

@mapedraza
Copy link
Collaborator

mapedraza commented Feb 23, 2022

When merged telefonicaid/iotagent-node-lib#1648, would be interesting to add the new alternative paths for configuring service groups to this component.

The Idea is to add the following routes:

  • POST /iot/groups -> create a new configuration group
  • GET /iot/groups -> get configuration group
  • etc.

As an alternative (additionally) to:

  • POST /iot/services -> create a new configuration group
  • GET /iot/services -> get configuration group
  • etc.

Original Issue: telefonicaid/iotagent-node-lib#752

@mapedraza mapedraza changed the title Add Add '/iot/configurations' routes to manager Feb 23, 2022
@mapedraza mapedraza changed the title Add '/iot/configurations' routes to manager Add '/iot/configGroups' routes to manager Feb 23, 2022
@mapedraza mapedraza changed the title Add '/iot/configGroups' routes to manager Add /iot/configGroups routes to manager Feb 23, 2022
@fgalan
Copy link
Member

fgalan commented Feb 23, 2022

I see two proxy alternatives:

  1. Keep the same URL in the mappings:
    • POST IOTAMan/iot/configGroups -> POST /IOTA/iot/configGroups
    • POST IOTAMan/iot/services-> POST /IOTA/iot/services
    • etc.
  2. Collapse to use always the no obsolete one at IOTA
    • POST IOTAMan/iot/configGroups -> POST IOTA/iot/configGroups
    • POST IOTAMan/iot/services-> POST IOTA/iot/configGroups
    • etc.

The second one could be complex if, apart from URL mapping, some transformation has to be done in the payload (I'm not sure but I suspects that /iot/configGroups and /iot/services use different root key in JSON payload).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants