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

Respect schema-to-asset relationship when contributing assets #4183

Merged
merged 2 commits into from
Jul 25, 2024

Conversation

nickgerace
Copy link
Contributor

@nickgerace nickgerace commented Jul 19, 2024

Description

This PR contains various changes related to respecting the one-to-one, schema-to-asset relationship that's presently in place. Normally, this PR description would be more detailed, but here is a rundown of the changes:

- Move module-related information in "app/web" to its own file in
  "api/sdf/dal/module.ts" (this is reflected in the frontend types
  crate)
- Move module syncing to the module store
- Convert ModuleExportModal to AssetContributeModal (the user domain
  language now understands _assets_ to be upgradeable, installable and
  contribute-able)
- Ensure AssetContributeModal only operates on what is passed down to
  it (avoids unnecessary computation since AssetListPanel is going to
  figure out what assets have "canContribute" set to "true" anyway)
- Reduce new contribution modal functionality to not have the ability to
  add or remove assets (I'm iffy on this one, but the "automatic")
  nature of preparing the request and the 1:1 nature of
  schemas-to-assets nudges me towards contracting and reducing failure
  modes in the interim... I'd add this with more time)
- Replace "module/export_module" with "v2/module/contribute" (we should
  consider a longer-term vision here domain wise... maybe this is all
  part of the asset concept and sdf should speak in assets?)
- Use 207 MULTI STATUS error for partial module contribution success
  when the dal is not at fault (e.g. 2 of 5 succeeded and the failures
  were only at the upload step)
- Use 502 BAD GATEWAY for total module contribution failure, but the dal
  was not at fault (e.g. 0 of 5 succeeded, but only at the upload step)
- Use 400 BAD REQUEST for malformed module contribution inpit
- Undo accidental buck2 support sync deps script commented out code
  on main
- Loosen "canContribute" constraints

@github-actions github-actions bot added A-sdf Area: Primary backend API service [Rust] A-dal A-web labels Jul 19, 2024
@nickgerace nickgerace force-pushed the nick/eng-2607 branch 2 times, most recently from 4e39eaa to c7ed13b Compare July 19, 2024 22:13
@nickgerace nickgerace force-pushed the nick/eng-2607 branch 3 times, most recently from ede4ecb to d3d8b87 Compare July 20, 2024 05:13
This commit contains various changes related to respecting the
one-to-one, schema-to-asset relationship that's presently in place.
Normally, this commit description would be more detailed, but here is a
rundown of the changes:

- Move module-related information in "app/web" to its own file in
  "api/sdf/dal/module.ts" (this is reflected in the frontend types
  crate)
- Move module syncing to the module store
- Convert ModuleExportModal to AssetContributeModal (the user domain
  language now understands _assets_ to be upgradeable, installable and
  contribute-able)
- Ensure AssetContributeModal only operates on what is passed down to
  it (avoids unnecessary computation since AssetListPanel is going to
  figure out what assets have "canContribute" set to "true" anyway)
- Reduce new contribution modal functionality to not have the ability to
  add or remove assets (I'm iffy on this one, but the "automatic")
  nature of preparing the request and the 1:1 nature of
  schemas-to-assets nudges me towards contracting and reducing failure
  modes in the interim... I'd add this with more time)
- Replace "module/export_module" with "v2/module/contribute" (we should
  consider a longer-term vision here domain wise... maybe this is all
  part of the asset concept and sdf should speak in assets?)
- Use 207 MULTI STATUS error for partial module contribution success
  when the dal is not at fault (e.g. 2 of 5 succeeded and the failures
  were only at the upload step)
- Use 502 BAD GATEWAY for total module contribution failure, but the dal
  was not at fault (e.g. 0 of 5 succeeded, but only at the upload step)
- Use 400 BAD REQUEST for malformed module contribution inpit
- Undo accidental buck2 support sync deps script commented out code
  on main
- Loosen "canContribute" constraints

Signed-off-by: Nick Gerace <[email protected]>
@stack72 stack72 marked this pull request as ready for review July 25, 2024 22:54
@stack72 stack72 added this pull request to the merge queue Jul 25, 2024
Merged via the queue into main with commit 074d5c8 Jul 25, 2024
9 checks passed
@stack72 stack72 deleted the nick/eng-2607 branch July 25, 2024 23:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-dal A-sdf Area: Primary backend API service [Rust] A-web
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants