Skip to content

Commit

Permalink
chore: mod versions and fuse logger fix (#61)
Browse files Browse the repository at this point in the history
  • Loading branch information
jgkawell authored Jan 14, 2025
1 parent 4fe4820 commit 40df653
Show file tree
Hide file tree
Showing 9 changed files with 28 additions and 25 deletions.
6 changes: 3 additions & 3 deletions services/core/blueprint/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@ require (
github.com/google/uuid v1.6.0
github.com/hashicorp/raft v1.6.0
github.com/steady-bytes/draft/api v1.0.0
github.com/steady-bytes/draft/pkg/chassis v0.4.0
github.com/steady-bytes/draft/pkg/loggers v0.2.2
github.com/steady-bytes/draft/pkg/chassis v0.4.1
github.com/steady-bytes/draft/pkg/loggers v0.2.3
github.com/steady-bytes/draft/pkg/repositories v0.0.3
google.golang.org/grpc v1.65.0
google.golang.org/protobuf v1.34.2
)

Expand Down Expand Up @@ -59,7 +60,6 @@ require (
golang.org/x/sys v0.20.0 // indirect
golang.org/x/text v0.15.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240528184218-531527333157 // indirect
google.golang.org/grpc v1.65.0 // indirect
gopkg.in/ini.v1 v1.67.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
8 changes: 4 additions & 4 deletions services/core/blueprint/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -198,10 +198,10 @@ github.com/spf13/viper v1.18.2 h1:LUXCnvUvSM6FXAsj6nnfc8Q2tp1dIgUfY9Kc8GsSOiQ=
github.com/spf13/viper v1.18.2/go.mod h1:EKmWIqdnk5lOcmR72yw6hS+8OPYcwD0jteitLMVB+yk=
github.com/steady-bytes/draft/api v1.0.0 h1:QIvboAJgU0fBOV6BKChLMhHYIjBTR53+LJaR3w3g0NY=
github.com/steady-bytes/draft/api v1.0.0/go.mod h1:mlwxjvRiqvwySGdzVmF8voFhMffWq2F7dyd+xt6kENA=
github.com/steady-bytes/draft/pkg/chassis v0.4.0 h1:MdIlkqcL+0IY7RHIgpuoDD/Ufy/jDYm4rxT/MBKnayM=
github.com/steady-bytes/draft/pkg/chassis v0.4.0/go.mod h1:5vZ9aOPtpVqrqeWBMtcGSOUr+MauaM8ezAN5H/HYGKM=
github.com/steady-bytes/draft/pkg/loggers v0.2.2 h1:pVTfd/ES6XGLXg8WJ1xGe3YIdQJLJ6sJ6PHxVZcc4SU=
github.com/steady-bytes/draft/pkg/loggers v0.2.2/go.mod h1:nXeOQ6lXhsVWHzRqVcJz0JIeSW75ORVN+0izJwwnH+Y=
github.com/steady-bytes/draft/pkg/chassis v0.4.1 h1:ZJLaNUyxnhm8vAzvNYDus+xUarczBGNQOtwi12m2EJM=
github.com/steady-bytes/draft/pkg/chassis v0.4.1/go.mod h1:Ee6UcaJ5rJbElW7t0pgryhir3qb12rmHhHKiyrTrdxM=
github.com/steady-bytes/draft/pkg/loggers v0.2.3 h1:tZadHH8f9fo+tRHVp3BaJlVYvKlrlX8Hd6LxncUVgAM=
github.com/steady-bytes/draft/pkg/loggers v0.2.3/go.mod h1:nXeOQ6lXhsVWHzRqVcJz0JIeSW75ORVN+0izJwwnH+Y=
github.com/steady-bytes/draft/pkg/repositories v0.0.3 h1:6MyBkga27olqM42HriZZJgbyvrwSwyZDHtrkdSKMNPA=
github.com/steady-bytes/draft/pkg/repositories v0.0.3/go.mod h1:JQ4wYAwaJQKDwKaG+9bdSIIzOuroIqNzVsIx9JX99H4=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
Expand Down
6 changes: 3 additions & 3 deletions services/core/catalyst/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ module github.com/steady-bytes/draft/services/core/catalyst
go 1.23.2

require (
github.com/steady-bytes/draft/api v0.6.0
github.com/steady-bytes/draft/pkg/chassis v0.3.4
github.com/steady-bytes/draft/pkg/loggers v0.2.1
github.com/steady-bytes/draft/api v1.0.0
github.com/steady-bytes/draft/pkg/chassis v0.4.1
github.com/steady-bytes/draft/pkg/loggers v0.2.3
)

require (
Expand Down
12 changes: 6 additions & 6 deletions services/core/catalyst/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -149,12 +149,12 @@ github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA=
github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
github.com/spf13/viper v1.18.2 h1:LUXCnvUvSM6FXAsj6nnfc8Q2tp1dIgUfY9Kc8GsSOiQ=
github.com/spf13/viper v1.18.2/go.mod h1:EKmWIqdnk5lOcmR72yw6hS+8OPYcwD0jteitLMVB+yk=
github.com/steady-bytes/draft/api v0.6.0 h1:Uc5BT5xlGAQgM/p4LWlq463l67RcZlGVd1kZs99pl7E=
github.com/steady-bytes/draft/api v0.6.0/go.mod h1:mlwxjvRiqvwySGdzVmF8voFhMffWq2F7dyd+xt6kENA=
github.com/steady-bytes/draft/pkg/chassis v0.3.4 h1:93LRY7y4Z2xBDDCCDFiaMRLTNnWLqC+fr4OJ4Qy0bxo=
github.com/steady-bytes/draft/pkg/chassis v0.3.4/go.mod h1:g7JMbVINwUnvtOGpR/QKOlGK62/3rRIR0qg3++7hZUM=
github.com/steady-bytes/draft/pkg/loggers v0.2.1 h1:9ng9X87CwuFGvahuKvMTJxUoUQYzqH23EA18YNTVJH0=
github.com/steady-bytes/draft/pkg/loggers v0.2.1/go.mod h1:nXeOQ6lXhsVWHzRqVcJz0JIeSW75ORVN+0izJwwnH+Y=
github.com/steady-bytes/draft/api v1.0.0 h1:QIvboAJgU0fBOV6BKChLMhHYIjBTR53+LJaR3w3g0NY=
github.com/steady-bytes/draft/api v1.0.0/go.mod h1:mlwxjvRiqvwySGdzVmF8voFhMffWq2F7dyd+xt6kENA=
github.com/steady-bytes/draft/pkg/chassis v0.4.1 h1:ZJLaNUyxnhm8vAzvNYDus+xUarczBGNQOtwi12m2EJM=
github.com/steady-bytes/draft/pkg/chassis v0.4.1/go.mod h1:Ee6UcaJ5rJbElW7t0pgryhir3qb12rmHhHKiyrTrdxM=
github.com/steady-bytes/draft/pkg/loggers v0.2.3 h1:tZadHH8f9fo+tRHVp3BaJlVYvKlrlX8Hd6LxncUVgAM=
github.com/steady-bytes/draft/pkg/loggers v0.2.3/go.mod h1:nXeOQ6lXhsVWHzRqVcJz0JIeSW75ORVN+0izJwwnH+Y=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw=
Expand Down
5 changes: 4 additions & 1 deletion services/core/fuse/control_plane/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,12 @@ func (cp *controlPlane) LoadCache() {
func (cp *controlPlane) UpdateCacheWithNewRoute(route *ntv1.Route) error {
var (
ctx = context.Background()
logger = cp.logger.WithField("route_name", route.Name)
client = kvv1Connect.NewKeyValueServiceClient(http.DefaultClient, chassis.GetConfig().Entrypoint())
)

logger.Info("updating cache with new route")

// upsert route in the blueprint key/value store
val, err := anypb.New(route)
if err != nil {
Expand All @@ -139,7 +142,7 @@ func (cp *controlPlane) UpdateCacheWithNewRoute(route *ntv1.Route) error {

_, err = client.Set(ctx, setReq)
if err != nil {
cp.logger.Error(err.Error())
logger.Error(err.Error())
return ErrUnableToSaveRoute
}

Expand Down
2 changes: 1 addition & 1 deletion services/core/fuse/control_plane/rpc.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ func (h *rpc) AddRoute(ctx context.Context, req *connect.Request[ntv1.AddRouteRe
err error
)

logger.WithField("msg", msg).Debug(AddingRoute)
logger.WithField("msg", msg).Info(AddingRoute)

// validate incoming request
// TODO: Add validation to the proto message
Expand Down
4 changes: 2 additions & 2 deletions services/core/fuse/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ require (
github.com/envoyproxy/go-control-plane v0.12.0
github.com/google/uuid v1.6.0
github.com/steady-bytes/draft/api v1.0.0
github.com/steady-bytes/draft/pkg/chassis v0.4.0
github.com/steady-bytes/draft/pkg/loggers v0.2.1
github.com/steady-bytes/draft/pkg/chassis v0.4.1
github.com/steady-bytes/draft/pkg/loggers v0.2.3
google.golang.org/protobuf v1.34.2
)

Expand Down
8 changes: 4 additions & 4 deletions services/core/fuse/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -163,10 +163,10 @@ github.com/spf13/viper v1.18.2 h1:LUXCnvUvSM6FXAsj6nnfc8Q2tp1dIgUfY9Kc8GsSOiQ=
github.com/spf13/viper v1.18.2/go.mod h1:EKmWIqdnk5lOcmR72yw6hS+8OPYcwD0jteitLMVB+yk=
github.com/steady-bytes/draft/api v1.0.0 h1:QIvboAJgU0fBOV6BKChLMhHYIjBTR53+LJaR3w3g0NY=
github.com/steady-bytes/draft/api v1.0.0/go.mod h1:mlwxjvRiqvwySGdzVmF8voFhMffWq2F7dyd+xt6kENA=
github.com/steady-bytes/draft/pkg/chassis v0.4.0 h1:MdIlkqcL+0IY7RHIgpuoDD/Ufy/jDYm4rxT/MBKnayM=
github.com/steady-bytes/draft/pkg/chassis v0.4.0/go.mod h1:5vZ9aOPtpVqrqeWBMtcGSOUr+MauaM8ezAN5H/HYGKM=
github.com/steady-bytes/draft/pkg/loggers v0.2.1 h1:9ng9X87CwuFGvahuKvMTJxUoUQYzqH23EA18YNTVJH0=
github.com/steady-bytes/draft/pkg/loggers v0.2.1/go.mod h1:nXeOQ6lXhsVWHzRqVcJz0JIeSW75ORVN+0izJwwnH+Y=
github.com/steady-bytes/draft/pkg/chassis v0.4.1 h1:ZJLaNUyxnhm8vAzvNYDus+xUarczBGNQOtwi12m2EJM=
github.com/steady-bytes/draft/pkg/chassis v0.4.1/go.mod h1:Ee6UcaJ5rJbElW7t0pgryhir3qb12rmHhHKiyrTrdxM=
github.com/steady-bytes/draft/pkg/loggers v0.2.3 h1:tZadHH8f9fo+tRHVp3BaJlVYvKlrlX8Hd6LxncUVgAM=
github.com/steady-bytes/draft/pkg/loggers v0.2.3/go.mod h1:nXeOQ6lXhsVWHzRqVcJz0JIeSW75ORVN+0izJwwnH+Y=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw=
Expand Down
2 changes: 1 addition & 1 deletion services/core/fuse/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ func main() {
controlPlaneRPC = cp.NewRPC(logger, controlPlane)
)

defer chassis.New(zerolog.New()).
defer chassis.New(logger).
Register(chassis.RegistrationOptions{
Namespace: "fuse",
}).
Expand Down

0 comments on commit 40df653

Please sign in to comment.