Skip to content

Commit

Permalink
Merge pull request #14 from th2-net/rabbitmq-update-lt
Browse files Browse the repository at this point in the history
changed outdated dependency streadway/amqp:1.0.0 to rabbitmq/amqp091-go:1.9.0
  • Loading branch information
OptimumCode authored Mar 3, 2024
2 parents 61d6275 + b46cdbd commit 5b0f3e5
Show file tree
Hide file tree
Showing 11 changed files with 28 additions and 12 deletions.
9 changes: 8 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# th2 common library GO (1.0.0)
# th2 common library GO (1.2.0)

## Usage

Expand Down Expand Up @@ -90,6 +90,13 @@ The `CommonFactory` reads a message's router configuration from the `mq.json` fi

## Release notes

### 1.2.0

#### Dependencies

+ Deprecated `streadway/amqp` dependency was replaced with `rabbitmq/amqp091-go`.
NOTE: this should not be visible to end users as the MQ is only used internally.

### 1.0.0

#### Implemented:
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ require (
github.com/IGLOU-EU/go-wildcard v1.0.3
github.com/magiconair/properties v1.8.7
github.com/prometheus/client_golang v1.14.0
github.com/rabbitmq/amqp091-go v1.9.0
github.com/rs/zerolog v1.29.0
github.com/streadway/amqp v1.0.0
github.com/stretchr/testify v1.8.4
github.com/testcontainers/testcontainers-go v0.23.0
google.golang.org/grpc v1.58.0
Expand Down
13 changes: 11 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,10 @@ github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
github.com/klauspost/compress v1.16.7 h1:2mk3MPGNzKyxErAw8YaohYh69+pa4sIQSC0fPGCFR9I=
github.com/klauspost/compress v1.16.7/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE=
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
github.com/kr/pretty v0.3.0 h1:WgNl7dwNpEZ6jJ9k1snq4pZsg7DOEN8hP9Xw0Tsjwk0=
github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0VQdvPDY=
Expand Down Expand Up @@ -89,22 +92,27 @@ github.com/prometheus/common v0.42.0 h1:EKsfXEYo4JpWMHH5cg+KOUWeuJSov1Id8zGR8eeI
github.com/prometheus/common v0.42.0/go.mod h1:xBwqVerjNdUDjgODMpudtOMwlOwf2SaTr1yjz4b7Zbc=
github.com/prometheus/procfs v0.9.0 h1:wzCHvIvM5SxWqYvwgVL7yJY8Lz3PKn49KQtpgMYJfhI=
github.com/prometheus/procfs v0.9.0/go.mod h1:+pB4zwohETzFnmlpe6yd2lSc+0/46IYZRB/chUwxUZY=
github.com/rabbitmq/amqp091-go v1.9.0 h1:qrQtyzB4H8BQgEuJwhmVQqVHB9O4+MNDJCCAcpc3Aoo=
github.com/rabbitmq/amqp091-go v1.9.0/go.mod h1:+jPrT9iY2eLjRaMSRHUhc3z14E/l85kv/f+6luSD3pc=
github.com/rogpeppe/go-internal v1.8.1 h1:geMPLpDpQOgVyCg5z5GoRwLHepNdb71NXb67XFkP+Eg=
github.com/rs/xid v1.4.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg=
github.com/rs/zerolog v1.29.0 h1:Zes4hju04hjbvkVkOhdl2HpZa+0PmVwigmo8XoORE5w=
github.com/rs/zerolog v1.29.0/go.mod h1:NILgTygv/Uej1ra5XxGf82ZFSLk58MFGAUS2o6usyD0=
github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ=
github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ=
github.com/streadway/amqp v1.0.0 h1:kuuDrUJFZL1QYL9hUNuCxNObNzB0bV/ZG5jV3RWAQgo=
github.com/streadway/amqp v1.0.0/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw=
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk=
github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo=
github.com/testcontainers/testcontainers-go v0.23.0 h1:ERYTSikX01QczBLPZpqsETTBO7lInqEP349phDOVJVs=
github.com/testcontainers/testcontainers-go v0.23.0/go.mod h1:3gzuZfb7T9qfcH2pHpV4RLlWrPjeWNQah6XlYQ32c4I=
github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
go.uber.org/goleak v1.2.1 h1:NBol2c7O1ZokfZ0LEU9K6Whx/KnwvepVetCUhtKja4A=
go.uber.org/goleak v1.2.1/go.mod h1:qlT2yGI9QafXHhZZLxlSuNsMw3FFLxBr+tBRlmO1xH4=
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
Expand Down Expand Up @@ -159,6 +167,7 @@ google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQ
google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8=
google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
Expand Down
2 changes: 1 addition & 1 deletion pkg/queue/rabbitmq/internal/confirmation.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ package internal

import (
"github.com/prometheus/client_golang/prometheus"
amqp "github.com/rabbitmq/amqp091-go"
"github.com/rs/zerolog"
"github.com/streadway/amqp"
)

type DeliveryConfirmation struct {
Expand Down
2 changes: 1 addition & 1 deletion pkg/queue/rabbitmq/internal/connection/consumer.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ import (
"errors"
"github.com/prometheus/client_golang/prometheus"
"github.com/prometheus/client_golang/prometheus/promauto"
amqp "github.com/rabbitmq/amqp091-go"
"github.com/rs/zerolog"
"github.com/streadway/amqp"
"github.com/th2-net/th2-common-go/pkg/metrics"
)

Expand Down
2 changes: 1 addition & 1 deletion pkg/queue/rabbitmq/internal/connection/consumer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
package connection

import (
amqp "github.com/rabbitmq/amqp091-go"
"github.com/rs/zerolog"
"github.com/streadway/amqp"
"github.com/stretchr/testify/assert"
"github.com/th2-net/th2-common-go/test/modules/rabbitmq"
"os"
Expand Down
2 changes: 1 addition & 1 deletion pkg/queue/rabbitmq/internal/connection/publisher.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ import (

"github.com/prometheus/client_golang/prometheus"
"github.com/prometheus/client_golang/prometheus/promauto"
amqp "github.com/rabbitmq/amqp091-go"
"github.com/rs/zerolog"
"github.com/streadway/amqp"
"github.com/th2-net/th2-common-go/pkg/metrics"
)

Expand Down
2 changes: 1 addition & 1 deletion pkg/queue/rabbitmq/internal/event/subscriber.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import (
"github.com/th2-net/th2-common-go/pkg/queue/rabbitmq/internal"
"github.com/th2-net/th2-common-go/pkg/queue/rabbitmq/internal/connection"

"github.com/streadway/amqp"
amqp "github.com/rabbitmq/amqp091-go"
"github.com/th2-net/th2-common-go/pkg/metrics"
"github.com/th2-net/th2-common-go/pkg/queue/event"
"google.golang.org/protobuf/proto"
Expand Down
2 changes: 1 addition & 1 deletion pkg/queue/rabbitmq/internal/message/subscriber.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import (
"github.com/th2-net/th2-common-go/pkg/queue/rabbitmq/internal"
"github.com/th2-net/th2-common-go/pkg/queue/rabbitmq/internal/connection"

"github.com/streadway/amqp"
amqp "github.com/rabbitmq/amqp091-go"
"github.com/th2-net/th2-common-go/pkg/metrics"
"github.com/th2-net/th2-common-go/pkg/queue/message"
"google.golang.org/protobuf/proto"
Expand Down
2 changes: 1 addition & 1 deletion pkg/queue/rabbitmq/internal/subscribers.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ import (
"errors"
"fmt"
"github.com/prometheus/client_golang/prometheus"
amqp "github.com/rabbitmq/amqp091-go"
"github.com/rs/zerolog"
"github.com/streadway/amqp"
"github.com/th2-net/th2-common-go/pkg/queue"
"github.com/th2-net/th2-common-go/pkg/queue/rabbitmq/internal/connection"
"io"
Expand Down
2 changes: 1 addition & 1 deletion test/modules/rabbitmq/shared.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package rabbitmq
import (
"context"
"fmt"
"github.com/streadway/amqp"
amqp "github.com/rabbitmq/amqp091-go"
"github.com/stretchr/testify/assert"
"github.com/testcontainers/testcontainers-go"
"github.com/testcontainers/testcontainers-go/wait"
Expand Down

0 comments on commit 5b0f3e5

Please sign in to comment.