Skip to content
This repository has been archived by the owner on Feb 10, 2025. It is now read-only.

Lambda InvocationType #38

Open
tomasz-kusy opened this issue Sep 5, 2019 · 0 comments
Open

Lambda InvocationType #38

tomasz-kusy opened this issue Sep 5, 2019 · 0 comments

Comments

@tomasz-kusy
Copy link

tomasz-kusy commented Sep 5, 2019

Hi,
Is it possible to add another (optional) parameter in the configuration, which is for Lambda InvocationType?
It is about this fragment of the code (/lambda/forwarder.go):

// Push pushes message to forwarding infrastructure
func (f Forwarder) Push(message string) error {

	if message == "" {
		return errors.New(forwarder.EmptyMessageError)
	}
	params := &lambda.InvokeInput{
		FunctionName: aws.String(f.function),
		Payload:      []byte(message),
		InvocationType: aws.String("Event"),
	}
	resp, err := f.lambdaClient.Invoke(params)

Of course, instead of aws.String("Event") there should be an option from the file /config/mapping.json

I think it would be a useful option

Regards

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant