From 36184ebd2d8f40da50117e3428825b40145bc6ec Mon Sep 17 00:00:00 2001 From: erda-bot <81558540+erda-bot@users.noreply.github.com> Date: Mon, 28 Feb 2022 14:09:26 +0800 Subject: [PATCH] fix: add json tag for url field in ReleaseResource (#4177) (#4178) Co-authored-by: CMC <49681321+CraigMChen@users.noreply.github.com> --- api/proto-go/core/dicehub/release/pb/release.pb.go | 4 ++-- api/proto/core/dicehub/release/release.proto | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/api/proto-go/core/dicehub/release/pb/release.pb.go b/api/proto-go/core/dicehub/release/pb/release.pb.go index 52b555f5b0e..a4a6aa2edfd 100644 --- a/api/proto-go/core/dicehub/release/pb/release.pb.go +++ b/api/proto-go/core/dicehub/release/pb/release.pb.go @@ -315,7 +315,7 @@ type ReleaseResource struct { // Name resource name,optional, eg: init.sql/upgrade.sql Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` // URL 资源URL, 可直接wget获取到资源, 选填(当type为diceyml, 资源作为release的dice字段在mysql存储) // URL resources URL, can get by wget - URL string `protobuf:"bytes,3,opt,name=URL,proto3" json:"URL,omitempty"` + URL string `protobuf:"bytes,3,opt,name=URL,json=url,proto3" json:"URL,omitempty"` Meta map[string]*structpb.Value `protobuf:"bytes,4,rep,name=meta,proto3" json:"meta,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` } @@ -3537,7 +3537,7 @@ var file_release_proto_rawDesc = []byte{ 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x55, 0x52, 0x4c, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x55, 0x52, 0x4c, 0x12, 0x48, 0x0a, 0x04, 0x6d, 0x65, 0x74, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x72, 0x6c, 0x12, 0x48, 0x0a, 0x04, 0x6d, 0x65, 0x74, 0x61, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x34, 0x2e, 0x65, 0x72, 0x64, 0x61, 0x2e, 0x63, 0x6f, 0x72, 0x65, 0x2e, 0x64, 0x69, 0x63, 0x65, 0x68, 0x75, 0x62, 0x2e, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2e, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x52, 0x65, 0x73, 0x6f, 0x75, diff --git a/api/proto/core/dicehub/release/release.proto b/api/proto/core/dicehub/release/release.proto index a07efaffe82..3cd7e39ef8f 100644 --- a/api/proto/core/dicehub/release/release.proto +++ b/api/proto/core/dicehub/release/release.proto @@ -232,7 +232,7 @@ message ReleaseResource { // URL 资源URL, 可直接wget获取到资源, 选填(当type为diceyml, 资源作为release的dice字段在mysql存储) // URL resources URL, can get by wget - string URL = 3; + string URL = 3 [json_name = "url"]; map meta = 4; }