-
Notifications
You must be signed in to change notification settings - Fork 16
[DAPS-1513] Rustlike JS #1523
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
base: devel
Are you sure you want to change the base?
[DAPS-1513] Rustlike JS #1523
Conversation
1219 daps bug gitlab ci gcs log
Remove nested docs.
Add support for authz lookup
…80-refactor-authz
…80-refactor-authz
* refactor: remove system secret from http params. * refactor: remove system secret from web, from client, from scrips and from tests.
* style: Removed non helpful logs from tasks.js * style:formatted tasks.js
* style: Formatted uninstall and utils scripts
JoshuaSBrown
left a comment
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.
Please address these two items.
message: "Missing required repository fields",
@param {string} config.pub_key - Public SSH key for authentication
| * @param {string[]} config.admins - Array of admin user IDs | ||
| * @param {string} [config.endpoint] - Globus endpoint (required for GLOBUS type) | ||
| * @param {string} [config.path] - File path (required for GLOBUS type) | ||
| * @param {string} [config.pub_key] - Public SSH key (required for GLOBUS type) |
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.
This is not an ssh key, see below.
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.
* style: Formatted the install scripts Co-authored-by: Joshua S Brown <[email protected]>
* style: Formatted all remaining scripts within core * style: Formatted all remaining scripts within common * style: Formatted all scripts within compose folder * style: Formatting remaining scripts within DataFed
ac3a1f3 to
de5636b
Compare
* refactor: run docker foxx with unpriviledged user. * docs: update documentation on running foxx. * fix: add security flags to end to end runs, and add group write permissions to folders. * fix: add .gitlab contents to rules for building foxx image. * fix: make datafed.sh writable if it is leftover from Dockerfile.dependencies * fix: improve performance of docker build by scoping permission changes. * fix: add additional permissions to folders for foxx install * fix: cleanup pre existing cmake generated files. * feat: add support for https in install_foxx, as well as detection of unsafe certs. * feat: support running foxx container on OpenShift with limited permissions, and with ssl enabled. * feat: run core server container longer on startup before failing on failed database connection. * fix: prevent configuring proto files if only using foxx. * tests: add foxx setup scripts, and grant execution mode. * fix: add BUILD_WEB as part of the conditions for configuring the version.prot file. * fix: add nvm folder to set of folders that require permissions changes. * style: fix shell formatting of entrypoint_foxx and install_foxx.sh
4d1a056 to
33c787f
Compare
* [TASK] Add CI cleanup for shell and js * [TASK] Utilize https://www.conventionalcommits.org/en/v1.0.0/ for @JoshuaSBrown
This reverts commit c5c2874. Revert "[DAPS-1531] Update comments" This reverts commit 464b0f1. Revert "[DAPS-1531] Address CI" This reverts commit 4d66b75. Revert "[DAPS-1531] Object to object" This reverts commit 5c39a8d. Revert "[DAPS-1531] Address Object -> object, address copilot comments" This reverts commit ae39a84.
… Rust-Compatible js
* [DAPS-1514] Add repository validation logic with tests. Add minimal Result type for Rust-like error handling. Implement pure validation functions for repository fields. Add comprehensive unit tests for all validation functions. Register validation tests in CMake configuration * [DAPS-1514] Run prettier
33c787f to
7c755f9
Compare
Ticket
Description
This PR implements a Rust-compatible design pattern system for the DataFed repository management, preparing the codebase for eventual Rust migration while maintaining JavaScript functionality.
Key changes:
-
types.js- Type definitions and data structures-
factory.js- Type-based repository creation-
operations.js- Trait-like repository operations-
validation.js- Pure validation functions-
globus.js/metadata.js- Type-specific implementationsHow Has This Been Tested?
Unit Tests - Created repository_types.test.js covering:
Integration Tests - Created test-foxx-api.sh:
Artifacts
API Response Examples:
Test Execution Output:
Summary by Sourcery
Introduce a Rust-compatible repository type system in JavaScript by modularizing repository logic into enum-like types, trait-like operations, and composition-based factories, update the Foxx API to use the new patterns while preserving legacy compatibility, and add supporting tests, examples, and documentation to facilitate a future Rust migration.
New Features:
typefield on existing repositoriesEnhancements:
Documentation:
Tests:
Chores: