Class: Jets::CLI::Concurrency::Get
- Defined in:
- lib/jets/cli/concurrency/get.rb
Direct Known Subclasses
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Get
constructor
A new instance of Get.
- #provisioned_concurrency ⇒ Object
- #reserved_concurrency ⇒ Object
- #run ⇒ Object
Methods inherited from Base
#paginate, #paging_params, rescue_api_error
Methods included from Util::Logging
Methods included from AwsServices
#apigateway, #aws_options, #cfn, #codebuild, #dynamodb, #lambda_client, #logs, #s3, #s3_resource, #sns, #sqs, #ssm, #sts, #wafv2
Methods included from AwsServices::StackStatus
Methods included from AwsServices::GlobalMemoist
Methods included from Api
Constructor Details
Instance Method Details
#provisioned_concurrency ⇒ Object
17 18 19 20 21 22 23 24 25 26 27 |
# File 'lib/jets/cli/concurrency/get.rb', line 17 def provisioned_concurrency info = @lambda_function.provisioned_concurrency_info if @lambda_function.provisioned_concurrency.nil? "not set" elsif info[:status] == "IN_PROGRESS" "#{info[:allocated]}/#{info[:requested]} (In progress)" else @lambda_function.provisioned_concurrency end end |
#reserved_concurrency ⇒ Object
29 30 31 32 33 34 35 |
# File 'lib/jets/cli/concurrency/get.rb', line 29 def reserved_concurrency if @lambda_function.reserved_concurrency.nil? "not set. Will scale to unreserved limit: #{account_limit.unreserved_concurrent_executions}" else @lambda_function.reserved_concurrency end end |
#run ⇒ Object
9 10 11 12 13 14 15 |
# File 'lib/jets/cli/concurrency/get.rb', line 9 def run puts <<~EOL Settings for Function: #{@lambda_function.name} Reserved concurrency: #{reserved_concurrency} Provisioned concurrency: #{provisioned_concurrency} EOL end |