-
Notifications
You must be signed in to change notification settings - Fork 75
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
Unable to find SSE Notification URI #1682
Comments
Thanks for your report @wdec .We are currently having a look into this and will inform about any progress. |
We are working on https://jira.opendaylight.org/browse/NETCONF-1218 and https://jira.opendaylight.org/browse/NETCONF-1220 at the moment. After finishing they need to be integrated and tested with lighty.io codebase. |
Base path for streams was hard-coded on this enpoint: /rests/data/ietf-restconf-monitoring:restconf-state/streams This caused issues as: PANTHEONtech/lighty#1682 This patch changes this so that we get base path from uriInfo parameter. JIRA: NETCONF-1220 Change-Id: I1c57ff3f4de800a73f364d8d520bb6a82ed2c1ae Signed-off-by: tobias.pobocik <tobias.pobocik@pantheon.tech>
Base path for streams was hard-coded on this enpoint: /rests/data/ietf-restconf-monitoring:restconf-state/streams This caused issues as: PANTHEONtech/lighty#1682 This patch changes this so that we get base path from uriInfo parameter. JIRA: NETCONF-1220 Change-Id: I1c57ff3f4de800a73f364d8d520bb6a82ed2c1ae Signed-off-by: tobias.pobocik <tobias.pobocik@pantheon.tech>
Base path for streams was hard-coded on this enpoint: /rests/data/ietf-restconf-monitoring:restconf-state/streams This caused issues as: PANTHEONtech/lighty#1682 This patch changes this so that we get base path from uriInfo parameter. JIRA: NETCONF-1220 Change-Id: I1c57ff3f4de800a73f364d8d520bb6a82ed2c1ae Signed-off-by: tobias.pobocik <tobias.pobocik@pantheon.tech>
Base path for streams was hard-coded with assumption that restconf base path is always configured to be "rests". There are some users that configures different paths for restconf, for example lighty.io. This patch changes this so that we get actual base path from uriInfo parameter. See also: PANTHEONtech/lighty#1682 JIRA: NETCONF-1220 Change-Id: I1c57ff3f4de800a73f364d8d520bb6a82ed2c1ae Signed-off-by: tobias.pobocik <tobias.pobocik@pantheon.tech> Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
Base path for streams was hard-coded with assumption that restconf base path is always configured to be "rests". There are some users that configures different paths for restconf, for example lighty.io. This patch changes this so that we get actual base path from uriInfo parameter. See also: PANTHEONtech/lighty#1682 JIRA: NETCONF-1220 Change-Id: I1c57ff3f4de800a73f364d8d520bb6a82ed2c1ae Signed-off-by: tobias.pobocik <tobias.pobocik@pantheon.tech> Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech> (cherry picked from commit 7c0de75)
#1703 needs some clean-up but provides a working example how to enable /notif path in lighty. |
Hello Ivan,
I applied the restconf-nb changes to our server and the notifications are now flowing, so the fix appears to be working ok.
Side question: In the notification capabilities the “replay-support” is set to True. How does one request a replay?
Regards,
Wojciech
From: Ivan Hrasko ***@***.***>
Reply to: PANTHEONtech/lighty ***@***.***>
Date: Friday, 26 January 2024 at 14:09
To: PANTHEONtech/lighty ***@***.***>
Cc: "Wojciech Dec (wdec)" ***@***.***>, Mention ***@***.***>
Subject: Re: [PANTHEONtech/lighty] Unable to find SSE Notification URI (Issue #1682)
#1703<#1703> needs some clean-up but provides a working example how to enable /notif path in lighty.
—
Reply to this email directly, view it on GitHub<#1682 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AAGY4GD277IV7FP2YAWMNQLYQOTJLAVCNFSM6AAAAABAMNBBU2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMJSGA2DKMBVGI>.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
Fixed in version 20.0.0 (eta March 2024), 19.2.0 (eta next week) and 18.4.0 (eta March 2024). |
Describe the bug
Error 404/Not found is returned when accessing a indicated URI for a Yang defined notification stream
Branch
Seen on lighty 19.x and also the current 20 main
To Reproduce
Expected behavior
Connection to the SSE notification channel should be established.
Screenshots
GET http://localhost:8888/restconf/data/ietf-restconf-monitoring:restconf-state/streams
Returns:
{
"ietf-restconf-monitoring:streams": {
"stream": [
{
"name": "yang-library-update",
"replay-support": true,
"access": [
{
"encoding": "JSON",
"location": "http://localhost:8888/rests/notif/notification-stream/ietf-yang-library:yang-library-update/JSON"
},
{
"encoding": "XML",
"location": "http://localhost:8888/rests/notif/notification-stream/ietf-yang-library:yang-library-update"
}
],
"description": "Generated when any YANG library information on the\nserver has changed."
},
{
"name": "yang-library-change",
"replay-support": true,
"access": [
{
"encoding": "JSON",
"location": "http://localhost:8888/rests/notif/notification-stream/ietf-yang-library:yang-library-change/JSON"
},
{
"encoding": "XML",
"location": "http://localhost:8888/rests/notif/notification-stream/ietf-yang-library:yang-library-change"
}
],
"description": "Generated when the set of modules and submodules supported\nby the server has changed."
},
{
"name": "data-changed-notification",
"replay-support": true,
"access": [
{
"encoding": "JSON",
"location": "http://localhost:8888/rests/notif/notification-stream/sal-remote:data-changed-notification/JSON"
},
{
"encoding": "XML",
"location": "http://localhost:8888/rests/notif/notification-stream/sal-remote:data-changed-notification"
}
],
"description": "Data change notification."
},
{
"name": "uni-admin-status",
"replay-support": true,
"access": [
{
"encoding": "JSON",
"location": "http://localhost:8888/rests/notif/notification-stream/hco-notification:uni-admin-status/JSON"
},
{
"encoding": "XML",
"location": "http://localhost:8888/rests/notif/notification-stream/hco-notification:uni-admin-status"
}
]
}
]
}
}
GET to any of the URIs returns a 404/not found:
GET: http://localhost:8888/rests/notif/notification-stream/ietf-yang-library:yang-library-change/JSON
<title>Error 404 Not Found</title>GET http://localhost:8888/restconf/notif/notification-stream/ietf-yang-library:yang-library-change/JSON
GET http://localhost:8888/rests/notif/notification-stream/hco-notification:uni-admin-status
GET http://localhost:8888/restconf/notif/notification-stream/ietf-yang-library:yang-library-change/JSON
Environment (please complete the following information):
JVM 17
Additional context
The issue also is seen when programmatically a notification is generated.
The text was updated successfully, but these errors were encountered: