Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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 join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant