-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(build): changes to decrease build time, cancel runs in case of multiple commits #5187
Changes from all commits
e570af8
e5de027
c503a50
5a8fecb
252364a
01f1dc6
2e8b631
ae3c604
bba17d8
2a0ad0b
b6e71d1
f12d45f
e6e4dc2
69d6f51
78c8ff1
4f452ba
378d15f
6cf623a
c756555
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -321,7 +321,6 @@ def get_long_description(): | |
"pytest-asyncio>=0.16.0", | ||
"pytest-cov>=2.8.1", | ||
"pytest-docker>=0.10.3,<0.12", | ||
"tox", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why did you remove tox? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Also interested to know! There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. tried parallelising via tox but there was some problem during builds. the build wheel being generated by the 3 test suites was stepping on each other's toes and causing at least one of them to fail. Also, thought it might be better to do it via github actions so we can easily parallelise and isolate. Now if that SAP HANA test flakes we can simply re-run that (that and nifi one under slow integration) one instead of all integration tests. |
||
"deepdiff", | ||
"requests-mock", | ||
"freezegun", | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
import json | ||
import logging | ||
import os | ||
from json.decoder import JSONDecodeError | ||
from typing import Any, Dict, List, Optional, Type | ||
|
||
|
@@ -24,6 +25,11 @@ | |
logger = logging.getLogger(__name__) | ||
|
||
|
||
telemetry_enabled = ( | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why is this guy in here? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Because in case we had file sink this was causing telemetry client id to fetched. In case telemetry is disabled it should not be doing that. For unit tests this was doing 3 retries and failing. Adding this and passing the environment variable reduced time for unit tests by 30-60 secs. |
||
os.environ.get("DATAHUB_TELEMETRY_ENABLED", "true").lower() == "true" | ||
) | ||
|
||
|
||
class DatahubClientConfig(ConfigModel): | ||
"""Configuration class for holding connectivity to datahub gms""" | ||
|
||
|
@@ -51,6 +57,9 @@ def __init__(self, config: DatahubClientConfig) -> None: | |
ca_certificate_path=self.config.ca_certificate_path, | ||
) | ||
self.test_connection() | ||
if not telemetry_enabled: | ||
self.server_id = "missing" | ||
return | ||
try: | ||
client_id: Optional[TelemetryClientIdClass] = self.get_aspect_v2( | ||
"urn:li:telemetry:clientId", TelemetryClientIdClass, "telemetryClientId" | ||
|
This file was deleted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This means cancelling only those in progress for the same PR right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the same branch