Skip to content
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

feat: retry crdb serializable errors #3895

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ replace github.com/gobuffalo/pop/v6 => github.com/ory/pop/v6 v6.2.0
//
// This is needed until we release the next version of the master branch, as that branch already contains the redirect URI validation fix, which
// may be breaking for some users.
replace github.com/ory/fosite => github.com/ory/fosite v0.47.1-0.20241101073333-eab241e153a4
replace github.com/ory/fosite => github.com/ory/fosite v0.47.1-0.20241125094724-b6468e644902

require (
github.com/ThalesIgnite/crypto11 v1.2.5
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -378,8 +378,8 @@ github.com/ory/analytics-go/v5 v5.0.1 h1:LX8T5B9FN8KZXOtxgN+R3I4THRRVB6+28IKgKBp
github.com/ory/analytics-go/v5 v5.0.1/go.mod h1:lWCiCjAaJkKfgR/BN5DCLMol8BjKS1x+4jxBxff/FF0=
github.com/ory/dockertest/v3 v3.10.1-0.20240704115616-d229e74b748d h1:By96ZSVuH5LyjXLVVMfvJoLVGHaT96LdOnwgFSLVf0E=
github.com/ory/dockertest/v3 v3.10.1-0.20240704115616-d229e74b748d/go.mod h1:F2FIjwwAk6CsNAs//B8+aPFQF0t84pbM8oliyNXwQrk=
github.com/ory/fosite v0.47.1-0.20241101073333-eab241e153a4 h1:1pEVHGC+Dx2xMPMgpRgG3lyejyK8iU9KKfSnLowLYd8=
github.com/ory/fosite v0.47.1-0.20241101073333-eab241e153a4/go.mod h1:AZyn1jrABUaGN12RHcWorRLbqLn52gTdHaIYY81m5J0=
github.com/ory/fosite v0.47.1-0.20241125094724-b6468e644902 h1:X0ngo+uPWCw90ueY3Kh6q8IyF2fbwkJ8bf9RvAmD71U=
github.com/ory/fosite v0.47.1-0.20241125094724-b6468e644902/go.mod h1:AZyn1jrABUaGN12RHcWorRLbqLn52gTdHaIYY81m5J0=
github.com/ory/go-acc v0.2.9-0.20230103102148-6b1c9a70dbbe h1:rvu4obdvqR0fkSIJ8IfgzKOWwZ5kOT2UNfLq81Qk7rc=
github.com/ory/go-acc v0.2.9-0.20230103102148-6b1c9a70dbbe/go.mod h1:z4n3u6as84LbV4YmgjHhnwtccQqzf4cZlSk9f1FhygI=
github.com/ory/go-convenience v0.1.0 h1:zouLKfF2GoSGnJwGq+PE/nJAE6dj2Zj5QlTgmMTsTS8=
Expand Down
12 changes: 4 additions & 8 deletions oauth2/fosite_store_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import (
"github.com/ory/hydra/v2/internal"
. "github.com/ory/hydra/v2/oauth2"
"github.com/ory/x/contextx"
"github.com/ory/x/networkx"
"github.com/ory/x/sqlcon/dockertest"
)

Expand Down Expand Up @@ -72,14 +71,11 @@ func TestManagers(t *testing.T) {

require.NoError(t, registries["memory"].ClientManager().CreateClient(context.Background(), &client.Client{ID: "foobar"})) // this is a workaround because the client is not being created for memory store by test helpers.

for k, store := range registries {
net := &networkx.Network{}
require.NoError(t, store.Persister().Connection(context.Background()).First(net))
store.Config().MustSet(ctx, config.KeyEncryptSessionData, tc.enableSessionEncrypted)
store.WithContextualizer(&contextx.Static{NID: net.ID, C: store.Config().Source(ctx)})
TestHelperRunner(t, store, k)
for k, _ := range registries {
reg := internal.NewRegistrySQLFromURL(t, registries[k].Config().DSN(), true, &contextx.Default{})
reg.Config().MustSet(ctx, config.KeyEncryptSessionData, tc.enableSessionEncrypted)
TestHelperRunner(t, reg, k)
}
})

}
}
Loading
Loading