airbyte-internal-ops 0.2.4__py3-none-any.whl → 0.3.1__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.
- {airbyte_internal_ops-0.2.4.dist-info → airbyte_internal_ops-0.3.1.dist-info}/METADATA +1 -1
- {airbyte_internal_ops-0.2.4.dist-info → airbyte_internal_ops-0.3.1.dist-info}/RECORD +18 -15
- airbyte_ops_mcp/cli/cloud.py +79 -0
- airbyte_ops_mcp/cloud_admin/api_client.py +463 -69
- airbyte_ops_mcp/connection_config_retriever/audit_logging.py +4 -8
- airbyte_ops_mcp/constants.py +3 -0
- airbyte_ops_mcp/gcp_auth.py +142 -49
- airbyte_ops_mcp/gcp_logs/__init__.py +18 -0
- airbyte_ops_mcp/gcp_logs/error_lookup.py +384 -0
- airbyte_ops_mcp/mcp/cloud_connector_versions.py +20 -1
- airbyte_ops_mcp/mcp/gcp_logs.py +92 -0
- airbyte_ops_mcp/mcp/prod_db_queries.py +180 -7
- airbyte_ops_mcp/mcp/server.py +2 -0
- airbyte_ops_mcp/prod_db_access/queries.py +82 -1
- airbyte_ops_mcp/prod_db_access/sql.py +299 -0
- airbyte_ops_mcp/regression_tests/connection_secret_retriever.py +0 -4
- {airbyte_internal_ops-0.2.4.dist-info → airbyte_internal_ops-0.3.1.dist-info}/WHEEL +0 -0
- {airbyte_internal_ops-0.2.4.dist-info → airbyte_internal_ops-0.3.1.dist-info}/entry_points.txt +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
airbyte_ops_mcp/__init__.py,sha256=tuzdlMkfnWBnsri5KGHM2M_xuNnzFk2u_aR79mmN7Yg,772
|
|
2
2
|
airbyte_ops_mcp/_annotations.py,sha256=MO-SBDnbykxxHDESG7d8rviZZ4WlZgJKv0a8eBqcEzQ,1757
|
|
3
|
-
airbyte_ops_mcp/constants.py,sha256=
|
|
4
|
-
airbyte_ops_mcp/gcp_auth.py,sha256=
|
|
3
|
+
airbyte_ops_mcp/constants.py,sha256=khcv9W3WkApIyPygEGgE2noBIqLomjoOMLxFBU1ArjA,5308
|
|
4
|
+
airbyte_ops_mcp/gcp_auth.py,sha256=i0cm1_xX4fj_31iKlfARpNvTaSr85iGTSw9KMf4f4MU,7206
|
|
5
5
|
airbyte_ops_mcp/github_actions.py,sha256=wKnuIVmF4u1gMYNdSoryD_PUmvMz5SaHgOvbU0dsolA,9957
|
|
6
6
|
airbyte_ops_mcp/github_api.py,sha256=uupbYKAkm7yLHK_1cDXYKl1bOYhUygZhG5IHspS7duE,8104
|
|
7
7
|
airbyte_ops_mcp/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -353,41 +353,44 @@ airbyte_ops_mcp/cli/__init__.py,sha256=XpL7FyVfgabfBF2JR7u7NwJ2krlYqjd_OwLcWf-Xc
|
|
|
353
353
|
airbyte_ops_mcp/cli/_base.py,sha256=I8tWnyQf0ks4r3J8N8h-5GZxyn37T-55KsbuHnxYlcg,415
|
|
354
354
|
airbyte_ops_mcp/cli/_shared.py,sha256=jg-xMyGzTCGPqKd8VTfE_3kGPIyO_3Kx5sQbG4rPc0Y,1311
|
|
355
355
|
airbyte_ops_mcp/cli/app.py,sha256=SEdBpqFUG2O8zGV5ifwptxrLGFph_dLr66-MX9d69gQ,789
|
|
356
|
-
airbyte_ops_mcp/cli/cloud.py,sha256=
|
|
356
|
+
airbyte_ops_mcp/cli/cloud.py,sha256=OmeJPW8ME82PLJSqzoU_tz_3iqsTA-MY4QBO-ad8gfo,44141
|
|
357
357
|
airbyte_ops_mcp/cli/gh.py,sha256=91b1AxFXvHQCFyXhrrym-756ZjnMCqvxFdmwCtma1zI,2046
|
|
358
358
|
airbyte_ops_mcp/cli/registry.py,sha256=tcf_CDiUVJpSdBRNqlEL3zFKMqK53AhFpJjAETM4gLs,9781
|
|
359
359
|
airbyte_ops_mcp/cli/repo.py,sha256=G1hoQpH0XYhUH3FFOsia9xabGB0LP9o3XcwBuqvFVo0,16331
|
|
360
360
|
airbyte_ops_mcp/cloud_admin/__init__.py,sha256=cqE96Q10Kp6elhH9DAi6TVsIwSUy3sooDLLrxTaktGk,816
|
|
361
|
-
airbyte_ops_mcp/cloud_admin/api_client.py,sha256=
|
|
361
|
+
airbyte_ops_mcp/cloud_admin/api_client.py,sha256=ysTztSbLX0SZSK3qneHTSKVODRzVmLbHBC3ND0j_LTc,38020
|
|
362
362
|
airbyte_ops_mcp/cloud_admin/auth.py,sha256=qE2Aqe0qbZB755KscL65s54Jz78-F-X5a8fXKsrYEOQ,3749
|
|
363
363
|
airbyte_ops_mcp/cloud_admin/connection_config.py,sha256=9opGQer-cGMJANmm-LFLMwvMCNu3nzxa2n2XHkZj9Fw,4899
|
|
364
364
|
airbyte_ops_mcp/cloud_admin/models.py,sha256=YZ3FbEW-tZa50khKTTl4Bzvy_LsGyyQd6qcpXo62jls,2670
|
|
365
365
|
airbyte_ops_mcp/connection_config_retriever/__init__.py,sha256=Xoi-YvARrNPhECdpwEDDkdwEpnvj8zuUlwULpf4iRrU,800
|
|
366
|
-
airbyte_ops_mcp/connection_config_retriever/audit_logging.py,sha256=
|
|
366
|
+
airbyte_ops_mcp/connection_config_retriever/audit_logging.py,sha256=QdOG9984NXeMaKeJnFUZ4oCOmqi37PBRG2NRBBjrZQQ,2753
|
|
367
367
|
airbyte_ops_mcp/connection_config_retriever/retrieval.py,sha256=s6yeCyrboWkUd6KdaheEo87x-rLtQNTL8XeR8O9z2HI,12160
|
|
368
368
|
airbyte_ops_mcp/connection_config_retriever/secrets_resolution.py,sha256=12g0lZzhCzAPl4Iv4eMW6d76mvXjIBGspOnNhywzks4,3644
|
|
369
|
+
airbyte_ops_mcp/gcp_logs/__init__.py,sha256=IqkxclXJnD1U4L2at7aC9GYqPXnuLdYLgmkm3ZiIu6s,409
|
|
370
|
+
airbyte_ops_mcp/gcp_logs/error_lookup.py,sha256=Ufl1FtNQJKP_yWndVT1Xku1mT-gxW_0atmNMCYMXvOo,12757
|
|
369
371
|
airbyte_ops_mcp/mcp/__init__.py,sha256=QqkNkxzdXlg-W03urBAQ3zmtOKFPf35rXgO9ceUjpng,334
|
|
370
372
|
airbyte_ops_mcp/mcp/_guidance.py,sha256=48tQSnDnxqXtyGJxxgjz0ZiI814o_7Fj7f6R8jpQ7so,2375
|
|
371
373
|
airbyte_ops_mcp/mcp/_http_headers.py,sha256=9TAH2RYhFR3z2JugW4Q3WrrqJIdaCzAbyA1GhtQ_EMM,7278
|
|
372
374
|
airbyte_ops_mcp/mcp/_mcp_utils.py,sha256=WNwcGzF7XGKZNAYRt0Uhj5BkRfmwqnFABCrk77OZjRw,11512
|
|
373
|
-
airbyte_ops_mcp/mcp/cloud_connector_versions.py,sha256=
|
|
375
|
+
airbyte_ops_mcp/mcp/cloud_connector_versions.py,sha256=5qUYRZapYBprmmc5J3lKQzeQ3yJUiFQbrxBgUvnLUgQ,16297
|
|
374
376
|
airbyte_ops_mcp/mcp/connector_analysis.py,sha256=OC4KrOSkMkKPkOisWnSv96BDDE5TQYHq-Jxa2vtjJpo,298
|
|
375
377
|
airbyte_ops_mcp/mcp/connector_qa.py,sha256=aImpqdnqBPDrz10BS0owsV4kuIU2XdalzgbaGZsbOL0,258
|
|
378
|
+
airbyte_ops_mcp/mcp/gcp_logs.py,sha256=IPtq4098_LN1Cgeba4jATO1iYFFFpL2-aRO0pGcOdzs,2689
|
|
376
379
|
airbyte_ops_mcp/mcp/github.py,sha256=h3M3VJrq09y_F9ueQVCq3bUbVBNFuTNKprHtGU_ttio,8045
|
|
377
380
|
airbyte_ops_mcp/mcp/github_repo_ops.py,sha256=PiERpt8abo20Gz4CfXhrDNlVM4o4FOt5sweZJND2a0s,5314
|
|
378
381
|
airbyte_ops_mcp/mcp/metadata.py,sha256=fwGW97WknR5lfKcQnFtK6dU87aA6TmLj1NkKyqDAV9g,270
|
|
379
382
|
airbyte_ops_mcp/mcp/prerelease.py,sha256=nc6VU03ADVHWM3OjGKxbS5XqY4VoyRyrZNU_fyAtaOI,10465
|
|
380
|
-
airbyte_ops_mcp/mcp/prod_db_queries.py,sha256=
|
|
383
|
+
airbyte_ops_mcp/mcp/prod_db_queries.py,sha256=DPzyHCT3yxj2kjkucefoVpsR71vscuJQ8tGgLs_lhv0,32068
|
|
381
384
|
airbyte_ops_mcp/mcp/prompts.py,sha256=mJld9mdPECXYZffWXGSvNs4Xevx3rxqUGNlzGKVC2_s,1599
|
|
382
385
|
airbyte_ops_mcp/mcp/registry.py,sha256=PW-VYUj42qx2pQ_apUkVaoUFq7VgB9zEU7-aGrkSCCw,290
|
|
383
386
|
airbyte_ops_mcp/mcp/regression_tests.py,sha256=S1h-5S5gcZA4WEtIZyAQ836hd04tjSRRqMiYMx0S93g,16079
|
|
384
|
-
airbyte_ops_mcp/mcp/server.py,sha256=
|
|
387
|
+
airbyte_ops_mcp/mcp/server.py,sha256=lKAXxt4u4bz7dsKvAYFFHziMbun2pOnxYmrMtRxsZvM,5317
|
|
385
388
|
airbyte_ops_mcp/mcp/server_info.py,sha256=Yi4B1auW64QZGBDas5mro_vwTjvrP785TFNSBP7GhRg,2361
|
|
386
389
|
airbyte_ops_mcp/prod_db_access/__init__.py,sha256=5pxouMPY1beyWlB0UwPnbaLTKTHqU6X82rbbgKY2vYU,1069
|
|
387
390
|
airbyte_ops_mcp/prod_db_access/db_engine.py,sha256=VUqEWZtharJUR-Cri_pMwtGh1C4Neu4s195mbEXlm-w,9190
|
|
388
391
|
airbyte_ops_mcp/prod_db_access/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
389
|
-
airbyte_ops_mcp/prod_db_access/queries.py,sha256=
|
|
390
|
-
airbyte_ops_mcp/prod_db_access/sql.py,sha256=
|
|
392
|
+
airbyte_ops_mcp/prod_db_access/queries.py,sha256=TNxTY5Hf3ImHBX0_e_20-VbF3yzYm2mX3ykWzQXgpno,17754
|
|
393
|
+
airbyte_ops_mcp/prod_db_access/sql.py,sha256=xB7SJGnBSlY-ZB7ku_9QfvNIEldGEmCn-jJcAdes_LY,30407
|
|
391
394
|
airbyte_ops_mcp/registry/__init__.py,sha256=iEaPlt9GrnlaLbc__98TguNeZG8wuQu7S-_2QkhHcbA,858
|
|
392
395
|
airbyte_ops_mcp/registry/models.py,sha256=B4L4TKr52wo0xs0CqvCBrpowqjShzVnZ5eTr2-EyhNs,2346
|
|
393
396
|
airbyte_ops_mcp/registry/publish.py,sha256=VoPxsM2_0zJ829orzCRN-kjgcJtuBNyXgW4I9J680ro,12717
|
|
@@ -396,7 +399,7 @@ airbyte_ops_mcp/regression_tests/cdk_secrets.py,sha256=iRjqqBS96KZoswfgT7ju-pE_p
|
|
|
396
399
|
airbyte_ops_mcp/regression_tests/ci_output.py,sha256=rrvCVKKShc1iVPMuQJDBqSbsiAHIDpX8SA9j0Uwl_Cg,12718
|
|
397
400
|
airbyte_ops_mcp/regression_tests/config.py,sha256=dwWeY0tatdbwl9BqbhZ7EljoZDCtKmGO5fvOAIxeXmA,5873
|
|
398
401
|
airbyte_ops_mcp/regression_tests/connection_fetcher.py,sha256=5wIiA0VvCFNEc-fr6Po18gZMX3E5fyPOGf2SuVOqv5U,12799
|
|
399
|
-
airbyte_ops_mcp/regression_tests/connection_secret_retriever.py,sha256=
|
|
402
|
+
airbyte_ops_mcp/regression_tests/connection_secret_retriever.py,sha256=FhWNVWq7sON4nwUmVJv8BgXBOqg1YV4b5WuWyCzZ0LU,4695
|
|
400
403
|
airbyte_ops_mcp/regression_tests/connector_runner.py,sha256=bappfBSq8dn3IyVAMS_XuzYEwWus23hkDCHLa2RFysI,9920
|
|
401
404
|
airbyte_ops_mcp/regression_tests/evaluation_modes.py,sha256=lAL6pEDmy_XCC7_m4_NXjt_f6Z8CXeAhMkc0FU8bm_M,1364
|
|
402
405
|
airbyte_ops_mcp/regression_tests/http_metrics.py,sha256=oTD7f2MnQOvx4plOxHop2bInQ0-whvuToSsrC7TIM-M,12469
|
|
@@ -411,7 +414,7 @@ airbyte_ops_mcp/regression_tests/regression/comparators.py,sha256=MJkLZEKHivgrG0
|
|
|
411
414
|
airbyte_ops_mcp/regression_tests/validation/__init__.py,sha256=MBEwGOoNuqT4_oCahtoK62OKWIjUCfWa7vZTxNj_0Ek,1532
|
|
412
415
|
airbyte_ops_mcp/regression_tests/validation/catalog_validators.py,sha256=jqqVAMOk0mtdPgwu4d0hA0ZEjtsNh5gapvGydRv3_qk,12553
|
|
413
416
|
airbyte_ops_mcp/regression_tests/validation/record_validators.py,sha256=RjauAhKWNwxMBTu0eNS2hMFNQVs5CLbQU51kp6FOVDk,7432
|
|
414
|
-
airbyte_internal_ops-0.
|
|
415
|
-
airbyte_internal_ops-0.
|
|
416
|
-
airbyte_internal_ops-0.
|
|
417
|
-
airbyte_internal_ops-0.
|
|
417
|
+
airbyte_internal_ops-0.3.1.dist-info/METADATA,sha256=kx1iQ0YE42LjpsFpjJD7SECaYMHEjo36VjvSVf3BwHk,5679
|
|
418
|
+
airbyte_internal_ops-0.3.1.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
|
|
419
|
+
airbyte_internal_ops-0.3.1.dist-info/entry_points.txt,sha256=WxP0l7bRFss4Cr5uQqVj9mTEKwnRKouNuphXQF0lotA,171
|
|
420
|
+
airbyte_internal_ops-0.3.1.dist-info/RECORD,,
|
airbyte_ops_mcp/cli/cloud.py
CHANGED
|
@@ -17,6 +17,7 @@ import shutil
|
|
|
17
17
|
import signal
|
|
18
18
|
import socket
|
|
19
19
|
import subprocess
|
|
20
|
+
import sys
|
|
20
21
|
import tempfile
|
|
21
22
|
import time
|
|
22
23
|
from pathlib import Path
|
|
@@ -44,6 +45,7 @@ from airbyte_ops_mcp.constants import (
|
|
|
44
45
|
DEFAULT_CLOUD_SQL_PROXY_PORT,
|
|
45
46
|
ENV_GCP_PROD_DB_ACCESS_CREDENTIALS,
|
|
46
47
|
)
|
|
48
|
+
from airbyte_ops_mcp.gcp_logs import GCPSeverity, fetch_error_logs
|
|
47
49
|
from airbyte_ops_mcp.mcp.cloud_connector_versions import (
|
|
48
50
|
get_cloud_connector_version,
|
|
49
51
|
set_cloud_connector_version_override,
|
|
@@ -98,6 +100,10 @@ cloud_app.command(connector_app)
|
|
|
98
100
|
db_app = App(name="db", help="Database operations for Airbyte Cloud Prod DB Replica.")
|
|
99
101
|
cloud_app.command(db_app)
|
|
100
102
|
|
|
103
|
+
# Create the logs sub-app under cloud
|
|
104
|
+
logs_app = App(name="logs", help="GCP Cloud Logging operations for Airbyte Cloud.")
|
|
105
|
+
cloud_app.command(logs_app)
|
|
106
|
+
|
|
101
107
|
|
|
102
108
|
@db_app.command(name="start-proxy")
|
|
103
109
|
def start_proxy(
|
|
@@ -1128,3 +1134,76 @@ def fetch_connection_config_cmd(
|
|
|
1128
1134
|
else:
|
|
1129
1135
|
print_error(result.message)
|
|
1130
1136
|
print_json(result.model_dump())
|
|
1137
|
+
|
|
1138
|
+
|
|
1139
|
+
@logs_app.command(name="lookup-cloud-backend-error")
|
|
1140
|
+
def lookup_cloud_backend_error(
|
|
1141
|
+
error_id: Annotated[
|
|
1142
|
+
str,
|
|
1143
|
+
Parameter(
|
|
1144
|
+
help=(
|
|
1145
|
+
"The error ID (UUID) to search for. This is typically returned "
|
|
1146
|
+
"in API error responses as {'errorId': '...'}"
|
|
1147
|
+
)
|
|
1148
|
+
),
|
|
1149
|
+
],
|
|
1150
|
+
lookback_days: Annotated[
|
|
1151
|
+
int,
|
|
1152
|
+
Parameter(help="Number of days to look back in logs."),
|
|
1153
|
+
] = 7,
|
|
1154
|
+
min_severity_filter: Annotated[
|
|
1155
|
+
GCPSeverity | None,
|
|
1156
|
+
Parameter(
|
|
1157
|
+
help="Optional minimum severity level to filter logs.",
|
|
1158
|
+
),
|
|
1159
|
+
] = None,
|
|
1160
|
+
raw: Annotated[
|
|
1161
|
+
bool,
|
|
1162
|
+
Parameter(help="Output raw JSON instead of formatted text."),
|
|
1163
|
+
] = False,
|
|
1164
|
+
) -> None:
|
|
1165
|
+
"""Look up error details from GCP Cloud Logging by error ID.
|
|
1166
|
+
|
|
1167
|
+
When an Airbyte Cloud API returns an error response with only an error ID
|
|
1168
|
+
(e.g., {"errorId": "3173452e-8f22-4286-a1ec-b0f16c1e078a"}), this command
|
|
1169
|
+
fetches the full stack trace and error details from GCP Cloud Logging.
|
|
1170
|
+
|
|
1171
|
+
Requires GCP credentials with Logs Viewer role on the target project.
|
|
1172
|
+
Set up credentials with: gcloud auth application-default login
|
|
1173
|
+
"""
|
|
1174
|
+
print(f"Searching for error ID: {error_id}", file=sys.stderr)
|
|
1175
|
+
print(f"Lookback days: {lookback_days}", file=sys.stderr)
|
|
1176
|
+
if min_severity_filter:
|
|
1177
|
+
print(f"Severity filter: {min_severity_filter}", file=sys.stderr)
|
|
1178
|
+
print(file=sys.stderr)
|
|
1179
|
+
|
|
1180
|
+
result = fetch_error_logs(
|
|
1181
|
+
error_id=error_id,
|
|
1182
|
+
lookback_days=lookback_days,
|
|
1183
|
+
min_severity_filter=min_severity_filter,
|
|
1184
|
+
)
|
|
1185
|
+
|
|
1186
|
+
if raw:
|
|
1187
|
+
print_json(result.model_dump())
|
|
1188
|
+
return
|
|
1189
|
+
|
|
1190
|
+
print(f"Found {result.total_entries_found} log entries", file=sys.stderr)
|
|
1191
|
+
print(file=sys.stderr)
|
|
1192
|
+
|
|
1193
|
+
if result.payloads:
|
|
1194
|
+
for i, payload in enumerate(result.payloads):
|
|
1195
|
+
print(f"=== Log Group {i + 1} ===")
|
|
1196
|
+
print(f"Timestamp: {payload.timestamp}")
|
|
1197
|
+
print(f"Severity: {payload.severity}")
|
|
1198
|
+
if payload.resource.labels.pod_name:
|
|
1199
|
+
print(f"Pod: {payload.resource.labels.pod_name}")
|
|
1200
|
+
print(f"Lines: {payload.num_log_lines}")
|
|
1201
|
+
print()
|
|
1202
|
+
print(payload.message)
|
|
1203
|
+
print()
|
|
1204
|
+
elif result.entries:
|
|
1205
|
+
print("No grouped payloads, showing raw entries:", file=sys.stderr)
|
|
1206
|
+
for entry in result.entries:
|
|
1207
|
+
print(f"[{entry.timestamp}] {entry.severity}: {entry.payload}")
|
|
1208
|
+
else:
|
|
1209
|
+
print_error("No log entries found for this error ID.")
|