-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change tag in discovery service to simple lamport clock value (int) #3098
Conversation
b24f79e
to
c9c9541
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And the thing about detecting when you're forwarding to your own node.
tag_prefix varchar(5) null | ||
id varchar(200) not null primary key, | ||
-- last_timestamp is the latest lamport_timestamp pointing to the last presentation registered on the service. | ||
last_timestamp integer not null |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in discovery_presentation this is called lamport_timestamp
. Call it last_lamport_timestamp
here, or timestamp
in the other table?
discovery/api/server/api.go
Outdated
echoCtx := ctx.Value("echo.Context") | ||
if echoCtx != nil { | ||
// forward X-Forwarded-Host header via context | ||
ctx = context.WithValue(ctx, "X-Forwarded-Host", echoCtx.(echo.Context).Request().Header.Get("X-Forwarded-Host")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const
discovery/api/server/api.go
Outdated
echoCtx := ctx.Value("echo.Context") | ||
if echoCtx != nil { | ||
// forward X-Forwarded-Host header via context | ||
ctx = context.WithValue(ctx, "X-Forwarded-Host", echoCtx.(echo.Context).Request().Header.Get("X-Forwarded-Host")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you shouldn't use string values for context keys, but unexported structs (codeclimate will complain)
Co-authored-by: reinkrul <info@reinkrul.nl>
Co-authored-by: reinkrul <info@reinkrul.nl>
Co-authored-by: reinkrul <info@reinkrul.nl>
9d07e97
to
9287229
Compare
* refs/heads/master: (71 commits) Remove nonce from default Request Object params (#3125) Burn nonce type SessionStore entries after first use (#3123) Crypto: alter Storage interface to create keys inside key store (#3120) Crypto: let Exists() return an error if one occurs (#3127) Bump github.com/nats-io/nats-server/v2 from 2.10.14 to 2.10.15 (#3121) Bump github.com/nats-io/nats.go from 1.34.1 to 1.35.0 (#3122) Bump google.golang.org/grpc from 1.63.2 to 1.64.0 (#3119) Bump azure/setup-helm from 3.5 to 4 (#3050) cleanup oauth constants (#3117) prevent panic (#3118) Support request_uri_method=post (#3102) add GetAndDelete to SessionStore (#3116) bugfix: redirect browser instead of returning error when requested scope is unknown (3104) (#3113) SQL: Fix SQL Server e2e test connection strings (#3112) Docs: updated v6 release notes to include missing stuff (#3108) IAM: nil deref when re-using same user session (#3106) cleanup metadata (#3103) Docs: fixed MySql example DSN (#3110) Change tag in discovery service to simple lamport clock value (int) (#3098) e2e tests: have Nuts containers wait for DB container healthy (#3109) ... # Conflicts: # charts/nuts-node/values.yaml
closes #2955
named it
timestamp
, spec and interface explain that it's not a unix timestamp...Added forwarding of calls if a client receives Get/Register.
see nuts-foundation/nuts-specification#274 for spec changes.