-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add grpc server timeout config to instance settings (#7387)
Summary: Creates an instance setting that you can use to say that your server should be allowed more than 60 seconds to start up when waiting for a gRPC server to start.
- Loading branch information
Showing
35 changed files
with
327 additions
and
265 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 11 additions & 9 deletions
20
python_modules/dagster-graphql/dagster_graphql_tests/graphql/test_dagster_environment.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,19 @@ | ||
import sys | ||
|
||
from dagster.core.host_representation import ManagedGrpcPythonEnvRepositoryLocationOrigin | ||
from dagster.core.test_utils import instance_for_test | ||
from dagster.core.types.loadable_target_origin import LoadableTargetOrigin | ||
from dagster.utils import file_relative_path | ||
|
||
|
||
def test_dagster_out_of_process_location(): | ||
with ManagedGrpcPythonEnvRepositoryLocationOrigin( | ||
location_name="test_location", | ||
loadable_target_origin=LoadableTargetOrigin( | ||
executable_path=sys.executable, | ||
python_file=file_relative_path(__file__, "setup.py"), | ||
attribute="test_repo", | ||
), | ||
).create_single_location() as env: | ||
assert env.get_repository("test_repo") | ||
with instance_for_test() as instance: | ||
with ManagedGrpcPythonEnvRepositoryLocationOrigin( | ||
location_name="test_location", | ||
loadable_target_origin=LoadableTargetOrigin( | ||
executable_path=sys.executable, | ||
python_file=file_relative_path(__file__, "setup.py"), | ||
attribute="test_repo", | ||
), | ||
).create_single_location(instance) as env: | ||
assert env.get_repository("test_repo") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
python_modules/dagster/dagster_tests/api_tests/conftest.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# pylint: disable=redefined-outer-name | ||
|
||
import pytest | ||
|
||
from dagster.core.test_utils import instance_for_test | ||
|
||
|
||
@pytest.fixture() | ||
def instance(): | ||
with instance_for_test() as instance: | ||
yield instance |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.