|
4808 | 4808 | } |
4809 | 4809 | }, |
4810 | 4810 | "ScheduleBase": { |
| 4811 | + "description": "Base definition of a schedule", |
| 4812 | + "required": [ |
| 4813 | + "scheduleType" |
| 4814 | + ], |
4811 | 4815 | "type": "object", |
4812 | 4816 | "properties": { |
4813 | | - "id": { |
| 4817 | + "endTime": { |
| 4818 | + "format": "date-time", |
| 4819 | + "description": "Specifies end time of schedule in ISO 8601 format.\r\nIf not present, the schedule will run indefinitely", |
4814 | 4820 | "type": "string", |
4815 | 4821 | "x-nullable": true |
4816 | 4822 | }, |
4817 | | - "provisioningStatus": { |
4818 | | - "$ref": "#/definitions/ScheduleProvisioningState" |
4819 | | - }, |
4820 | | - "status": { |
| 4823 | + "scheduleStatus": { |
| 4824 | + "description": "Specifies the schedule's status", |
| 4825 | + "default": "Enabled", |
4821 | 4826 | "$ref": "#/definitions/ScheduleStatus" |
| 4827 | + }, |
| 4828 | + "scheduleType": { |
| 4829 | + "description": "[Required] Specifies the schedule type", |
| 4830 | + "$ref": "#/definitions/ScheduleType", |
| 4831 | + "x-ms-mutability": [ |
| 4832 | + "create", |
| 4833 | + "read" |
| 4834 | + ] |
| 4835 | + }, |
| 4836 | + "startTime": { |
| 4837 | + "format": "date-time", |
| 4838 | + "description": "Specifies start time of schedule in ISO 8601 format.", |
| 4839 | + "type": "string", |
| 4840 | + "x-nullable": true |
| 4841 | + }, |
| 4842 | + "timeZone": { |
| 4843 | + "description": "Specifies time zone in which the schedule runs.\r\nTimeZone should follow Windows time zone format.", |
| 4844 | + "default": "UTC", |
| 4845 | + "type": "string", |
| 4846 | + "x-nullable": true |
| 4847 | + } |
| 4848 | + }, |
| 4849 | + "discriminator": "scheduleType" |
| 4850 | + }, |
| 4851 | + "ScheduleType": { |
| 4852 | + "description": "Enum to describe type of schedule", |
| 4853 | + "enum": [ |
| 4854 | + "Cron", |
| 4855 | + "Recurrence" |
| 4856 | + ], |
| 4857 | + "type": "string", |
| 4858 | + "x-ms-enum": { |
| 4859 | + "name": "ScheduleType", |
| 4860 | + "modelAsString": true, |
| 4861 | + "values": [ |
| 4862 | + { |
| 4863 | + "value": "Cron", |
| 4864 | + "description": "Cron schedule type" |
| 4865 | + }, |
| 4866 | + { |
| 4867 | + "value": "Recurrence", |
| 4868 | + "description": "Recurrence schedule type" |
| 4869 | + } |
| 4870 | + ] |
| 4871 | + }, |
| 4872 | + "additionalProperties": false |
| 4873 | + }, |
| 4874 | + "CronSchedule": { |
| 4875 | + "description": "Cron schedule definition", |
| 4876 | + "required": [ |
| 4877 | + "expression" |
| 4878 | + ], |
| 4879 | + "type": "object", |
| 4880 | + "allOf": [ |
| 4881 | + { |
| 4882 | + "$ref": "#/definitions/ScheduleBase" |
| 4883 | + } |
| 4884 | + ], |
| 4885 | + "properties": { |
| 4886 | + "expression": { |
| 4887 | + "description": "[Required] Specifies cron expression of schedule.\r\nThe expression should follow NCronTab format.", |
| 4888 | + "pattern": "[a-zA-Z0-9_]", |
| 4889 | + "type": "string" |
| 4890 | + } |
| 4891 | + }, |
| 4892 | + "x-ms-discriminator-value": "Cron", |
| 4893 | + "additionalProperties": false |
| 4894 | + }, |
| 4895 | + "RecurrenceSchedule": { |
| 4896 | + "description": "Recurrence schedule definition", |
| 4897 | + "required": [ |
| 4898 | + "frequency", |
| 4899 | + "interval" |
| 4900 | + ], |
| 4901 | + "type": "object", |
| 4902 | + "allOf": [ |
| 4903 | + { |
| 4904 | + "$ref": "#/definitions/ScheduleBase" |
| 4905 | + } |
| 4906 | + ], |
| 4907 | + "properties": { |
| 4908 | + "frequency": { |
| 4909 | + "description": "[Required] Specifies frequency with with which to trigger schedule", |
| 4910 | + "$ref": "#/definitions/RecurrenceFrequency" |
| 4911 | + }, |
| 4912 | + "interval": { |
| 4913 | + "format": "int32", |
| 4914 | + "description": "[Required] Specifies schedule interval in conjunction with frequency", |
| 4915 | + "type": "integer" |
| 4916 | + }, |
| 4917 | + "pattern": { |
| 4918 | + "description": "Specifies the recurrence schedule pattern", |
| 4919 | + "$ref": "#/definitions/RecurrencePattern", |
| 4920 | + "x-nullable": true |
4822 | 4921 | } |
4823 | 4922 | }, |
| 4923 | + "x-ms-discriminator-value": "Recurrence", |
4824 | 4924 | "additionalProperties": false |
4825 | 4925 | }, |
4826 | | - "ScheduleProvisioningState": { |
| 4926 | + "RecurrenceFrequency": { |
| 4927 | + "description": "Enum to describe the frequency of a recurrence schedule", |
4827 | 4928 | "enum": [ |
4828 | | - "Completed", |
4829 | | - "Provisioning", |
4830 | | - "Failed" |
| 4929 | + "Minute", |
| 4930 | + "Hour", |
| 4931 | + "Day", |
| 4932 | + "Week", |
| 4933 | + "Month" |
4831 | 4934 | ], |
4832 | 4935 | "type": "string", |
4833 | 4936 | "x-ms-enum": { |
4834 | | - "name": "ScheduleProvisioningState", |
| 4937 | + "name": "RecurrenceFrequency", |
4835 | 4938 | "modelAsString": true, |
4836 | 4939 | "values": [ |
4837 | 4940 | { |
4838 | | - "value": "Completed" |
| 4941 | + "value": "Minute", |
| 4942 | + "description": "Minute frequency" |
| 4943 | + }, |
| 4944 | + { |
| 4945 | + "value": "Hour", |
| 4946 | + "description": "Hour frequency" |
| 4947 | + }, |
| 4948 | + { |
| 4949 | + "value": "Day", |
| 4950 | + "description": "Day frequency" |
| 4951 | + }, |
| 4952 | + { |
| 4953 | + "value": "Week", |
| 4954 | + "description": "Week frequency" |
| 4955 | + }, |
| 4956 | + { |
| 4957 | + "value": "Month", |
| 4958 | + "description": "Month frequency" |
| 4959 | + } |
| 4960 | + ] |
| 4961 | + }, |
| 4962 | + "additionalProperties": false |
| 4963 | + }, |
| 4964 | + "RecurrencePattern": { |
| 4965 | + "description": "Recurrence schedule pattern definition", |
| 4966 | + "required": [ |
| 4967 | + "hours", |
| 4968 | + "minutes" |
| 4969 | + ], |
| 4970 | + "type": "object", |
| 4971 | + "properties": { |
| 4972 | + "hours": { |
| 4973 | + "description": "[Required] List of hours for recurrence schedule pattern", |
| 4974 | + "type": "array", |
| 4975 | + "items": { |
| 4976 | + "format": "int32", |
| 4977 | + "type": "integer" |
| 4978 | + } |
| 4979 | + }, |
| 4980 | + "minutes": { |
| 4981 | + "description": "[Required] List of minutes for recurrence schedule pattern", |
| 4982 | + "type": "array", |
| 4983 | + "items": { |
| 4984 | + "format": "int32", |
| 4985 | + "type": "integer" |
| 4986 | + } |
| 4987 | + }, |
| 4988 | + "weekdays": { |
| 4989 | + "description": "List of weekdays for recurrence schedule pattern", |
| 4990 | + "type": "array", |
| 4991 | + "items": { |
| 4992 | + "$ref": "#/definitions/Weekday" |
| 4993 | + }, |
| 4994 | + "x-nullable": true |
| 4995 | + } |
| 4996 | + }, |
| 4997 | + "additionalProperties": false |
| 4998 | + }, |
| 4999 | + "Weekday": { |
| 5000 | + "description": "Enum of weekdays", |
| 5001 | + "enum": [ |
| 5002 | + "Monday", |
| 5003 | + "Tuesday", |
| 5004 | + "Wednesday", |
| 5005 | + "Thursday", |
| 5006 | + "Friday", |
| 5007 | + "Saturday", |
| 5008 | + "Sunday" |
| 5009 | + ], |
| 5010 | + "type": "string", |
| 5011 | + "x-ms-enum": { |
| 5012 | + "name": "Weekday", |
| 5013 | + "modelAsString": true, |
| 5014 | + "values": [ |
| 5015 | + { |
| 5016 | + "value": "Monday", |
| 5017 | + "description": "Monday weekday" |
| 5018 | + }, |
| 5019 | + { |
| 5020 | + "value": "Tuesday", |
| 5021 | + "description": "Tuesday weekday" |
| 5022 | + }, |
| 5023 | + { |
| 5024 | + "value": "Wednesday", |
| 5025 | + "description": "Wednesday weekday" |
| 5026 | + }, |
| 5027 | + { |
| 5028 | + "value": "Thursday", |
| 5029 | + "description": "Thursday weekday" |
| 5030 | + }, |
| 5031 | + { |
| 5032 | + "value": "Friday", |
| 5033 | + "description": "Friday weekday" |
4839 | 5034 | }, |
4840 | 5035 | { |
4841 | | - "value": "Provisioning" |
| 5036 | + "value": "Saturday", |
| 5037 | + "description": "Saturday weekday" |
4842 | 5038 | }, |
4843 | 5039 | { |
4844 | | - "value": "Failed" |
| 5040 | + "value": "Sunday", |
| 5041 | + "description": "Sunday weekday" |
4845 | 5042 | } |
4846 | 5043 | ] |
4847 | 5044 | }, |
4848 | 5045 | "additionalProperties": false |
4849 | 5046 | }, |
4850 | 5047 | "ScheduleStatus": { |
| 5048 | + "description": "Enum to describe status of schedule", |
4851 | 5049 | "enum": [ |
4852 | 5050 | "Enabled", |
4853 | 5051 | "Disabled" |
|
4858 | 5056 | "modelAsString": true, |
4859 | 5057 | "values": [ |
4860 | 5058 | { |
4861 | | - "value": "Enabled" |
| 5059 | + "value": "Enabled", |
| 5060 | + "description": "Schedule is enabled" |
4862 | 5061 | }, |
4863 | 5062 | { |
4864 | | - "value": "Disabled" |
| 5063 | + "value": "Disabled", |
| 5064 | + "description": "Schedule is disabled" |
4865 | 5065 | } |
4866 | 5066 | ] |
4867 | 5067 | }, |
|
0 commit comments