cribl-control-plane 0.0.13__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.
- cribl_control_plane/__init__.py +17 -0
- cribl_control_plane/_hooks/__init__.py +5 -0
- cribl_control_plane/_hooks/clientcredentials.py +211 -0
- cribl_control_plane/_hooks/registration.py +13 -0
- cribl_control_plane/_hooks/sdkhooks.py +81 -0
- cribl_control_plane/_hooks/types.py +112 -0
- cribl_control_plane/_version.py +15 -0
- cribl_control_plane/auth_sdk.py +184 -0
- cribl_control_plane/basesdk.py +358 -0
- cribl_control_plane/errors/__init__.py +60 -0
- cribl_control_plane/errors/apierror.py +38 -0
- cribl_control_plane/errors/criblcontrolplaneerror.py +26 -0
- cribl_control_plane/errors/error.py +24 -0
- cribl_control_plane/errors/healthstatus_error.py +38 -0
- cribl_control_plane/errors/no_response_error.py +13 -0
- cribl_control_plane/errors/responsevalidationerror.py +25 -0
- cribl_control_plane/health.py +166 -0
- cribl_control_plane/httpclient.py +126 -0
- cribl_control_plane/models/__init__.py +7305 -0
- cribl_control_plane/models/addhectokenrequest.py +34 -0
- cribl_control_plane/models/authtoken.py +13 -0
- cribl_control_plane/models/createinputhectokenbyidop.py +45 -0
- cribl_control_plane/models/createinputop.py +24 -0
- cribl_control_plane/models/createoutputop.py +24 -0
- cribl_control_plane/models/createoutputtestbyidop.py +46 -0
- cribl_control_plane/models/criblevent.py +14 -0
- cribl_control_plane/models/deleteinputbyidop.py +37 -0
- cribl_control_plane/models/deleteoutputbyidop.py +37 -0
- cribl_control_plane/models/deleteoutputpqbyidop.py +36 -0
- cribl_control_plane/models/getinputbyidop.py +37 -0
- cribl_control_plane/models/getoutputbyidop.py +37 -0
- cribl_control_plane/models/getoutputpqbyidop.py +36 -0
- cribl_control_plane/models/getoutputsamplesbyidop.py +37 -0
- cribl_control_plane/models/healthstatus.py +36 -0
- cribl_control_plane/models/input.py +199 -0
- cribl_control_plane/models/inputappscope.py +448 -0
- cribl_control_plane/models/inputazureblob.py +308 -0
- cribl_control_plane/models/inputcollection.py +208 -0
- cribl_control_plane/models/inputconfluentcloud.py +585 -0
- cribl_control_plane/models/inputcribl.py +165 -0
- cribl_control_plane/models/inputcriblhttp.py +341 -0
- cribl_control_plane/models/inputcribllakehttp.py +342 -0
- cribl_control_plane/models/inputcriblmetrics.py +175 -0
- cribl_control_plane/models/inputcribltcp.py +299 -0
- cribl_control_plane/models/inputcrowdstrike.py +410 -0
- cribl_control_plane/models/inputdatadogagent.py +364 -0
- cribl_control_plane/models/inputdatagen.py +180 -0
- cribl_control_plane/models/inputedgeprometheus.py +551 -0
- cribl_control_plane/models/inputelastic.py +494 -0
- cribl_control_plane/models/inputeventhub.py +360 -0
- cribl_control_plane/models/inputexec.py +213 -0
- cribl_control_plane/models/inputfile.py +259 -0
- cribl_control_plane/models/inputfirehose.py +341 -0
- cribl_control_plane/models/inputgooglepubsub.py +247 -0
- cribl_control_plane/models/inputgrafana_union.py +1247 -0
- cribl_control_plane/models/inputhttp.py +403 -0
- cribl_control_plane/models/inputhttpraw.py +407 -0
- cribl_control_plane/models/inputjournalfiles.py +208 -0
- cribl_control_plane/models/inputkafka.py +581 -0
- cribl_control_plane/models/inputkinesis.py +363 -0
- cribl_control_plane/models/inputkubeevents.py +182 -0
- cribl_control_plane/models/inputkubelogs.py +256 -0
- cribl_control_plane/models/inputkubemetrics.py +233 -0
- cribl_control_plane/models/inputloki.py +468 -0
- cribl_control_plane/models/inputmetrics.py +290 -0
- cribl_control_plane/models/inputmodeldriventelemetry.py +274 -0
- cribl_control_plane/models/inputmsk.py +654 -0
- cribl_control_plane/models/inputnetflow.py +224 -0
- cribl_control_plane/models/inputoffice365mgmt.py +384 -0
- cribl_control_plane/models/inputoffice365msgtrace.py +449 -0
- cribl_control_plane/models/inputoffice365service.py +377 -0
- cribl_control_plane/models/inputopentelemetry.py +516 -0
- cribl_control_plane/models/inputprometheus.py +464 -0
- cribl_control_plane/models/inputprometheusrw.py +470 -0
- cribl_control_plane/models/inputrawudp.py +207 -0
- cribl_control_plane/models/inputs3.py +416 -0
- cribl_control_plane/models/inputs3inventory.py +440 -0
- cribl_control_plane/models/inputsecuritylake.py +425 -0
- cribl_control_plane/models/inputsnmp.py +274 -0
- cribl_control_plane/models/inputsplunk.py +387 -0
- cribl_control_plane/models/inputsplunkhec.py +478 -0
- cribl_control_plane/models/inputsplunksearch.py +537 -0
- cribl_control_plane/models/inputsqs.py +320 -0
- cribl_control_plane/models/inputsyslog_union.py +759 -0
- cribl_control_plane/models/inputsystemmetrics.py +533 -0
- cribl_control_plane/models/inputsystemstate.py +417 -0
- cribl_control_plane/models/inputtcp.py +359 -0
- cribl_control_plane/models/inputtcpjson.py +334 -0
- cribl_control_plane/models/inputwef.py +498 -0
- cribl_control_plane/models/inputwindowsmetrics.py +457 -0
- cribl_control_plane/models/inputwineventlogs.py +222 -0
- cribl_control_plane/models/inputwiz.py +334 -0
- cribl_control_plane/models/inputzscalerhec.py +439 -0
- cribl_control_plane/models/listinputop.py +24 -0
- cribl_control_plane/models/listoutputop.py +24 -0
- cribl_control_plane/models/logininfo.py +16 -0
- cribl_control_plane/models/output.py +229 -0
- cribl_control_plane/models/outputazureblob.py +471 -0
- cribl_control_plane/models/outputazuredataexplorer.py +660 -0
- cribl_control_plane/models/outputazureeventhub.py +321 -0
- cribl_control_plane/models/outputazurelogs.py +386 -0
- cribl_control_plane/models/outputclickhouse.py +650 -0
- cribl_control_plane/models/outputcloudwatch.py +273 -0
- cribl_control_plane/models/outputconfluentcloud.py +591 -0
- cribl_control_plane/models/outputcriblhttp.py +494 -0
- cribl_control_plane/models/outputcribllake.py +396 -0
- cribl_control_plane/models/outputcribltcp.py +387 -0
- cribl_control_plane/models/outputcrowdstrikenextgensiem.py +410 -0
- cribl_control_plane/models/outputdatadog.py +472 -0
- cribl_control_plane/models/outputdataset.py +437 -0
- cribl_control_plane/models/outputdefault.py +55 -0
- cribl_control_plane/models/outputdevnull.py +50 -0
- cribl_control_plane/models/outputdiskspool.py +89 -0
- cribl_control_plane/models/outputdls3.py +560 -0
- cribl_control_plane/models/outputdynatracehttp.py +454 -0
- cribl_control_plane/models/outputdynatraceotlp.py +486 -0
- cribl_control_plane/models/outputelastic.py +494 -0
- cribl_control_plane/models/outputelasticcloud.py +407 -0
- cribl_control_plane/models/outputexabeam.py +297 -0
- cribl_control_plane/models/outputfilesystem.py +357 -0
- cribl_control_plane/models/outputgooglechronicle.py +486 -0
- cribl_control_plane/models/outputgooglecloudlogging.py +557 -0
- cribl_control_plane/models/outputgooglecloudstorage.py +499 -0
- cribl_control_plane/models/outputgooglepubsub.py +274 -0
- cribl_control_plane/models/outputgrafanacloud_union.py +1024 -0
- cribl_control_plane/models/outputgraphite.py +225 -0
- cribl_control_plane/models/outputhoneycomb.py +369 -0
- cribl_control_plane/models/outputhumiohec.py +389 -0
- cribl_control_plane/models/outputinfluxdb.py +523 -0
- cribl_control_plane/models/outputkafka.py +581 -0
- cribl_control_plane/models/outputkinesis.py +312 -0
- cribl_control_plane/models/outputloki.py +425 -0
- cribl_control_plane/models/outputminio.py +512 -0
- cribl_control_plane/models/outputmsk.py +654 -0
- cribl_control_plane/models/outputnetflow.py +80 -0
- cribl_control_plane/models/outputnewrelic.py +424 -0
- cribl_control_plane/models/outputnewrelicevents.py +401 -0
- cribl_control_plane/models/outputopentelemetry.py +669 -0
- cribl_control_plane/models/outputprometheus.py +485 -0
- cribl_control_plane/models/outputring.py +121 -0
- cribl_control_plane/models/outputrouter.py +83 -0
- cribl_control_plane/models/outputs3.py +556 -0
- cribl_control_plane/models/outputsamplesresponse.py +14 -0
- cribl_control_plane/models/outputsecuritylake.py +505 -0
- cribl_control_plane/models/outputsentinel.py +488 -0
- cribl_control_plane/models/outputsentineloneaisiem.py +505 -0
- cribl_control_plane/models/outputservicenow.py +543 -0
- cribl_control_plane/models/outputsignalfx.py +369 -0
- cribl_control_plane/models/outputsnmp.py +80 -0
- cribl_control_plane/models/outputsns.py +274 -0
- cribl_control_plane/models/outputsplunk.py +383 -0
- cribl_control_plane/models/outputsplunkhec.py +434 -0
- cribl_control_plane/models/outputsplunklb.py +558 -0
- cribl_control_plane/models/outputsqs.py +328 -0
- cribl_control_plane/models/outputstatsd.py +224 -0
- cribl_control_plane/models/outputstatsdext.py +225 -0
- cribl_control_plane/models/outputsumologic.py +378 -0
- cribl_control_plane/models/outputsyslog.py +415 -0
- cribl_control_plane/models/outputtcpjson.py +413 -0
- cribl_control_plane/models/outputtestrequest.py +15 -0
- cribl_control_plane/models/outputtestresponse.py +29 -0
- cribl_control_plane/models/outputwavefront.py +369 -0
- cribl_control_plane/models/outputwebhook.py +689 -0
- cribl_control_plane/models/outputxsiam.py +415 -0
- cribl_control_plane/models/schemeclientoauth.py +24 -0
- cribl_control_plane/models/security.py +36 -0
- cribl_control_plane/models/updatehectokenrequest.py +31 -0
- cribl_control_plane/models/updateinputbyidop.py +44 -0
- cribl_control_plane/models/updateinputhectokenbyidandtokenop.py +52 -0
- cribl_control_plane/models/updateoutputbyidop.py +44 -0
- cribl_control_plane/outputs.py +1615 -0
- cribl_control_plane/py.typed +1 -0
- cribl_control_plane/sdk.py +164 -0
- cribl_control_plane/sdkconfiguration.py +36 -0
- cribl_control_plane/sources.py +1355 -0
- cribl_control_plane/types/__init__.py +21 -0
- cribl_control_plane/types/basemodel.py +39 -0
- cribl_control_plane/utils/__init__.py +187 -0
- cribl_control_plane/utils/annotations.py +55 -0
- cribl_control_plane/utils/datetimes.py +23 -0
- cribl_control_plane/utils/enums.py +74 -0
- cribl_control_plane/utils/eventstreaming.py +238 -0
- cribl_control_plane/utils/forms.py +223 -0
- cribl_control_plane/utils/headers.py +136 -0
- cribl_control_plane/utils/logger.py +27 -0
- cribl_control_plane/utils/metadata.py +118 -0
- cribl_control_plane/utils/queryparams.py +205 -0
- cribl_control_plane/utils/requestbodies.py +66 -0
- cribl_control_plane/utils/retries.py +217 -0
- cribl_control_plane/utils/security.py +207 -0
- cribl_control_plane/utils/serializers.py +249 -0
- cribl_control_plane/utils/unmarshal_json_response.py +24 -0
- cribl_control_plane/utils/url.py +155 -0
- cribl_control_plane/utils/values.py +137 -0
- cribl_control_plane-0.0.13.dist-info/METADATA +489 -0
- cribl_control_plane-0.0.13.dist-info/RECORD +197 -0
- cribl_control_plane-0.0.13.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,1024 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from cribl_control_plane import utils
|
|
5
|
+
from cribl_control_plane.types import BaseModel
|
|
6
|
+
from cribl_control_plane.utils import validate_open_enum
|
|
7
|
+
from enum import Enum
|
|
8
|
+
import pydantic
|
|
9
|
+
from pydantic.functional_validators import PlainValidator
|
|
10
|
+
from typing import List, Optional, Union
|
|
11
|
+
from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class OutputGrafanaCloudType2(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
15
|
+
GRAFANA_CLOUD = "grafana_cloud"
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
class OutputGrafanaCloudMessageFormat2(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
19
|
+
r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
|
|
20
|
+
|
|
21
|
+
PROTOBUF = "protobuf"
|
|
22
|
+
JSON = "json"
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
class OutputGrafanaCloudLabel2TypedDict(TypedDict):
|
|
26
|
+
value: str
|
|
27
|
+
name: NotRequired[str]
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
class OutputGrafanaCloudLabel2(BaseModel):
|
|
31
|
+
value: str
|
|
32
|
+
|
|
33
|
+
name: Optional[str] = ""
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
class OutputGrafanaCloudPrometheusAuthAuthenticationType2(
|
|
37
|
+
str, Enum, metaclass=utils.OpenEnumMeta
|
|
38
|
+
):
|
|
39
|
+
NONE = "none"
|
|
40
|
+
TOKEN = "token"
|
|
41
|
+
TEXT_SECRET = "textSecret"
|
|
42
|
+
BASIC = "basic"
|
|
43
|
+
CREDENTIALS_SECRET = "credentialsSecret"
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
class OutputGrafanaCloudPrometheusAuth2TypedDict(TypedDict):
|
|
47
|
+
auth_type: NotRequired[OutputGrafanaCloudPrometheusAuthAuthenticationType2]
|
|
48
|
+
token: NotRequired[str]
|
|
49
|
+
r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
|
|
50
|
+
text_secret: NotRequired[str]
|
|
51
|
+
r"""Select or create a stored text secret"""
|
|
52
|
+
username: NotRequired[str]
|
|
53
|
+
r"""Username for authentication"""
|
|
54
|
+
password: NotRequired[str]
|
|
55
|
+
r"""Password (API key in Grafana Cloud domain) for authentication"""
|
|
56
|
+
credentials_secret: NotRequired[str]
|
|
57
|
+
r"""Select or create a secret that references your credentials"""
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
class OutputGrafanaCloudPrometheusAuth2(BaseModel):
|
|
61
|
+
auth_type: Annotated[
|
|
62
|
+
Annotated[
|
|
63
|
+
Optional[OutputGrafanaCloudPrometheusAuthAuthenticationType2],
|
|
64
|
+
PlainValidator(validate_open_enum(False)),
|
|
65
|
+
],
|
|
66
|
+
pydantic.Field(alias="authType"),
|
|
67
|
+
] = OutputGrafanaCloudPrometheusAuthAuthenticationType2.BASIC
|
|
68
|
+
|
|
69
|
+
token: Optional[str] = None
|
|
70
|
+
r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
|
|
71
|
+
|
|
72
|
+
text_secret: Annotated[Optional[str], pydantic.Field(alias="textSecret")] = None
|
|
73
|
+
r"""Select or create a stored text secret"""
|
|
74
|
+
|
|
75
|
+
username: Optional[str] = None
|
|
76
|
+
r"""Username for authentication"""
|
|
77
|
+
|
|
78
|
+
password: Optional[str] = None
|
|
79
|
+
r"""Password (API key in Grafana Cloud domain) for authentication"""
|
|
80
|
+
|
|
81
|
+
credentials_secret: Annotated[
|
|
82
|
+
Optional[str], pydantic.Field(alias="credentialsSecret")
|
|
83
|
+
] = None
|
|
84
|
+
r"""Select or create a secret that references your credentials"""
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
class OutputGrafanaCloudLokiAuthAuthenticationType2(
|
|
88
|
+
str, Enum, metaclass=utils.OpenEnumMeta
|
|
89
|
+
):
|
|
90
|
+
NONE = "none"
|
|
91
|
+
TOKEN = "token"
|
|
92
|
+
TEXT_SECRET = "textSecret"
|
|
93
|
+
BASIC = "basic"
|
|
94
|
+
CREDENTIALS_SECRET = "credentialsSecret"
|
|
95
|
+
|
|
96
|
+
|
|
97
|
+
class OutputGrafanaCloudLokiAuth2TypedDict(TypedDict):
|
|
98
|
+
auth_type: NotRequired[OutputGrafanaCloudLokiAuthAuthenticationType2]
|
|
99
|
+
token: NotRequired[str]
|
|
100
|
+
r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
|
|
101
|
+
text_secret: NotRequired[str]
|
|
102
|
+
r"""Select or create a stored text secret"""
|
|
103
|
+
username: NotRequired[str]
|
|
104
|
+
r"""Username for authentication"""
|
|
105
|
+
password: NotRequired[str]
|
|
106
|
+
r"""Password (API key in Grafana Cloud domain) for authentication"""
|
|
107
|
+
credentials_secret: NotRequired[str]
|
|
108
|
+
r"""Select or create a secret that references your credentials"""
|
|
109
|
+
|
|
110
|
+
|
|
111
|
+
class OutputGrafanaCloudLokiAuth2(BaseModel):
|
|
112
|
+
auth_type: Annotated[
|
|
113
|
+
Annotated[
|
|
114
|
+
Optional[OutputGrafanaCloudLokiAuthAuthenticationType2],
|
|
115
|
+
PlainValidator(validate_open_enum(False)),
|
|
116
|
+
],
|
|
117
|
+
pydantic.Field(alias="authType"),
|
|
118
|
+
] = OutputGrafanaCloudLokiAuthAuthenticationType2.BASIC
|
|
119
|
+
|
|
120
|
+
token: Optional[str] = None
|
|
121
|
+
r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
|
|
122
|
+
|
|
123
|
+
text_secret: Annotated[Optional[str], pydantic.Field(alias="textSecret")] = None
|
|
124
|
+
r"""Select or create a stored text secret"""
|
|
125
|
+
|
|
126
|
+
username: Optional[str] = None
|
|
127
|
+
r"""Username for authentication"""
|
|
128
|
+
|
|
129
|
+
password: Optional[str] = None
|
|
130
|
+
r"""Password (API key in Grafana Cloud domain) for authentication"""
|
|
131
|
+
|
|
132
|
+
credentials_secret: Annotated[
|
|
133
|
+
Optional[str], pydantic.Field(alias="credentialsSecret")
|
|
134
|
+
] = None
|
|
135
|
+
r"""Select or create a secret that references your credentials"""
|
|
136
|
+
|
|
137
|
+
|
|
138
|
+
class OutputGrafanaCloudExtraHTTPHeader2TypedDict(TypedDict):
|
|
139
|
+
value: str
|
|
140
|
+
name: NotRequired[str]
|
|
141
|
+
|
|
142
|
+
|
|
143
|
+
class OutputGrafanaCloudExtraHTTPHeader2(BaseModel):
|
|
144
|
+
value: str
|
|
145
|
+
|
|
146
|
+
name: Optional[str] = None
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
class OutputGrafanaCloudFailedRequestLoggingMode2(
|
|
150
|
+
str, Enum, metaclass=utils.OpenEnumMeta
|
|
151
|
+
):
|
|
152
|
+
r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
|
|
153
|
+
|
|
154
|
+
PAYLOAD = "payload"
|
|
155
|
+
PAYLOAD_AND_HEADERS = "payloadAndHeaders"
|
|
156
|
+
NONE = "none"
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
class OutputGrafanaCloudResponseRetrySetting2TypedDict(TypedDict):
|
|
160
|
+
http_status: float
|
|
161
|
+
r"""The HTTP response status code that will trigger retries"""
|
|
162
|
+
initial_backoff: NotRequired[float]
|
|
163
|
+
r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
|
|
164
|
+
backoff_rate: NotRequired[float]
|
|
165
|
+
r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
|
|
166
|
+
max_backoff: NotRequired[float]
|
|
167
|
+
r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
class OutputGrafanaCloudResponseRetrySetting2(BaseModel):
|
|
171
|
+
http_status: Annotated[float, pydantic.Field(alias="httpStatus")]
|
|
172
|
+
r"""The HTTP response status code that will trigger retries"""
|
|
173
|
+
|
|
174
|
+
initial_backoff: Annotated[
|
|
175
|
+
Optional[float], pydantic.Field(alias="initialBackoff")
|
|
176
|
+
] = 1000
|
|
177
|
+
r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
|
|
178
|
+
|
|
179
|
+
backoff_rate: Annotated[Optional[float], pydantic.Field(alias="backoffRate")] = 2
|
|
180
|
+
r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
|
|
181
|
+
|
|
182
|
+
max_backoff: Annotated[Optional[float], pydantic.Field(alias="maxBackoff")] = 10000
|
|
183
|
+
r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
class OutputGrafanaCloudTimeoutRetrySettings2TypedDict(TypedDict):
|
|
187
|
+
timeout_retry: NotRequired[bool]
|
|
188
|
+
initial_backoff: NotRequired[float]
|
|
189
|
+
r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
|
|
190
|
+
backoff_rate: NotRequired[float]
|
|
191
|
+
r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
|
|
192
|
+
max_backoff: NotRequired[float]
|
|
193
|
+
r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
|
|
194
|
+
|
|
195
|
+
|
|
196
|
+
class OutputGrafanaCloudTimeoutRetrySettings2(BaseModel):
|
|
197
|
+
timeout_retry: Annotated[Optional[bool], pydantic.Field(alias="timeoutRetry")] = (
|
|
198
|
+
False
|
|
199
|
+
)
|
|
200
|
+
|
|
201
|
+
initial_backoff: Annotated[
|
|
202
|
+
Optional[float], pydantic.Field(alias="initialBackoff")
|
|
203
|
+
] = 1000
|
|
204
|
+
r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
|
|
205
|
+
|
|
206
|
+
backoff_rate: Annotated[Optional[float], pydantic.Field(alias="backoffRate")] = 2
|
|
207
|
+
r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
|
|
208
|
+
|
|
209
|
+
max_backoff: Annotated[Optional[float], pydantic.Field(alias="maxBackoff")] = 10000
|
|
210
|
+
r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
|
|
211
|
+
|
|
212
|
+
|
|
213
|
+
class OutputGrafanaCloudBackpressureBehavior2(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
214
|
+
r"""How to handle events when all receivers are exerting backpressure"""
|
|
215
|
+
|
|
216
|
+
BLOCK = "block"
|
|
217
|
+
DROP = "drop"
|
|
218
|
+
QUEUE = "queue"
|
|
219
|
+
|
|
220
|
+
|
|
221
|
+
class OutputGrafanaCloudCompression2(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
222
|
+
r"""Codec to use to compress the persisted data"""
|
|
223
|
+
|
|
224
|
+
NONE = "none"
|
|
225
|
+
GZIP = "gzip"
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
class OutputGrafanaCloudQueueFullBehavior2(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
229
|
+
r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
|
|
230
|
+
|
|
231
|
+
BLOCK = "block"
|
|
232
|
+
DROP = "drop"
|
|
233
|
+
|
|
234
|
+
|
|
235
|
+
class OutputGrafanaCloudMode2(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
236
|
+
r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
|
|
237
|
+
|
|
238
|
+
ERROR = "error"
|
|
239
|
+
BACKPRESSURE = "backpressure"
|
|
240
|
+
ALWAYS = "always"
|
|
241
|
+
|
|
242
|
+
|
|
243
|
+
class OutputGrafanaCloudPqControls2TypedDict(TypedDict):
|
|
244
|
+
pass
|
|
245
|
+
|
|
246
|
+
|
|
247
|
+
class OutputGrafanaCloudPqControls2(BaseModel):
|
|
248
|
+
pass
|
|
249
|
+
|
|
250
|
+
|
|
251
|
+
class OutputGrafanaCloud2TypedDict(TypedDict):
|
|
252
|
+
id: str
|
|
253
|
+
r"""Unique ID for this output"""
|
|
254
|
+
type: OutputGrafanaCloudType2
|
|
255
|
+
prometheus_url: str
|
|
256
|
+
r"""The remote_write endpoint to send Prometheus metrics to, such as https://prometheus-blocks-prod-us-central1.grafana.net/api/prom/push"""
|
|
257
|
+
pipeline: NotRequired[str]
|
|
258
|
+
r"""Pipeline to process data before sending out to this output"""
|
|
259
|
+
system_fields: NotRequired[List[str]]
|
|
260
|
+
r"""Fields to automatically add to events, such as cribl_pipe. Supports wildcards. These fields are added as dimensions and labels to generated metrics and logs, respectively."""
|
|
261
|
+
environment: NotRequired[str]
|
|
262
|
+
r"""Optionally, enable this config only on a specified Git branch. If empty, will be enabled everywhere."""
|
|
263
|
+
streamtags: NotRequired[List[str]]
|
|
264
|
+
r"""Tags for filtering and grouping in @{product}"""
|
|
265
|
+
loki_url: NotRequired[str]
|
|
266
|
+
r"""The endpoint to send logs to, such as https://logs-prod-us-central1.grafana.net"""
|
|
267
|
+
message: NotRequired[str]
|
|
268
|
+
r"""Name of the event field that contains the message to send. If not specified, Stream sends a JSON representation of the whole event."""
|
|
269
|
+
message_format: NotRequired[OutputGrafanaCloudMessageFormat2]
|
|
270
|
+
r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
|
|
271
|
+
labels: NotRequired[List[OutputGrafanaCloudLabel2TypedDict]]
|
|
272
|
+
r"""List of labels to send with logs. Labels define Loki streams, so use static labels to avoid proliferating label value combinations and streams. Can be merged and/or overridden by the event's __labels field. Example: '__labels: {host: \"cribl.io\", level: \"error\"}'"""
|
|
273
|
+
metric_rename_expr: NotRequired[str]
|
|
274
|
+
r"""JavaScript expression that can be used to rename metrics. For example, name.replace(/\./g, '_') will replace all '.' characters in a metric's name with the supported '_' character. Use the 'name' global variable to access the metric's name. You can access event fields' values via __e.<fieldName>."""
|
|
275
|
+
prometheus_auth: NotRequired[OutputGrafanaCloudPrometheusAuth2TypedDict]
|
|
276
|
+
loki_auth: NotRequired[OutputGrafanaCloudLokiAuth2TypedDict]
|
|
277
|
+
concurrency: NotRequired[float]
|
|
278
|
+
r"""Maximum number of ongoing requests before blocking. Warning: Setting this value > 1 can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
279
|
+
max_payload_size_kb: NotRequired[float]
|
|
280
|
+
r"""Maximum size, in KB, of the request body. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
281
|
+
max_payload_events: NotRequired[float]
|
|
282
|
+
r"""Maximum number of events to include in the request body. Default is 0 (unlimited). Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
283
|
+
reject_unauthorized: NotRequired[bool]
|
|
284
|
+
r"""Reject certificates not authorized by a CA in the CA certificate path or by another trusted CA (such as the system's).
|
|
285
|
+
Enabled by default. When this setting is also present in TLS Settings (Client Side),
|
|
286
|
+
that value will take precedence.
|
|
287
|
+
"""
|
|
288
|
+
timeout_sec: NotRequired[float]
|
|
289
|
+
r"""Amount of time, in seconds, to wait for a request to complete before canceling it"""
|
|
290
|
+
flush_period_sec: NotRequired[float]
|
|
291
|
+
r"""Maximum time between requests. Small values could cause the payload size to be smaller than the configured Maximum time between requests. Small values can reduce the payload size below the configured 'Max record size' and 'Max events per request'. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
292
|
+
extra_http_headers: NotRequired[List[OutputGrafanaCloudExtraHTTPHeader2TypedDict]]
|
|
293
|
+
r"""Headers to add to all events"""
|
|
294
|
+
use_round_robin_dns: NotRequired[bool]
|
|
295
|
+
r"""Enable round-robin DNS lookup. When a DNS server returns multiple addresses, @{product} will cycle through them in the order returned. For optimal performance, consider enabling this setting for non-load balanced destinations."""
|
|
296
|
+
failed_request_logging_mode: NotRequired[
|
|
297
|
+
OutputGrafanaCloudFailedRequestLoggingMode2
|
|
298
|
+
]
|
|
299
|
+
r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
|
|
300
|
+
safe_headers: NotRequired[List[str]]
|
|
301
|
+
r"""List of headers that are safe to log in plain text"""
|
|
302
|
+
response_retry_settings: NotRequired[
|
|
303
|
+
List[OutputGrafanaCloudResponseRetrySetting2TypedDict]
|
|
304
|
+
]
|
|
305
|
+
r"""Automatically retry after unsuccessful response status codes, such as 429 (Too Many Requests) or 503 (Service Unavailable)"""
|
|
306
|
+
timeout_retry_settings: NotRequired[
|
|
307
|
+
OutputGrafanaCloudTimeoutRetrySettings2TypedDict
|
|
308
|
+
]
|
|
309
|
+
response_honor_retry_after_header: NotRequired[bool]
|
|
310
|
+
r"""Honor any Retry-After header that specifies a delay (in seconds) no longer than 180 seconds after the retry request. @{product} limits the delay to 180 seconds, even if the Retry-After header specifies a longer delay. When enabled, takes precedence over user-configured retry options. When disabled, all Retry-After headers are ignored."""
|
|
311
|
+
on_backpressure: NotRequired[OutputGrafanaCloudBackpressureBehavior2]
|
|
312
|
+
r"""How to handle events when all receivers are exerting backpressure"""
|
|
313
|
+
description: NotRequired[str]
|
|
314
|
+
compress: NotRequired[bool]
|
|
315
|
+
r"""Compress the payload body before sending. Applies only to JSON payloads; the Protobuf variant for both Prometheus and Loki are snappy-compressed by default."""
|
|
316
|
+
pq_max_file_size: NotRequired[str]
|
|
317
|
+
r"""The maximum size to store in each queue file before closing and optionally compressing (KB, MB, etc.)"""
|
|
318
|
+
pq_max_size: NotRequired[str]
|
|
319
|
+
r"""The maximum disk space that the queue can consume (as an average per Worker Process) before queueing stops. Enter a numeral with units of KB, MB, etc."""
|
|
320
|
+
pq_path: NotRequired[str]
|
|
321
|
+
r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/<output-id>."""
|
|
322
|
+
pq_compress: NotRequired[OutputGrafanaCloudCompression2]
|
|
323
|
+
r"""Codec to use to compress the persisted data"""
|
|
324
|
+
pq_on_backpressure: NotRequired[OutputGrafanaCloudQueueFullBehavior2]
|
|
325
|
+
r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
|
|
326
|
+
pq_mode: NotRequired[OutputGrafanaCloudMode2]
|
|
327
|
+
r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
|
|
328
|
+
pq_controls: NotRequired[OutputGrafanaCloudPqControls2TypedDict]
|
|
329
|
+
|
|
330
|
+
|
|
331
|
+
class OutputGrafanaCloud2(BaseModel):
|
|
332
|
+
id: str
|
|
333
|
+
r"""Unique ID for this output"""
|
|
334
|
+
|
|
335
|
+
type: Annotated[OutputGrafanaCloudType2, PlainValidator(validate_open_enum(False))]
|
|
336
|
+
|
|
337
|
+
prometheus_url: Annotated[str, pydantic.Field(alias="prometheusUrl")]
|
|
338
|
+
r"""The remote_write endpoint to send Prometheus metrics to, such as https://prometheus-blocks-prod-us-central1.grafana.net/api/prom/push"""
|
|
339
|
+
|
|
340
|
+
pipeline: Optional[str] = None
|
|
341
|
+
r"""Pipeline to process data before sending out to this output"""
|
|
342
|
+
|
|
343
|
+
system_fields: Annotated[
|
|
344
|
+
Optional[List[str]], pydantic.Field(alias="systemFields")
|
|
345
|
+
] = None
|
|
346
|
+
r"""Fields to automatically add to events, such as cribl_pipe. Supports wildcards. These fields are added as dimensions and labels to generated metrics and logs, respectively."""
|
|
347
|
+
|
|
348
|
+
environment: Optional[str] = None
|
|
349
|
+
r"""Optionally, enable this config only on a specified Git branch. If empty, will be enabled everywhere."""
|
|
350
|
+
|
|
351
|
+
streamtags: Optional[List[str]] = None
|
|
352
|
+
r"""Tags for filtering and grouping in @{product}"""
|
|
353
|
+
|
|
354
|
+
loki_url: Annotated[Optional[str], pydantic.Field(alias="lokiUrl")] = None
|
|
355
|
+
r"""The endpoint to send logs to, such as https://logs-prod-us-central1.grafana.net"""
|
|
356
|
+
|
|
357
|
+
message: Optional[str] = None
|
|
358
|
+
r"""Name of the event field that contains the message to send. If not specified, Stream sends a JSON representation of the whole event."""
|
|
359
|
+
|
|
360
|
+
message_format: Annotated[
|
|
361
|
+
Annotated[
|
|
362
|
+
Optional[OutputGrafanaCloudMessageFormat2],
|
|
363
|
+
PlainValidator(validate_open_enum(False)),
|
|
364
|
+
],
|
|
365
|
+
pydantic.Field(alias="messageFormat"),
|
|
366
|
+
] = OutputGrafanaCloudMessageFormat2.PROTOBUF
|
|
367
|
+
r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
|
|
368
|
+
|
|
369
|
+
labels: Optional[List[OutputGrafanaCloudLabel2]] = None
|
|
370
|
+
r"""List of labels to send with logs. Labels define Loki streams, so use static labels to avoid proliferating label value combinations and streams. Can be merged and/or overridden by the event's __labels field. Example: '__labels: {host: \"cribl.io\", level: \"error\"}'"""
|
|
371
|
+
|
|
372
|
+
metric_rename_expr: Annotated[
|
|
373
|
+
Optional[str], pydantic.Field(alias="metricRenameExpr")
|
|
374
|
+
] = "name.replace(/[^a-zA-Z0-9_]/g, '_')"
|
|
375
|
+
r"""JavaScript expression that can be used to rename metrics. For example, name.replace(/\./g, '_') will replace all '.' characters in a metric's name with the supported '_' character. Use the 'name' global variable to access the metric's name. You can access event fields' values via __e.<fieldName>."""
|
|
376
|
+
|
|
377
|
+
prometheus_auth: Annotated[
|
|
378
|
+
Optional[OutputGrafanaCloudPrometheusAuth2],
|
|
379
|
+
pydantic.Field(alias="prometheusAuth"),
|
|
380
|
+
] = None
|
|
381
|
+
|
|
382
|
+
loki_auth: Annotated[
|
|
383
|
+
Optional[OutputGrafanaCloudLokiAuth2], pydantic.Field(alias="lokiAuth")
|
|
384
|
+
] = None
|
|
385
|
+
|
|
386
|
+
concurrency: Optional[float] = 1
|
|
387
|
+
r"""Maximum number of ongoing requests before blocking. Warning: Setting this value > 1 can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
388
|
+
|
|
389
|
+
max_payload_size_kb: Annotated[
|
|
390
|
+
Optional[float], pydantic.Field(alias="maxPayloadSizeKB")
|
|
391
|
+
] = 4096
|
|
392
|
+
r"""Maximum size, in KB, of the request body. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
393
|
+
|
|
394
|
+
max_payload_events: Annotated[
|
|
395
|
+
Optional[float], pydantic.Field(alias="maxPayloadEvents")
|
|
396
|
+
] = 0
|
|
397
|
+
r"""Maximum number of events to include in the request body. Default is 0 (unlimited). Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
398
|
+
|
|
399
|
+
reject_unauthorized: Annotated[
|
|
400
|
+
Optional[bool], pydantic.Field(alias="rejectUnauthorized")
|
|
401
|
+
] = True
|
|
402
|
+
r"""Reject certificates not authorized by a CA in the CA certificate path or by another trusted CA (such as the system's).
|
|
403
|
+
Enabled by default. When this setting is also present in TLS Settings (Client Side),
|
|
404
|
+
that value will take precedence.
|
|
405
|
+
"""
|
|
406
|
+
|
|
407
|
+
timeout_sec: Annotated[Optional[float], pydantic.Field(alias="timeoutSec")] = 30
|
|
408
|
+
r"""Amount of time, in seconds, to wait for a request to complete before canceling it"""
|
|
409
|
+
|
|
410
|
+
flush_period_sec: Annotated[
|
|
411
|
+
Optional[float], pydantic.Field(alias="flushPeriodSec")
|
|
412
|
+
] = 15
|
|
413
|
+
r"""Maximum time between requests. Small values could cause the payload size to be smaller than the configured Maximum time between requests. Small values can reduce the payload size below the configured 'Max record size' and 'Max events per request'. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
414
|
+
|
|
415
|
+
extra_http_headers: Annotated[
|
|
416
|
+
Optional[List[OutputGrafanaCloudExtraHTTPHeader2]],
|
|
417
|
+
pydantic.Field(alias="extraHttpHeaders"),
|
|
418
|
+
] = None
|
|
419
|
+
r"""Headers to add to all events"""
|
|
420
|
+
|
|
421
|
+
use_round_robin_dns: Annotated[
|
|
422
|
+
Optional[bool], pydantic.Field(alias="useRoundRobinDns")
|
|
423
|
+
] = False
|
|
424
|
+
r"""Enable round-robin DNS lookup. When a DNS server returns multiple addresses, @{product} will cycle through them in the order returned. For optimal performance, consider enabling this setting for non-load balanced destinations."""
|
|
425
|
+
|
|
426
|
+
failed_request_logging_mode: Annotated[
|
|
427
|
+
Annotated[
|
|
428
|
+
Optional[OutputGrafanaCloudFailedRequestLoggingMode2],
|
|
429
|
+
PlainValidator(validate_open_enum(False)),
|
|
430
|
+
],
|
|
431
|
+
pydantic.Field(alias="failedRequestLoggingMode"),
|
|
432
|
+
] = OutputGrafanaCloudFailedRequestLoggingMode2.NONE
|
|
433
|
+
r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
|
|
434
|
+
|
|
435
|
+
safe_headers: Annotated[
|
|
436
|
+
Optional[List[str]], pydantic.Field(alias="safeHeaders")
|
|
437
|
+
] = None
|
|
438
|
+
r"""List of headers that are safe to log in plain text"""
|
|
439
|
+
|
|
440
|
+
response_retry_settings: Annotated[
|
|
441
|
+
Optional[List[OutputGrafanaCloudResponseRetrySetting2]],
|
|
442
|
+
pydantic.Field(alias="responseRetrySettings"),
|
|
443
|
+
] = None
|
|
444
|
+
r"""Automatically retry after unsuccessful response status codes, such as 429 (Too Many Requests) or 503 (Service Unavailable)"""
|
|
445
|
+
|
|
446
|
+
timeout_retry_settings: Annotated[
|
|
447
|
+
Optional[OutputGrafanaCloudTimeoutRetrySettings2],
|
|
448
|
+
pydantic.Field(alias="timeoutRetrySettings"),
|
|
449
|
+
] = None
|
|
450
|
+
|
|
451
|
+
response_honor_retry_after_header: Annotated[
|
|
452
|
+
Optional[bool], pydantic.Field(alias="responseHonorRetryAfterHeader")
|
|
453
|
+
] = False
|
|
454
|
+
r"""Honor any Retry-After header that specifies a delay (in seconds) no longer than 180 seconds after the retry request. @{product} limits the delay to 180 seconds, even if the Retry-After header specifies a longer delay. When enabled, takes precedence over user-configured retry options. When disabled, all Retry-After headers are ignored."""
|
|
455
|
+
|
|
456
|
+
on_backpressure: Annotated[
|
|
457
|
+
Annotated[
|
|
458
|
+
Optional[OutputGrafanaCloudBackpressureBehavior2],
|
|
459
|
+
PlainValidator(validate_open_enum(False)),
|
|
460
|
+
],
|
|
461
|
+
pydantic.Field(alias="onBackpressure"),
|
|
462
|
+
] = OutputGrafanaCloudBackpressureBehavior2.BLOCK
|
|
463
|
+
r"""How to handle events when all receivers are exerting backpressure"""
|
|
464
|
+
|
|
465
|
+
description: Optional[str] = None
|
|
466
|
+
|
|
467
|
+
compress: Optional[bool] = True
|
|
468
|
+
r"""Compress the payload body before sending. Applies only to JSON payloads; the Protobuf variant for both Prometheus and Loki are snappy-compressed by default."""
|
|
469
|
+
|
|
470
|
+
pq_max_file_size: Annotated[
|
|
471
|
+
Optional[str], pydantic.Field(alias="pqMaxFileSize")
|
|
472
|
+
] = "1 MB"
|
|
473
|
+
r"""The maximum size to store in each queue file before closing and optionally compressing (KB, MB, etc.)"""
|
|
474
|
+
|
|
475
|
+
pq_max_size: Annotated[Optional[str], pydantic.Field(alias="pqMaxSize")] = "5GB"
|
|
476
|
+
r"""The maximum disk space that the queue can consume (as an average per Worker Process) before queueing stops. Enter a numeral with units of KB, MB, etc."""
|
|
477
|
+
|
|
478
|
+
pq_path: Annotated[Optional[str], pydantic.Field(alias="pqPath")] = (
|
|
479
|
+
"$CRIBL_HOME/state/queues"
|
|
480
|
+
)
|
|
481
|
+
r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/<output-id>."""
|
|
482
|
+
|
|
483
|
+
pq_compress: Annotated[
|
|
484
|
+
Annotated[
|
|
485
|
+
Optional[OutputGrafanaCloudCompression2],
|
|
486
|
+
PlainValidator(validate_open_enum(False)),
|
|
487
|
+
],
|
|
488
|
+
pydantic.Field(alias="pqCompress"),
|
|
489
|
+
] = OutputGrafanaCloudCompression2.NONE
|
|
490
|
+
r"""Codec to use to compress the persisted data"""
|
|
491
|
+
|
|
492
|
+
pq_on_backpressure: Annotated[
|
|
493
|
+
Annotated[
|
|
494
|
+
Optional[OutputGrafanaCloudQueueFullBehavior2],
|
|
495
|
+
PlainValidator(validate_open_enum(False)),
|
|
496
|
+
],
|
|
497
|
+
pydantic.Field(alias="pqOnBackpressure"),
|
|
498
|
+
] = OutputGrafanaCloudQueueFullBehavior2.BLOCK
|
|
499
|
+
r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
|
|
500
|
+
|
|
501
|
+
pq_mode: Annotated[
|
|
502
|
+
Annotated[
|
|
503
|
+
Optional[OutputGrafanaCloudMode2], PlainValidator(validate_open_enum(False))
|
|
504
|
+
],
|
|
505
|
+
pydantic.Field(alias="pqMode"),
|
|
506
|
+
] = OutputGrafanaCloudMode2.ERROR
|
|
507
|
+
r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
|
|
508
|
+
|
|
509
|
+
pq_controls: Annotated[
|
|
510
|
+
Optional[OutputGrafanaCloudPqControls2], pydantic.Field(alias="pqControls")
|
|
511
|
+
] = None
|
|
512
|
+
|
|
513
|
+
|
|
514
|
+
class OutputGrafanaCloudType1(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
515
|
+
GRAFANA_CLOUD = "grafana_cloud"
|
|
516
|
+
|
|
517
|
+
|
|
518
|
+
class OutputGrafanaCloudMessageFormat1(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
519
|
+
r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
|
|
520
|
+
|
|
521
|
+
PROTOBUF = "protobuf"
|
|
522
|
+
JSON = "json"
|
|
523
|
+
|
|
524
|
+
|
|
525
|
+
class OutputGrafanaCloudLabel1TypedDict(TypedDict):
|
|
526
|
+
value: str
|
|
527
|
+
name: NotRequired[str]
|
|
528
|
+
|
|
529
|
+
|
|
530
|
+
class OutputGrafanaCloudLabel1(BaseModel):
|
|
531
|
+
value: str
|
|
532
|
+
|
|
533
|
+
name: Optional[str] = ""
|
|
534
|
+
|
|
535
|
+
|
|
536
|
+
class OutputGrafanaCloudPrometheusAuthAuthenticationType1(
|
|
537
|
+
str, Enum, metaclass=utils.OpenEnumMeta
|
|
538
|
+
):
|
|
539
|
+
NONE = "none"
|
|
540
|
+
TOKEN = "token"
|
|
541
|
+
TEXT_SECRET = "textSecret"
|
|
542
|
+
BASIC = "basic"
|
|
543
|
+
CREDENTIALS_SECRET = "credentialsSecret"
|
|
544
|
+
|
|
545
|
+
|
|
546
|
+
class OutputGrafanaCloudPrometheusAuth1TypedDict(TypedDict):
|
|
547
|
+
auth_type: NotRequired[OutputGrafanaCloudPrometheusAuthAuthenticationType1]
|
|
548
|
+
token: NotRequired[str]
|
|
549
|
+
r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
|
|
550
|
+
text_secret: NotRequired[str]
|
|
551
|
+
r"""Select or create a stored text secret"""
|
|
552
|
+
username: NotRequired[str]
|
|
553
|
+
r"""Username for authentication"""
|
|
554
|
+
password: NotRequired[str]
|
|
555
|
+
r"""Password (API key in Grafana Cloud domain) for authentication"""
|
|
556
|
+
credentials_secret: NotRequired[str]
|
|
557
|
+
r"""Select or create a secret that references your credentials"""
|
|
558
|
+
|
|
559
|
+
|
|
560
|
+
class OutputGrafanaCloudPrometheusAuth1(BaseModel):
|
|
561
|
+
auth_type: Annotated[
|
|
562
|
+
Annotated[
|
|
563
|
+
Optional[OutputGrafanaCloudPrometheusAuthAuthenticationType1],
|
|
564
|
+
PlainValidator(validate_open_enum(False)),
|
|
565
|
+
],
|
|
566
|
+
pydantic.Field(alias="authType"),
|
|
567
|
+
] = OutputGrafanaCloudPrometheusAuthAuthenticationType1.BASIC
|
|
568
|
+
|
|
569
|
+
token: Optional[str] = None
|
|
570
|
+
r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
|
|
571
|
+
|
|
572
|
+
text_secret: Annotated[Optional[str], pydantic.Field(alias="textSecret")] = None
|
|
573
|
+
r"""Select or create a stored text secret"""
|
|
574
|
+
|
|
575
|
+
username: Optional[str] = None
|
|
576
|
+
r"""Username for authentication"""
|
|
577
|
+
|
|
578
|
+
password: Optional[str] = None
|
|
579
|
+
r"""Password (API key in Grafana Cloud domain) for authentication"""
|
|
580
|
+
|
|
581
|
+
credentials_secret: Annotated[
|
|
582
|
+
Optional[str], pydantic.Field(alias="credentialsSecret")
|
|
583
|
+
] = None
|
|
584
|
+
r"""Select or create a secret that references your credentials"""
|
|
585
|
+
|
|
586
|
+
|
|
587
|
+
class OutputGrafanaCloudLokiAuthAuthenticationType1(
|
|
588
|
+
str, Enum, metaclass=utils.OpenEnumMeta
|
|
589
|
+
):
|
|
590
|
+
NONE = "none"
|
|
591
|
+
TOKEN = "token"
|
|
592
|
+
TEXT_SECRET = "textSecret"
|
|
593
|
+
BASIC = "basic"
|
|
594
|
+
CREDENTIALS_SECRET = "credentialsSecret"
|
|
595
|
+
|
|
596
|
+
|
|
597
|
+
class OutputGrafanaCloudLokiAuth1TypedDict(TypedDict):
|
|
598
|
+
auth_type: NotRequired[OutputGrafanaCloudLokiAuthAuthenticationType1]
|
|
599
|
+
token: NotRequired[str]
|
|
600
|
+
r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
|
|
601
|
+
text_secret: NotRequired[str]
|
|
602
|
+
r"""Select or create a stored text secret"""
|
|
603
|
+
username: NotRequired[str]
|
|
604
|
+
r"""Username for authentication"""
|
|
605
|
+
password: NotRequired[str]
|
|
606
|
+
r"""Password (API key in Grafana Cloud domain) for authentication"""
|
|
607
|
+
credentials_secret: NotRequired[str]
|
|
608
|
+
r"""Select or create a secret that references your credentials"""
|
|
609
|
+
|
|
610
|
+
|
|
611
|
+
class OutputGrafanaCloudLokiAuth1(BaseModel):
|
|
612
|
+
auth_type: Annotated[
|
|
613
|
+
Annotated[
|
|
614
|
+
Optional[OutputGrafanaCloudLokiAuthAuthenticationType1],
|
|
615
|
+
PlainValidator(validate_open_enum(False)),
|
|
616
|
+
],
|
|
617
|
+
pydantic.Field(alias="authType"),
|
|
618
|
+
] = OutputGrafanaCloudLokiAuthAuthenticationType1.BASIC
|
|
619
|
+
|
|
620
|
+
token: Optional[str] = None
|
|
621
|
+
r"""Bearer token to include in the authorization header. In Grafana Cloud, this is generally built by concatenating the username and the API key, separated by a colon. Example: <your-username>:<your-api-key>"""
|
|
622
|
+
|
|
623
|
+
text_secret: Annotated[Optional[str], pydantic.Field(alias="textSecret")] = None
|
|
624
|
+
r"""Select or create a stored text secret"""
|
|
625
|
+
|
|
626
|
+
username: Optional[str] = None
|
|
627
|
+
r"""Username for authentication"""
|
|
628
|
+
|
|
629
|
+
password: Optional[str] = None
|
|
630
|
+
r"""Password (API key in Grafana Cloud domain) for authentication"""
|
|
631
|
+
|
|
632
|
+
credentials_secret: Annotated[
|
|
633
|
+
Optional[str], pydantic.Field(alias="credentialsSecret")
|
|
634
|
+
] = None
|
|
635
|
+
r"""Select or create a secret that references your credentials"""
|
|
636
|
+
|
|
637
|
+
|
|
638
|
+
class OutputGrafanaCloudExtraHTTPHeader1TypedDict(TypedDict):
|
|
639
|
+
value: str
|
|
640
|
+
name: NotRequired[str]
|
|
641
|
+
|
|
642
|
+
|
|
643
|
+
class OutputGrafanaCloudExtraHTTPHeader1(BaseModel):
|
|
644
|
+
value: str
|
|
645
|
+
|
|
646
|
+
name: Optional[str] = None
|
|
647
|
+
|
|
648
|
+
|
|
649
|
+
class OutputGrafanaCloudFailedRequestLoggingMode1(
|
|
650
|
+
str, Enum, metaclass=utils.OpenEnumMeta
|
|
651
|
+
):
|
|
652
|
+
r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
|
|
653
|
+
|
|
654
|
+
PAYLOAD = "payload"
|
|
655
|
+
PAYLOAD_AND_HEADERS = "payloadAndHeaders"
|
|
656
|
+
NONE = "none"
|
|
657
|
+
|
|
658
|
+
|
|
659
|
+
class OutputGrafanaCloudResponseRetrySetting1TypedDict(TypedDict):
|
|
660
|
+
http_status: float
|
|
661
|
+
r"""The HTTP response status code that will trigger retries"""
|
|
662
|
+
initial_backoff: NotRequired[float]
|
|
663
|
+
r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
|
|
664
|
+
backoff_rate: NotRequired[float]
|
|
665
|
+
r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
|
|
666
|
+
max_backoff: NotRequired[float]
|
|
667
|
+
r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
|
|
668
|
+
|
|
669
|
+
|
|
670
|
+
class OutputGrafanaCloudResponseRetrySetting1(BaseModel):
|
|
671
|
+
http_status: Annotated[float, pydantic.Field(alias="httpStatus")]
|
|
672
|
+
r"""The HTTP response status code that will trigger retries"""
|
|
673
|
+
|
|
674
|
+
initial_backoff: Annotated[
|
|
675
|
+
Optional[float], pydantic.Field(alias="initialBackoff")
|
|
676
|
+
] = 1000
|
|
677
|
+
r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
|
|
678
|
+
|
|
679
|
+
backoff_rate: Annotated[Optional[float], pydantic.Field(alias="backoffRate")] = 2
|
|
680
|
+
r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
|
|
681
|
+
|
|
682
|
+
max_backoff: Annotated[Optional[float], pydantic.Field(alias="maxBackoff")] = 10000
|
|
683
|
+
r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
|
|
684
|
+
|
|
685
|
+
|
|
686
|
+
class OutputGrafanaCloudTimeoutRetrySettings1TypedDict(TypedDict):
|
|
687
|
+
timeout_retry: NotRequired[bool]
|
|
688
|
+
initial_backoff: NotRequired[float]
|
|
689
|
+
r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
|
|
690
|
+
backoff_rate: NotRequired[float]
|
|
691
|
+
r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
|
|
692
|
+
max_backoff: NotRequired[float]
|
|
693
|
+
r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
|
|
694
|
+
|
|
695
|
+
|
|
696
|
+
class OutputGrafanaCloudTimeoutRetrySettings1(BaseModel):
|
|
697
|
+
timeout_retry: Annotated[Optional[bool], pydantic.Field(alias="timeoutRetry")] = (
|
|
698
|
+
False
|
|
699
|
+
)
|
|
700
|
+
|
|
701
|
+
initial_backoff: Annotated[
|
|
702
|
+
Optional[float], pydantic.Field(alias="initialBackoff")
|
|
703
|
+
] = 1000
|
|
704
|
+
r"""How long, in milliseconds, Cribl Stream should wait before initiating backoff. Maximum interval is 600,000 ms (10 minutes)."""
|
|
705
|
+
|
|
706
|
+
backoff_rate: Annotated[Optional[float], pydantic.Field(alias="backoffRate")] = 2
|
|
707
|
+
r"""Base for exponential backoff. A value of 2 (default) means Cribl Stream will retry after 2 seconds, then 4 seconds, then 8 seconds, etc."""
|
|
708
|
+
|
|
709
|
+
max_backoff: Annotated[Optional[float], pydantic.Field(alias="maxBackoff")] = 10000
|
|
710
|
+
r"""The maximum backoff interval, in milliseconds, Cribl Stream should apply. Default (and minimum) is 10,000 ms (10 seconds); maximum is 180,000 ms (180 seconds)."""
|
|
711
|
+
|
|
712
|
+
|
|
713
|
+
class OutputGrafanaCloudBackpressureBehavior1(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
714
|
+
r"""How to handle events when all receivers are exerting backpressure"""
|
|
715
|
+
|
|
716
|
+
BLOCK = "block"
|
|
717
|
+
DROP = "drop"
|
|
718
|
+
QUEUE = "queue"
|
|
719
|
+
|
|
720
|
+
|
|
721
|
+
class OutputGrafanaCloudCompression1(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
722
|
+
r"""Codec to use to compress the persisted data"""
|
|
723
|
+
|
|
724
|
+
NONE = "none"
|
|
725
|
+
GZIP = "gzip"
|
|
726
|
+
|
|
727
|
+
|
|
728
|
+
class OutputGrafanaCloudQueueFullBehavior1(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
729
|
+
r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
|
|
730
|
+
|
|
731
|
+
BLOCK = "block"
|
|
732
|
+
DROP = "drop"
|
|
733
|
+
|
|
734
|
+
|
|
735
|
+
class OutputGrafanaCloudMode1(str, Enum, metaclass=utils.OpenEnumMeta):
|
|
736
|
+
r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
|
|
737
|
+
|
|
738
|
+
ERROR = "error"
|
|
739
|
+
BACKPRESSURE = "backpressure"
|
|
740
|
+
ALWAYS = "always"
|
|
741
|
+
|
|
742
|
+
|
|
743
|
+
class OutputGrafanaCloudPqControls1TypedDict(TypedDict):
|
|
744
|
+
pass
|
|
745
|
+
|
|
746
|
+
|
|
747
|
+
class OutputGrafanaCloudPqControls1(BaseModel):
|
|
748
|
+
pass
|
|
749
|
+
|
|
750
|
+
|
|
751
|
+
class OutputGrafanaCloud1TypedDict(TypedDict):
|
|
752
|
+
id: str
|
|
753
|
+
r"""Unique ID for this output"""
|
|
754
|
+
type: OutputGrafanaCloudType1
|
|
755
|
+
loki_url: str
|
|
756
|
+
r"""The endpoint to send logs to, such as https://logs-prod-us-central1.grafana.net"""
|
|
757
|
+
pipeline: NotRequired[str]
|
|
758
|
+
r"""Pipeline to process data before sending out to this output"""
|
|
759
|
+
system_fields: NotRequired[List[str]]
|
|
760
|
+
r"""Fields to automatically add to events, such as cribl_pipe. Supports wildcards. These fields are added as dimensions and labels to generated metrics and logs, respectively."""
|
|
761
|
+
environment: NotRequired[str]
|
|
762
|
+
r"""Optionally, enable this config only on a specified Git branch. If empty, will be enabled everywhere."""
|
|
763
|
+
streamtags: NotRequired[List[str]]
|
|
764
|
+
r"""Tags for filtering and grouping in @{product}"""
|
|
765
|
+
prometheus_url: NotRequired[str]
|
|
766
|
+
r"""The remote_write endpoint to send Prometheus metrics to, such as https://prometheus-blocks-prod-us-central1.grafana.net/api/prom/push"""
|
|
767
|
+
message: NotRequired[str]
|
|
768
|
+
r"""Name of the event field that contains the message to send. If not specified, Stream sends a JSON representation of the whole event."""
|
|
769
|
+
message_format: NotRequired[OutputGrafanaCloudMessageFormat1]
|
|
770
|
+
r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
|
|
771
|
+
labels: NotRequired[List[OutputGrafanaCloudLabel1TypedDict]]
|
|
772
|
+
r"""List of labels to send with logs. Labels define Loki streams, so use static labels to avoid proliferating label value combinations and streams. Can be merged and/or overridden by the event's __labels field. Example: '__labels: {host: \"cribl.io\", level: \"error\"}'"""
|
|
773
|
+
metric_rename_expr: NotRequired[str]
|
|
774
|
+
r"""JavaScript expression that can be used to rename metrics. For example, name.replace(/\./g, '_') will replace all '.' characters in a metric's name with the supported '_' character. Use the 'name' global variable to access the metric's name. You can access event fields' values via __e.<fieldName>."""
|
|
775
|
+
prometheus_auth: NotRequired[OutputGrafanaCloudPrometheusAuth1TypedDict]
|
|
776
|
+
loki_auth: NotRequired[OutputGrafanaCloudLokiAuth1TypedDict]
|
|
777
|
+
concurrency: NotRequired[float]
|
|
778
|
+
r"""Maximum number of ongoing requests before blocking. Warning: Setting this value > 1 can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
779
|
+
max_payload_size_kb: NotRequired[float]
|
|
780
|
+
r"""Maximum size, in KB, of the request body. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
781
|
+
max_payload_events: NotRequired[float]
|
|
782
|
+
r"""Maximum number of events to include in the request body. Default is 0 (unlimited). Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
783
|
+
reject_unauthorized: NotRequired[bool]
|
|
784
|
+
r"""Reject certificates not authorized by a CA in the CA certificate path or by another trusted CA (such as the system's).
|
|
785
|
+
Enabled by default. When this setting is also present in TLS Settings (Client Side),
|
|
786
|
+
that value will take precedence.
|
|
787
|
+
"""
|
|
788
|
+
timeout_sec: NotRequired[float]
|
|
789
|
+
r"""Amount of time, in seconds, to wait for a request to complete before canceling it"""
|
|
790
|
+
flush_period_sec: NotRequired[float]
|
|
791
|
+
r"""Maximum time between requests. Small values could cause the payload size to be smaller than the configured Maximum time between requests. Small values can reduce the payload size below the configured 'Max record size' and 'Max events per request'. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
792
|
+
extra_http_headers: NotRequired[List[OutputGrafanaCloudExtraHTTPHeader1TypedDict]]
|
|
793
|
+
r"""Headers to add to all events"""
|
|
794
|
+
use_round_robin_dns: NotRequired[bool]
|
|
795
|
+
r"""Enable round-robin DNS lookup. When a DNS server returns multiple addresses, @{product} will cycle through them in the order returned. For optimal performance, consider enabling this setting for non-load balanced destinations."""
|
|
796
|
+
failed_request_logging_mode: NotRequired[
|
|
797
|
+
OutputGrafanaCloudFailedRequestLoggingMode1
|
|
798
|
+
]
|
|
799
|
+
r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
|
|
800
|
+
safe_headers: NotRequired[List[str]]
|
|
801
|
+
r"""List of headers that are safe to log in plain text"""
|
|
802
|
+
response_retry_settings: NotRequired[
|
|
803
|
+
List[OutputGrafanaCloudResponseRetrySetting1TypedDict]
|
|
804
|
+
]
|
|
805
|
+
r"""Automatically retry after unsuccessful response status codes, such as 429 (Too Many Requests) or 503 (Service Unavailable)"""
|
|
806
|
+
timeout_retry_settings: NotRequired[
|
|
807
|
+
OutputGrafanaCloudTimeoutRetrySettings1TypedDict
|
|
808
|
+
]
|
|
809
|
+
response_honor_retry_after_header: NotRequired[bool]
|
|
810
|
+
r"""Honor any Retry-After header that specifies a delay (in seconds) no longer than 180 seconds after the retry request. @{product} limits the delay to 180 seconds, even if the Retry-After header specifies a longer delay. When enabled, takes precedence over user-configured retry options. When disabled, all Retry-After headers are ignored."""
|
|
811
|
+
on_backpressure: NotRequired[OutputGrafanaCloudBackpressureBehavior1]
|
|
812
|
+
r"""How to handle events when all receivers are exerting backpressure"""
|
|
813
|
+
description: NotRequired[str]
|
|
814
|
+
compress: NotRequired[bool]
|
|
815
|
+
r"""Compress the payload body before sending. Applies only to JSON payloads; the Protobuf variant for both Prometheus and Loki are snappy-compressed by default."""
|
|
816
|
+
pq_max_file_size: NotRequired[str]
|
|
817
|
+
r"""The maximum size to store in each queue file before closing and optionally compressing (KB, MB, etc.)"""
|
|
818
|
+
pq_max_size: NotRequired[str]
|
|
819
|
+
r"""The maximum disk space that the queue can consume (as an average per Worker Process) before queueing stops. Enter a numeral with units of KB, MB, etc."""
|
|
820
|
+
pq_path: NotRequired[str]
|
|
821
|
+
r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/<output-id>."""
|
|
822
|
+
pq_compress: NotRequired[OutputGrafanaCloudCompression1]
|
|
823
|
+
r"""Codec to use to compress the persisted data"""
|
|
824
|
+
pq_on_backpressure: NotRequired[OutputGrafanaCloudQueueFullBehavior1]
|
|
825
|
+
r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
|
|
826
|
+
pq_mode: NotRequired[OutputGrafanaCloudMode1]
|
|
827
|
+
r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
|
|
828
|
+
pq_controls: NotRequired[OutputGrafanaCloudPqControls1TypedDict]
|
|
829
|
+
|
|
830
|
+
|
|
831
|
+
class OutputGrafanaCloud1(BaseModel):
|
|
832
|
+
id: str
|
|
833
|
+
r"""Unique ID for this output"""
|
|
834
|
+
|
|
835
|
+
type: Annotated[OutputGrafanaCloudType1, PlainValidator(validate_open_enum(False))]
|
|
836
|
+
|
|
837
|
+
loki_url: Annotated[str, pydantic.Field(alias="lokiUrl")]
|
|
838
|
+
r"""The endpoint to send logs to, such as https://logs-prod-us-central1.grafana.net"""
|
|
839
|
+
|
|
840
|
+
pipeline: Optional[str] = None
|
|
841
|
+
r"""Pipeline to process data before sending out to this output"""
|
|
842
|
+
|
|
843
|
+
system_fields: Annotated[
|
|
844
|
+
Optional[List[str]], pydantic.Field(alias="systemFields")
|
|
845
|
+
] = None
|
|
846
|
+
r"""Fields to automatically add to events, such as cribl_pipe. Supports wildcards. These fields are added as dimensions and labels to generated metrics and logs, respectively."""
|
|
847
|
+
|
|
848
|
+
environment: Optional[str] = None
|
|
849
|
+
r"""Optionally, enable this config only on a specified Git branch. If empty, will be enabled everywhere."""
|
|
850
|
+
|
|
851
|
+
streamtags: Optional[List[str]] = None
|
|
852
|
+
r"""Tags for filtering and grouping in @{product}"""
|
|
853
|
+
|
|
854
|
+
prometheus_url: Annotated[Optional[str], pydantic.Field(alias="prometheusUrl")] = (
|
|
855
|
+
None
|
|
856
|
+
)
|
|
857
|
+
r"""The remote_write endpoint to send Prometheus metrics to, such as https://prometheus-blocks-prod-us-central1.grafana.net/api/prom/push"""
|
|
858
|
+
|
|
859
|
+
message: Optional[str] = None
|
|
860
|
+
r"""Name of the event field that contains the message to send. If not specified, Stream sends a JSON representation of the whole event."""
|
|
861
|
+
|
|
862
|
+
message_format: Annotated[
|
|
863
|
+
Annotated[
|
|
864
|
+
Optional[OutputGrafanaCloudMessageFormat1],
|
|
865
|
+
PlainValidator(validate_open_enum(False)),
|
|
866
|
+
],
|
|
867
|
+
pydantic.Field(alias="messageFormat"),
|
|
868
|
+
] = OutputGrafanaCloudMessageFormat1.PROTOBUF
|
|
869
|
+
r"""Format to use when sending logs to Loki (Protobuf or JSON)"""
|
|
870
|
+
|
|
871
|
+
labels: Optional[List[OutputGrafanaCloudLabel1]] = None
|
|
872
|
+
r"""List of labels to send with logs. Labels define Loki streams, so use static labels to avoid proliferating label value combinations and streams. Can be merged and/or overridden by the event's __labels field. Example: '__labels: {host: \"cribl.io\", level: \"error\"}'"""
|
|
873
|
+
|
|
874
|
+
metric_rename_expr: Annotated[
|
|
875
|
+
Optional[str], pydantic.Field(alias="metricRenameExpr")
|
|
876
|
+
] = "name.replace(/[^a-zA-Z0-9_]/g, '_')"
|
|
877
|
+
r"""JavaScript expression that can be used to rename metrics. For example, name.replace(/\./g, '_') will replace all '.' characters in a metric's name with the supported '_' character. Use the 'name' global variable to access the metric's name. You can access event fields' values via __e.<fieldName>."""
|
|
878
|
+
|
|
879
|
+
prometheus_auth: Annotated[
|
|
880
|
+
Optional[OutputGrafanaCloudPrometheusAuth1],
|
|
881
|
+
pydantic.Field(alias="prometheusAuth"),
|
|
882
|
+
] = None
|
|
883
|
+
|
|
884
|
+
loki_auth: Annotated[
|
|
885
|
+
Optional[OutputGrafanaCloudLokiAuth1], pydantic.Field(alias="lokiAuth")
|
|
886
|
+
] = None
|
|
887
|
+
|
|
888
|
+
concurrency: Optional[float] = 1
|
|
889
|
+
r"""Maximum number of ongoing requests before blocking. Warning: Setting this value > 1 can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
890
|
+
|
|
891
|
+
max_payload_size_kb: Annotated[
|
|
892
|
+
Optional[float], pydantic.Field(alias="maxPayloadSizeKB")
|
|
893
|
+
] = 4096
|
|
894
|
+
r"""Maximum size, in KB, of the request body. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
895
|
+
|
|
896
|
+
max_payload_events: Annotated[
|
|
897
|
+
Optional[float], pydantic.Field(alias="maxPayloadEvents")
|
|
898
|
+
] = 0
|
|
899
|
+
r"""Maximum number of events to include in the request body. Default is 0 (unlimited). Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
900
|
+
|
|
901
|
+
reject_unauthorized: Annotated[
|
|
902
|
+
Optional[bool], pydantic.Field(alias="rejectUnauthorized")
|
|
903
|
+
] = True
|
|
904
|
+
r"""Reject certificates not authorized by a CA in the CA certificate path or by another trusted CA (such as the system's).
|
|
905
|
+
Enabled by default. When this setting is also present in TLS Settings (Client Side),
|
|
906
|
+
that value will take precedence.
|
|
907
|
+
"""
|
|
908
|
+
|
|
909
|
+
timeout_sec: Annotated[Optional[float], pydantic.Field(alias="timeoutSec")] = 30
|
|
910
|
+
r"""Amount of time, in seconds, to wait for a request to complete before canceling it"""
|
|
911
|
+
|
|
912
|
+
flush_period_sec: Annotated[
|
|
913
|
+
Optional[float], pydantic.Field(alias="flushPeriodSec")
|
|
914
|
+
] = 15
|
|
915
|
+
r"""Maximum time between requests. Small values could cause the payload size to be smaller than the configured Maximum time between requests. Small values can reduce the payload size below the configured 'Max record size' and 'Max events per request'. Warning: Setting this too low can increase the number of ongoing requests (depending on the value of 'Request concurrency'); this can cause Loki and Prometheus to complain about entries being delivered out of order."""
|
|
916
|
+
|
|
917
|
+
extra_http_headers: Annotated[
|
|
918
|
+
Optional[List[OutputGrafanaCloudExtraHTTPHeader1]],
|
|
919
|
+
pydantic.Field(alias="extraHttpHeaders"),
|
|
920
|
+
] = None
|
|
921
|
+
r"""Headers to add to all events"""
|
|
922
|
+
|
|
923
|
+
use_round_robin_dns: Annotated[
|
|
924
|
+
Optional[bool], pydantic.Field(alias="useRoundRobinDns")
|
|
925
|
+
] = False
|
|
926
|
+
r"""Enable round-robin DNS lookup. When a DNS server returns multiple addresses, @{product} will cycle through them in the order returned. For optimal performance, consider enabling this setting for non-load balanced destinations."""
|
|
927
|
+
|
|
928
|
+
failed_request_logging_mode: Annotated[
|
|
929
|
+
Annotated[
|
|
930
|
+
Optional[OutputGrafanaCloudFailedRequestLoggingMode1],
|
|
931
|
+
PlainValidator(validate_open_enum(False)),
|
|
932
|
+
],
|
|
933
|
+
pydantic.Field(alias="failedRequestLoggingMode"),
|
|
934
|
+
] = OutputGrafanaCloudFailedRequestLoggingMode1.NONE
|
|
935
|
+
r"""Data to log when a request fails. All headers are redacted by default, unless listed as safe headers below."""
|
|
936
|
+
|
|
937
|
+
safe_headers: Annotated[
|
|
938
|
+
Optional[List[str]], pydantic.Field(alias="safeHeaders")
|
|
939
|
+
] = None
|
|
940
|
+
r"""List of headers that are safe to log in plain text"""
|
|
941
|
+
|
|
942
|
+
response_retry_settings: Annotated[
|
|
943
|
+
Optional[List[OutputGrafanaCloudResponseRetrySetting1]],
|
|
944
|
+
pydantic.Field(alias="responseRetrySettings"),
|
|
945
|
+
] = None
|
|
946
|
+
r"""Automatically retry after unsuccessful response status codes, such as 429 (Too Many Requests) or 503 (Service Unavailable)"""
|
|
947
|
+
|
|
948
|
+
timeout_retry_settings: Annotated[
|
|
949
|
+
Optional[OutputGrafanaCloudTimeoutRetrySettings1],
|
|
950
|
+
pydantic.Field(alias="timeoutRetrySettings"),
|
|
951
|
+
] = None
|
|
952
|
+
|
|
953
|
+
response_honor_retry_after_header: Annotated[
|
|
954
|
+
Optional[bool], pydantic.Field(alias="responseHonorRetryAfterHeader")
|
|
955
|
+
] = False
|
|
956
|
+
r"""Honor any Retry-After header that specifies a delay (in seconds) no longer than 180 seconds after the retry request. @{product} limits the delay to 180 seconds, even if the Retry-After header specifies a longer delay. When enabled, takes precedence over user-configured retry options. When disabled, all Retry-After headers are ignored."""
|
|
957
|
+
|
|
958
|
+
on_backpressure: Annotated[
|
|
959
|
+
Annotated[
|
|
960
|
+
Optional[OutputGrafanaCloudBackpressureBehavior1],
|
|
961
|
+
PlainValidator(validate_open_enum(False)),
|
|
962
|
+
],
|
|
963
|
+
pydantic.Field(alias="onBackpressure"),
|
|
964
|
+
] = OutputGrafanaCloudBackpressureBehavior1.BLOCK
|
|
965
|
+
r"""How to handle events when all receivers are exerting backpressure"""
|
|
966
|
+
|
|
967
|
+
description: Optional[str] = None
|
|
968
|
+
|
|
969
|
+
compress: Optional[bool] = True
|
|
970
|
+
r"""Compress the payload body before sending. Applies only to JSON payloads; the Protobuf variant for both Prometheus and Loki are snappy-compressed by default."""
|
|
971
|
+
|
|
972
|
+
pq_max_file_size: Annotated[
|
|
973
|
+
Optional[str], pydantic.Field(alias="pqMaxFileSize")
|
|
974
|
+
] = "1 MB"
|
|
975
|
+
r"""The maximum size to store in each queue file before closing and optionally compressing (KB, MB, etc.)"""
|
|
976
|
+
|
|
977
|
+
pq_max_size: Annotated[Optional[str], pydantic.Field(alias="pqMaxSize")] = "5GB"
|
|
978
|
+
r"""The maximum disk space that the queue can consume (as an average per Worker Process) before queueing stops. Enter a numeral with units of KB, MB, etc."""
|
|
979
|
+
|
|
980
|
+
pq_path: Annotated[Optional[str], pydantic.Field(alias="pqPath")] = (
|
|
981
|
+
"$CRIBL_HOME/state/queues"
|
|
982
|
+
)
|
|
983
|
+
r"""The location for the persistent queue files. To this field's value, the system will append: /<worker-id>/<output-id>."""
|
|
984
|
+
|
|
985
|
+
pq_compress: Annotated[
|
|
986
|
+
Annotated[
|
|
987
|
+
Optional[OutputGrafanaCloudCompression1],
|
|
988
|
+
PlainValidator(validate_open_enum(False)),
|
|
989
|
+
],
|
|
990
|
+
pydantic.Field(alias="pqCompress"),
|
|
991
|
+
] = OutputGrafanaCloudCompression1.NONE
|
|
992
|
+
r"""Codec to use to compress the persisted data"""
|
|
993
|
+
|
|
994
|
+
pq_on_backpressure: Annotated[
|
|
995
|
+
Annotated[
|
|
996
|
+
Optional[OutputGrafanaCloudQueueFullBehavior1],
|
|
997
|
+
PlainValidator(validate_open_enum(False)),
|
|
998
|
+
],
|
|
999
|
+
pydantic.Field(alias="pqOnBackpressure"),
|
|
1000
|
+
] = OutputGrafanaCloudQueueFullBehavior1.BLOCK
|
|
1001
|
+
r"""How to handle events when the queue is exerting backpressure (full capacity or low disk). 'Block' is the same behavior as non-PQ blocking. 'Drop new data' throws away incoming data, while leaving the contents of the PQ unchanged."""
|
|
1002
|
+
|
|
1003
|
+
pq_mode: Annotated[
|
|
1004
|
+
Annotated[
|
|
1005
|
+
Optional[OutputGrafanaCloudMode1], PlainValidator(validate_open_enum(False))
|
|
1006
|
+
],
|
|
1007
|
+
pydantic.Field(alias="pqMode"),
|
|
1008
|
+
] = OutputGrafanaCloudMode1.ERROR
|
|
1009
|
+
r"""In Error mode, PQ writes events to the filesystem if the Destination is unavailable. In Backpressure mode, PQ writes events to the filesystem when it detects backpressure from the Destination. In Always On mode, PQ always writes events to the filesystem."""
|
|
1010
|
+
|
|
1011
|
+
pq_controls: Annotated[
|
|
1012
|
+
Optional[OutputGrafanaCloudPqControls1], pydantic.Field(alias="pqControls")
|
|
1013
|
+
] = None
|
|
1014
|
+
|
|
1015
|
+
|
|
1016
|
+
OutputGrafanaCloudUnionTypedDict = TypeAliasType(
|
|
1017
|
+
"OutputGrafanaCloudUnionTypedDict",
|
|
1018
|
+
Union[OutputGrafanaCloud1TypedDict, OutputGrafanaCloud2TypedDict],
|
|
1019
|
+
)
|
|
1020
|
+
|
|
1021
|
+
|
|
1022
|
+
OutputGrafanaCloudUnion = TypeAliasType(
|
|
1023
|
+
"OutputGrafanaCloudUnion", Union[OutputGrafanaCloud1, OutputGrafanaCloud2]
|
|
1024
|
+
)
|