Skip to content

[Feature] ArangoDb Repo Metadata Only Mode #1423

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

Open
AronPerez opened this issue May 12, 2025 · 0 comments
Open

[Feature] ArangoDb Repo Metadata Only Mode #1423

AronPerez opened this issue May 12, 2025 · 0 comments
Assignees
Labels
Type: New Feature New or enhanced feature

Comments

@AronPerez
Copy link
Collaborator

AronPerez commented May 12, 2025

Problem We Want to Solve

We want to figure out how to represent a repo in ArangoDb when someone is using Metadata Mode. The Repo and User documents are nodes in the database, the allocation connects the two.

Why not have a separate allocation per repository per project?
We don't need multiple repo's.
We assume that you only need 1 repository when in Metadata mode

Describe the Solution You'd Like

Alternatives (optional)

There are 2 ways to create an alloc

  • User
  • Project

Additional context

How a repo looks in Arango

Image

Arango Queries for setting up Repo + Alloc

db._useDatabase("sdms");


db.repo.save({
    "_key" : "empty",
    "_id" : "repo/empty",
    "capacity" : 80000000000000,
    "pub_key" : "dummy_repo_key",
    "address" : "tcp://somedomain:9000",
    "endpoint" : "<endpoint UUID>",
    "path" : "/path/to/content/empty/",
    "title" : "My dummy repo",
    "desc" : "",
    "domain" : "localhost"
});

db.alloc.save({
    "_key" : "6956825",
    "_id" : "alloc/6956825",
    "_from" : "u/<someone>_username",
    "_to" : "repo/cades-test",
    "_rev" : "_iAbn6Eq--t",
    "path" : "/data/cades-test/user/<someone>_username/",
    "rec_count" : 0,
    "rec_limit" : 1000,
    "data_size" : 0,
    "data_limit" : 104857600
  })

Data Model

https://confluence.ccs.ornl.gov/pages/viewpage.action?pageId=344163314&spaceKey=DATAFED&title=STRUCTURAL%2B-%2BData%2BModel%2B1

For a Metadata only repo, only need

- title
- _id
- _key
- summary

For a metadata only repo, only need

 _from 
- _to
_ rec_limit
_ rec_count

Repo Document is touched here:
Allocation document is touched here:

  • support.js (assignRepo function)
  • support.js (verifyRepo function)
  • repo_router.js ( .post("/create"))
  • core/database/foxx/api/support.js:178

Image

@AronPerez AronPerez added the Type: New Feature New or enhanced feature label May 12, 2025
@AronPerez AronPerez self-assigned this May 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: New Feature New or enhanced feature
Projects
None yet
Development

No branches or pull requests

1 participant