Skip to content

[#509] Implement support for logical quotas (main) - #510

Open
korydraughn wants to merge 4 commits into
irods:mainfrom
korydraughn:509.m
Open

[#509] Implement support for logical quotas (main)#510
korydraughn wants to merge 4 commits into
irods:mainfrom
korydraughn:509.m

Conversation

@korydraughn

Copy link
Copy Markdown
Contributor

New tests pass.

All non-OIDC tests pass too.

This commit introduces a new endpoint, /logical-quotas, which supports
the following operations:

    - stat
    - set_quota
    - recalculate
Comment thread endpoints/logical_quotas/src/main.cpp Outdated
Comment on lines +144 to +147
{"max_bytes", _e.max_bytes},
{"max_objects", _e.max_objects},
{"over_bytes", _e.over_bytes},
{"over_objects", _e.over_objects}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should these names change?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

max -> maximum

and... perhaps switching the order of the 'overs'... but then sorting would not be clean.

  • bytes_over
  • objects_over

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

max -> maximum -- done.

Still thinking about the names and presentation of this data.

Comment on lines +219 to +227
const auto max_bytes_iter = _args.find("maximum-bytes");
if (max_bytes_iter != std::end(_args)) {
input.arg2 = max_bytes_iter->second.c_str();
}

const auto max_objects_iter = _args.find("maximum-objects");
if (max_objects_iter != std::end(_args)) {
input.arg3 = max_objects_iter->second.c_str();
}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should these names change?

  • maximum-bytes
  • maximum-objects

Comment thread endpoints/logical_quotas/src/main.cpp
Comment thread API.md Outdated
Comment thread API.md Outdated

@trel trel left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, a renaming of a couple things conversation should happen. otherwise, looks pretty good. i like how similar this is to the physical quotas.

Comment thread endpoints/logical_quotas/src/main.cpp Outdated
Comment on lines +144 to +147
{"max_bytes", _e.max_bytes},
{"max_objects", _e.max_objects},
{"over_bytes", _e.over_bytes},
{"over_objects", _e.over_objects}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

max -> maximum

and... perhaps switching the order of the 'overs'... but then sorting would not be clean.

  • bytes_over
  • objects_over

Comment thread endpoints/logical_quotas/src/main.cpp
Comment thread endpoints/logical_quotas/src/main.cpp
Comment thread endpoints/logical_quotas/src/main.cpp
Comment thread API.md Outdated
Comment thread test/irods_error_codes.py
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 this pull request may close these issues.

2 participants