Documentation ¶
Index ¶
- Constants
- type BaseNodeVersion
- type BucketInfo
- type BucketSettings
- type CORSConfiguration
- type CORSRule
- type DefaultRetention
- type DeleteMarkerInfo
- type ExtendedObjectInfo
- type Filter
- type FilterRule
- type Key
- type LambdaFunctionConfiguration
- type LegalHold
- type LegalHoldLock
- type LockInfo
- func (l LockInfo) ID() uint64
- func (l LockInfo) IsCompliance() bool
- func (l LockInfo) IsLegalHoldSet() bool
- func (l LockInfo) IsRetentionSet() bool
- func (l LockInfo) LegalHold() oid.ID
- func (l *LockInfo) ResetLegalHold()
- func (l LockInfo) Retention() oid.ID
- func (l *LockInfo) SetLegalHold(objID oid.ID)
- func (l *LockInfo) SetRetention(objID oid.ID, until string, isCompliance bool)
- func (l LockInfo) UntilDate() string
- type MultipartInfo
- type NodeVersion
- type NotificationConfiguration
- type NotificationInfo
- type ObjectInfo
- type ObjectLock
- type ObjectLockConfiguration
- type ObjectLockRule
- type ObjectTaggingInfo
- type PartInfo
- type QueueConfiguration
- type Retention
- type RetentionLock
- type TopicConfiguration
Constants ¶
const ( VersioningUnversioned = "Unversioned" VersioningEnabled = "Enabled" VersioningSuspended = "Suspended" )
const (
UnversionedObjectVersionID = "null"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BaseNodeVersion ¶
type BaseNodeVersion struct { ID uint64 ParenID uint64 OID oid.ID Timestamp uint64 Size int64 ETag string FilePath string }
BaseNodeVersion is minimal node info from tree service. Basically used for "system" object.
type BucketInfo ¶
type BucketInfo struct { Name string // container name from system attribute Zone string // container zone from system attribute CID cid.ID Owner user.ID Created time.Time LocationConstraint string ObjectLockEnabled bool }
BucketInfo stores basic bucket data.
func (*BucketInfo) CORSObjectName ¶
func (b *BucketInfo) CORSObjectName() string
CORSObjectName returns a system name for a bucket CORS configuration file.
func (*BucketInfo) NotificationConfigurationObjectName ¶
func (b *BucketInfo) NotificationConfigurationObjectName() string
func (*BucketInfo) SettingsObjectName ¶
func (b *BucketInfo) SettingsObjectName() string
SettingsObjectName is a system name for a bucket settings file.
type BucketSettings ¶
type BucketSettings struct { Versioning string `json:"versioning"` LockConfiguration *ObjectLockConfiguration `json:"lock_configuration"` }
BucketSettings stores settings such as versioning.
func (BucketSettings) Unversioned ¶
func (b BucketSettings) Unversioned() bool
func (BucketSettings) VersioningEnabled ¶
func (b BucketSettings) VersioningEnabled() bool
func (BucketSettings) VersioningSuspended ¶
func (b BucketSettings) VersioningSuspended() bool
type CORSConfiguration ¶
type CORSConfiguration struct { XMLName xml.Name `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CORSConfiguration" json:"-"` CORSRules []CORSRule `xml:"CORSRule" json:"CORSRules"` }
CORSConfiguration stores CORS configuration of a request.
type CORSRule ¶
type CORSRule struct { ID string `xml:"ID,omitempty" json:"ID,omitempty"` AllowedHeaders []string `xml:"AllowedHeader" json:"AllowedHeaders"` AllowedMethods []string `xml:"AllowedMethod" json:"AllowedMethods"` AllowedOrigins []string `xml:"AllowedOrigin" json:"AllowedOrigins"` ExposeHeaders []string `xml:"ExposeHeader" json:"ExposeHeaders"` MaxAgeSeconds int `xml:"MaxAgeSeconds,omitempty" json:"MaxAgeSeconds,omitempty"` }
CORSRule stores rules for CORS in a bucket.
type DefaultRetention ¶
type DeleteMarkerInfo ¶
DeleteMarkerInfo is used to save object info if node in the tree service is delete marker. We need this information because the "delete marker" object is no longer stored in FrostFS.
type ExtendedObjectInfo ¶
type ExtendedObjectInfo struct { ObjectInfo *ObjectInfo NodeVersion *NodeVersion IsLatest bool }
ExtendedObjectInfo contains additional node info to be able to sort versions by timestamp.
func (ExtendedObjectInfo) Version ¶
func (e ExtendedObjectInfo) Version() string
type FilterRule ¶
type Key ¶
type Key struct {
FilterRules []FilterRule `xml:"FilterRule" json:"FilterRules"`
}
type LambdaFunctionConfiguration ¶
type LambdaFunctionConfiguration struct{}
type LegalHoldLock ¶
type LegalHoldLock struct {
Enabled bool
}
type LockInfo ¶
type LockInfo struct {
// contains filtered or unexported fields
}
LockInfo is lock information to create appropriate tree node.
func NewLockInfo ¶
func (LockInfo) IsCompliance ¶
func (LockInfo) IsLegalHoldSet ¶
func (LockInfo) IsRetentionSet ¶
func (*LockInfo) ResetLegalHold ¶
func (l *LockInfo) ResetLegalHold()
func (*LockInfo) SetLegalHold ¶
func (*LockInfo) SetRetention ¶
type MultipartInfo ¶
type MultipartInfo struct { // ID is node id in tree service. // It's ignored when creating a new multipart upload. ID uint64 Key string UploadID string Owner user.ID Created time.Time Meta map[string]string CopiesNumber uint32 }
MultipartInfo is multipart upload information.
type NodeVersion ¶
type NodeVersion struct { BaseNodeVersion DeleteMarker *DeleteMarkerInfo IsUnversioned bool }
NodeVersion represent node from tree service.
func (NodeVersion) IsDeleteMarker ¶
func (v NodeVersion) IsDeleteMarker() bool
type NotificationConfiguration ¶
type NotificationConfiguration struct { QueueConfigurations []QueueConfiguration `xml:"QueueConfiguration" json:"QueueConfigurations"` // Not supported topics TopicConfigurations []TopicConfiguration `xml:"TopicConfiguration" json:"TopicConfigurations"` LambdaFunctionConfigurations []LambdaFunctionConfiguration `xml:"CloudFunctionConfiguration" json:"CloudFunctionConfigurations"` }
func (NotificationConfiguration) IsEmpty ¶
func (n NotificationConfiguration) IsEmpty() bool
type NotificationInfo ¶
NotificationInfo store info to send s3 notification.
func NotificationInfoFromObject ¶
func NotificationInfoFromObject(objInfo *ObjectInfo) *NotificationInfo
NotificationInfoFromObject creates new NotificationInfo from ObjectInfo.
type ObjectInfo ¶
type ObjectInfo struct { ID oid.ID CID cid.ID IsDir bool IsDeleteMarker bool Bucket string Name string Size int64 ContentType string Created time.Time HashSum string Owner user.ID Headers map[string]string }
ObjectInfo holds S3 object data.
func (*ObjectInfo) Address ¶
func (o *ObjectInfo) Address() oid.Address
Address returns object address.
func (*ObjectInfo) NiceName ¶
func (o *ObjectInfo) NiceName() string
NiceName returns object name for cache.
func (*ObjectInfo) VersionID ¶
func (o *ObjectInfo) VersionID() string
VersionID returns object version from ObjectInfo.
type ObjectLock ¶
type ObjectLock struct { LegalHold *LegalHoldLock Retention *RetentionLock }
type ObjectLockConfiguration ¶
type ObjectLockConfiguration struct { XMLName xml.Name `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ObjectLockConfiguration" json:"-"` ObjectLockEnabled string `xml:"ObjectLockEnabled" json:"ObjectLockEnabled"` Rule *ObjectLockRule `xml:"Rule" json:"Rule"` }
type ObjectLockRule ¶
type ObjectLockRule struct {
DefaultRetention *DefaultRetention `xml:"DefaultRetention" json:"DefaultRetention"`
}
type ObjectTaggingInfo ¶
type PartInfo ¶
type PartInfo struct { Key string UploadID string Number int OID oid.ID Size int64 ETag string Created time.Time }
PartInfo is upload information about part.
func (*PartInfo) ToHeaderString ¶
ToHeaderString form short part representation to use in S3-Completed-Parts header.
type QueueConfiguration ¶
type RetentionLock ¶
type TopicConfiguration ¶
type TopicConfiguration struct{}
TopicConfiguration and LambdaFunctionConfiguration -- we don't support these configurations, but we need them to detect in notification configurations in requests.