cribl-control-plane 0.0.15__py3-none-any.whl → 0.0.17__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of cribl-control-plane might be problematic. Click here for more details.

Files changed (144) hide show
  1. cribl_control_plane/_version.py +3 -3
  2. cribl_control_plane/{outputs.py → destinations.py} +69 -71
  3. cribl_control_plane/errors/healthstatus_error.py +2 -8
  4. cribl_control_plane/models/__init__.py +5347 -115
  5. cribl_control_plane/models/createinputop.py +18216 -2
  6. cribl_control_plane/models/createoutputop.py +18417 -4
  7. cribl_control_plane/models/createoutputtestbyidop.py +2 -2
  8. cribl_control_plane/models/deleteoutputbyidop.py +2 -2
  9. cribl_control_plane/models/deleteoutputpqbyidop.py +2 -2
  10. cribl_control_plane/models/getoutputbyidop.py +2 -2
  11. cribl_control_plane/models/getoutputpqbyidop.py +2 -2
  12. cribl_control_plane/models/getoutputsamplesbyidop.py +2 -2
  13. cribl_control_plane/models/healthstatus.py +4 -7
  14. cribl_control_plane/models/inputappscope.py +16 -36
  15. cribl_control_plane/models/inputazureblob.py +8 -19
  16. cribl_control_plane/models/inputcollection.py +6 -15
  17. cribl_control_plane/models/inputconfluentcloud.py +22 -45
  18. cribl_control_plane/models/inputcribl.py +6 -13
  19. cribl_control_plane/models/inputcriblhttp.py +12 -27
  20. cribl_control_plane/models/inputcribllakehttp.py +14 -26
  21. cribl_control_plane/models/inputcriblmetrics.py +6 -14
  22. cribl_control_plane/models/inputcribltcp.py +12 -27
  23. cribl_control_plane/models/inputcrowdstrike.py +12 -28
  24. cribl_control_plane/models/inputdatadogagent.py +12 -28
  25. cribl_control_plane/models/inputdatagen.py +6 -13
  26. cribl_control_plane/models/inputedgeprometheus.py +33 -64
  27. cribl_control_plane/models/inputelastic.py +18 -44
  28. cribl_control_plane/models/inputeventhub.py +10 -19
  29. cribl_control_plane/models/inputexec.py +8 -16
  30. cribl_control_plane/models/inputfile.py +8 -17
  31. cribl_control_plane/models/inputfirehose.py +12 -27
  32. cribl_control_plane/models/inputgooglepubsub.py +10 -23
  33. cribl_control_plane/models/inputgrafana_union.py +39 -81
  34. cribl_control_plane/models/inputhttp.py +12 -27
  35. cribl_control_plane/models/inputhttpraw.py +12 -27
  36. cribl_control_plane/models/inputjournalfiles.py +8 -16
  37. cribl_control_plane/models/inputkafka.py +18 -45
  38. cribl_control_plane/models/inputkinesis.py +18 -42
  39. cribl_control_plane/models/inputkubeevents.py +6 -13
  40. cribl_control_plane/models/inputkubelogs.py +10 -18
  41. cribl_control_plane/models/inputkubemetrics.py +10 -18
  42. cribl_control_plane/models/inputloki.py +14 -33
  43. cribl_control_plane/models/inputmetrics.py +10 -25
  44. cribl_control_plane/models/inputmodeldriventelemetry.py +14 -33
  45. cribl_control_plane/models/inputmsk.py +20 -52
  46. cribl_control_plane/models/inputnetflow.py +8 -15
  47. cribl_control_plane/models/inputoffice365mgmt.py +18 -37
  48. cribl_control_plane/models/inputoffice365msgtrace.py +20 -41
  49. cribl_control_plane/models/inputoffice365service.py +20 -41
  50. cribl_control_plane/models/inputopentelemetry.py +20 -42
  51. cribl_control_plane/models/inputprometheus.py +22 -54
  52. cribl_control_plane/models/inputprometheusrw.py +14 -34
  53. cribl_control_plane/models/inputrawudp.py +8 -15
  54. cribl_control_plane/models/inputs3.py +10 -23
  55. cribl_control_plane/models/inputs3inventory.py +12 -28
  56. cribl_control_plane/models/inputsecuritylake.py +12 -29
  57. cribl_control_plane/models/inputsnmp.py +10 -20
  58. cribl_control_plane/models/inputsplunk.py +16 -37
  59. cribl_control_plane/models/inputsplunkhec.py +14 -33
  60. cribl_control_plane/models/inputsplunksearch.py +18 -37
  61. cribl_control_plane/models/inputsqs.py +14 -31
  62. cribl_control_plane/models/inputsyslog_union.py +29 -53
  63. cribl_control_plane/models/inputsystemmetrics.py +26 -50
  64. cribl_control_plane/models/inputsystemstate.py +10 -18
  65. cribl_control_plane/models/inputtcp.py +14 -33
  66. cribl_control_plane/models/inputtcpjson.py +14 -33
  67. cribl_control_plane/models/inputwef.py +22 -45
  68. cribl_control_plane/models/inputwindowsmetrics.py +26 -46
  69. cribl_control_plane/models/inputwineventlogs.py +12 -22
  70. cribl_control_plane/models/inputwiz.py +12 -25
  71. cribl_control_plane/models/inputzscalerhec.py +14 -33
  72. cribl_control_plane/models/listoutputop.py +2 -2
  73. cribl_control_plane/models/output.py +3 -6
  74. cribl_control_plane/models/outputazureblob.py +20 -52
  75. cribl_control_plane/models/outputazuredataexplorer.py +30 -77
  76. cribl_control_plane/models/outputazureeventhub.py +20 -44
  77. cribl_control_plane/models/outputazurelogs.py +14 -37
  78. cribl_control_plane/models/outputclickhouse.py +22 -59
  79. cribl_control_plane/models/outputcloudwatch.py +12 -33
  80. cribl_control_plane/models/outputconfluentcloud.py +32 -75
  81. cribl_control_plane/models/outputcriblhttp.py +18 -46
  82. cribl_control_plane/models/outputcribllake.py +18 -48
  83. cribl_control_plane/models/outputcribltcp.py +20 -47
  84. cribl_control_plane/models/outputcrowdstrikenextgensiem.py +16 -54
  85. cribl_control_plane/models/outputdatadog.py +22 -50
  86. cribl_control_plane/models/outputdataset.py +20 -48
  87. cribl_control_plane/models/outputdefault.py +2 -5
  88. cribl_control_plane/models/outputdevnull.py +2 -5
  89. cribl_control_plane/models/outputdiskspool.py +4 -9
  90. cribl_control_plane/models/outputdls3.py +26 -72
  91. cribl_control_plane/models/outputdynatracehttp.py +22 -57
  92. cribl_control_plane/models/outputdynatraceotlp.py +24 -59
  93. cribl_control_plane/models/outputelastic.py +20 -45
  94. cribl_control_plane/models/outputelasticcloud.py +14 -40
  95. cribl_control_plane/models/outputexabeam.py +12 -33
  96. cribl_control_plane/models/outputfilesystem.py +16 -41
  97. cribl_control_plane/models/outputgooglechronicle.py +18 -54
  98. cribl_control_plane/models/outputgooglecloudlogging.py +16 -46
  99. cribl_control_plane/models/outputgooglecloudstorage.py +26 -71
  100. cribl_control_plane/models/outputgooglepubsub.py +16 -39
  101. cribl_control_plane/models/{outputgrafanacloud_union.py → outputgrafanacloud.py} +49 -110
  102. cribl_control_plane/models/outputgraphite.py +16 -35
  103. cribl_control_plane/models/outputhoneycomb.py +14 -37
  104. cribl_control_plane/models/outputhumiohec.py +18 -47
  105. cribl_control_plane/models/outputinfluxdb.py +18 -44
  106. cribl_control_plane/models/outputkafka.py +28 -73
  107. cribl_control_plane/models/outputkinesis.py +18 -44
  108. cribl_control_plane/models/outputloki.py +18 -43
  109. cribl_control_plane/models/outputminio.py +26 -69
  110. cribl_control_plane/models/outputmsk.py +30 -81
  111. cribl_control_plane/models/outputnetflow.py +2 -5
  112. cribl_control_plane/models/outputnewrelic.py +20 -45
  113. cribl_control_plane/models/outputnewrelicevents.py +16 -45
  114. cribl_control_plane/models/outputopentelemetry.py +28 -69
  115. cribl_control_plane/models/outputprometheus.py +14 -37
  116. cribl_control_plane/models/outputring.py +10 -21
  117. cribl_control_plane/models/outputrouter.py +2 -5
  118. cribl_control_plane/models/outputs3.py +28 -72
  119. cribl_control_plane/models/outputsecuritylake.py +20 -56
  120. cribl_control_plane/models/outputsentinel.py +20 -49
  121. cribl_control_plane/models/outputsentineloneaisiem.py +20 -54
  122. cribl_control_plane/models/outputservicenow.py +26 -64
  123. cribl_control_plane/models/outputsignalfx.py +16 -39
  124. cribl_control_plane/models/outputsnmp.py +2 -5
  125. cribl_control_plane/models/outputsns.py +16 -40
  126. cribl_control_plane/models/outputsplunk.py +26 -64
  127. cribl_control_plane/models/outputsplunkhec.py +14 -37
  128. cribl_control_plane/models/outputsplunklb.py +36 -83
  129. cribl_control_plane/models/outputsqs.py +18 -45
  130. cribl_control_plane/models/outputstatsd.py +16 -34
  131. cribl_control_plane/models/outputstatsdext.py +14 -33
  132. cribl_control_plane/models/outputsumologic.py +14 -37
  133. cribl_control_plane/models/outputsyslog.py +26 -60
  134. cribl_control_plane/models/outputtcpjson.py +22 -54
  135. cribl_control_plane/models/outputwavefront.py +14 -37
  136. cribl_control_plane/models/outputwebhook.py +24 -60
  137. cribl_control_plane/models/outputxsiam.py +16 -37
  138. cribl_control_plane/models/updateoutputbyidop.py +4 -4
  139. cribl_control_plane/sdk.py +3 -5
  140. cribl_control_plane/sources.py +8 -10
  141. {cribl_control_plane-0.0.15.dist-info → cribl_control_plane-0.0.17.dist-info}/METADATA +13 -13
  142. cribl_control_plane-0.0.17.dist-info/RECORD +215 -0
  143. cribl_control_plane-0.0.15.dist-info/RECORD +0 -215
  144. {cribl_control_plane-0.0.15.dist-info → cribl_control_plane-0.0.17.dist-info}/WHEEL +0 -0
@@ -1,17 +1,14 @@
1
1
  """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
2
 
3
3
  from __future__ import annotations
4
- from cribl_control_plane import utils
5
4
  from cribl_control_plane.types import BaseModel
6
- from cribl_control_plane.utils import validate_open_enum
7
5
  from enum import Enum
8
6
  import pydantic
9
- from pydantic.functional_validators import PlainValidator
10
7
  from typing import List, Optional
11
8
  from typing_extensions import Annotated, NotRequired, TypedDict
12
9
 
13
10
 
14
- class InputEventhubType(str, Enum, metaclass=utils.OpenEnumMeta):
11
+ class InputEventhubType(str, Enum):
15
12
  EVENTHUB = "eventhub"
16
13
 
17
14
 
@@ -26,14 +23,14 @@ class InputEventhubConnection(BaseModel):
26
23
  pipeline: Optional[str] = None
27
24
 
28
25
 
29
- class InputEventhubMode(str, Enum, metaclass=utils.OpenEnumMeta):
26
+ class InputEventhubMode(str, Enum):
30
27
  r"""With Smart mode, PQ will write events to the filesystem only when it detects backpressure from the processing engine. With Always On mode, PQ will always write events directly to the queue before forwarding them to the processing engine."""
31
28
 
32
29
  SMART = "smart"
33
30
  ALWAYS = "always"
34
31
 
35
32
 
36
- class InputEventhubCompression(str, Enum, metaclass=utils.OpenEnumMeta):
33
+ class InputEventhubCompression(str, Enum):
37
34
  r"""Codec to use to compress the persisted data"""
38
35
 
39
36
  NONE = "none"
@@ -58,9 +55,7 @@ class InputEventhubPqTypedDict(TypedDict):
58
55
 
59
56
 
60
57
  class InputEventhubPq(BaseModel):
61
- mode: Annotated[
62
- Optional[InputEventhubMode], PlainValidator(validate_open_enum(False))
63
- ] = InputEventhubMode.ALWAYS
58
+ mode: Optional[InputEventhubMode] = InputEventhubMode.ALWAYS
64
59
  r"""With Smart mode, PQ will write events to the filesystem only when it detects backpressure from the processing engine. With Always On mode, PQ will always write events directly to the queue before forwarding them to the processing engine."""
65
60
 
66
61
  max_buffer_size: Annotated[
@@ -84,13 +79,11 @@ class InputEventhubPq(BaseModel):
84
79
  path: Optional[str] = "$CRIBL_HOME/state/queues"
85
80
  r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/inputs/<input-id>"""
86
81
 
87
- compress: Annotated[
88
- Optional[InputEventhubCompression], PlainValidator(validate_open_enum(False))
89
- ] = InputEventhubCompression.NONE
82
+ compress: Optional[InputEventhubCompression] = InputEventhubCompression.NONE
90
83
  r"""Codec to use to compress the persisted data"""
91
84
 
92
85
 
93
- class InputEventhubSASLMechanism(str, Enum, metaclass=utils.OpenEnumMeta):
86
+ class InputEventhubSASLMechanism(str, Enum):
94
87
  PLAIN = "plain"
95
88
  OAUTHBEARER = "oauthbearer"
96
89
 
@@ -107,9 +100,7 @@ class InputEventhubAuthentication(BaseModel):
107
100
 
108
101
  disabled: Optional[bool] = False
109
102
 
110
- mechanism: Annotated[
111
- Optional[InputEventhubSASLMechanism], PlainValidator(validate_open_enum(False))
112
- ] = InputEventhubSASLMechanism.PLAIN
103
+ mechanism: Optional[InputEventhubSASLMechanism] = InputEventhubSASLMechanism.PLAIN
113
104
 
114
105
 
115
106
  class InputEventhubTLSSettingsClientSideTypedDict(TypedDict):
@@ -141,13 +132,13 @@ class InputEventhubMetadatum(BaseModel):
141
132
 
142
133
 
143
134
  class InputEventhubTypedDict(TypedDict):
144
- type: InputEventhubType
145
135
  brokers: List[str]
146
136
  r"""List of Event Hubs Kafka brokers to connect to (example: yourdomain.servicebus.windows.net:9093). The hostname can be found in the host portion of the primary or secondary connection string in Shared Access Policies."""
147
137
  topics: List[str]
148
138
  r"""The name of the Event Hub (Kafka topic) to subscribe to. Warning: To optimize performance, Cribl suggests subscribing each Event Hubs Source to only a single topic."""
149
139
  id: NotRequired[str]
150
140
  r"""Unique ID for this input"""
141
+ type: NotRequired[InputEventhubType]
151
142
  disabled: NotRequired[bool]
152
143
  pipeline: NotRequired[str]
153
144
  r"""Pipeline to process data from this Source before sending it through the Routes"""
@@ -219,8 +210,6 @@ class InputEventhubTypedDict(TypedDict):
219
210
 
220
211
 
221
212
  class InputEventhub(BaseModel):
222
- type: Annotated[InputEventhubType, PlainValidator(validate_open_enum(False))]
223
-
224
213
  brokers: List[str]
225
214
  r"""List of Event Hubs Kafka brokers to connect to (example: yourdomain.servicebus.windows.net:9093). The hostname can be found in the host portion of the primary or secondary connection string in Shared Access Policies."""
226
215
 
@@ -230,6 +219,8 @@ class InputEventhub(BaseModel):
230
219
  id: Optional[str] = None
231
220
  r"""Unique ID for this input"""
232
221
 
222
+ type: Optional[InputEventhubType] = None
223
+
233
224
  disabled: Optional[bool] = False
234
225
 
235
226
  pipeline: Optional[str] = None
@@ -1,17 +1,14 @@
1
1
  """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
2
 
3
3
  from __future__ import annotations
4
- from cribl_control_plane import utils
5
4
  from cribl_control_plane.types import BaseModel
6
- from cribl_control_plane.utils import validate_open_enum
7
5
  from enum import Enum
8
6
  import pydantic
9
- from pydantic.functional_validators import PlainValidator
10
7
  from typing import List, Optional
11
8
  from typing_extensions import Annotated, NotRequired, TypedDict
12
9
 
13
10
 
14
- class InputExecType(str, Enum, metaclass=utils.OpenEnumMeta):
11
+ class InputExecType(str, Enum):
15
12
  EXEC = "exec"
16
13
 
17
14
 
@@ -26,14 +23,14 @@ class InputExecConnection(BaseModel):
26
23
  pipeline: Optional[str] = None
27
24
 
28
25
 
29
- class InputExecMode(str, Enum, metaclass=utils.OpenEnumMeta):
26
+ class InputExecMode(str, Enum):
30
27
  r"""With Smart mode, PQ will write events to the filesystem only when it detects backpressure from the processing engine. With Always On mode, PQ will always write events directly to the queue before forwarding them to the processing engine."""
31
28
 
32
29
  SMART = "smart"
33
30
  ALWAYS = "always"
34
31
 
35
32
 
36
- class InputExecCompression(str, Enum, metaclass=utils.OpenEnumMeta):
33
+ class InputExecCompression(str, Enum):
37
34
  r"""Codec to use to compress the persisted data"""
38
35
 
39
36
  NONE = "none"
@@ -58,9 +55,7 @@ class InputExecPqTypedDict(TypedDict):
58
55
 
59
56
 
60
57
  class InputExecPq(BaseModel):
61
- mode: Annotated[
62
- Optional[InputExecMode], PlainValidator(validate_open_enum(False))
63
- ] = InputExecMode.ALWAYS
58
+ mode: Optional[InputExecMode] = InputExecMode.ALWAYS
64
59
  r"""With Smart mode, PQ will write events to the filesystem only when it detects backpressure from the processing engine. With Always On mode, PQ will always write events directly to the queue before forwarding them to the processing engine."""
65
60
 
66
61
  max_buffer_size: Annotated[
@@ -84,13 +79,11 @@ class InputExecPq(BaseModel):
84
79
  path: Optional[str] = "$CRIBL_HOME/state/queues"
85
80
  r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/inputs/<input-id>"""
86
81
 
87
- compress: Annotated[
88
- Optional[InputExecCompression], PlainValidator(validate_open_enum(False))
89
- ] = InputExecCompression.NONE
82
+ compress: Optional[InputExecCompression] = InputExecCompression.NONE
90
83
  r"""Codec to use to compress the persisted data"""
91
84
 
92
85
 
93
- class ScheduleType(str, Enum, metaclass=utils.OpenEnumMeta):
86
+ class ScheduleType(str, Enum):
94
87
  r"""Select a schedule type; either an interval (in seconds) or a cron-style schedule."""
95
88
 
96
89
  INTERVAL = "interval"
@@ -148,7 +141,7 @@ class InputExecTypedDict(TypedDict):
148
141
 
149
142
 
150
143
  class InputExec(BaseModel):
151
- type: Annotated[InputExecType, PlainValidator(validate_open_enum(False))]
144
+ type: InputExecType
152
145
 
153
146
  command: str
154
147
  r"""Command to execute; supports Bourne shell (or CMD on Windows) syntax"""
@@ -184,8 +177,7 @@ class InputExec(BaseModel):
184
177
  r"""Maximum number of retry attempts in the event that the command fails"""
185
178
 
186
179
  schedule_type: Annotated[
187
- Annotated[Optional[ScheduleType], PlainValidator(validate_open_enum(False))],
188
- pydantic.Field(alias="scheduleType"),
180
+ Optional[ScheduleType], pydantic.Field(alias="scheduleType")
189
181
  ] = ScheduleType.INTERVAL
190
182
  r"""Select a schedule type; either an interval (in seconds) or a cron-style schedule."""
191
183
 
@@ -1,17 +1,14 @@
1
1
  """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
2
 
3
3
  from __future__ import annotations
4
- from cribl_control_plane import utils
5
4
  from cribl_control_plane.types import BaseModel
6
- from cribl_control_plane.utils import validate_open_enum
7
5
  from enum import Enum
8
6
  import pydantic
9
- from pydantic.functional_validators import PlainValidator
10
7
  from typing import List, Optional
11
8
  from typing_extensions import Annotated, NotRequired, TypedDict
12
9
 
13
10
 
14
- class InputFileType(str, Enum, metaclass=utils.OpenEnumMeta):
11
+ class InputFileType(str, Enum):
15
12
  FILE = "file"
16
13
 
17
14
 
@@ -26,14 +23,14 @@ class InputFileConnection(BaseModel):
26
23
  pipeline: Optional[str] = None
27
24
 
28
25
 
29
- class InputFilePqMode(str, Enum, metaclass=utils.OpenEnumMeta):
26
+ class InputFilePqMode(str, Enum):
30
27
  r"""With Smart mode, PQ will write events to the filesystem only when it detects backpressure from the processing engine. With Always On mode, PQ will always write events directly to the queue before forwarding them to the processing engine."""
31
28
 
32
29
  SMART = "smart"
33
30
  ALWAYS = "always"
34
31
 
35
32
 
36
- class InputFileCompression(str, Enum, metaclass=utils.OpenEnumMeta):
33
+ class InputFileCompression(str, Enum):
37
34
  r"""Codec to use to compress the persisted data"""
38
35
 
39
36
  NONE = "none"
@@ -58,9 +55,7 @@ class InputFilePqTypedDict(TypedDict):
58
55
 
59
56
 
60
57
  class InputFilePq(BaseModel):
61
- mode: Annotated[
62
- Optional[InputFilePqMode], PlainValidator(validate_open_enum(False))
63
- ] = InputFilePqMode.ALWAYS
58
+ mode: Optional[InputFilePqMode] = InputFilePqMode.ALWAYS
64
59
  r"""With Smart mode, PQ will write events to the filesystem only when it detects backpressure from the processing engine. With Always On mode, PQ will always write events directly to the queue before forwarding them to the processing engine."""
65
60
 
66
61
  max_buffer_size: Annotated[
@@ -84,13 +79,11 @@ class InputFilePq(BaseModel):
84
79
  path: Optional[str] = "$CRIBL_HOME/state/queues"
85
80
  r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/inputs/<input-id>"""
86
81
 
87
- compress: Annotated[
88
- Optional[InputFileCompression], PlainValidator(validate_open_enum(False))
89
- ] = InputFileCompression.NONE
82
+ compress: Optional[InputFileCompression] = InputFileCompression.NONE
90
83
  r"""Codec to use to compress the persisted data"""
91
84
 
92
85
 
93
- class InputFileMode(str, Enum, metaclass=utils.OpenEnumMeta):
86
+ class InputFileMode(str, Enum):
94
87
  r"""Choose how to discover files to monitor"""
95
88
 
96
89
  AUTO = "auto"
@@ -168,7 +161,7 @@ class InputFile(BaseModel):
168
161
  id: str
169
162
  r"""Unique ID for this input"""
170
163
 
171
- type: Annotated[InputFileType, PlainValidator(validate_open_enum(False))]
164
+ type: InputFileType
172
165
 
173
166
  disabled: Optional[bool] = False
174
167
 
@@ -194,9 +187,7 @@ class InputFile(BaseModel):
194
187
 
195
188
  pq: Optional[InputFilePq] = None
196
189
 
197
- mode: Annotated[
198
- Optional[InputFileMode], PlainValidator(validate_open_enum(False))
199
- ] = InputFileMode.AUTO
190
+ mode: Optional[InputFileMode] = InputFileMode.AUTO
200
191
  r"""Choose how to discover files to monitor"""
201
192
 
202
193
  interval: Optional[float] = 10
@@ -1,17 +1,14 @@
1
1
  """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
2
 
3
3
  from __future__ import annotations
4
- from cribl_control_plane import utils
5
4
  from cribl_control_plane.types import BaseModel
6
- from cribl_control_plane.utils import validate_open_enum
7
5
  from enum import Enum
8
6
  import pydantic
9
- from pydantic.functional_validators import PlainValidator
10
7
  from typing import Any, List, Optional
11
8
  from typing_extensions import Annotated, NotRequired, TypedDict
12
9
 
13
10
 
14
- class InputFirehoseType(str, Enum, metaclass=utils.OpenEnumMeta):
11
+ class InputFirehoseType(str, Enum):
15
12
  FIREHOSE = "firehose"
16
13
 
17
14
 
@@ -26,14 +23,14 @@ class InputFirehoseConnection(BaseModel):
26
23
  pipeline: Optional[str] = None
27
24
 
28
25
 
29
- class InputFirehoseMode(str, Enum, metaclass=utils.OpenEnumMeta):
26
+ class InputFirehoseMode(str, Enum):
30
27
  r"""With Smart mode, PQ will write events to the filesystem only when it detects backpressure from the processing engine. With Always On mode, PQ will always write events directly to the queue before forwarding them to the processing engine."""
31
28
 
32
29
  SMART = "smart"
33
30
  ALWAYS = "always"
34
31
 
35
32
 
36
- class InputFirehoseCompression(str, Enum, metaclass=utils.OpenEnumMeta):
33
+ class InputFirehoseCompression(str, Enum):
37
34
  r"""Codec to use to compress the persisted data"""
38
35
 
39
36
  NONE = "none"
@@ -58,9 +55,7 @@ class InputFirehosePqTypedDict(TypedDict):
58
55
 
59
56
 
60
57
  class InputFirehosePq(BaseModel):
61
- mode: Annotated[
62
- Optional[InputFirehoseMode], PlainValidator(validate_open_enum(False))
63
- ] = InputFirehoseMode.ALWAYS
58
+ mode: Optional[InputFirehoseMode] = InputFirehoseMode.ALWAYS
64
59
  r"""With Smart mode, PQ will write events to the filesystem only when it detects backpressure from the processing engine. With Always On mode, PQ will always write events directly to the queue before forwarding them to the processing engine."""
65
60
 
66
61
  max_buffer_size: Annotated[
@@ -84,20 +79,18 @@ class InputFirehosePq(BaseModel):
84
79
  path: Optional[str] = "$CRIBL_HOME/state/queues"
85
80
  r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/inputs/<input-id>"""
86
81
 
87
- compress: Annotated[
88
- Optional[InputFirehoseCompression], PlainValidator(validate_open_enum(False))
89
- ] = InputFirehoseCompression.NONE
82
+ compress: Optional[InputFirehoseCompression] = InputFirehoseCompression.NONE
90
83
  r"""Codec to use to compress the persisted data"""
91
84
 
92
85
 
93
- class InputFirehoseMinimumTLSVersion(str, Enum, metaclass=utils.OpenEnumMeta):
86
+ class InputFirehoseMinimumTLSVersion(str, Enum):
94
87
  TL_SV1 = "TLSv1"
95
88
  TL_SV1_1 = "TLSv1.1"
96
89
  TL_SV1_2 = "TLSv1.2"
97
90
  TL_SV1_3 = "TLSv1.3"
98
91
 
99
92
 
100
- class InputFirehoseMaximumTLSVersion(str, Enum, metaclass=utils.OpenEnumMeta):
93
+ class InputFirehoseMaximumTLSVersion(str, Enum):
101
94
  TL_SV1 = "TLSv1"
102
95
  TL_SV1_1 = "TLSv1.1"
103
96
  TL_SV1_2 = "TLSv1.2"
@@ -156,19 +149,11 @@ class InputFirehoseTLSSettingsServerSide(BaseModel):
156
149
  ] = None
157
150
 
158
151
  min_version: Annotated[
159
- Annotated[
160
- Optional[InputFirehoseMinimumTLSVersion],
161
- PlainValidator(validate_open_enum(False)),
162
- ],
163
- pydantic.Field(alias="minVersion"),
152
+ Optional[InputFirehoseMinimumTLSVersion], pydantic.Field(alias="minVersion")
164
153
  ] = None
165
154
 
166
155
  max_version: Annotated[
167
- Annotated[
168
- Optional[InputFirehoseMaximumTLSVersion],
169
- PlainValidator(validate_open_enum(False)),
170
- ],
171
- pydantic.Field(alias="maxVersion"),
156
+ Optional[InputFirehoseMaximumTLSVersion], pydantic.Field(alias="maxVersion")
172
157
  ] = None
173
158
 
174
159
 
@@ -186,11 +171,11 @@ class InputFirehoseMetadatum(BaseModel):
186
171
 
187
172
 
188
173
  class InputFirehoseTypedDict(TypedDict):
189
- type: InputFirehoseType
190
174
  port: float
191
175
  r"""Port to listen on"""
192
176
  id: NotRequired[str]
193
177
  r"""Unique ID for this input"""
178
+ type: NotRequired[InputFirehoseType]
194
179
  disabled: NotRequired[bool]
195
180
  pipeline: NotRequired[str]
196
181
  r"""Pipeline to process data from this Source before sending it through the Routes"""
@@ -238,14 +223,14 @@ class InputFirehoseTypedDict(TypedDict):
238
223
 
239
224
 
240
225
  class InputFirehose(BaseModel):
241
- type: Annotated[InputFirehoseType, PlainValidator(validate_open_enum(False))]
242
-
243
226
  port: float
244
227
  r"""Port to listen on"""
245
228
 
246
229
  id: Optional[str] = None
247
230
  r"""Unique ID for this input"""
248
231
 
232
+ type: Optional[InputFirehoseType] = None
233
+
249
234
  disabled: Optional[bool] = False
250
235
 
251
236
  pipeline: Optional[str] = None
@@ -1,17 +1,14 @@
1
1
  """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
2
 
3
3
  from __future__ import annotations
4
- from cribl_control_plane import utils
5
4
  from cribl_control_plane.types import BaseModel
6
- from cribl_control_plane.utils import validate_open_enum
7
5
  from enum import Enum
8
6
  import pydantic
9
- from pydantic.functional_validators import PlainValidator
10
7
  from typing import List, Optional
11
8
  from typing_extensions import Annotated, NotRequired, TypedDict
12
9
 
13
10
 
14
- class InputGooglePubsubType(str, Enum, metaclass=utils.OpenEnumMeta):
11
+ class InputGooglePubsubType(str, Enum):
15
12
  GOOGLE_PUBSUB = "google_pubsub"
16
13
 
17
14
 
@@ -26,14 +23,14 @@ class InputGooglePubsubConnection(BaseModel):
26
23
  pipeline: Optional[str] = None
27
24
 
28
25
 
29
- class InputGooglePubsubMode(str, Enum, metaclass=utils.OpenEnumMeta):
26
+ class InputGooglePubsubMode(str, Enum):
30
27
  r"""With Smart mode, PQ will write events to the filesystem only when it detects backpressure from the processing engine. With Always On mode, PQ will always write events directly to the queue before forwarding them to the processing engine."""
31
28
 
32
29
  SMART = "smart"
33
30
  ALWAYS = "always"
34
31
 
35
32
 
36
- class InputGooglePubsubCompression(str, Enum, metaclass=utils.OpenEnumMeta):
33
+ class InputGooglePubsubCompression(str, Enum):
37
34
  r"""Codec to use to compress the persisted data"""
38
35
 
39
36
  NONE = "none"
@@ -58,9 +55,7 @@ class InputGooglePubsubPqTypedDict(TypedDict):
58
55
 
59
56
 
60
57
  class InputGooglePubsubPq(BaseModel):
61
- mode: Annotated[
62
- Optional[InputGooglePubsubMode], PlainValidator(validate_open_enum(False))
63
- ] = InputGooglePubsubMode.ALWAYS
58
+ mode: Optional[InputGooglePubsubMode] = InputGooglePubsubMode.ALWAYS
64
59
  r"""With Smart mode, PQ will write events to the filesystem only when it detects backpressure from the processing engine. With Always On mode, PQ will always write events directly to the queue before forwarding them to the processing engine."""
65
60
 
66
61
  max_buffer_size: Annotated[
@@ -84,16 +79,11 @@ class InputGooglePubsubPq(BaseModel):
84
79
  path: Optional[str] = "$CRIBL_HOME/state/queues"
85
80
  r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/inputs/<input-id>"""
86
81
 
87
- compress: Annotated[
88
- Optional[InputGooglePubsubCompression],
89
- PlainValidator(validate_open_enum(False)),
90
- ] = InputGooglePubsubCompression.NONE
82
+ compress: Optional[InputGooglePubsubCompression] = InputGooglePubsubCompression.NONE
91
83
  r"""Codec to use to compress the persisted data"""
92
84
 
93
85
 
94
- class InputGooglePubsubGoogleAuthenticationMethod(
95
- str, Enum, metaclass=utils.OpenEnumMeta
96
- ):
86
+ class InputGooglePubsubGoogleAuthenticationMethod(str, Enum):
97
87
  r"""Choose Auto to use Google Application Default Credentials (ADC), Manual to enter Google service account credentials directly, or Secret to select or create a stored secret that references Google service account credentials."""
98
88
 
99
89
  AUTO = "auto"
@@ -115,13 +105,13 @@ class InputGooglePubsubMetadatum(BaseModel):
115
105
 
116
106
 
117
107
  class InputGooglePubsubTypedDict(TypedDict):
118
- type: InputGooglePubsubType
119
108
  topic_name: str
120
109
  r"""ID of the topic to receive events from"""
121
110
  subscription_name: str
122
111
  r"""ID of the subscription to use when receiving events"""
123
112
  id: NotRequired[str]
124
113
  r"""Unique ID for this input"""
114
+ type: NotRequired[InputGooglePubsubType]
125
115
  disabled: NotRequired[bool]
126
116
  pipeline: NotRequired[str]
127
117
  r"""Pipeline to process data from this Source before sending it through the Routes"""
@@ -162,8 +152,6 @@ class InputGooglePubsubTypedDict(TypedDict):
162
152
 
163
153
 
164
154
  class InputGooglePubsub(BaseModel):
165
- type: Annotated[InputGooglePubsubType, PlainValidator(validate_open_enum(False))]
166
-
167
155
  topic_name: Annotated[str, pydantic.Field(alias="topicName")]
168
156
  r"""ID of the topic to receive events from"""
169
157
 
@@ -173,6 +161,8 @@ class InputGooglePubsub(BaseModel):
173
161
  id: Optional[str] = None
174
162
  r"""Unique ID for this input"""
175
163
 
164
+ type: Optional[InputGooglePubsubType] = None
165
+
176
166
  disabled: Optional[bool] = False
177
167
 
178
168
  pipeline: Optional[str] = None
@@ -209,10 +199,7 @@ class InputGooglePubsub(BaseModel):
209
199
  r"""Region to retrieve messages from. Select 'default' to allow Google to auto-select the nearest region. When using ordered delivery, the selected region must be allowed by message storage policy."""
210
200
 
211
201
  google_auth_method: Annotated[
212
- Annotated[
213
- Optional[InputGooglePubsubGoogleAuthenticationMethod],
214
- PlainValidator(validate_open_enum(False)),
215
- ],
202
+ Optional[InputGooglePubsubGoogleAuthenticationMethod],
216
203
  pydantic.Field(alias="googleAuthMethod"),
217
204
  ] = InputGooglePubsubGoogleAuthenticationMethod.MANUAL
218
205
  r"""Choose Auto to use Google Application Default Credentials (ADC), Manual to enter Google service account credentials directly, or Secret to select or create a stored secret that references Google service account credentials."""