Skip to content

[#1134] Give a VLV row of backendstat show-index-status its Confidential cell, so that its record count lands under Record Count - #1139

Merged
vharseko merged 1 commit into
OpenIdentityPlatform:masterfrom
vharseko:issue-1134
Oct 1, 2026
Merged

vharseko merged 1 commit into
OpenIdentityPlatform:masterfrom
vharseko:issue-1134

Conversation

@vharseko

Copy link
Copy Markdown
Member

Fixes #1134

backendstat show-index-status prints 9 headings, but a VLV index row carried only 8 cells: its record count landed under Confidential, - under Record Count, and the 85% column was left empty.

Row Before After
attribute index id, name, valid, confidential, 5 stats (or 5 × -) unchanged
VLV index id, name, valid, record count, 4 × - id, name, valid, -, record count, 4 × -
  • A VLV index has no confidentiality setting (BackendVLVIndexCfg has no confidentiality-enabled, and VLVIndex keeps no crypto suite), so its Confidential cell is -, like the other columns that do not apply to it.
  • The table is now built by a package-private appendIndexStatusTable(builder, ec, undefinedKeys), split out of showIndexStatus so that a test can read the rows; showIndexStatus keeps the lookup of the entry container, the printing and the error handling. Most of the diff in BackendStat is the re-indentation of that move (git diff -w shows the change itself).
  • JDKLogging.disableLogging() moves from the BackendStat constructor to main(args, out, err), the only place the tool is constructed. The tool behaves as before; a test that constructs a BackendStat no longer resets the JDK LogManager of the whole test JVM.

Tests

PluggableBackendImplTestCase.testShowIndexStatusPutsEachCellOfAVlvRowUnderItsHeading builds the table on the live backend of the suite, which has the people VLV index, and captures it through a TablePrinter of its own. It checks that no row has an empty cell - TableBuilder.print pads a short row with "", so the size of a row alone says nothing - and that the VLV row shows - under Confidential, the record count read from the VLV tree under Record Count, and 4 × - after it.

  • Before the fix: fails with ["vlv.people", "/dc=com,dc=test/vlv.people", "true", "14", …] - the count under Confidential, the last cell empty.
  • After the fix: PDBTestCase and JETestCase 78/78 green. The JDBC and Cassandra suites inherit the test and run in CI.

The reference partial _variablelist-backendstat-index-status.adoc added by #1132 describes the Confidential column; it does not yet say that a VLV index shows - there.

…status its Confidential cell, so that its record count lands under Record Count
@vharseko vharseko added bug index Attribute/VLV index subsystem: build, trust, rebuild, confidentiality java Changes to Java sources labels Sep 30, 2026

@maximthomas maximthomas left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

praise: The fix goes into the one row that was short, and the new test fails on the old row shape in two separate ways.

  • appendStatsNoData(builder, 1) in the VLV loop of appendIndexStatusTable (opendj-server-legacy/src/main/java/org/opends/server/backends/pluggable/BackendStat.java:1098) gives the VLV row a cell under each of the 9 headings, so its record count now sits under Record Count.
  • With that line reverted, testShowIndexStatusPutsEachCellOfAVlvRowUnderItsHeading would fail on two separate assertions: the count would sit at the Confidential index (PluggableBackendImplTestCase.java:1230), and the row would carry a padded "" cell (:1216).
  • CI run 36766766642 ran the inherited case green on all 11 storage suites: Cassandra ×2, JDBC ×5 (incl. MsSql, MySql, Oracle, PgSql), JE ×2 and PDB ×2.

@vharseko
vharseko merged commit 429a25b into OpenIdentityPlatform:master Oct 1, 2026
24 checks passed
@vharseko
vharseko deleted the issue-1134 branch October 1, 2026 10:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug index Attribute/VLV index subsystem: build, trust, rebuild, confidentiality java Changes to Java sources

Projects

None yet

Development

Successfully merging this pull request may close these issues.

backendstat show-index-status: a VLV row has one cell fewer than the headings, shifting its record count under Confidential

2 participants