Documentation ¶
Overview ¶
Package eventbridge contains helpers for AWS EventBridge.
Index ¶
- func AssociatePartnerEventSource(ebClient eventbridgeiface.EventBridgeAPI, f *framework.Framework, ...) string
- func CreateRule(ebClient eventbridgeiface.EventBridgeAPI, f *framework.Framework, ...) (string, string)
- func DeleteEventBus(ebClient eventbridgeiface.EventBridgeAPI, eventBusName string)
- func DeleteRule(ebClient eventbridgeiface.EventBridgeAPI, name, eventBusName string)
- func DescribeEventSource(ebClient eventbridgeiface.EventBridgeAPI, eventSourceName string) *eventbridge.DescribeEventSourceOutput
- func MatchSourcePattern(src string) string
- func NewEventBridgeToSQSPolicyStatement(ruleARN, queueARN string) iam.PolicyStatement
- func SetRuleTarget(ebClient eventbridgeiface.EventBridgeAPI, ...)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AssociatePartnerEventSource ¶
func AssociatePartnerEventSource(ebClient eventbridgeiface.EventBridgeAPI, f *framework.Framework, eventSourceName string) string
AssociatePartnerEventSource associates a partner event source with a partner event bus. The partner event source automatically becomes ACTIVE after this operation.
func CreateRule ¶
func CreateRule(ebClient eventbridgeiface.EventBridgeAPI, f *framework.Framework, eventBusName, pattern string) (string, string)
CreateRule creates a rule named after the given framework.Framework.
func DeleteEventBus ¶
func DeleteEventBus(ebClient eventbridgeiface.EventBridgeAPI, eventBusName string)
DeleteEventBus deletes an event bus.
func DeleteRule ¶
func DeleteRule(ebClient eventbridgeiface.EventBridgeAPI, name, eventBusName string)
DeleteRule deletes a rule and all its targets.
func DescribeEventSource ¶
func DescribeEventSource(ebClient eventbridgeiface.EventBridgeAPI, eventSourceName string) *eventbridge.DescribeEventSourceOutput
DescribeEventSource returns details about the given event source.
func MatchSourcePattern ¶
MatchSourcePattern returns a rule pattern that matches on the "source" attribute of an event.
Sample event:
{ "version": "0", "id": "291b74d6-af33-2dcd-0ed6-b358bc2909ec", "detail-type": "e2e.test", "source": "aws.partner/triggermesh.com/123456789012/test-1234/sample", "account": "123456789012", "time": "2020-09-17T22:38:19Z", "region": "eu-central-1", "resources": [], "detail": { "data": "Hello, World", "datacontenttype": "text/plain", "id": "0000", "iotriggermeshe2e": "test-1234", "source": "e2e.triggermesh", "specversion": "1.0", "type": "e2e.test" } }
func NewEventBridgeToSQSPolicyStatement ¶
func NewEventBridgeToSQSPolicyStatement(ruleARN, queueARN string) iam.PolicyStatement
NewEventBridgeToSQSPolicyStatement returns an IAM Policy Statement that allows messages matching the given rule to be sent to the given SQS queue.
func SetRuleTarget ¶
func SetRuleTarget(ebClient eventbridgeiface.EventBridgeAPI, targetARN, ruleName, eventBusName string)
SetRuleTarget sets a target on a rule.
Types ¶
This section is empty.