forked from TrueCloudLab/frostfs-sdk-go
[#197] session: Refactor and document the package
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
497053c785
commit
552c7875bf
32 changed files with 1622 additions and 1358 deletions
|
@ -80,8 +80,11 @@ func (x *ObjectWriter) WithBearerToken(t bearer.Token) {
|
|||
|
||||
// WithinSession specifies session within which object should be stored.
|
||||
// Should be called once before any writing steps.
|
||||
func (x *ObjectWriter) WithinSession(t session.Token) {
|
||||
x.metaHdr.SetSessionToken(t.ToV2())
|
||||
func (x *ObjectWriter) WithinSession(t session.Object) {
|
||||
var tv2 v2session.Token
|
||||
t.WriteToV2(&tv2)
|
||||
|
||||
x.metaHdr.SetSessionToken(&tv2)
|
||||
}
|
||||
|
||||
// MarkLocal tells the server to execute the operation locally.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue