remove github.com/golang/protobuf/proto

This commit is contained in:
chrislu
2024-03-16 23:17:27 -07:00
parent b74e8082ba
commit 1516e0249f
3 changed files with 5 additions and 7 deletions

View File

@@ -5,8 +5,9 @@ import (
"github.com/seaweedfs/seaweedfs/weed/storage/erasure_coding"
"github.com/seaweedfs/seaweedfs/weed/storage/types"
"github.com/stretchr/testify/assert"
//"google.golang.org/protobuf/proto"
"github.com/golang/protobuf/proto"
// "google.golang.org/protobuf/proto"
//"github.com/golang/protobuf/proto"
jsonpb "google.golang.org/protobuf/encoding/protojson"
"strconv"
"strings"
"testing"
@@ -91,7 +92,7 @@ func parseOutput(output string) *master_pb.TopologyInfo {
case "volume":
volumeLine := line[len("volume "):]
volume := &master_pb.VolumeInformationMessage{}
proto.UnmarshalText(volumeLine, volume)
jsonpb.Unmarshal([]byte(volumeLine), volume)
disk.VolumeInfos = append(disk.VolumeInfos, volume)
case "ec":
ecVolumeLine := line[len("ec volume "):]