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

Functionbeat use a concurrency of 5 by default for AWS lambda #8992

Merged
merged 2 commits into from
Nov 15, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ https://github.com/elastic/beats/compare/v6.4.0...master[Check the HEAD diff]
*Winlogbeat*

*Functionbeat*
- Function concurrency is now set to 5 instead of unreserved. {pull}8992[8992]

==== Bugfixes

Expand Down
4 changes: 2 additions & 2 deletions x-pack/functionbeat/_meta/beat.reference.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ functionbeat.provider.aws.functions:
description: "lambda function for cloudwatch logs"

# Concurrency, is the reserved number of instances for that function.
# Default is unreserved.
# Default is 5.
#
# Note: There is a hard limit of 1000 functions of any kind per account.
#concurrency: 5
Expand Down Expand Up @@ -62,7 +62,7 @@ functionbeat.provider.aws.functions:
description: "lambda function for sqs events"

# Concurrency, is the reserved number of instances for that function.
# Default is unreserved.
# Default is 5.
#
# Note: There is a hard limit of 1000 functions of any kind per account.
#concurrency: 5
Expand Down
4 changes: 2 additions & 2 deletions x-pack/functionbeat/_meta/beat.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ functionbeat.provider.aws.functions:
description: "lambda function for cloudwatch logs"

# Concurrency, is the reserved number of instances for that function.
# Default is unreserved.
# Default is 5.
#
# Note: There is a hard limit of 1000 functions of any kind per account.
#concurrency: 5
Expand Down Expand Up @@ -63,7 +63,7 @@ functionbeat.provider.aws.functions:
description: "lambda function for SQS events"

# Concurrency, is the reserved number of instances for that function.
# Default is unreserved.
# Default is 5.
#
# Note: There is a hard limit of 1000 functions of any kind per account.
#concurrency: 5
Expand Down
4 changes: 2 additions & 2 deletions x-pack/functionbeat/functionbeat.reference.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ functionbeat.provider.aws.functions:
description: "lambda function for cloudwatch logs"

# Concurrency, is the reserved number of instances for that function.
# Default is unreserved.
# Default is 5.
#
# Note: There is a hard limit of 1000 functions of any kind per account.
#concurrency: 5
Expand Down Expand Up @@ -62,7 +62,7 @@ functionbeat.provider.aws.functions:
description: "lambda function for sqs events"

# Concurrency, is the reserved number of instances for that function.
# Default is unreserved.
# Default is 5.
#
# Note: There is a hard limit of 1000 functions of any kind per account.
#concurrency: 5
Expand Down
4 changes: 2 additions & 2 deletions x-pack/functionbeat/functionbeat.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ functionbeat.provider.aws.functions:
description: "lambda function for cloudwatch logs"

# Concurrency, is the reserved number of instances for that function.
# Default is unreserved.
# Default is 5.
#
# Note: There is a hard limit of 1000 functions of any kind per account.
#concurrency: 5
Expand Down Expand Up @@ -63,7 +63,7 @@ functionbeat.provider.aws.functions:
description: "lambda function for SQS events"

# Concurrency, is the reserved number of instances for that function.
# Default is unreserved.
# Default is 5.
#
# Note: There is a hard limit of 1000 functions of any kind per account.
#concurrency: 5
Expand Down
4 changes: 2 additions & 2 deletions x-pack/functionbeat/provider/aws/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ const maxMegabytes = 3008
var DefaultLambdaConfig = &lambdaConfig{
MemorySize: 128 * 1024 * 1024,
Timeout: time.Second * 3,
Concurrency: 0, // unreserve
Concurrency: 5,
}

type lambdaConfig struct {
Concurrency int `config:"concurrency" validate:"positive"`
Concurrency int `config:"concurrency" validate:"min=0,max=1000"`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm wondering, is 1000 as hard maximum in AWS?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is indeed a weird setting, it is a hard limit per account of the total of running function of any kind.

IE: if you set this function to 5, It will run a maximum of 5 of your function.

DeadLetterConfig *deadLetterConfig `config:"dead_letter_config"`
Description string `config:"description"`
MemorySize MemSizeFactor64 `config:"memory_size"`
Expand Down