Skip to content

Commit

Permalink
Removed simple gogo/protobuf/proto dependencies
Browse files Browse the repository at this point in the history
As part of issue hyperledger-labs#174, replaced most dependencies of gogo/protobuf/proto with golang/protobuf/proto. The remaining occurrences reside in p2p.go and their removal requires handling of the dependency from the package gogo/protobuf/io.

Signed-off-by: Alexandros Filios <alexandros.filios@ibm.com>
  • Loading branch information
alexandrosfilios authored and mbrandenburger committed Jul 25, 2022
1 parent b91abbe commit 3234fb0
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion platform/fabric/core/generic/rwset/envelope.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ package rwset
import (
"fmt"

"github.com/gogo/protobuf/proto"
"github.com/golang/protobuf/proto"
"github.com/hyperledger/fabric-protos-go/common"
"github.com/hyperledger/fabric-protos-go/peer"
"github.com/hyperledger/fabric/protoutil"
Expand Down
2 changes: 1 addition & 1 deletion platform/fabric/core/generic/rwset/processor.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ SPDX-License-Identifier: Apache-2.0
package rwset

import (
"github.com/gogo/protobuf/proto"
"github.com/golang/protobuf/proto"
"github.com/hyperledger/fabric-protos-go/common"
"github.com/pkg/errors"

Expand Down
2 changes: 1 addition & 1 deletion platform/fabric/core/generic/transaction/envelope.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ package transaction
import (
"fmt"

"github.com/gogo/protobuf/proto"
"github.com/golang/protobuf/proto"
"github.com/hyperledger/fabric-protos-go/common"
"github.com/hyperledger/fabric-protos-go/peer"
"github.com/hyperledger/fabric/protoutil"
Expand Down
2 changes: 1 addition & 1 deletion platform/fabric/core/generic/transaction/pr.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ SPDX-License-Identifier: Apache-2.0
package transaction

import (
"github.com/gogo/protobuf/proto"
"github.com/golang/protobuf/proto"
"github.com/hyperledger/fabric-protos-go/peer"
"github.com/hyperledger/fabric/protoutil"
"github.com/pkg/errors"
Expand Down
5 changes: 2 additions & 3 deletions platform/view/services/comm/p2p.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import (
"sync/atomic"

"github.com/gogo/protobuf/io"
protoio "github.com/gogo/protobuf/io"
"github.com/gogo/protobuf/proto"
proto2 "github.com/golang/protobuf/proto"
"github.com/libp2p/go-libp2p-core/host"
Expand Down Expand Up @@ -224,8 +223,8 @@ func (p *P2PNode) Lookup(peerID string) (peer.AddrInfo, bool) {
type streamHandler struct {
lock sync.Mutex
stream network.Stream
reader protoio.ReadCloser
writer protoio.WriteCloser
reader io.ReadCloser
writer io.WriteCloser
node *P2PNode
wg sync.WaitGroup
refCtr int
Expand Down

0 comments on commit 3234fb0

Please sign in to comment.