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

HonoClient is not able to refresh its access token for connections to hono components without re-create connection #647

Closed
DanielMaier-BSI opened this issue Jun 8, 2018 · 4 comments

Comments

@DanielMaier-BSI
Copy link
Contributor

Per default hono client gets disconnected from other hono components every 10 minutes with a "amqp:unauthorized-access" error because access token is expired.

This leads to undesirable behavior for users, e.g. protocol adapter reject messages with "Service Unavailable" when this happens. While "Service Unavailable" is just fine in exceptional cases, in my opinion it is not acceptable to occur on a regular basis. It is also hard to implement custom hono components with dependencies to other hono components without exposing this behavior to users.

As I understood hono client has no possibility to refresh its access token without creating a new connection. Would be great if hono client is able to refresh the access token on itself while keeping the connection alive.

What do you think about this issue? What needs to be changed to implement this?

@sophokles73
Copy link
Contributor

see #530

@DanielMaier-BSI
Copy link
Contributor Author

Great this is exactly what I need.

I close my issue because it duplicates #530.

@sophokles73
Copy link
Contributor

sophokles73 commented Jul 17, 2018

@DanielMaier-BSI A short term solution might be to set the timeout of the JWTs to a high value or to completely disable expiration (however, that would require a small code change).
Note that when connecting to enMasse, the connections will never be closed by the Dispatch Router in enMasse as well. So following my proposal would probably not make things worse ...

@DanielMaier-BSI
Copy link
Contributor Author

Hi @sophokles73 ,

we will think about your suggestion as a mid term solution. Perhaps it would be a good idea to be able to configure token expiration per user? The only difference to qdrouter endpoint I see is that the other endpoints might reveal even more sensitive data, e.g. credentials.

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

No branches or pull requests

2 participants