Documentation ¶
Index ¶
- func GetCache() *redis.Client
- func GetCelery() (*gocelery.RedisCeleryBroker, *gocelery.RedisCeleryBackend)
- func GetDB() *gorm.DB
- func GetElasticsearch() *elastic.Client
- func Migrate()
- func NewPattern(prefix, suffix string) (pattern string)
- func SetCache()
- func SetCelery()
- func SetDB()
- func SetElasticsearch()
- type Config
- type Endpoint
- type Event
- type FilterRule
- type FilterRuleList
- type Model
- type Queue
- type Resource
- type Rules
- type RulesMap
- type S3Key
- type Service
- type Topic
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetCelery ¶
func GetCelery() (*gocelery.RedisCeleryBroker, *gocelery.RedisCeleryBackend)
func GetElasticsearch ¶
func NewPattern ¶
NewPattern - create new pattern for prefix/suffix.
func SetElasticsearch ¶
func SetElasticsearch()
Types ¶
type Config ¶
type Config struct { Model Bucket string `xml:"-" gorm:"unique;not null"` XMLName xml.Name `xml:"NotificationConfiguration"` Queues []Queue `xml:"QueueConfiguration,omitempty"` Topics []Topic `xml:"TopicConfiguration,omitempty"` }
func (Config) ToRulesMap ¶
func (*Config) UnmarshalXML ¶
UnmarshalXML - decodes XML data.
type Endpoint ¶
func ParseSubscription ¶
type Event ¶
func (*Event) MarshalXML ¶
MarshalXML - encodes to XML data.
func (*Event) UnmarshalXML ¶
type FilterRule ¶
type FilterRule struct { Model Name string `xml:"Name"` Value string `xml:"Value"` FilterRuleListID uint `xml:"-"` }
func (*FilterRule) UnmarshalXML ¶
func (filter *FilterRule) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error
UnmarshalXML - decodes XML data.
type FilterRuleList ¶
type FilterRuleList struct { Model Rules []FilterRule `xml:"FilterRule,omitempty"` S3KeyID uint }
func (FilterRuleList) Pattern ¶
func (ruleList FilterRuleList) Pattern() string
Pattern - returns pattern using prefix and suffix values.
func (*FilterRuleList) UnmarshalXML ¶
func (ruleList *FilterRuleList) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error
UnmarshalXML - decodes XML data.
type Queue ¶
type Queue struct { Model QueueIdentifier string `xml:"Id"` Filter S3Key `xml:"Filter"` Events []Event `xml:"Event"` ARN string `xml:"Queue"` Resource Resource `xml:"-"` ResourceID uint `xml:"-"` ConfigID uint `xml:"-"` }
func (Queue) ToRulesMap ¶
func (*Queue) UnmarshalXML ¶
UnmarshalXML - decodes XML data.
type Resource ¶
type RulesMap ¶
func NewRulesMap ¶
NewRulesMap - creates new rules map with given values.
type S3Key ¶
type S3Key struct { Model RuleList FilterRuleList `xml:"S3Key,omitempty"` QueueID uint TopicID uint }
Click to show internal directories.
Click to hide internal directories.