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

"lookup_resource" macro should support different primary keys #847

Closed
davepacheco opened this issue Apr 1, 2022 · 1 comment · Fixed by #905
Closed

"lookup_resource" macro should support different primary keys #847

davepacheco opened this issue Apr 1, 2022 · 1 comment · Fixed by #905

Comments

@davepacheco
Copy link
Collaborator

See #845. We want the new lookup API to support a few more cases:

  • where there's a composite primary key (e.g., for built-in roles and update artifacts) and "id" is usually not present
  • where there's no "name" column (e.g., for sleds, silo users)
@davepacheco
Copy link
Collaborator Author

This winds up being kind of a blocker for ssh key support (see #849) because SiloUser does not have a name column and it doesn't really make sense for it to have one. (The closest thing would be "external id". Even if we add this, it should have a more specific name than "name" (to distinguish it from "username", "first name", "surname", etc., and so that people realize it's not the same kind of "name" that all the other resources have) and it would definitely have a different type (since "Name" is highly specific to the requirements in RFD 4).)

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

Successfully merging a pull request may close this issue.

1 participant