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

Suggestion to login again with the same credential #158

Open
TheoMornicoQarnot opened this issue Apr 8, 2024 · 2 comments
Open

Suggestion to login again with the same credential #158

TheoMornicoQarnot opened this issue Apr 8, 2024 · 2 comments

Comments

@TheoMornicoQarnot
Copy link

Hello,
(First, thanks for your job)

I use this library in a service to communicate with a Redfish server, I use session for faster-processing when I have multiple commands.

But in my case, sometime I need to login again because the Redfish server close my session (no command since a long-time).

I use an extern timeout (to detect when the Redfish server close my session), but with this library implementation I need to give my credential each time. (An automatic reconnection would be a great feature for me, but I am not sure it's in this project scope)

I suppose you set username and password to null after successfully login because each time you login it's supposed there is some change in credentials ?

Anyway, I found strange you can set your credentials in constructor, use login a first time without credentials, but you need to set them again if you want login again...

Proposition

Don't set username and password to null after successful login.

@mraineri
Copy link
Contributor

I'd have to ask around about this... I find it odd too, but I wonder if the thought was along the lines of "if I'm done with the credentials, I should discard them so they're not in memory anymore".

@TheoMornicoQarnot
Copy link
Author

Yes that's my guess too, but in this case I don't think it should be possible to set theses values in the constructor.
At the moment, we find ourselves in a rather odd in-between situation. It can be set in memory during the initializer, then it's discard.

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