Skip to content

Register ClockSkewTimestampSample in the marshalling schema - #55235

Open
ahus1 wants to merge 1 commit into
keycloak:mainfrom
ahus1:is-54284-clock-skew-protofield
Open

ahus1 wants to merge 1 commit into
keycloak:mainfrom
ahus1:is-54284-clock-skew-protofield

Conversation

@ahus1

@ahus1 ahus1 commented Nov 16, 2026 •

Copy link
Copy Markdown
Member

Closes #55238

The class from 69527b1 is annotated with @ProtoTypeId but was never added to KeycloakModelSchema, so it was missing from the generated protobuf schema.

Decisions and assumptions:

@ahus1
ahus1 requested a review from ruchikajha95 November 16, 2026 16:18
@ahus1

ahus1 commented Nov 16, 2026

Copy link
Copy Markdown
Member Author

@ruchikajha95 - I found that some items were missing: The field numbers for Protostream should be explicitly numbered to care for eventually removed fields. Also the new Protostream object wasn't registered in the marshaller, and due to that I saw exeception once I created multiple nodes.

Thanks!

Copilot AI 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.

🟢 Approval recommended

No active review issues remain for the clock-skew sample serialization changes.

No open issues 🎉

What changed in this PR

This PR addresses #55238 by registering clock-skew samples in Keycloak’s ProtoStream schema so they can be serialized between cluster nodes.

Changes:

  • Add ClockSkewTimestampSample to KeycloakModelSchema.
  • Assign explicit protobuf field numbers to stabilize the sample’s wire format.
File Description
model/​infinispan/​src/​main/​java/​org/​keycloak/​marshalling/​KeycloakModelSchema.java Include clock-skew samples in the generated marshalling schema.
model/​infinispan/​src/​main/​java/​org/​keycloak/​cluster/​infinispan/​ClockSkewTimestampSample.java Explicitly number the node-name and timestamp fields.

Review effort: Balanced

@ruchikajha95 ruchikajha95 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.

LGTM . Thanks @ahus1 for the PR.

@ahus1
ahus1 marked this pull request as ready for review November 17, 2026 12:25
@ahus1
ahus1 requested review from a team as code owners November 17, 2026 12:25
Closes keycloak#55238

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Signed-off-by: Alexander Schwartz <alexander.schwartz@ibm.com>
@ahus1
ahus1 force-pushed the is-54284-clock-skew-protofield branch from a733f3f to df3331a Compare November 17, 2026 12:30
Copilot AI balanced review requested due to automatic review settings November 17, 2026 12:30

Copilot AI 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.

🟡 Changes recommended

The local-cache test passes even without the registration, so a production-schema ProtoStream round-trip regression test is needed to verify that both ClockSkewTimestampSample components survive serialization.

1 open issue

Review effort: Balanced

Copilot AI 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.

🟢 Approval recommended

No active review issues were identified for the clock-skew sample serialization changes.

No open issues 🎉

1 resolved since last review

Review effort: Balanced

@ahus1
ahus1 requested a review from ruchikajha95 November 17, 2026 12:49

@ruchikajha95 ruchikajha95 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.

Approving again after rebase. Thanks @ahus1

@ahus1
ahus1 enabled auto-merge (squash) November 17, 2026 18:36
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.

ClockSkewTimestampSample is missing from the ProtoStream schema

3 participants