Skip to content

dird: status subscriptions shows more details about subscription units#989

Merged
pstorz merged 20 commits intobareos:masterfrom
alaaeddineelamri:dev/alaaeddineelamri/master/status-subscription
Dec 16, 2021
Merged

dird: status subscriptions shows more details about subscription units#989
pstorz merged 20 commits intobareos:masterfrom
alaaeddineelamri:dev/alaaeddineelamri/master/status-subscription

Conversation

@alaaeddineelamri
Copy link
Contributor

@alaaeddineelamri alaaeddineelamri commented Nov 16, 2021

Description:

This PR aims to improve the status subscriptions command and show more details to the user, as well as making it available as JSON using .api 2. Improvements were inspired from the status-subscription script solution.

Please check

  • Short description and the purpose of this PR is present above this paragraph
  • Your name is present in the AUTHORS file (optional)

If you have any questions or problems, please give a comment in the PR.

Helpful documentation and best practices

Checklist for the reviewer of the PR (will be processed by the Bareos team)

General
  • PR name is meaningful
  • Purpose of the PR is understood
  • Separate commit for this PR in the CHANGELOG.md, PR number referenced is same
  • Commit descriptions are understandable and well formatted
Source code quality
  • Source code changes are understandable
  • Variable and function names are meaningful
  • Code comments are correct (logically and spelling)
  • Required documentation changes are present and part of the PR
  • bareos-check-sources --since-merge does not report any problems
  • git status should not report modifications in the source tree after building and testing
Tests
  • Decision taken that a system- or unittest is required (if not, then remove this paragraph)
  • The decision towards a systemtest is reasonable compared to a unittest
  • Testname matches exactly what is being tested
  • Output of the test leads quickly to the origin of the fault

@alaaeddineelamri alaaeddineelamri force-pushed the dev/alaaeddineelamri/master/status-subscription branch 4 times, most recently from 3ec3432 to 07d9090 Compare November 17, 2021 17:25
@alaaeddineelamri alaaeddineelamri force-pushed the dev/alaaeddineelamri/master/status-subscription branch 4 times, most recently from 8a8d51f to d83d5d6 Compare November 23, 2021 16:06
@arogge arogge self-assigned this Nov 25, 2021
@arogge arogge added the onhold label Nov 25, 2021
@alaaeddineelamri alaaeddineelamri force-pushed the dev/alaaeddineelamri/master/status-subscription branch 2 times, most recently from 3583086 to 0201baa Compare December 6, 2021 13:57
@alaaeddineelamri alaaeddineelamri force-pushed the dev/alaaeddineelamri/master/status-subscription branch from 0201baa to 9233618 Compare December 10, 2021 12:40
bruno-at-bareos and others added 9 commits December 14, 2021 17:45
Signed-off-by: Bruno Friedmann <bruno.friedmann@bareos.com>
Add the queries to catalog dml

Signed-off-by: Bruno Friedmann <bruno.friedmann@bareos.com>
- Version 2210 include new subscription views
- Add postgresql update 2192 to 2210 sql
- Run create_queryfiles.sh
- Rename dml sql script to normalized name

Signed-off-by: Bruno Friedmann <bruno.friedmann@bareos.com>
Now displaying the data from the newly added queries
Displays correct json format when on `api 2` mode
@arogge arogge force-pushed the dev/alaaeddineelamri/master/status-subscription branch from 9233618 to dc8a306 Compare December 15, 2021 08:16
Alaa Eddine Elamri and others added 4 commits December 15, 2021 09:21
@arogge arogge force-pushed the dev/alaaeddineelamri/master/status-subscription branch from dc8a306 to 225c315 Compare December 15, 2021 08:22
* by default only a summary is shown
  * this also displays "remaining" units based on the configured
    subscriptions
* keyword "detail" shows clients/filesets
* keyword "unknown" shows uncategorized data
* keyword "all" shows a complete report
* document the new features of status subscriptions
* promote status scheduler, status subscription and status
  configuration to have their own sections
@arogge arogge force-pushed the dev/alaaeddineelamri/master/status-subscription branch 2 times, most recently from 48bae26 to 436079b Compare December 15, 2021 16:49
@arogge arogge assigned pstorz and unassigned arogge Dec 16, 2021
@pstorz pstorz self-requested a review December 16, 2021 11:24
@pstorz pstorz changed the title dird: status subscription dird: status subscriptions shows more details about subscriptions and units data Dec 16, 2021
@pstorz pstorz changed the title dird: status subscriptions shows more details about subscriptions and units data dird: status subscriptions shows more details about subscription units Dec 16, 2021
Copy link
Member

@pstorz pstorz left a comment

Choose a reason for hiding this comment

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

Minimum change in docs

@pstorz pstorz self-requested a review December 16, 2021 11:47
Copy link
Member

@pstorz pstorz left a comment

Choose a reason for hiding this comment

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

bareos-check-sources is sad about some files, I guess we will have to exclude the .txt files, right?

Plugin 'clang-format check' would modify 'core/src/dird/dird_conf.h'
Plugin 'clang-format check' would modify 'core/src/dird/ua_status.cc'
Plugin 'cmake format' would modify 'systemtests/tests/bareos/CMakeLists.txt'
Plugin 'trailing newlines' would modify 'systemtests/tests/bareos/expected/status-subscriptions-detail.txt'
Plugin 'trailing newlines' would modify 'systemtests/tests/bareos/expected/status-subscriptions.txt'

arogge and others added 5 commits December 16, 2021 13:47
Change the test system:bareos:status-subscription to check the new
status subscription command.

Also leverage fixtures in system:bareos so we only run one backup for
all tests instead of one per test.
Access to `status subscription` now requires access to the configure
command. This works just like for `status configuration`.
@pstorz pstorz force-pushed the dev/alaaeddineelamri/master/status-subscription branch from 060835d to 863a83e Compare December 16, 2021 12:48
@pstorz pstorz merged commit 238efd8 into bareos:master Dec 16, 2021
@pstorz pstorz deleted the dev/alaaeddineelamri/master/status-subscription branch December 16, 2021 12:51
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.

4 participants