forked from TrueCloudLab/frostfs-api-go
[#139] sdk/acl: Highlight prefix of well known header names
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
This commit is contained in:
parent
d1499e65b9
commit
052a4a97dc
1 changed files with 12 additions and 6 deletions
|
@ -60,23 +60,29 @@ const (
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
// ReservedHeaderNamePrefix used in filter names to specify well known
|
||||||
|
// headers such as container id, object id, owner id, etc.
|
||||||
|
// All names without this prefix used to lookup through user defined headers
|
||||||
|
// in object or x-headers in request.
|
||||||
|
ReservedHeaderNamePrefix = "_"
|
||||||
|
|
||||||
// HdrObjSysNameID is a name of ID field in system header of object.
|
// HdrObjSysNameID is a name of ID field in system header of object.
|
||||||
HdrObjSysNameID = "_ID"
|
HdrObjSysNameID = ReservedHeaderNamePrefix + "ID"
|
||||||
|
|
||||||
// HdrObjSysNameCID is a name of cid field in system header of object.
|
// HdrObjSysNameCID is a name of cid field in system header of object.
|
||||||
HdrObjSysNameCID = "_CID"
|
HdrObjSysNameCID = ReservedHeaderNamePrefix + "CID"
|
||||||
|
|
||||||
// HdrObjSysNameOwnerID is a name of OwnerID field in system header of object.
|
// HdrObjSysNameOwnerID is a name of OwnerID field in system header of object.
|
||||||
HdrObjSysNameOwnerID = "_OWNER_ID"
|
HdrObjSysNameOwnerID = ReservedHeaderNamePrefix + "OWNER_ID"
|
||||||
|
|
||||||
// HdrObjSysNameVersion is a name of version field in system header of object.
|
// HdrObjSysNameVersion is a name of version field in system header of object.
|
||||||
HdrObjSysNameVersion = "_VERSION"
|
HdrObjSysNameVersion = ReservedHeaderNamePrefix + "VERSION"
|
||||||
|
|
||||||
// HdrObjSysNamePayloadLength is a name of PayloadLength field in system header of object.
|
// HdrObjSysNamePayloadLength is a name of PayloadLength field in system header of object.
|
||||||
HdrObjSysNamePayloadLength = "_PAYLOAD_LENGTH"
|
HdrObjSysNamePayloadLength = ReservedHeaderNamePrefix + "PAYLOAD_LENGTH"
|
||||||
|
|
||||||
// HdrObjSysNameCreatedEpoch is a name of CreatedAt.Epoch field in system header of object.
|
// HdrObjSysNameCreatedEpoch is a name of CreatedAt.Epoch field in system header of object.
|
||||||
HdrObjSysNameCreatedEpoch = "_CREATED_EPOCH"
|
HdrObjSysNameCreatedEpoch = ReservedHeaderNamePrefix + "CREATED_EPOCH"
|
||||||
)
|
)
|
||||||
|
|
||||||
func (a Action) ToV2() v2acl.Action {
|
func (a Action) ToV2() v2acl.Action {
|
||||||
|
|
Loading…
Reference in a new issue