Skip to content

Commit

Permalink
version: 0.1.28
Browse files Browse the repository at this point in the history
  • Loading branch information
wss-git committed Dec 23, 2021
1 parent da136aa commit c456b42
Show file tree
Hide file tree
Showing 31 changed files with 916 additions and 516 deletions.
86 changes: 52 additions & 34 deletions dist/command/alias.d.ts
Original file line number Diff line number Diff line change
@@ -1,103 +1,117 @@
export declare function get(): void;
export declare function list(): void;
export declare function publish(): void;
export declare function get(): void;
/**
* s alias <sub-command>\n
* s alias <sub-command> <options>
* @pre_help
* {"header":"Alias","content":"Service alias operation"}
* @pre_help
* {"header":"Document","content":"https://github.com/devsapp/fc/blob/main/docs/command/alias.md"}
* @after_help
* {"header": "SubCommand List", "content": [{"desc":"get","example":"Get alias details, you can get help through [s alias get -h]"},{"desc":"list","example":"View the list of service alias, you can get help through [s alias list -h]"},{"desc":"publish","example":"Publish service alias, you can get help through [s alias publish -h]"}]}
* {"header": "SubCommand List", "content": [{"desc":"get","example":"Get alias details; help command [s alias get -h]"},{"desc":"list","example":"View the list of alias; help command [s alias list -h]"},{"desc":"publish","example":"Publish alias; help command [s alias publish -h]"}]}
*/
export interface AliasInputsArgs {
}
/**
* s alias get\n
* s alias get <options>
* @pre_help
* {"header":"Alias get","content":"Get alias details"}
* @pre_help
* {"header":"Document","content":"https://github.com/devsapp/fc/blob/main/docs/command/alias.md"}
* @after_help
* {"ref":"GlobalParams"}
* @after_help
* {"ref":"GlobalDescribe"}
* @example
* {"header": "Examples with Yaml","content": ["$ s alias get --alias-name xxx"]}
* {"header": "Examples with Yaml","content": ["$ s alias get --alias-name aliasName"]}
* @example
* {"header": "Examples with CLI","content": ["$ s cli fc alias get --region cn-hangzhou --service-name name --alias-name xxx"]}
* {"header": "Examples with CLI","content": ["$ s cli fc alias get --region cn-hangzhou --service-name serviceName --alias-name aliasName"]}
*/
export interface AliasGetInputsArgs {
/**
* Specify the region of alicloud
* [C-Required] Specify the fc region, value: cn-hangzhou/cn-beijing/cn-beijing/cn-hangzhou/cn-shanghai/cn-qingdao/cn-zhangjiakou/cn-huhehaote/cn-shenzhen/cn-chengdu/cn-hongkong/ap-southeast-1/ap-southeast-2/ap-southeast-3/ap-southeast-5/ap-northeast-1/eu-central-1/eu-west-1/us-west-1/us-east-1/ap-south-1
*/
region: string;
/**
* Specify the alicloud fc service name
*/
* [C-Required] Specify the fc service name
*/
'service-name': string;
/**
* Specify the alias name parameter
*/
* [Required] Specify the fc alias name
*/
'alias-name': string;
}
/**
* s alias list <options>\n
* s alias list <options>
* @pre_help
* {"header":"Alias list","content":"View the list of service alias"}
* @pre_help
* {"header":"Document","content":"https://github.com/devsapp/fc/blob/main/docs/command/alias.md"}
* @after_help
* {"ref":"GlobalParams"}
* @after_help
* {"ref":"GlobalDescribe"}
* @example
* {"header": "Examples with Yaml","content": ["$ s alias list"]}
* @example
* {"header": "Examples with CLI","content": ["$ s cli fc alias list --region cn-hangzhou --service-name name"]}
* {"header": "Examples with CLI","content": ["$ s cli fc alias list --region cn-hangzhou --service-name serviceName"]}
*/
export interface AliasListInputsArgs {
/**
* Specify the region of alicloud
* [C-Required] Specify the fc region, value: cn-hangzhou/cn-beijing/cn-beijing/cn-hangzhou/cn-shanghai/cn-qingdao/cn-zhangjiakou/cn-huhehaote/cn-shenzhen/cn-chengdu/cn-hongkong/ap-southeast-1/ap-southeast-2/ap-southeast-3/ap-southeast-5/ap-northeast-1/eu-central-1/eu-west-1/us-west-1/us-east-1/ap-south-1
*/
region: string;
/**
* Specify the alicloud fc service name
* [C-Required] Specify the fc service name
*/
'service-name': string;
/**
* Table format output
* [Optional] Table format output
*/
'table': boolean;
}
/**
* s alias publish <options>\n
* s alias publish <options>
* @pre_help
* {"header":"Alias publish","content":"Publish service alias"}
* @pre_help
* {"header":"Document","content":"https://github.com/devsapp/fc/blob/main/docs/command/alias.md"}
* @after_help
* {"ref":"GlobalParams"}
* @after_help
* {"ref":"GlobalDescribe"}
* @example
* {"header": "Examples with Yaml","content": ["$ s alias publish --alias-name pre --version-id 2","$ s alias publish --description xxx --alias-name pre --version-id 2 --gversion 3 --weight 20"]}
* {"header": "Examples with Yaml","content": ["$ s alias publish --alias-name aliasName --version-id 2","$ s alias publish --description description --alias-name aliasName --version-id 2 --gversion 3 --weight 20"]}
* @example
* {"header": "Examples with CLI","content": ["$ s cli fc alias publish --region cn-hangzhou --service-name name --alias-name pre --version-id 2"]}
* {"header": "Examples with CLI","content": ["$ s cli fc alias publish --region cn-hangzhou --service-name serviceName --alias-name aliasName --version-id 2"]}
*/
export interface AliasPublishInputsArgs {
/**
* Specify the region of alicloud
* [C-Required] Specify the fc region, value: cn-hangzhou/cn-beijing/cn-beijing/cn-hangzhou/cn-shanghai/cn-qingdao/cn-zhangjiakou/cn-huhehaote/cn-shenzhen/cn-chengdu/cn-hongkong/ap-southeast-1/ap-southeast-2/ap-southeast-3/ap-southeast-5/ap-northeast-1/eu-central-1/eu-west-1/us-west-1/us-east-1/ap-south-1
*/
region: string;
/**
* Specify the alicloud fc service name
* [C-Required] Specify the fc service name
*/
'service-name': string;
/**
* Specify the alicloud fc alias name
* [Required] Specify the fc alias name
*/
'alias-name': string;
/**
* Specify the version parameter
* [Required] The version Id
*/
'version-id': string;
/**
* Specify the description parameter
* [Optional] Specify the alias description
*/
'description': string;
/**
* Specify the grayscale version id parameter
* [Optional] The grayscale version id
*/
'gversion': string;
/**
* Specify the weight parameter
* [Optional] The weight for grayscale version
*/
'weight': string;
}
Expand All @@ -107,23 +121,25 @@ export interface AliasPublishInputsArgs {
* {"header":"Alias remove","content":"Delete service alias"}
* @after_help
* {"ref":"GlobalParams"}
* @after_help
* {"ref":"GlobalDescribe"}
* @example
* {"header": "Examples with Yaml","content": ["$ s alias remove --alias-name xxx"]}
* @example
* {"header": "Examples with CLI","content": ["$ s cli fc alias remove --region cn-hangzhou --service-name name --alias-name xxx"]}
*/
export interface AliasDeleteInputsArgs {
/**
* Specify the region of alicloud
* [C-Required] Specify the fc region, value: cn-hangzhou/cn-beijing/cn-beijing/cn-hangzhou/cn-shanghai/cn-qingdao/cn-zhangjiakou/cn-huhehaote/cn-shenzhen/cn-chengdu/cn-hongkong/ap-southeast-1/ap-southeast-2/ap-southeast-3/ap-southeast-5/ap-northeast-1/eu-central-1/eu-west-1/us-west-1/us-east-1/ap-south-1
*/
region: string;
/**
* Specify the alicloud fc service name
*/
* [C-Required] Specify the fc service name
*/
'service-name': string;
/**
* Specify the alias name parameter
*/
* [Required] Specify the fc alias name
*/
'alias-name': string;
}
/**
Expand All @@ -132,18 +148,20 @@ export interface AliasDeleteInputsArgs {
* {"header":"Alias removeAll","content":"Delete service all alias"}
* @after_help
* {"ref":"GlobalParams"}
* @after_help
* {"ref":"GlobalDescribe"}
* @example
* {"header": "Examples with Yaml","content": ["$ s alias removeAll"]}
* @example
* {"header": "Examples with CLI","content": ["$ s cli fc alias removeAll --region cn-hangzhou --service-name name"]}
*/
export interface AliasDeleteAllInputsArgs {
/**
* Specify the region of alicloud
* [C-Required] Specify the fc region, value: cn-hangzhou/cn-beijing/cn-beijing/cn-hangzhou/cn-shanghai/cn-qingdao/cn-zhangjiakou/cn-huhehaote/cn-shenzhen/cn-chengdu/cn-hongkong/ap-southeast-1/ap-southeast-2/ap-southeast-3/ap-southeast-5/ap-northeast-1/eu-central-1/eu-west-1/us-west-1/us-east-1/ap-south-1
*/
region: string;
/**
* Specify the alicloud fc service name
*/
* [C-Required] Specify the fc service name
*/
'service-name': string;
}
98 changes: 52 additions & 46 deletions dist/command/eval.d.ts
Original file line number Diff line number Diff line change
@@ -1,84 +1,90 @@
import { IInputs } from '../lib/interface/interface';
export declare function start(inputs: IInputs): Promise<any>;
/**
* s eval <sub-command>\n
* s eval <sub-command>
* @pre_help
* {"header":"Eval","content":"Power tuning online functions"}
* @pre_help
* {"header":"Document","content":"https://github.com/devsapp/fc/blob/main/docs/command/eval.md"}
* @after_help
* {"header": "SubCommand List", "content": [{"name":"start","summary":"Power tuning online functions, you can get help through [s cli fc eval start -h]"}]}
* {"header": "SubCommand List", "content": [{"name":"start","summary":"Power tuning online functions; help command [s eval start -h]"}]}
*/
export interface EvalInputsArgs {
}
/**
* s start <options>\n
* s eval start <options>
* @pre_help
* {"header":"Eval start","content":"Power tuning start"}
* @pre_help
* {"header":"Document","content":"https://github.com/devsapp/fc/blob/main/docs/command/eval.md"}
* @after_help
* {"ref":"GlobalParams"}
* @after_help
* {"ref":"GlobalDescribe"}
* @example
* {"header": "Examples with CLI","content": ["$ s cli fc eval start --region cn-hangzhou --function-name myFunctionName --service-name myServiceName --function-type event --eval-type memory --run-count 10 --payload-file ./payload.file --memory-size 128,256,512,1024 --access default","\n$ s cli fc start --region cn-hangzhou --function-name myFunctionName --service-name myServiceName --function-type http --eval-type memory --run-count 50 --payload 'hello world' --memory-size 128,256,512,1024 --method get --path '/login' --query 'a=1&b=2' --access default", "\n$ s cli fc start --region cn-hangzhou --function-name myFunctionName --service-name myServiceName --function-type event --eval-type concurrency --memory 1536 --concurrency-args 2,30,5 --rt 250 --payload-file ./payload.file --access default","\n$ s cli fc start --region cn-hangzhou --function-name myFunctionName --service-name myServiceName --function-type http --eval-type concurrency --memory 1536 --concurrency-args 2,20,5 --rt 250 --method get --path '/login' --query 'a=1&b=2' --access default"]}
* {"header": "Examples with Yaml","content": ["$ s eval start --eval-type memory --run-count 10 --payload-file ./payload.file --memory-size 128,256,512,1024 ","$ s eval start --eval-type concurrency --memory 1536 --concurrency-args 2,20,5 --rt 250 --method get --path '/login' --query 'a=1&b=2'", "$ s eval start --eval-type concurrencyPostman --memory 1536 --concurrency-args 2,20,5 --rt 250 --payload-file ./postman.json"]}
* @example
* {"header": "Examples with CLI","content": ["$ s cli fc eval start --region cn-hangzhou --function-name functionName --service-name serviceName --eval-type memory --run-count 10 --payload 'hello world' --memory-size 128,256,512,1024 --access default", "$ s cli fc eval start --region cn-hangzhou --function-name functionName --service-name serviceName --eval-type concurrency --memory 1536 --concurrency-args 2,30,5 --rt 250 --method get --path '/login' --query 'a=1&b=2' --access default", "$ s cli fc eval start --region cn-hangzhou --function-name functionName --service-name serviceName --eval-type concurrencyPostman --memory 1536 --concurrency-args 2,20,5 --rt 250 --payload-file ./postman.json --access default"]}
*/
export interface EvalStartInputsArgs {
/**
* Specify the region of alicloud
* @alias r
*/
* [C-Required] Specify the fc region, value: cn-hangzhou/cn-beijing/cn-beijing/cn-hangzhou/cn-shanghai/cn-qingdao/cn-zhangjiakou/cn-huhehaote/cn-shenzhen/cn-chengdu/cn-hongkong/ap-southeast-1/ap-southeast-2/ap-southeast-3/ap-southeast-5/ap-northeast-1/eu-central-1/eu-west-1/us-west-1/us-east-1/ap-south-1
*/
region: string;
/**
* Specify the alicloud fc service name
*/
* [C-Required] Specify the fc service name
*/
'service-name': string;
/**
* Specify the alicloud fc function name
* [C-Required] Specify the fc function name
*/
'function-name'?: string;
/**
* Type of the power tuning, including memory and concurrency
*/
'eval-type': string;
/**
* Type of the target function, including event and http
*/
'function-type': string;
'function-name': string;
/**
* Number of Invoke Function, only for --eval-type memory
*/
'run-count': number;
/**
* Function MemorySize List of power tuning, only for --eval-type memory
*/
'memory-size': string;
/**
* Concurrency args of power tuning that can convert to concurrency list, only for --eval-type concurrency
*/
* [Optional] Concurrency args of power tuning that can convert to concurrency list, for --eval-type concurrency or concurrencyPostman
*/
'concurrency-args': string;
/**
* Function memory of power tuning, only for --eval-type concurrency
*/
'memory': number;
* [Optional] Type of the power tuning, value: memory/concurrency/concurrencyPostman
*/
'eval-type': string;
/**
* Max response time, only for --eval-type concurrency
*/
'rt': number;
* [Optional] Function MemorySize List of power tuning, only for --eval-type memory
*/
'memory-size': string;
/**
* Target method, only for --function-type http
*/
* [Optional] Target method, only for HTTP function
*/
'method': string;
/**
* Target path, only for --function-type http
*/
* [Optional] Target path, only for HTTP function
*/
'path': string;
/**
* Target query, only for --function-type http
*/
* [Optional] Target query, only for HTTP function
*/
'query': string;
/**
* For --function-type event, represents the event passed to the function;\nFor --function-type http, represents the request body passed to the function
*/
* [Optional] Target headers, only for HTTP function
*/
'headers': string;
/**
* [Optional] Represents the event(Event function)/request_body(HTTP function) passed to the function
*/
'payload': string;
/**
* For --function-type event, contains the event passed to the function;\nFor --function-type http, contains the request body passed to the function
* @alias f
*/
* [Optional] Represents the the event(Event function)/request_body(HTTP function)/postman-export-json-file which be readed from file to pass to the function
*/
'payload-file': string;
/**
* [Optional] Max response time, only for --eval-type concurrency/concurrencyPostman
*/
'rt': number;
/**
* [Optional] Number of Invoke Function, only for --eval-type memory
*/
'run-count': number;
/**
* [Optional] Function memory of power tuning, only for --eval-type concurrency/concurrencyPostman
*/
'memory': number;
}
20 changes: 12 additions & 8 deletions dist/command/fun2s.d.ts
Original file line number Diff line number Diff line change
@@ -1,27 +1,31 @@
/**
* s cli fc fun2s <options>\n
* s cli fc fun2s <options>
* @pre_help
* {"header":"Fun2s","content":"Convert fun into exclusive configuration"}
* {"header":"Fun2s","content":"Convert the Yaml specification of Funcraft to the Yaml specification of Serverless Devs."}
* @pre_help
* {"header":"Document","content":"https://github.com/devsapp/fc/blob/main/docs/command/fun2s.md"}
* @after_help
* {"ref":"GlobalParams"}
* @after_help
* {"ref":"GlobalDescribe"}
* @example
* {"header": "Examples with CLI","content": ["$ s cli fc fun2s --region cn-shenzhen --target ./s.yml"]}
* {"header": "Examples with CLI","content": ["$ s cli fc fun2s --region cn-shenzhen --target ./s.yaml"]}
*/
export interface Fun2SInputsArgs {
/**
* Specify the region of alicloud
* [Optional] Specify the fc region, value: cn-hangzhou/cn-beijing/cn-beijing/cn-hangzhou/cn-shanghai/cn-qingdao/cn-zhangjiakou/cn-huhehaote/cn-shenzhen/cn-chengdu/cn-hongkong/ap-southeast-1/ap-southeast-2/ap-southeast-3/ap-southeast-5/ap-northeast-1/eu-central-1/eu-west-1/us-west-1/us-east-1/ap-south-1
*/
region?: string;
/**
* Specify fun configuration path(default: template.[yaml|yml])
* [Optional] Specify Funcraft configuration path, default: template.yaml/template.yml
*/
source?: string;
/**
* Specify serverless devs configuration path(default: s.yaml)
* [Optional] Specify Serverless Devs configuration path, default: s.yaml
*/
target?: string;
/**
* Mandatory overwrite s file
* [Optional] Mandatory overwrite s file
*/
force?: string;
force?: boolean;
}
Loading

0 comments on commit c456b42

Please sign in to comment.