-
Notifications
You must be signed in to change notification settings - Fork 35
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 a way to manage API keys #1136
Conversation
🤖 Meticulous spotted visual differences in 1 of 6 screens tested: view and approve differences detected. Last updated for commit b80d8d0. This comment will update as new commits are pushed. |
8c2c26d
to
ff02539
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Regarding the side bar. I don't think "ecosystem" is the right section for these settings.
API key generation should only be exposed by the UI when using authentication. It should be part of the user profile drop down on the top right.
@@ -8,7 +8,7 @@ use super::{ManagerError, ServerState}; | |||
|
|||
/// Get authentication provider configuration | |||
#[utoipa::path( | |||
path="/config/authentication", | |||
path="/../config/authentication", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this change required? This was fixed to /config/authentication
as part of #1084. ../
also looks sloppy in the API documentation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Otherwise TypeScript generates a url /v0/config/authentication for this action, which is wrong. I understand this path is relative (a subpath), hence the issue?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, now I see why you need this.
Our use of a Servers
variable is the issue: https://github.com/feldera/feldera/blob/main/crates/pipeline_manager/src/api/mod.rs#L63
I'll see if I can find a quick workaround so you don't need this change. Basically, we need the /v0
prefix only for the authenticated APIs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Karakatiza666 btw, I've been using the authentication code from the UI just fine. What workflow breaks without the relative pathing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are just using previous, correct UI code. I generated latest UI OpenAPI bindings and there this issue popped up, so I had to add '/../' to get generated code to behave as before.
I think I added this previously too, actually.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ack. I've opened #1139. See if that fixes your problem. If so, let's merge that and rebase this PR on top of it.
<br /> | ||
You will not be able to view API key secret afterwards. | ||
<br /> | ||
You should store generated API key yourself. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You will be shown the generated API key only once. You will not be able view it afterwards. Please store it securely.
ff02539
to
12d4cbe
Compare
Would it make sense to leave API keys view on the settings page and only show it when authenticated? |
12d4cbe
to
9e319bb
Compare
I'm fine with that too. |
9e319bb
to
d984509
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM from my side.
<Stack spacing={4}> | ||
{title} | ||
<Box sx={{ display: 'flex', alignItems: 'center', gap: 2 }}> | ||
<Icon270RingWithBg></Icon270RingWithBg>fetching keys... |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<Icon270RingWithBg></Icon270RingWithBg>fetching keys... | |
<Icon270RingWithBg></Icon270RingWithBg>Fetching keys... |
return ( | ||
<Stack spacing={4}> | ||
{title} | ||
No api keys generated |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No api keys generated | |
No API keys generated |
The scrollbar only appears to scroll through more than 4 keys |
@gz yes, the keys should only be accessible when auth is enabled. Authentication is the only section in settings, but only temporarily. There is no point to add code to hide the page when it will get filled with content relatively soon |
Signed-off-by: George <bulakh.96@gmail.com>
Signed-off-by: George <bulakh.96@gmail.com>
d984509
to
b80d8d0
Compare
Is this a user-visible change (yes/no): yes
Fix #1103