Skip to content

Commit

Permalink
fix(deps): update module buf.build/gen/go/open-feature/flagd/grpc/go …
Browse files Browse the repository at this point in the history
…to v1.5.1-20240906125204-0a6a901b42e8.1 (#1400)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| buf.build/gen/go/open-feature/flagd/grpc/go |
`v1.5.1-20240215170432-1e611e2999cc.1` ->
`v1.5.1-20240906125204-0a6a901b42e8.1` |
[![age](https://developer.mend.io/api/mc/badges/age/go/buf.build%2fgen%2fgo%2fopen-feature%2fflagd%2fgrpc%2fgo/v1.5.1-20240906125204-0a6a901b42e8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/go/buf.build%2fgen%2fgo%2fopen-feature%2fflagd%2fgrpc%2fgo/v1.5.1-20240906125204-0a6a901b42e8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/go/buf.build%2fgen%2fgo%2fopen-feature%2fflagd%2fgrpc%2fgo/v1.5.1-20240215170432-1e611e2999cc.1/v1.5.1-20240906125204-0a6a901b42e8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/go/buf.build%2fgen%2fgo%2fopen-feature%2fflagd%2fgrpc%2fgo/v1.5.1-20240215170432-1e611e2999cc.1/v1.5.1-20240906125204-0a6a901b42e8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR is behind base branch, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/open-feature/flagd).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOC41OS4yIiwidXBkYXRlZEluVmVyIjoiMzguODAuMCIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->

---------

Signed-off-by: Todd Baert <[email protected]>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Todd Baert <[email protected]>
  • Loading branch information
renovate[bot] and toddbaert authored Sep 23, 2024
1 parent 94860d6 commit 954d972
Show file tree
Hide file tree
Showing 11 changed files with 44 additions and 13 deletions.
4 changes: 2 additions & 2 deletions core/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ go 1.22.0
toolchain go1.22.7

require (
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240215170432-1e611e2999cc.1
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240215170432-1e611e2999cc.2
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240906125204-0a6a901b42e8.1
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240906125204-0a6a901b42e8.2
connectrpc.com/connect v1.17.0
connectrpc.com/otelconnect v0.7.1
github.com/diegoholiveira/jsonlogic/v3 v3.5.3
Expand Down
4 changes: 4 additions & 0 deletions core/go.sum
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240215170432-1e611e2999cc.1 h1:i30n9d9zBIbLOzwsH82w7g6EOv6xtPN/byveEH9B9KQ=
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240215170432-1e611e2999cc.1/go.mod h1:aqQ1tVIXcuAslNu5a3xTSE9qvYEazL6pCZ/VLU7j1hc=
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240906125204-0a6a901b42e8.1 h1:18ZObecoJfRbNQDeuW0PoBR829Mw8FrPrmWIbbaA5hs=
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240906125204-0a6a901b42e8.1/go.mod h1:WA65xyBj+VxPfJ3a+EqdZtWGeNdwqiaQO1sriHaNL1Y=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240215170432-1e611e2999cc.2 h1:f0Zk6mcwiIZNs5pRkK8hfaE1NynStc2Z4hEnripAKTo=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240215170432-1e611e2999cc.2/go.mod h1:Y4p3/wjytMsn6a+N0geaRNEilEqj2pS3qrPqRFO5cY0=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240906125204-0a6a901b42e8.2 h1:z/+GDTJLJJjpTon7CK/pxrbwwtK7YmllO7jSTvGh0QA=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240906125204-0a6a901b42e8.2/go.mod h1:OA7of1NYh+7uttnef5AxaNjL7y1AdjLpZ4DD1a4vuZg=
cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
cloud.google.com/go v0.115.0 h1:CnFSK6Xo3lDYRoBKEcAtia6VSC837/ZkJuRduSFnr14=
cloud.google.com/go v0.115.0/go.mod h1:8jIM5vVgoAEoiVxQ/O4BFTfHqulPZgs/ufEzMcFMdWU=
Expand Down
4 changes: 2 additions & 2 deletions flagd-proxy/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ go 1.22.0
toolchain go1.22.7

require (
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240215170432-1e611e2999cc.1
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240215170432-1e611e2999cc.2
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240906125204-0a6a901b42e8.1
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240906125204-0a6a901b42e8.2
github.com/dimiro1/banner v1.1.0
github.com/mattn/go-colorable v0.1.13
github.com/open-feature/flagd/core v0.10.2
Expand Down
4 changes: 4 additions & 0 deletions flagd-proxy/go.sum
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240215170432-1e611e2999cc.1 h1:i30n9d9zBIbLOzwsH82w7g6EOv6xtPN/byveEH9B9KQ=
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240215170432-1e611e2999cc.1/go.mod h1:aqQ1tVIXcuAslNu5a3xTSE9qvYEazL6pCZ/VLU7j1hc=
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240906125204-0a6a901b42e8.1 h1:18ZObecoJfRbNQDeuW0PoBR829Mw8FrPrmWIbbaA5hs=
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240906125204-0a6a901b42e8.1/go.mod h1:WA65xyBj+VxPfJ3a+EqdZtWGeNdwqiaQO1sriHaNL1Y=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240215170432-1e611e2999cc.2 h1:f0Zk6mcwiIZNs5pRkK8hfaE1NynStc2Z4hEnripAKTo=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240215170432-1e611e2999cc.2/go.mod h1:Y4p3/wjytMsn6a+N0geaRNEilEqj2pS3qrPqRFO5cY0=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240906125204-0a6a901b42e8.2 h1:z/+GDTJLJJjpTon7CK/pxrbwwtK7YmllO7jSTvGh0QA=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240906125204-0a6a901b42e8.2/go.mod h1:OA7of1NYh+7uttnef5AxaNjL7y1AdjLpZ4DD1a4vuZg=
cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
cloud.google.com/go v0.112.1 h1:uJSeirPke5UNZHIb4SxfZklVSiWWVqW4oXlETwZziwM=
cloud.google.com/go v0.112.1/go.mod h1:+Vbu+Y1UU+I1rjmzeMOb/8RfkKJK2Gyxi1X6jJCZLo4=
Expand Down
3 changes: 3 additions & 0 deletions flagd-proxy/pkg/service/handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ type oldHandler struct {
ctx context.Context
}

//nolint:staticcheck
func (l *oldHandler) FetchAllFlags(ctx context.Context, req *syncv1.FetchAllFlagsRequest) (
*syncv1.FetchAllFlagsResponse,
error,
Expand All @@ -86,6 +87,7 @@ func (l *oldHandler) FetchAllFlags(ctx context.Context, req *syncv1.FetchAllFlag
}, nil
}

//nolint:staticcheck
func (l *oldHandler) SyncFlags(
req *syncv1.SyncFlagsRequest,
stream rpc.FlagSyncService_SyncFlagsServer,
Expand Down Expand Up @@ -114,6 +116,7 @@ func (l *oldHandler) SyncFlags(
}
}

//nolint:staticcheck
func dataSyncToGrpcState(s sync.DataSync) syncv1.SyncState {
return syncv1.SyncState(s.Type + 1)
}
5 changes: 4 additions & 1 deletion flagd-proxy/tests/loadtest/pkg/watcher/watcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,21 +15,24 @@ const (
)

type Watcher struct {
client syncv1grpc.FlagSyncServiceClient
client syncv1grpc.FlagSyncServiceClient
//nolint:staticcheck
Stream chan syncv1Types.SyncState
Ready chan struct{}
targetFile string
}

func NewWatcher(client syncv1grpc.FlagSyncServiceClient, target string) *Watcher {
return &Watcher{
//nolint:staticcheck
Stream: make(chan syncv1Types.SyncState, 1),
client: client,
Ready: make(chan struct{}),
targetFile: target,
}
}

//nolint:staticcheck
func (w *Watcher) StartWatcher(ctx context.Context) error {
stream, err := w.client.SyncFlags(ctx, &syncv1Types.SyncFlagsRequest{
Selector: fmt.Sprintf("file:%s", w.targetFile),
Expand Down
4 changes: 2 additions & 2 deletions flagd/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ toolchain go1.22.7

require (
buf.build/gen/go/open-feature/flagd/connectrpc/go v1.16.2-20240906125204-0a6a901b42e8.1
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240215170432-1e611e2999cc.1
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240215170432-1e611e2999cc.2
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240906125204-0a6a901b42e8.1
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240906125204-0a6a901b42e8.2
connectrpc.com/connect v1.17.0
github.com/dimiro1/banner v1.1.0
github.com/gorilla/mux v1.8.1
Expand Down
4 changes: 4 additions & 0 deletions flagd/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,12 @@ buf.build/gen/go/open-feature/flagd/connectrpc/go v1.16.2-20240906125204-0a6a901
buf.build/gen/go/open-feature/flagd/connectrpc/go v1.16.2-20240906125204-0a6a901b42e8.1/go.mod h1:1ZCmwepvRLrOEOv9Hto8qUGE+S0dhHqiCbDZHsG8jGk=
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240215170432-1e611e2999cc.1 h1:i30n9d9zBIbLOzwsH82w7g6EOv6xtPN/byveEH9B9KQ=
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240215170432-1e611e2999cc.1/go.mod h1:aqQ1tVIXcuAslNu5a3xTSE9qvYEazL6pCZ/VLU7j1hc=
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240906125204-0a6a901b42e8.1 h1:18ZObecoJfRbNQDeuW0PoBR829Mw8FrPrmWIbbaA5hs=
buf.build/gen/go/open-feature/flagd/grpc/go v1.5.1-20240906125204-0a6a901b42e8.1/go.mod h1:WA65xyBj+VxPfJ3a+EqdZtWGeNdwqiaQO1sriHaNL1Y=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240215170432-1e611e2999cc.2 h1:f0Zk6mcwiIZNs5pRkK8hfaE1NynStc2Z4hEnripAKTo=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240215170432-1e611e2999cc.2/go.mod h1:Y4p3/wjytMsn6a+N0geaRNEilEqj2pS3qrPqRFO5cY0=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240906125204-0a6a901b42e8.2 h1:z/+GDTJLJJjpTon7CK/pxrbwwtK7YmllO7jSTvGh0QA=
buf.build/gen/go/open-feature/flagd/protocolbuffers/go v1.34.2-20240906125204-0a6a901b42e8.2/go.mod h1:OA7of1NYh+7uttnef5AxaNjL7y1AdjLpZ4DD1a4vuZg=
cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
cloud.google.com/go v0.112.1 h1:uJSeirPke5UNZHIb4SxfZklVSiWWVqW4oXlETwZziwM=
cloud.google.com/go v0.112.1/go.mod h1:+Vbu+Y1UU+I1rjmzeMOb/8RfkKJK2Gyxi1X6jJCZLo4=
Expand Down
11 changes: 7 additions & 4 deletions flagd/pkg/service/flag-evaluation/flag_evaluator.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
//lint:file-ignore SA4003 old proto is deprecated but we want to serve it for a while

package service

import (
Expand Down Expand Up @@ -55,7 +53,7 @@ func NewOldFlagEvaluationService(log *logger.Logger,
return svc
}

// nolint:dupl,funlen
// nolint:dupl,funlen,staticcheck
func (s *OldFlagEvaluationService) ResolveAll(
ctx context.Context,
req *connect.Request[schemaV1.ResolveAllRequest],
Expand Down Expand Up @@ -126,7 +124,7 @@ func (s *OldFlagEvaluationService) ResolveAll(
return connect.NewResponse(res), nil
}

// nolint:dupl
// nolint:dupl,staticcheck
func (s *OldFlagEvaluationService) EventStream(
ctx context.Context,
req *connect.Request[schemaV1.EventStreamRequest],
Expand Down Expand Up @@ -166,6 +164,7 @@ func (s *OldFlagEvaluationService) EventStream(
}
}

//nolint:staticcheck
func (s *OldFlagEvaluationService) ResolveBoolean(
ctx context.Context,
req *connect.Request[schemaV1.ResolveBooleanRequest],
Expand All @@ -190,6 +189,7 @@ func (s *OldFlagEvaluationService) ResolveBoolean(
return res, err
}

//nolint:staticcheck
func (s *OldFlagEvaluationService) ResolveString(
ctx context.Context,
req *connect.Request[schemaV1.ResolveStringRequest],
Expand All @@ -215,6 +215,7 @@ func (s *OldFlagEvaluationService) ResolveString(
return res, err
}

//nolint:staticcheck
func (s *OldFlagEvaluationService) ResolveInt(
ctx context.Context,
req *connect.Request[schemaV1.ResolveIntRequest],
Expand All @@ -240,6 +241,7 @@ func (s *OldFlagEvaluationService) ResolveInt(
return res, err
}

//nolint:staticcheck
func (s *OldFlagEvaluationService) ResolveFloat(
ctx context.Context,
req *connect.Request[schemaV1.ResolveFloatRequest],
Expand All @@ -265,6 +267,7 @@ func (s *OldFlagEvaluationService) ResolveFloat(
return res, err
}

//nolint:staticcheck
func (s *OldFlagEvaluationService) ResolveObject(
ctx context.Context,
req *connect.Request[schemaV1.ResolveObjectRequest],
Expand Down
13 changes: 11 additions & 2 deletions flagd/pkg/service/flag-evaluation/flag_evaluator_types.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
//lint:file-ignore SA4003 old proto is deprecated but we want to serve it for a while

package service

import (
Expand All @@ -20,10 +18,12 @@ type constraints interface {
}

type booleanResponse struct {
//nolint:staticcheck
schemaV1Resp *connect.Response[schemaV1.ResolveBooleanResponse]
evalV1Resp *connect.Response[evalV1.ResolveBooleanResponse]
}

//nolint:staticcheck
func (r *booleanResponse) SetResult(value bool, variant, reason string, metadata map[string]interface{}) error {
newStruct, err := structpb.NewStruct(metadata)
if err != nil {
Expand All @@ -47,10 +47,12 @@ func (r *booleanResponse) SetResult(value bool, variant, reason string, metadata
}

type stringResponse struct {
//nolint:staticcheck
schemaV1Resp *connect.Response[schemaV1.ResolveStringResponse]
evalV1Resp *connect.Response[evalV1.ResolveStringResponse]
}

//nolint:staticcheck
func (r *stringResponse) SetResult(value string, variant, reason string, metadata map[string]interface{}) error {
newStruct, err := structpb.NewStruct(metadata)
if err != nil {
Expand All @@ -74,17 +76,20 @@ func (r *stringResponse) SetResult(value string, variant, reason string, metadat
}

type floatResponse struct {
//nolint:staticcheck
schemaV1Resp *connect.Response[schemaV1.ResolveFloatResponse]
evalV1Resp *connect.Response[evalV1.ResolveFloatResponse]
}

//nolint:staticcheck
func (r *floatResponse) SetResult(value float64, variant, reason string, metadata map[string]interface{}) error {
newStruct, err := structpb.NewStruct(metadata)
if err != nil {
return fmt.Errorf("failure to wrap metadata %w", err)
}

if r.schemaV1Resp != nil {
// nolint:staticcheck
r.schemaV1Resp.Msg.Value = value
r.schemaV1Resp.Msg.Variant = variant
r.schemaV1Resp.Msg.Reason = reason
Expand All @@ -101,10 +106,12 @@ func (r *floatResponse) SetResult(value float64, variant, reason string, metadat
}

type intResponse struct {
//nolint:staticcheck
schemaV1Resp *connect.Response[schemaV1.ResolveIntResponse]
evalV1Resp *connect.Response[evalV1.ResolveIntResponse]
}

//nolint:staticcheck
func (r *intResponse) SetResult(value int64, variant, reason string, metadata map[string]interface{}) error {
newStruct, err := structpb.NewStruct(metadata)
if err != nil {
Expand All @@ -127,10 +134,12 @@ func (r *intResponse) SetResult(value int64, variant, reason string, metadata ma
}

type objectResponse struct {
// nolint:staticcheck
schemaV1Resp *connect.Response[schemaV1.ResolveObjectResponse]
evalV1Resp *connect.Response[evalV1.ResolveObjectResponse]
}

//nolint:staticcheck
func (r *objectResponse) SetResult(value map[string]any, variant, reason string,
metadata map[string]interface{},
) error {
Expand Down
1 change: 1 addition & 0 deletions test/zero-downtime-flagd-proxy/grpc.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import (
"google.golang.org/grpc/credentials/insecure"
)

//nolint:staticcheck
func doRequests(grpcClient pb.FlagSyncServiceClient, waitSecondsBetweenRequests int) error {
ctx := context.TODO()
stream, err := grpcClient.SyncFlags(ctx, &schemav1.SyncFlagsRequest{
Expand Down

0 comments on commit 954d972

Please sign in to comment.