closes https://github.com/twentyhq/core-team-issues/issues/242 - unify timeout behavior between local and lambda - add timeout in serverless entity - set timeout default to 300s (5min)
31 lines
465 B
TypeScript
31 lines
465 B
TypeScript
import { Field, InputType } from '@nestjs/graphql';
|
|
|
|
import {
|
|
IsNotEmpty,
|
|
IsNumber,
|
|
IsOptional,
|
|
IsString,
|
|
Max,
|
|
Min,
|
|
} from 'class-validator';
|
|
|
|
@InputType()
|
|
export class CreateServerlessFunctionInput {
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
@Field()
|
|
name: string;
|
|
|
|
@IsString()
|
|
@IsOptional()
|
|
@Field({ nullable: true })
|
|
description?: string;
|
|
|
|
@IsNumber()
|
|
@Field({ nullable: true })
|
|
@Min(1)
|
|
@Max(900)
|
|
@IsOptional()
|
|
timeoutSeconds?: number;
|
|
}
|