Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
canifa_note
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Vũ Hoàng Anh
canifa_note
Commits
16d3de63
Commit
16d3de63
authored
May 21, 2024
by
Steven
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
chore: update resource binary endpoint
parent
2c50d346
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
152 additions
and
112 deletions
+152
-112
apidocs.swagger.yaml
docs/apidocs.swagger.yaml
+30
-25
resource_service.proto
proto/api/v1/resource_service.proto
+5
-2
resource_service.pb.go
proto/gen/api/v1/resource_service.pb.go
+92
-80
resource_service.pb.gw.go
proto/gen/api/v1/resource_service.pb.gw.go
+23
-3
rss.go
server/router/rss/rss.go
+1
-1
resource.ts
web/src/utils/resource.ts
+1
-1
No files found.
docs/apidocs.swagger.yaml
View file @
16d3de63
...
@@ -1736,31 +1736,6 @@ paths:
...
@@ -1736,31 +1736,6 @@ paths:
format
:
date-time
format
:
date-time
tags
:
tags
:
-
UserService
-
UserService
/file/{name}
:
get
:
summary
:
GetResourceBinary returns a resource binary by name.
operationId
:
ResourceService_GetResourceBinary
responses
:
"
200"
:
description
:
A successful response.
schema
:
$ref
:
'
#/definitions/apiHttpBody'
default
:
description
:
An unexpected error response.
schema
:
$ref
:
'
#/definitions/googlerpcStatus'
parameters
:
-
name
:
name
description
:
|-
The name of the resource.
Format: resources/{id}
id is the system generated unique identifier.
in: path
required: true
type: string
pattern: resources/[^/]+
tags
:
-
ResourceService
/file/{name}/avatar
:
/file/{name}/avatar
:
get
:
get
:
summary
:
GetUserAvatarBinary gets the avatar of a user.
summary
:
GetUserAvatarBinary gets the avatar of a user.
...
@@ -1796,6 +1771,36 @@ paths:
...
@@ -1796,6 +1771,36 @@ paths:
format
:
byte
format
:
byte
tags
:
tags
:
-
UserService
-
UserService
/file/{name}/{filename}
:
get
:
summary
:
GetResourceBinary returns a resource binary by name.
operationId
:
ResourceService_GetResourceBinary
responses
:
"
200"
:
description
:
A successful response.
schema
:
$ref
:
'
#/definitions/apiHttpBody'
default
:
description
:
An unexpected error response.
schema
:
$ref
:
'
#/definitions/googlerpcStatus'
parameters
:
-
name
:
name
description
:
|-
The name of the resource.
Format: resources/{id}
id is the system generated unique identifier.
in: path
required: true
type: string
pattern: resources/[^/]+
-
name
:
filename
description
:
The filename of the resource. Mainly used for downloading.
in
:
path
required
:
true
type
:
string
tags
:
-
ResourceService
definitions
:
definitions
:
MemoServiceRebuildMemoPropertyBody
:
MemoServiceRebuildMemoPropertyBody
:
type
:
object
type
:
object
...
...
proto/api/v1/resource_service.proto
View file @
16d3de63
...
@@ -35,8 +35,8 @@ service ResourceService {
...
@@ -35,8 +35,8 @@ service ResourceService {
}
}
// GetResourceBinary returns a resource binary by name.
// GetResourceBinary returns a resource binary by name.
rpc
GetResourceBinary
(
GetResourceBinaryRequest
)
returns
(
google.api.HttpBody
)
{
rpc
GetResourceBinary
(
GetResourceBinaryRequest
)
returns
(
google.api.HttpBody
)
{
option
(
google.api.http
)
=
{
get
:
"/file/{name=resources/*}"
};
option
(
google.api.http
)
=
{
get
:
"/file/{name=resources/*}
/{filename}
"
};
option
(
google.api.method_signature
)
=
"name"
;
option
(
google.api.method_signature
)
=
"name
,filename
"
;
}
}
// UpdateResource updates a resource.
// UpdateResource updates a resource.
rpc
UpdateResource
(
UpdateResourceRequest
)
returns
(
Resource
)
{
rpc
UpdateResource
(
UpdateResourceRequest
)
returns
(
Resource
)
{
...
@@ -109,6 +109,9 @@ message GetResourceBinaryRequest {
...
@@ -109,6 +109,9 @@ message GetResourceBinaryRequest {
// Format: resources/{id}
// Format: resources/{id}
// id is the system generated unique identifier.
// id is the system generated unique identifier.
string
name
=
1
;
string
name
=
1
;
// The filename of the resource. Mainly used for downloading.
string
filename
=
2
;
}
}
message
UpdateResourceRequest
{
message
UpdateResourceRequest
{
...
...
proto/gen/api/v1/resource_service.pb.go
View file @
16d3de63
...
@@ -427,6 +427,8 @@ type GetResourceBinaryRequest struct {
...
@@ -427,6 +427,8 @@ type GetResourceBinaryRequest struct {
// Format: resources/{id}
// Format: resources/{id}
// id is the system generated unique identifier.
// id is the system generated unique identifier.
Name
string
`protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
Name
string
`protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// The filename of the resource. Mainly used for downloading.
Filename
string
`protobuf:"bytes,2,opt,name=filename,proto3" json:"filename,omitempty"`
}
}
func
(
x
*
GetResourceBinaryRequest
)
Reset
()
{
func
(
x
*
GetResourceBinaryRequest
)
Reset
()
{
...
@@ -468,6 +470,13 @@ func (x *GetResourceBinaryRequest) GetName() string {
...
@@ -468,6 +470,13 @@ func (x *GetResourceBinaryRequest) GetName() string {
return
""
return
""
}
}
func
(
x
*
GetResourceBinaryRequest
)
GetFilename
()
string
{
if
x
!=
nil
{
return
x
.
Filename
}
return
""
}
type
UpdateResourceRequest
struct
{
type
UpdateResourceRequest
struct
{
state
protoimpl
.
MessageState
state
protoimpl
.
MessageState
sizeCache
protoimpl
.
SizeCache
sizeCache
protoimpl
.
SizeCache
...
@@ -632,89 +641,92 @@ var file_api_v1_resource_service_proto_rawDesc = []byte{
...
@@ -632,89 +641,92 @@ var file_api_v1_resource_service_proto_rawDesc = []byte{
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x22
,
0x28
,
0x0a
,
0x12
,
0x47
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x22
,
0x28
,
0x0a
,
0x12
,
0x47
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x12
,
0x12
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x12
,
0x12
,
0x0a
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x09
,
0x52
,
0x04
,
0x6e
,
0x61
,
0x0a
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x09
,
0x52
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x22
,
0x
2e
,
0x0a
,
0x18
,
0x47
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x6d
,
0x65
,
0x22
,
0x
4a
,
0x0a
,
0x18
,
0x47
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x42
,
0x69
,
0x6e
,
0x61
,
0x72
,
0x79
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x12
,
0x12
,
0x65
,
0x42
,
0x69
,
0x6e
,
0x61
,
0x72
,
0x79
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x12
,
0x12
,
0x0a
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x09
,
0x52
,
0x04
,
0x6e
,
0x61
,
0x0a
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x09
,
0x52
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x22
,
0x88
,
0x01
,
0x0a
,
0x15
,
0x55
,
0x70
,
0x64
,
0x61
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6d
,
0x65
,
0x12
,
0x1a
,
0x0a
,
0x08
,
0x66
,
0x69
,
0x6c
,
0x65
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x18
,
0x02
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x12
,
0x32
,
0x0a
,
0x08
,
0x20
,
0x01
,
0x28
,
0x09
,
0x52
,
0x08
,
0x66
,
0x69
,
0x6c
,
0x65
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x22
,
0x88
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x0b
,
0x32
,
0x16
,
0x01
,
0x0a
,
0x15
,
0x55
,
0x70
,
0x64
,
0x61
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x52
,
0x65
,
0x65
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x12
,
0x32
,
0x0a
,
0x08
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x08
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x75
,
0x72
,
0x63
,
0x65
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x0b
,
0x32
,
0x16
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x12
,
0x3b
,
0x0a
,
0x0b
,
0x75
,
0x70
,
0x64
,
0x61
,
0x74
,
0x65
,
0x5f
,
0x6d
,
0x61
,
0x73
,
0x6b
,
0x18
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x02
,
0x20
,
0x01
,
0x28
,
0x0b
,
0x32
,
0x1a
,
0x2e
,
0x67
,
0x6f
,
0x6f
,
0x67
,
0x6c
,
0x65
,
0x2e
,
0x70
,
0x63
,
0x65
,
0x52
,
0x08
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x12
,
0x3b
,
0x0a
,
0x0b
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x62
,
0x75
,
0x66
,
0x2e
,
0x46
,
0x69
,
0x65
,
0x6c
,
0x64
,
0x4d
,
0x61
,
0x73
,
0x75
,
0x70
,
0x64
,
0x61
,
0x74
,
0x65
,
0x5f
,
0x6d
,
0x61
,
0x73
,
0x6b
,
0x18
,
0x02
,
0x20
,
0x01
,
0x28
,
0x6b
,
0x52
,
0x0a
,
0x75
,
0x70
,
0x64
,
0x61
,
0x74
,
0x65
,
0x4d
,
0x61
,
0x73
,
0x6b
,
0x22
,
0x2b
,
0x0a
,
0x0b
,
0x32
,
0x1a
,
0x2e
,
0x67
,
0x6f
,
0x6f
,
0x67
,
0x6c
,
0x65
,
0x2e
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x15
,
0x44
,
0x65
,
0x6c
,
0x65
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x62
,
0x75
,
0x66
,
0x2e
,
0x46
,
0x69
,
0x65
,
0x6c
,
0x64
,
0x4d
,
0x61
,
0x73
,
0x6b
,
0x52
,
0x0a
,
0x75
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x12
,
0x12
,
0x0a
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x18
,
0x01
,
0x70
,
0x64
,
0x61
,
0x74
,
0x65
,
0x4d
,
0x61
,
0x73
,
0x6b
,
0x22
,
0x2b
,
0x0a
,
0x15
,
0x44
,
0x65
,
0x6c
,
0x20
,
0x01
,
0x28
,
0x09
,
0x52
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x32
,
0x85
,
0x07
,
0x0a
,
0x0f
,
0x52
,
0x65
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x53
,
0x65
,
0x72
,
0x76
,
0x69
,
0x63
,
0x65
,
0x12
,
0x72
,
0x73
,
0x74
,
0x12
,
0x12
,
0x0a
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x18
,
0x01
,
0x20
,
0x01
,
0x28
,
0x09
,
0x0a
,
0x0e
,
0x43
,
0x72
,
0x65
,
0x61
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x32
,
0x9a
,
0x07
,
0x0a
,
0x0f
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x12
,
0x23
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x72
,
0x63
,
0x65
,
0x53
,
0x65
,
0x72
,
0x76
,
0x69
,
0x63
,
0x65
,
0x12
,
0x72
,
0x0a
,
0x0e
,
0x43
,
0x72
,
0x43
,
0x72
,
0x65
,
0x61
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x65
,
0x65
,
0x61
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x12
,
0x23
,
0x2e
,
0x6d
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x16
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x43
,
0x72
,
0x65
,
0x61
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x22
,
0x23
,
0x82
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x1d
,
0x3a
,
0x08
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x22
,
0x74
,
0x1a
,
0x16
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x11
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x2e
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x22
,
0x23
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x65
,
0x73
,
0x12
,
0x73
,
0x0a
,
0x0d
,
0x4c
,
0x69
,
0x73
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x1d
,
0x3a
,
0x08
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x22
,
0x11
,
0x2f
,
0x61
,
0x70
,
0x63
,
0x65
,
0x73
,
0x12
,
0x22
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x12
,
0x73
,
0x0a
,
0x0d
,
0x4c
,
0x69
,
0x73
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x12
,
0x22
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x4c
,
0x69
,
0x73
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x23
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x4c
,
0x69
,
0x73
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x76
,
0x31
,
0x2e
,
0x4c
,
0x69
,
0x73
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x23
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x52
,
0x65
,
0x73
,
0x70
,
0x6f
,
0x6e
,
0x73
,
0x65
,
0x22
,
0x19
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x13
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x4c
,
0x69
,
0x73
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x12
,
0x11
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x72
,
0x63
,
0x65
,
0x73
,
0x52
,
0x65
,
0x73
,
0x70
,
0x6f
,
0x6e
,
0x73
,
0x65
,
0x22
,
0x19
,
0x82
,
0xd3
,
0x63
,
0x65
,
0x73
,
0x12
,
0x80
,
0x01
,
0x0a
,
0x0f
,
0x53
,
0x65
,
0x61
,
0x72
,
0x63
,
0x68
,
0x52
,
0x65
,
0xe4
,
0x93
,
0x02
,
0x13
,
0x12
,
0x11
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x12
,
0x24
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x12
,
0x80
,
0x01
,
0x0a
,
0x0f
,
0x53
,
0x65
,
0x61
,
0x72
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x53
,
0x65
,
0x61
,
0x72
,
0x63
,
0x68
,
0x52
,
0x65
,
0x73
,
0x63
,
0x68
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x12
,
0x24
,
0x2e
,
0x6d
,
0x65
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x25
,
0x2e
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x53
,
0x65
,
0x61
,
0x72
,
0x63
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x53
,
0x65
,
0x61
,
0x68
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x72
,
0x63
,
0x68
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x52
,
0x65
,
0x73
,
0x70
,
0x74
,
0x1a
,
0x25
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x6f
,
0x6e
,
0x73
,
0x65
,
0x22
,
0x20
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x1a
,
0x12
,
0x18
,
0x2f
,
0x61
,
0x2e
,
0x53
,
0x65
,
0x61
,
0x72
,
0x63
,
0x68
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x3a
,
0x52
,
0x65
,
0x73
,
0x70
,
0x6f
,
0x6e
,
0x73
,
0x65
,
0x22
,
0x20
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x1a
,
0x73
,
0x65
,
0x61
,
0x72
,
0x63
,
0x68
,
0x12
,
0x72
,
0x0a
,
0x0b
,
0x47
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x12
,
0x18
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x12
,
0x20
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x63
,
0x65
,
0x73
,
0x3a
,
0x73
,
0x65
,
0x61
,
0x72
,
0x63
,
0x68
,
0x12
,
0x72
,
0x0a
,
0x0b
,
0x47
,
0x65
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x47
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x12
,
0x20
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x16
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x47
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x22
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x16
,
0x2e
,
0x6d
,
0x65
,
0x29
,
0xda
,
0x41
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x1c
,
0x12
,
0x1a
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x7b
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x3d
,
0x72
,
0x65
,
0x72
,
0x63
,
0x65
,
0x22
,
0x29
,
0xda
,
0x41
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x2f
,
0x2a
,
0x7d
,
0x12
,
0x8e
,
0x01
,
0x0a
,
0x11
,
0x47
,
0x02
,
0x1c
,
0x12
,
0x1a
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x7b
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x42
,
0x69
,
0x6e
,
0x61
,
0x72
,
0x79
,
0x65
,
0x3d
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x2f
,
0x2a
,
0x7d
,
0x12
,
0x7a
,
0x12
,
0x26
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x0a
,
0x11
,
0x47
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x42
,
0x69
,
0x6e
,
0x47
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x42
,
0x69
,
0x6e
,
0x61
,
0x72
,
0x61
,
0x72
,
0x79
,
0x12
,
0x26
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x79
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x14
,
0x2e
,
0x67
,
0x6f
,
0x6f
,
0x67
,
0x6c
,
0x76
,
0x31
,
0x2e
,
0x47
,
0x65
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x42
,
0x69
,
0x65
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x48
,
0x74
,
0x74
,
0x70
,
0x42
,
0x6f
,
0x64
,
0x79
,
0x22
,
0x3b
,
0x6e
,
0x61
,
0x72
,
0x79
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x14
,
0x2e
,
0x67
,
0x6f
,
0xda
,
0x41
,
0x0d
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x2c
,
0x66
,
0x69
,
0x6c
,
0x65
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x6f
,
0x67
,
0x6c
,
0x65
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x48
,
0x74
,
0x74
,
0x70
,
0x42
,
0x6f
,
0x64
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x25
,
0x12
,
0x23
,
0x2f
,
0x66
,
0x69
,
0x6c
,
0x65
,
0x2f
,
0x7b
,
0x6e
,
0x79
,
0x22
,
0x27
,
0xda
,
0x41
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x1a
,
0x61
,
0x6d
,
0x65
,
0x3d
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x2f
,
0x2a
,
0x7d
,
0x12
,
0x18
,
0x2f
,
0x66
,
0x69
,
0x6c
,
0x65
,
0x2f
,
0x7b
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x3d
,
0x72
,
0x65
,
0x2f
,
0x7b
,
0x66
,
0x69
,
0x6c
,
0x65
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x7d
,
0x12
,
0x9b
,
0x01
,
0x0a
,
0x0e
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x2f
,
0x2a
,
0x7d
,
0x12
,
0x9b
,
0x01
,
0x0a
,
0x0e
,
0x55
,
0x55
,
0x70
,
0x64
,
0x61
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x12
,
0x23
,
0x70
,
0x64
,
0x61
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x12
,
0x23
,
0x2e
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x55
,
0x70
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x55
,
0x70
,
0x64
,
0x64
,
0x61
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x65
,
0x71
,
0x75
,
0x61
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x16
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x73
,
0x74
,
0x1a
,
0x16
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x76
,
0x31
,
0x2e
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x22
,
0x4c
,
0xda
,
0x41
,
0x14
,
0x31
,
0x2e
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x22
,
0x4c
,
0xda
,
0x41
,
0x14
,
0x72
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x2c
,
0x75
,
0x70
,
0x64
,
0x61
,
0x74
,
0x65
,
0x5f
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x2c
,
0x75
,
0x70
,
0x64
,
0x61
,
0x74
,
0x65
,
0x5f
,
0x6d
,
0x6d
,
0x61
,
0x73
,
0x6b
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x2f
,
0x3a
,
0x08
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x61
,
0x73
,
0x6b
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x2f
,
0x3a
,
0x08
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x75
,
0x72
,
0x63
,
0x65
,
0x32
,
0x23
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x7b
,
0x72
,
0x72
,
0x63
,
0x65
,
0x32
,
0x23
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x7b
,
0x72
,
0x65
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x2e
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x3d
,
0x72
,
0x65
,
0x73
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x2e
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x3d
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x2f
,
0x2a
,
0x7d
,
0x12
,
0x78
,
0x0a
,
0x0e
,
0x44
,
0x65
,
0x6c
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x2f
,
0x2a
,
0x7d
,
0x12
,
0x78
,
0x0a
,
0x0e
,
0x44
,
0x65
,
0x6c
,
0x65
,
0x65
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x12
,
0x23
,
0x2e
,
0x6d
,
0x65
,
0x74
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x12
,
0x23
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x44
,
0x65
,
0x6c
,
0x65
,
0x74
,
0x6f
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x2e
,
0x44
,
0x65
,
0x6c
,
0x65
,
0x74
,
0x65
,
0x65
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x52
,
0x65
,
0x71
,
0x75
,
0x65
,
0x73
,
0x74
,
0x1a
,
0x1a
,
0x16
,
0x2e
,
0x67
,
0x6f
,
0x6f
,
0x67
,
0x6c
,
0x65
,
0x2e
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x62
,
0x16
,
0x2e
,
0x67
,
0x6f
,
0x6f
,
0x67
,
0x6c
,
0x65
,
0x2e
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x62
,
0x75
,
0x75
,
0x66
,
0x2e
,
0x45
,
0x6d
,
0x70
,
0x74
,
0x79
,
0x22
,
0x29
,
0xda
,
0x41
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x66
,
0x2e
,
0x45
,
0x6d
,
0x70
,
0x74
,
0x79
,
0x22
,
0x29
,
0xda
,
0x41
,
0x04
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x65
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x1c
,
0x2a
,
0x1a
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x82
,
0xd3
,
0xe4
,
0x93
,
0x02
,
0x1c
,
0x2a
,
0x1a
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x2f
,
0x2f
,
0x7b
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x3d
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x7b
,
0x6e
,
0x61
,
0x6d
,
0x65
,
0x3d
,
0x72
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x65
,
0x73
,
0x2f
,
0x2f
,
0x2a
,
0x7d
,
0x42
,
0xac
,
0x01
,
0x0a
,
0x10
,
0x63
,
0x6f
,
0x6d
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x2a
,
0x7d
,
0x42
,
0xac
,
0x01
,
0x0a
,
0x10
,
0x63
,
0x6f
,
0x6d
,
0x2e
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x73
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x42
,
0x14
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x2e
,
0x61
,
0x70
,
0x69
,
0x2e
,
0x76
,
0x31
,
0x42
,
0x14
,
0x52
,
0x65
,
0x73
,
0x6f
,
0x75
,
0x72
,
0x63
,
0x63
,
0x65
,
0x53
,
0x65
,
0x72
,
0x76
,
0x69
,
0x63
,
0x65
,
0x50
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x50
,
0x01
,
0x65
,
0x53
,
0x65
,
0x72
,
0x76
,
0x69
,
0x63
,
0x65
,
0x50
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x50
,
0x01
,
0x5a
,
0x5a
,
0x30
,
0x67
,
0x69
,
0x74
,
0x68
,
0x75
,
0x62
,
0x2e
,
0x63
,
0x6f
,
0x6d
,
0x2f
,
0x75
,
0x73
,
0x65
,
0x30
,
0x67
,
0x69
,
0x74
,
0x68
,
0x75
,
0x62
,
0x2e
,
0x63
,
0x6f
,
0x6d
,
0x2f
,
0x75
,
0x73
,
0x65
,
0x6d
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2f
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2f
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2f
,
0x6d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2f
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x6f
,
0x2f
,
0x67
,
0x65
,
0x6e
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x3b
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x67
,
0x65
,
0x6e
,
0x2f
,
0x61
,
0x70
,
0x69
,
0x2f
,
0x76
,
0x31
,
0x3b
,
0x61
,
0x70
,
0x69
,
0x76
,
0x76
,
0x31
,
0xa2
,
0x02
,
0x03
,
0x4d
,
0x41
,
0x58
,
0xaa
,
0x02
,
0x0c
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x31
,
0xa2
,
0x02
,
0x03
,
0x4d
,
0x41
,
0x58
,
0xaa
,
0x02
,
0x0c
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x2e
,
0x2e
,
0x41
,
0x70
,
0x69
,
0x2e
,
0x56
,
0x31
,
0xca
,
0x02
,
0x0c
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x5c
,
0x41
,
0x70
,
0x69
,
0x2e
,
0x56
,
0x31
,
0xca
,
0x02
,
0x0c
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x5c
,
0x41
,
0x41
,
0x70
,
0x69
,
0x5c
,
0x56
,
0x31
,
0xe2
,
0x02
,
0x18
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x5c
,
0x41
,
0x70
,
0x69
,
0x5c
,
0x56
,
0x31
,
0xe2
,
0x02
,
0x18
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x5c
,
0x41
,
0x70
,
0x70
,
0x69
,
0x5c
,
0x56
,
0x31
,
0x5c
,
0x47
,
0x50
,
0x42
,
0x4d
,
0x65
,
0x74
,
0x61
,
0x64
,
0x61
,
0x74
,
0x69
,
0x5c
,
0x56
,
0x31
,
0x5c
,
0x47
,
0x50
,
0x42
,
0x4d
,
0x65
,
0x74
,
0x61
,
0x64
,
0x61
,
0x74
,
0x61
,
0x61
,
0xea
,
0x02
,
0x0e
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x3a
,
0x3a
,
0x41
,
0x70
,
0x69
,
0x3a
,
0x3a
,
0xea
,
0x02
,
0x0e
,
0x4d
,
0x65
,
0x6d
,
0x6f
,
0x73
,
0x3a
,
0x3a
,
0x41
,
0x70
,
0x69
,
0x3a
,
0x3a
,
0x56
,
0x56
,
0x31
,
0x62
,
0x06
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x33
,
0x31
,
0x62
,
0x06
,
0x70
,
0x72
,
0x6f
,
0x74
,
0x6f
,
0x33
,
}
}
var
(
var
(
...
...
proto/gen/api/v1/resource_service.pb.gw.go
View file @
16d3de63
...
@@ -184,6 +184,16 @@ func request_ResourceService_GetResourceBinary_0(ctx context.Context, marshaler
...
@@ -184,6 +184,16 @@ func request_ResourceService_GetResourceBinary_0(ctx context.Context, marshaler
return
nil
,
metadata
,
status
.
Errorf
(
codes
.
InvalidArgument
,
"type mismatch, parameter: %s, error: %v"
,
"name"
,
err
)
return
nil
,
metadata
,
status
.
Errorf
(
codes
.
InvalidArgument
,
"type mismatch, parameter: %s, error: %v"
,
"name"
,
err
)
}
}
val
,
ok
=
pathParams
[
"filename"
]
if
!
ok
{
return
nil
,
metadata
,
status
.
Errorf
(
codes
.
InvalidArgument
,
"missing parameter %s"
,
"filename"
)
}
protoReq
.
Filename
,
err
=
runtime
.
String
(
val
)
if
err
!=
nil
{
return
nil
,
metadata
,
status
.
Errorf
(
codes
.
InvalidArgument
,
"type mismatch, parameter: %s, error: %v"
,
"filename"
,
err
)
}
msg
,
err
:=
client
.
GetResourceBinary
(
ctx
,
&
protoReq
,
grpc
.
Header
(
&
metadata
.
HeaderMD
),
grpc
.
Trailer
(
&
metadata
.
TrailerMD
))
msg
,
err
:=
client
.
GetResourceBinary
(
ctx
,
&
protoReq
,
grpc
.
Header
(
&
metadata
.
HeaderMD
),
grpc
.
Trailer
(
&
metadata
.
TrailerMD
))
return
msg
,
metadata
,
err
return
msg
,
metadata
,
err
...
@@ -210,6 +220,16 @@ func local_request_ResourceService_GetResourceBinary_0(ctx context.Context, mars
...
@@ -210,6 +220,16 @@ func local_request_ResourceService_GetResourceBinary_0(ctx context.Context, mars
return
nil
,
metadata
,
status
.
Errorf
(
codes
.
InvalidArgument
,
"type mismatch, parameter: %s, error: %v"
,
"name"
,
err
)
return
nil
,
metadata
,
status
.
Errorf
(
codes
.
InvalidArgument
,
"type mismatch, parameter: %s, error: %v"
,
"name"
,
err
)
}
}
val
,
ok
=
pathParams
[
"filename"
]
if
!
ok
{
return
nil
,
metadata
,
status
.
Errorf
(
codes
.
InvalidArgument
,
"missing parameter %s"
,
"filename"
)
}
protoReq
.
Filename
,
err
=
runtime
.
String
(
val
)
if
err
!=
nil
{
return
nil
,
metadata
,
status
.
Errorf
(
codes
.
InvalidArgument
,
"type mismatch, parameter: %s, error: %v"
,
"filename"
,
err
)
}
msg
,
err
:=
server
.
GetResourceBinary
(
ctx
,
&
protoReq
)
msg
,
err
:=
server
.
GetResourceBinary
(
ctx
,
&
protoReq
)
return
msg
,
metadata
,
err
return
msg
,
metadata
,
err
...
@@ -481,7 +501,7 @@ func RegisterResourceServiceHandlerServer(ctx context.Context, mux *runtime.Serv
...
@@ -481,7 +501,7 @@ func RegisterResourceServiceHandlerServer(ctx context.Context, mux *runtime.Serv
inboundMarshaler
,
outboundMarshaler
:=
runtime
.
MarshalerForRequest
(
mux
,
req
)
inboundMarshaler
,
outboundMarshaler
:=
runtime
.
MarshalerForRequest
(
mux
,
req
)
var
err
error
var
err
error
var
annotatedContext
context
.
Context
var
annotatedContext
context
.
Context
annotatedContext
,
err
=
runtime
.
AnnotateIncomingContext
(
ctx
,
mux
,
req
,
"/memos.api.v1.ResourceService/GetResourceBinary"
,
runtime
.
WithHTTPPathPattern
(
"/file/{name=resources/*}"
))
annotatedContext
,
err
=
runtime
.
AnnotateIncomingContext
(
ctx
,
mux
,
req
,
"/memos.api.v1.ResourceService/GetResourceBinary"
,
runtime
.
WithHTTPPathPattern
(
"/file/{name=resources/*}
/{filename}
"
))
if
err
!=
nil
{
if
err
!=
nil
{
runtime
.
HTTPError
(
ctx
,
mux
,
outboundMarshaler
,
w
,
req
,
err
)
runtime
.
HTTPError
(
ctx
,
mux
,
outboundMarshaler
,
w
,
req
,
err
)
return
return
...
@@ -683,7 +703,7 @@ func RegisterResourceServiceHandlerClient(ctx context.Context, mux *runtime.Serv
...
@@ -683,7 +703,7 @@ func RegisterResourceServiceHandlerClient(ctx context.Context, mux *runtime.Serv
inboundMarshaler
,
outboundMarshaler
:=
runtime
.
MarshalerForRequest
(
mux
,
req
)
inboundMarshaler
,
outboundMarshaler
:=
runtime
.
MarshalerForRequest
(
mux
,
req
)
var
err
error
var
err
error
var
annotatedContext
context
.
Context
var
annotatedContext
context
.
Context
annotatedContext
,
err
=
runtime
.
AnnotateContext
(
ctx
,
mux
,
req
,
"/memos.api.v1.ResourceService/GetResourceBinary"
,
runtime
.
WithHTTPPathPattern
(
"/file/{name=resources/*}"
))
annotatedContext
,
err
=
runtime
.
AnnotateContext
(
ctx
,
mux
,
req
,
"/memos.api.v1.ResourceService/GetResourceBinary"
,
runtime
.
WithHTTPPathPattern
(
"/file/{name=resources/*}
/{filename}
"
))
if
err
!=
nil
{
if
err
!=
nil
{
runtime
.
HTTPError
(
ctx
,
mux
,
outboundMarshaler
,
w
,
req
,
err
)
runtime
.
HTTPError
(
ctx
,
mux
,
outboundMarshaler
,
w
,
req
,
err
)
return
return
...
@@ -755,7 +775,7 @@ var (
...
@@ -755,7 +775,7 @@ var (
pattern_ResourceService_GetResource_0
=
runtime
.
MustPattern
(
runtime
.
NewPattern
(
1
,
[]
int
{
2
,
0
,
2
,
1
,
2
,
2
,
1
,
0
,
4
,
2
,
5
,
3
},
[]
string
{
"api"
,
"v1"
,
"resources"
,
"name"
},
""
))
pattern_ResourceService_GetResource_0
=
runtime
.
MustPattern
(
runtime
.
NewPattern
(
1
,
[]
int
{
2
,
0
,
2
,
1
,
2
,
2
,
1
,
0
,
4
,
2
,
5
,
3
},
[]
string
{
"api"
,
"v1"
,
"resources"
,
"name"
},
""
))
pattern_ResourceService_GetResourceBinary_0
=
runtime
.
MustPattern
(
runtime
.
NewPattern
(
1
,
[]
int
{
2
,
0
,
2
,
1
,
1
,
0
,
4
,
2
,
5
,
2
},
[]
string
{
"file"
,
"resources"
,
"
name"
},
""
))
pattern_ResourceService_GetResourceBinary_0
=
runtime
.
MustPattern
(
runtime
.
NewPattern
(
1
,
[]
int
{
2
,
0
,
2
,
1
,
1
,
0
,
4
,
2
,
5
,
2
,
1
,
0
,
4
,
1
,
5
,
3
},
[]
string
{
"file"
,
"resources"
,
"name"
,
"file
name"
},
""
))
pattern_ResourceService_UpdateResource_0
=
runtime
.
MustPattern
(
runtime
.
NewPattern
(
1
,
[]
int
{
2
,
0
,
2
,
1
,
2
,
2
,
1
,
0
,
4
,
2
,
5
,
3
},
[]
string
{
"api"
,
"v1"
,
"resources"
,
"resource.name"
},
""
))
pattern_ResourceService_UpdateResource_0
=
runtime
.
MustPattern
(
runtime
.
NewPattern
(
1
,
[]
int
{
2
,
0
,
2
,
1
,
2
,
2
,
1
,
0
,
4
,
2
,
5
,
3
},
[]
string
{
"api"
,
"v1"
,
"resources"
,
"resource.name"
},
""
))
...
...
server/router/rss/rss.go
View file @
16d3de63
...
@@ -129,7 +129,7 @@ func (s *RSSService) generateRSSFromMemoList(ctx context.Context, memoList []*st
...
@@ -129,7 +129,7 @@ func (s *RSSService) generateRSSFromMemoList(ctx context.Context, memoList []*st
if
resource
.
StorageType
==
storepb
.
ResourceStorageType_EXTERNAL
||
resource
.
StorageType
==
storepb
.
ResourceStorageType_S3
{
if
resource
.
StorageType
==
storepb
.
ResourceStorageType_EXTERNAL
||
resource
.
StorageType
==
storepb
.
ResourceStorageType_S3
{
enclosure
.
Url
=
resource
.
Reference
enclosure
.
Url
=
resource
.
Reference
}
else
{
}
else
{
enclosure
.
Url
=
fmt
.
Sprintf
(
"%s/file/resources/%d
"
,
baseURL
,
resource
.
ID
)
enclosure
.
Url
=
fmt
.
Sprintf
(
"%s/file/resources/%d
/%s"
,
baseURL
,
resource
.
ID
,
resource
.
Filename
)
}
}
enclosure
.
Length
=
strconv
.
Itoa
(
int
(
resource
.
Size
))
enclosure
.
Length
=
strconv
.
Itoa
(
int
(
resource
.
Size
))
enclosure
.
Type
=
resource
.
Type
enclosure
.
Type
=
resource
.
Type
...
...
web/src/utils/resource.ts
View file @
16d3de63
...
@@ -5,7 +5,7 @@ export const getResourceUrl = (resource: Resource) => {
...
@@ -5,7 +5,7 @@ export const getResourceUrl = (resource: Resource) => {
return
resource
.
externalLink
;
return
resource
.
externalLink
;
}
}
return
`
${
window
.
location
.
origin
}
/file/
${
resource
.
name
}
`
;
return
`
${
window
.
location
.
origin
}
/file/
${
resource
.
name
}
/
${
resource
.
filename
}
`
;
};
};
export
const
getResourceType
=
(
resource
:
Resource
)
=>
{
export
const
getResourceType
=
(
resource
:
Resource
)
=>
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment