Skip to content

FunctionProps

Properties for defining a Function.

See https://www.alibabacloud.com/help/ros/developer-reference/aliyun-fc3-function

Initializer

import com.aliyun.ros.cdk.fc3.FunctionProps;
FunctionProps.builder()
    .functionName(java.lang.String)
    .functionName(IResolvable)
    .handler(java.lang.String)
    .handler(IResolvable)
    .runtime(java.lang.String)
    .runtime(IResolvable)
//  .code(IResolvable)
//  .code(CodeProperty)
//  .cpu(java.lang.Number)
//  .cpu(IResolvable)
//  .customContainerConfig(IResolvable)
//  .customContainerConfig(CustomContainerConfigProperty)
//  .customDns(IResolvable)
//  .customDns(CustomDnsProperty)
//  .customRuntimeConfig(IResolvable)
//  .customRuntimeConfig(CustomRuntimeConfigProperty)
//  .description(java.lang.String)
//  .description(IResolvable)
//  .diskSize(java.lang.Number)
//  .diskSize(IResolvable)
//  .environmentVariables(IResolvable)
//  .environmentVariables(java.util.Map<java.lang.String, java.lang.Object>)
//  .gpuConfig(IResolvable)
//  .gpuConfig(GpuConfigProperty)
//  .instanceConcurrency(java.lang.Number)
//  .instanceConcurrency(IResolvable)
//  .instanceLifecycleConfig(IResolvable)
//  .instanceLifecycleConfig(InstanceLifecycleConfigProperty)
//  .internetAccess(java.lang.Boolean)
//  .internetAccess(IResolvable)
//  .layers(IResolvable)
//  .layers(java.util.List<java.lang.String)
//  .layers(IResolvable>)
//  .logConfig(IResolvable)
//  .logConfig(LogConfigProperty)
//  .memorySize(java.lang.Number)
//  .memorySize(IResolvable)
//  .nasConfig(IResolvable)
//  .nasConfig(NasConfigProperty)
//  .ossMountConfig(IResolvable)
//  .ossMountConfig(OssMountConfigProperty)
//  .role(java.lang.String)
//  .role(IResolvable)
//  .timeout(java.lang.Number)
//  .timeout(IResolvable)
//  .tracingConfig(IResolvable)
//  .tracingConfig(TracingConfigProperty)
//  .vpcConfig(IResolvable)
//  .vpcConfig(VpcConfigProperty)
    .build();

Properties

Name Type Description
functionName java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property functionName: The name of the function.
handler java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property handler: The handler of the function.
runtime java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property runtime: The programming language of the function.
code com.aliyun.ros.cdk.core.IResolvable OR CodeProperty Property code: Function code ZIP package.
cpu java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property cpu: The CPU size of the function in vCPU as a multiple of 0.05 vCPU. The minimum value is 0.05 and the maximum value is 16. At the same time, the ratio of cpu to memorySize (in GB) should be between 1:1 and 1:4.
customContainerConfig com.aliyun.ros.cdk.core.IResolvable OR CustomContainerConfigProperty Property customContainerConfig: Custom container configuration.
customDns com.aliyun.ros.cdk.core.IResolvable OR CustomDnsProperty Property customDns: Custom DNS configuration.
customRuntimeConfig com.aliyun.ros.cdk.core.IResolvable OR CustomRuntimeConfigProperty Property customRuntimeConfig: Custom runtime configuration.
description java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property description: Function description.
diskSize java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property diskSize: The disk size of the function, in MB.
environmentVariables com.aliyun.ros.cdk.core.IResolvable OR java.util.Map Property environmentVariables: The environment variables of the function.
gpuConfig com.aliyun.ros.cdk.core.IResolvable OR GpuConfigProperty Property gpuConfig: The GPU configuration of the function.
instanceConcurrency java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property instanceConcurrency: The maximum number of concurrent instances of the function.
instanceLifecycleConfig com.aliyun.ros.cdk.core.IResolvable OR InstanceLifecycleConfigProperty Property instanceLifecycleConfig: The instance lifecycle configuration of the function.
internetAccess java.lang.Boolean OR com.aliyun.ros.cdk.core.IResolvable Property internetAccess: Whether the function can access the Internet.
layers com.aliyun.ros.cdk.core.IResolvable OR java.util.List Property layers: The layers of the function.
logConfig com.aliyun.ros.cdk.core.IResolvable OR LogConfigProperty Property logConfig: The log configuration of the function.
memorySize java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property memorySize: The memory size of the function, in MB.
nasConfig com.aliyun.ros.cdk.core.IResolvable OR NasConfigProperty Property nasConfig: The NAS configuration of the function.
ossMountConfig com.aliyun.ros.cdk.core.IResolvable OR OssMountConfigProperty Property ossMountConfig: The OSS mount configuration of the function.
role java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property role: The user is authorized to the RAM role of Function Compute.
timeout java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property timeout: The timeout of the function.
tracingConfig com.aliyun.ros.cdk.core.IResolvable OR TracingConfigProperty Property tracingConfig: The tracing configuration of the function.
vpcConfig com.aliyun.ros.cdk.core.IResolvable OR VpcConfigProperty Property vpcConfig: The VPC configuration of the function.

functionNameRequired

public java.lang.Object getFunctionName();
  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property functionName: The name of the function.


handlerRequired

public java.lang.Object getHandler();
  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property handler: The handler of the function.


runtimeRequired

public java.lang.Object getRuntime();
  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property runtime: The programming language of the function.


codeOptional

public java.lang.Object getCode();

Property code: Function code ZIP package.

Choose one of Code and CustomContainerConfig.


cpuOptional

public java.lang.Object getCpu();
  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property cpu: The CPU size of the function in vCPU as a multiple of 0.05 vCPU. The minimum value is 0.05 and the maximum value is 16. At the same time, the ratio of cpu to memorySize (in GB) should be between 1:1 and 1:4.


customContainerConfigOptional

public java.lang.Object getCustomContainerConfig();

Property customContainerConfig: Custom container configuration.

Choose one of Code and CustomContainerConfig.


customDnsOptional

public java.lang.Object getCustomDns();

Property customDns: Custom DNS configuration.


customRuntimeConfigOptional

public java.lang.Object getCustomRuntimeConfig();

Property customRuntimeConfig: Custom runtime configuration.


descriptionOptional

public java.lang.Object getDescription();
  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property description: Function description.


diskSizeOptional

public java.lang.Object getDiskSize();
  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property diskSize: The disk size of the function, in MB.


environmentVariablesOptional

public java.lang.Object getEnvironmentVariables();
  • Type: com.aliyun.ros.cdk.core.IResolvable OR java.util.Map

Property environmentVariables: The environment variables of the function.


gpuConfigOptional

public java.lang.Object getGpuConfig();

Property gpuConfig: The GPU configuration of the function.


instanceConcurrencyOptional

public java.lang.Object getInstanceConcurrency();
  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property instanceConcurrency: The maximum number of concurrent instances of the function.


instanceLifecycleConfigOptional

public java.lang.Object getInstanceLifecycleConfig();

Property instanceLifecycleConfig: The instance lifecycle configuration of the function.


internetAccessOptional

public java.lang.Object getInternetAccess();
  • Type: java.lang.Boolean OR com.aliyun.ros.cdk.core.IResolvable

Property internetAccess: Whether the function can access the Internet.


layersOptional

public java.lang.Object getLayers();
  • Type: com.aliyun.ros.cdk.core.IResolvable OR java.util.List

Property layers: The layers of the function.


logConfigOptional

public java.lang.Object getLogConfig();

Property logConfig: The log configuration of the function.


memorySizeOptional

public java.lang.Object getMemorySize();
  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property memorySize: The memory size of the function, in MB.


nasConfigOptional

public java.lang.Object getNasConfig();

Property nasConfig: The NAS configuration of the function.


ossMountConfigOptional

public java.lang.Object getOssMountConfig();

Property ossMountConfig: The OSS mount configuration of the function.


roleOptional

public java.lang.Object getRole();
  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property role: The user is authorized to the RAM role of Function Compute.

After setting, Function Compute will assume the role and generate temporary access credentials. The temporary access credentials of this role can be used in functions to access specified Alibaba Cloud services, such as OSS and OTS.


timeoutOptional

public java.lang.Object getTimeout();
  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property timeout: The timeout of the function.


tracingConfigOptional

public java.lang.Object getTracingConfig();

Property tracingConfig: The tracing configuration of the function.


vpcConfigOptional

public java.lang.Object getVpcConfig();

Property vpcConfig: The VPC configuration of the function.