WIP: [#100] types: Make sdk types as protobuf wrappers #100
No reviewers
TrueCloudLab/storage-services-committers
TrueCloudLab/storage-core-developers
TrueCloudLab/storage-services-developers
Labels
No labels
P0
P1
P2
P3
good first issue
pool
Infrastructure
blocked
bug
config
discussion
documentation
duplicate
enhancement
go
help wanted
internal
invalid
kludge
observability
perfomance
question
refactoring
wontfix
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: TrueCloudLab/frostfs-sdk-go#100
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "aarifullin/frostfs-sdk-go:feature/40-decorate_protobufs"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Signed-off-by: Airat Arifullin a.arifullin@yadro.com
[#xx] types: Make sdk types as protobuf wrappersto WIP: [#xx] types: Make sdk types as protobuf wrappers13806d2e05
to8caf769231
8caf769231
to4c4d887aae
WIP: [#xx] types: Make sdk types as protobuf wrappersto WIP: [#100] types: Make sdk types as protobuf wrappers4c4d887aae
toed4db105cb
ed4db105cb
to8bdf6eba4f
8bdf6eba4f
to3e4e7f750d
3e4e7f750d
toc0ff809141
c0ff809141
to4ef9c4409c
4ef9c4409c
to023f1dc375
@ -25,20 +28,20 @@ type Token struct {
targetUser user.ID
eaclTableSet bool
looks redundant: value replaced to pointer, so we can check pointer against nil
Yes. The flag looks really little bit misterious for now. Anyway, I removed it
@ -97,3 +96,1 @@
if cc.err != nil {
cc.err = newErrInvalidResponseField(fieldBalance, cc.err)
}
res.amount.ReadFromV2(bal)
check error?
Probably, when you glanced at PR first time, the method returned an error. Now it returns nothing
023f1dc375
toc124955199
c124955199
to9cb4a3a08e
9cb4a3a08e
to0d9e1ff5c3
0d9e1ff5c3
to992be266bf
992be266bf
to9f8f61da77
9f8f61da77
to2a172c8fbb
2a172c8fbb
to474bd27ab9
474bd27ab9
toa2e9794d2e
WIP: [#100] types: Make sdk types as protobuf wrappersto [#100] types: Make sdk types as protobuf wrappers@ -3,2 +3,4 @@
go 1.19
replace (
git.frostfs.info/TrueCloudLab/frostfs-api-go/v2 v2.15.1-0.20230531114046-62edd68f47ac => /home/aarifullin/ws/frostfs-api-go
I don't replace this line, until
api-go
will be merged (go.mod should be fixed anyway to update api-go ver)@ -0,0 +1,18 @@
package slices
func MakePreallocPointerSlice[T any](sizes ...int) (res []*T) {
Why
Make...(0)
returnsnil
?make(..., 0, 0)
returns empty slice.Why this function is variadic? Looks like the are 3 variant, but variadic args run to replace build time check to runtime check.
It seems that there is no difference between empty slice and nil-slice but I remembered that I use this method to initialize slices within protobuf (actually
any
must beproto.Message
), but I think that can be really painful for encoding. So, yes, must be empty sliceTo make it look like
built-in
make to create slice with given length, or length and capacitya2e9794d2e
to93a9f32669
93a9f32669
to03e3b6267a
03e3b6267a
to22d4fd3aa9
22d4fd3aa9
to615e7ebf49
615e7ebf49
to7559aeb810
7559aeb810
to6281a25556
[#100] types: Make sdk types as protobuf wrappersto WIP: [#100] types: Make sdk types as protobuf wrappersPostponed.
Pull request closed