Leonard Lyubich
2b171e1617
[ #188 ] sdk: Implement Epoch method
...
Implement Epoch method on Client that receives epoch number through Netmap
.LocalNodeInfo call.
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-11-05 09:58:21 +03:00
Leonard Lyubich
89a7a946dc
[ #187 ] sdk: Implement IsSupportedVersion function
...
Implement function that checks the compatibility of the specified version
with the current NeoFS revision.
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-11-03 11:36:23 +03:00
Leonard Lyubich
ac38d13f04
[ #182 ] sdk/object: Refactor a way to add filters by properties
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-28 14:11:49 +03:00
Leonard Lyubich
88c8c08c6b
[ #182 ] sdk/object: Implement methods for adding object search filters
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-28 14:11:49 +03:00
Leonard Lyubich
6f45f713c1
[ #182 ] sdk/eacl: Implement convenient methods for adding object filters
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-28 14:11:49 +03:00
Leonard Lyubich
dc9fcd5d98
[ #182 ] Rename methods to match updated field names
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-28 14:11:49 +03:00
Leonard Lyubich
7f0f42bc30
[ #180 ] sdk/client: Set session token field in all requests
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-28 12:15:49 +03:00
Leonard Lyubich
b2ba0eef07
[ #180 ] sdk/client: Implement methods that attach tokens to Client
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-28 12:15:49 +03:00
Leonard Lyubich
805ad54f41
[ #180 ] sdk/client: Make defaultOptions func a Client method
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-28 12:15:49 +03:00
Leonard Lyubich
ad0b01e892
[ #172 ] Improve the readability of named attribute constants
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-22 19:15:45 +03:00
Leonard Lyubich
5494d3417f
[ #172 ] sdk/object: Define well-known application attributes
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-22 19:15:45 +03:00
Leonard Lyubich
4357430e0f
[ #172 ] sdk/container: Define well-known application attributes
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-22 19:15:45 +03:00
Alex Vanin
7b212431df
[ #179 ] sdk/token: Add function to return token issuer
...
With new neofs-api changes, token issuer will not be stored
in ownerID field of bearer token. We can identify owner by
public key that has been used in signature.
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-10-22 15:41:59 +03:00
Alex Vanin
e023b6e51e
[ #179 ] sdk/client: Ease bearer token sanity check
...
Now owner ID field is not required to be set. According to
latest neofs-api, this field set if token was issued for
specific owner ID. If this field is not set, then any user
can use this token while it is correctly signed and has valid
lifetime.
Lifetime is also can be omitted since node interpret empty
lifetime as a lifetime with zero values.
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-10-22 15:41:59 +03:00
Alex Vanin
2aa40b0dd3
[ #177 ] sdk/client: Set version of new EACL table
...
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-10-20 15:35:41 +03:00
Alex Vanin
5f6720f456
[ #172 ] v2/acl: Rename target keyList
field to keys
...
According to new neofs-api target filed `key_list`
rename to `keys`.
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-10-20 13:45:14 +03:00
Evgenii Stratonikov
6a69a896e5
[ #174 ] netmap: process unspecified attribute as ID
...
When selector attribute is provided it should be
silently replaced by transparent ID, so each node
resides in a separate bucket.
Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
2020-10-20 13:05:15 +03:00
Evgeniy Kulikov
4e6350f6d4
[ #147 ] Work around owner package
...
- implement Stringer interface and Parse method for owner.ID
- increase test coverage
closes #147
Signed-off-by: Evgeniy Kulikov <kim@nspcc.ru>
2020-10-15 11:05:37 +03:00
Evgeniy Kulikov
e2d8f408d8
[ #147 ] Work around owner package
...
Add NEO3WalletSize as constant value.
closes #147
Signed-off-by: Evgeniy Kulikov <kim@nspcc.ru>
2020-10-15 11:05:37 +03:00
Evgeniy Kulikov
20273357f6
[ #147 ] Work around object package
...
- implement Stringer interface and Parse method for object.Address
- increase test coverage
closes #147
Signed-off-by: Evgeniy Kulikov <kim@nspcc.ru>
2020-10-15 11:05:37 +03:00
Evgeniy Kulikov
f5b442fe3b
[ #147 ] Work around object package
...
- implement Stringer interface and Parse method for object.ID
- increase test coverage
closes #147
Signed-off-by: Evgeniy Kulikov <kim@nspcc.ru>
2020-10-15 11:05:37 +03:00
Evgeniy Kulikov
f5388b553e
[ #147 ] Work around container package
...
- implement Stringer interface and Parse method for container.ID
- increase test coverage
closes #147
Signed-off-by: Evgeniy Kulikov <kim@nspcc.ru>
2020-10-15 11:05:37 +03:00
Alex Vanin
7b3736567c
[ #169 ] sdk/client: Do not resign session token
...
In some cases SDK Client provided with signed and prepared
session token. In this case we don't need to change verb
or sign it.
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-10-14 21:09:56 +03:00
Alex Vanin
d3e3889425
[ #167 ] sdk/client: Add endpoint info getter
...
Adds support of new netmap service to the SDK client.
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-10-09 09:15:34 +03:00
Alex Vanin
fa18f5ede7
[ #165 ] pkg/owner: Add ID constructor from wallet
...
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-10-07 10:16:36 +03:00
Leonard Lyubich
cf70026c7e
[ #164 ] sdk/container: Implement Equal method on ID
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-01 10:06:30 +03:00
Leonard Lyubich
1305bc750e
[ #164 ] sdk/object: Add HasParent method
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-01 10:06:30 +03:00
Leonard Lyubich
2a2e4d8577
[ #164 ] sdk/object: Implement method to reset relation fields
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-01 10:06:30 +03:00
Leonard Lyubich
f3bddc2ba5
[ #164 ] sdk/object: Define filters to search virtual objects
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-01 10:06:30 +03:00
Leonard Lyubich
09e6093e64
[ #164 ] sdk/object: Define filters to search root objects
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-01 10:06:30 +03:00
Leonard Lyubich
9799e5d48c
[ #164 ] sdk/object: Return nil parent if parent fields are empty
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-01 10:06:30 +03:00
Leonard Lyubich
ae81f4584e
[ #164 ] sdk/object: Add parent ID getter and setter
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-10-01 10:06:30 +03:00
Leonard Lyubich
420d956062
[ #162 ] sdk/object: Detach header verification functions
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-29 15:26:41 +03:00
Leonard Lyubich
2cc58e36f8
[ #160 ] sdk/client: Set object identifier in Head result
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-25 17:37:44 +03:00
Alex Vanin
c814cc62fa
[ #158 ] pkg/client: Ignore EOF on buffer copy in object.Put
...
There is a issue when user sends payload chunk to the neofs
node, but node closes connection earlier, e.g. node can return
error as soon as it checked ACL permission and denied request.
In this case client will receive EOF error and it produces
`could not send payload bytes to Put object stream` error, but
in fact there is different error.
If we ignore EOF there then `stream.CloseAndRecv()` return
correct error message later.
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-09-25 15:58:40 +03:00
Leonard Lyubich
d19e5418da
[ #159 ] sdk: Define object range in object pkg
...
Define Range type in object package. Replace Range in client package with
the new one.
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-25 15:58:24 +03:00
Leonard Lyubich
14fa89b819
[ #155 ] sdk/object: Add Object to RawObject converter
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-22 18:07:14 +03:00
Leonard Lyubich
cecdeeac73
[ #155 ] sdk/object: Add CutPayload method to RawObject
...
Add CutPayload method that returns RawObject's copy with untethered empty
payload. Changing the result payload doesn't affect source object. Changing
the other fields affects source object.
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-22 18:07:14 +03:00
Leonard Lyubich
dbb5102c02
[ #155 ] sdk/object: Add object type getter/setter
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-22 18:07:14 +03:00
Leonard Lyubich
2fb1547cd8
[ #155 ] sdk/object: Define object types
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-22 18:07:14 +03:00
Leonard Lyubich
b991e014a9
[ #155 ] sdk/eacl: Fix package cross dependency
...
Remove the usage of object package constants from eacl unit tests.
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-22 18:07:14 +03:00
Leonard Lyubich
c66b23995c
[ #155 ] sdk/object: Add session token getter/setter
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-22 18:07:14 +03:00
Alex Vanin
3347e53cde
[ #151 ] sdk/netmap: Add public key getter for node
...
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-09-22 10:25:09 +03:00
Alex Vanin
59033d330d
[ #143 ] sdk/client: Add call option to set bearer token
...
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-09-18 10:45:11 +03:00
Alex Vanin
96de0bd25a
[ #143 ] sdk/token: Define bearer token structure
...
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-09-18 10:45:11 +03:00
Leonard Lyubich
0259a06783
[ #150 ] sdk/token: Add owner ID
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-18 10:45:11 +03:00
Alex Vanin
73220620c5
[ #148 ] sdk/client: Support object search rpc
...
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-09-18 10:45:11 +03:00
Alex Vanin
549fcad76e
[ #148 ] sdk/object: Change search filters v2 converter return type
...
Unified structures from v2 package work with the slice of pointers.
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-09-18 10:45:11 +03:00
Leonard Lyubich
353448c0c3
[ #149 ] sdk/object: Add address field getters and setters
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-18 10:45:11 +03:00
Leonard Lyubich
7ef249f8db
[ #149 ] sdk/netmap: Add net address getter to Node
...
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-09-18 10:45:11 +03:00