Skip to content

feat: 2797 rsa bootstrap followup#2862

Open
berryware wants to merge 8 commits into
mainfrom
2797-rsa-bootstrap-followup
Open

feat: 2797 rsa bootstrap followup#2862
berryware wants to merge 8 commits into
mainfrom
2797-rsa-bootstrap-followup

Conversation

@berryware
Copy link
Copy Markdown
Contributor

@berryware berryware commented May 20, 2026

Reviewer Notes

  • replace GSON with PBJ for JSON parsing
    • null or missing strings default to empty string so need to update the tests and the plugin
  • change the RsaBootstrapPlugin to check for Node address books

Submitting these two seperately as a partial completion of #2797 as these are higher priority

Related Issue(s)

berryware added 2 commits May 20, 2026 09:32
… has been put into the pbj repo for a fix

____________________________________________________________________
Signed-off-by: berryware <[email protected]>

# Conflicts:
#	block-node/roster-bootstrap-rsa/build.gradle.kts
- remove gson from the plugin

____________________________________________________________________
Signed-off-by: berryware <[email protected]>
@berryware berryware added this to the 0.35.0 milestone May 20, 2026
@berryware berryware self-assigned this May 20, 2026
@berryware berryware added the Block Node Issues/PR related to the Block Node. label May 20, 2026
berryware added 3 commits May 20, 2026 12:45
…Node a 17 minute window to start up.

____________________________________________________________________
Signed-off-by: berryware <[email protected]>
…usly in the background

- add an executor to run the background task.
- cancel the task once an addressbook is found
- update tests to pass
- remove the test for IllegalStateException

____________________________________________________________________
Signed-off-by: berryware <[email protected]>
____________________________________________________________________
Signed-off-by: berryware <[email protected]>
@berryware berryware marked this pull request as ready for review May 20, 2026 19:42
@berryware berryware requested review from a team as code owners May 20, 2026 19:42
@codecov
Copy link
Copy Markdown

codecov Bot commented May 20, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

@@             Coverage Diff              @@
##               main    #2862      +/-   ##
============================================
+ Coverage     81.47%   81.61%   +0.13%     
- Complexity     1559     1562       +3     
============================================
  Files           144      144              
  Lines          7413     7412       -1     
  Branches        777      777              
============================================
+ Hits           6040     6049       +9     
+ Misses         1050     1039      -11     
- Partials        323      324       +1     
Files with missing lines Coverage Δ Complexity Δ
...roster/bootstrap/tss/RosterBootstrapTssConfig.java 100.00% <ø> (ø) 1.00 <0.00> (ø)
...roster/bootstrap/tss/RosterBootstrapTssPlugin.java 87.20% <100.00%> (-0.15%) 19.00 <0.00> (ø)

... and 2 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Copy Markdown
Contributor

@jsync-swirlds jsync-swirlds left a comment

Choose a reason for hiding this comment

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

A few minor items (which are not required) and a couple questions.

Comment thread block-node/roster-bootstrap-rsa/src/main/java/module-info.java
berryware and others added 3 commits May 20, 2026 17:11
…node/roster/bootstrap/rsa/RsaRosterBootstrapConfig.java

Co-authored-by: Joseph S. <[email protected]>
Signed-off-by: David Berry <[email protected]>
…node/roster/bootstrap/rsa/RsaRosterBootstrapPlugin.java

Co-authored-by: Joseph S. <[email protected]>
Signed-off-by: David Berry <[email protected]>
…node/roster/bootstrap/rsa/RsaRosterBootstrapPlugin.java

Co-authored-by: Joseph S. <[email protected]>
Signed-off-by: David Berry <[email protected]>
Copy link
Copy Markdown
Contributor

@Nana-EC Nana-EC left a comment

Choose a reason for hiding this comment

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

Nice additions

NodeAddressBook.newBuilder().nodeAddress(addresses).build();

// We found an address book stop the mirror node requests
scheduledFuture.cancel(true);
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.

nit: stop the schedule after a successful updateAddressBook call, to ensure data goes out first

Comment on lines +231 to +233
"RSA roster available: {0} entries obtained from {1}",
rosterEntriesLoaded,
addressBookSource,
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.

Suggested change
"RSA roster available: {0} entries obtained from {1}",
rosterEntriesLoaded,
addressBookSource,
"RSA roster available: {0} entries obtained from {1}",
book.nodeAddress().size(),
"Mirror Node",


start(plugin, new SimpleInMemoryHistoricalBlockFacility(), serverConfig());

latch.await();
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.

This (and others) should have a timeout

/// UncaughtExceptionHandler for logging uncaught exceptions
private void uncaughtExceptionHandler(Thread thread, Throwable throwable) {
LOGGER.log(
WARNING, "Uncaught exception in RsaRosterBootstrapPlugin thread {0}: {1}", thread.getName(), throwable);
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.

I think the throwable needs to be the trailing argument after all substitutions right?

Suggested change
WARNING, "Uncaught exception in RsaRosterBootstrapPlugin thread {0}: {1}", thread.getName(), throwable);
WARNING, "Uncaught exception in RsaRosterBootstrapPlugin thread {0}", thread.getName(), throwable);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Block Node Issues/PR related to the Block Node.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants