All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.lambda.model.AccountLimit Maven / Gradle / Ivy

Go to download

The AWS Java SDK for AWS Lambda module holds the client classes that are used for communicating with AWS Lambda Service

There is a newer version: 1.12.765
Show newest version
/*
 * Copyright 2011-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */
package com.amazonaws.services.lambda.model;

import java.io.Serializable;

/**
 * 

* Provides limits of code size and concurrency associated with the current account and region. *

*/ public class AccountLimit implements Serializable, Cloneable { /** *

* Maximum size, in megabytes, of a code package you can upload per region. The default size is 75 GB. *

*/ private Long totalCodeSize; /** *

* Size, in bytes, of code/dependencies that you can zip into a deployment package (uncompressed zip/jar size) for * uploading. The default limit is 250 MB. *

*/ private Long codeSizeUnzipped; /** *

* Size, in bytes, of a single zipped code/dependencies package you can upload for your Lambda function(.zip/.jar * file). Try using AWS S3 for uploading larger files. Default limit is 50 MB. *

*/ private Long codeSizeZipped; /** *

* Number of simultaneous executions of your function per region. For more information or to request a limit * increase for concurrent executions, see Lambda Function Concurrent * Executions. The default limit is 100. *

*/ private Integer concurrentExecutions; /** *

* Maximum size, in megabytes, of a code package you can upload per region. The default size is 75 GB. *

* * @param totalCodeSize * Maximum size, in megabytes, of a code package you can upload per region. The default size is 75 GB. */ public void setTotalCodeSize(Long totalCodeSize) { this.totalCodeSize = totalCodeSize; } /** *

* Maximum size, in megabytes, of a code package you can upload per region. The default size is 75 GB. *

* * @return Maximum size, in megabytes, of a code package you can upload per region. The default size is 75 GB. */ public Long getTotalCodeSize() { return this.totalCodeSize; } /** *

* Maximum size, in megabytes, of a code package you can upload per region. The default size is 75 GB. *

* * @param totalCodeSize * Maximum size, in megabytes, of a code package you can upload per region. The default size is 75 GB. * @return Returns a reference to this object so that method calls can be chained together. */ public AccountLimit withTotalCodeSize(Long totalCodeSize) { setTotalCodeSize(totalCodeSize); return this; } /** *

* Size, in bytes, of code/dependencies that you can zip into a deployment package (uncompressed zip/jar size) for * uploading. The default limit is 250 MB. *

* * @param codeSizeUnzipped * Size, in bytes, of code/dependencies that you can zip into a deployment package (uncompressed zip/jar * size) for uploading. The default limit is 250 MB. */ public void setCodeSizeUnzipped(Long codeSizeUnzipped) { this.codeSizeUnzipped = codeSizeUnzipped; } /** *

* Size, in bytes, of code/dependencies that you can zip into a deployment package (uncompressed zip/jar size) for * uploading. The default limit is 250 MB. *

* * @return Size, in bytes, of code/dependencies that you can zip into a deployment package (uncompressed zip/jar * size) for uploading. The default limit is 250 MB. */ public Long getCodeSizeUnzipped() { return this.codeSizeUnzipped; } /** *

* Size, in bytes, of code/dependencies that you can zip into a deployment package (uncompressed zip/jar size) for * uploading. The default limit is 250 MB. *

* * @param codeSizeUnzipped * Size, in bytes, of code/dependencies that you can zip into a deployment package (uncompressed zip/jar * size) for uploading. The default limit is 250 MB. * @return Returns a reference to this object so that method calls can be chained together. */ public AccountLimit withCodeSizeUnzipped(Long codeSizeUnzipped) { setCodeSizeUnzipped(codeSizeUnzipped); return this; } /** *

* Size, in bytes, of a single zipped code/dependencies package you can upload for your Lambda function(.zip/.jar * file). Try using AWS S3 for uploading larger files. Default limit is 50 MB. *

* * @param codeSizeZipped * Size, in bytes, of a single zipped code/dependencies package you can upload for your Lambda * function(.zip/.jar file). Try using AWS S3 for uploading larger files. Default limit is 50 MB. */ public void setCodeSizeZipped(Long codeSizeZipped) { this.codeSizeZipped = codeSizeZipped; } /** *

* Size, in bytes, of a single zipped code/dependencies package you can upload for your Lambda function(.zip/.jar * file). Try using AWS S3 for uploading larger files. Default limit is 50 MB. *

* * @return Size, in bytes, of a single zipped code/dependencies package you can upload for your Lambda * function(.zip/.jar file). Try using AWS S3 for uploading larger files. Default limit is 50 MB. */ public Long getCodeSizeZipped() { return this.codeSizeZipped; } /** *

* Size, in bytes, of a single zipped code/dependencies package you can upload for your Lambda function(.zip/.jar * file). Try using AWS S3 for uploading larger files. Default limit is 50 MB. *

* * @param codeSizeZipped * Size, in bytes, of a single zipped code/dependencies package you can upload for your Lambda * function(.zip/.jar file). Try using AWS S3 for uploading larger files. Default limit is 50 MB. * @return Returns a reference to this object so that method calls can be chained together. */ public AccountLimit withCodeSizeZipped(Long codeSizeZipped) { setCodeSizeZipped(codeSizeZipped); return this; } /** *

* Number of simultaneous executions of your function per region. For more information or to request a limit * increase for concurrent executions, see Lambda Function Concurrent * Executions. The default limit is 100. *

* * @param concurrentExecutions * Number of simultaneous executions of your function per region. For more information or to request a limit * increase for concurrent executions, see Lambda Function Concurrent * Executions. The default limit is 100. */ public void setConcurrentExecutions(Integer concurrentExecutions) { this.concurrentExecutions = concurrentExecutions; } /** *

* Number of simultaneous executions of your function per region. For more information or to request a limit * increase for concurrent executions, see Lambda Function Concurrent * Executions. The default limit is 100. *

* * @return Number of simultaneous executions of your function per region. For more information or to request a limit * increase for concurrent executions, see Lambda Function Concurrent * Executions. The default limit is 100. */ public Integer getConcurrentExecutions() { return this.concurrentExecutions; } /** *

* Number of simultaneous executions of your function per region. For more information or to request a limit * increase for concurrent executions, see Lambda Function Concurrent * Executions. The default limit is 100. *

* * @param concurrentExecutions * Number of simultaneous executions of your function per region. For more information or to request a limit * increase for concurrent executions, see Lambda Function Concurrent * Executions. The default limit is 100. * @return Returns a reference to this object so that method calls can be chained together. */ public AccountLimit withConcurrentExecutions(Integer concurrentExecutions) { setConcurrentExecutions(concurrentExecutions); return this; } /** * Returns a string representation of this object; useful for testing and debugging. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getTotalCodeSize() != null) sb.append("TotalCodeSize: " + getTotalCodeSize() + ","); if (getCodeSizeUnzipped() != null) sb.append("CodeSizeUnzipped: " + getCodeSizeUnzipped() + ","); if (getCodeSizeZipped() != null) sb.append("CodeSizeZipped: " + getCodeSizeZipped() + ","); if (getConcurrentExecutions() != null) sb.append("ConcurrentExecutions: " + getConcurrentExecutions()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof AccountLimit == false) return false; AccountLimit other = (AccountLimit) obj; if (other.getTotalCodeSize() == null ^ this.getTotalCodeSize() == null) return false; if (other.getTotalCodeSize() != null && other.getTotalCodeSize().equals(this.getTotalCodeSize()) == false) return false; if (other.getCodeSizeUnzipped() == null ^ this.getCodeSizeUnzipped() == null) return false; if (other.getCodeSizeUnzipped() != null && other.getCodeSizeUnzipped().equals(this.getCodeSizeUnzipped()) == false) return false; if (other.getCodeSizeZipped() == null ^ this.getCodeSizeZipped() == null) return false; if (other.getCodeSizeZipped() != null && other.getCodeSizeZipped().equals(this.getCodeSizeZipped()) == false) return false; if (other.getConcurrentExecutions() == null ^ this.getConcurrentExecutions() == null) return false; if (other.getConcurrentExecutions() != null && other.getConcurrentExecutions().equals(this.getConcurrentExecutions()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getTotalCodeSize() == null) ? 0 : getTotalCodeSize().hashCode()); hashCode = prime * hashCode + ((getCodeSizeUnzipped() == null) ? 0 : getCodeSizeUnzipped().hashCode()); hashCode = prime * hashCode + ((getCodeSizeZipped() == null) ? 0 : getCodeSizeZipped().hashCode()); hashCode = prime * hashCode + ((getConcurrentExecutions() == null) ? 0 : getConcurrentExecutions().hashCode()); return hashCode; } @Override public AccountLimit clone() { try { return (AccountLimit) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy