Skip to content

Commit

Permalink
Merge pull request #180 from polamayster/issue-167-X-RAY-creates-new-…
Browse files Browse the repository at this point in the history
…session-with-hardcoded-region

[iss-167] X-RAY creates new session
  • Loading branch information
chanchiem authored Nov 21, 2019
2 parents 697f06a + f597438 commit 324d185
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion aws_xray_sdk/core/sampling/connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -160,5 +160,6 @@ def _create_xray_client(self, ip='127.0.0.1', port='2000'):
url = 'http://%s:%s' % (ip, port)
return session.create_client('xray', endpoint_url=url,
region_name='us-west-2',
config=Config(signature_version=UNSIGNED)
config=Config(signature_version=UNSIGNED),
aws_access_key_id='', aws_secret_access_key=''
)
3 changes: 2 additions & 1 deletion tests/test_recorder.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,11 @@


@pytest.fixture(autouse=True)
def construct_ctx():
def construct_ctx(monkeypatch):
"""
Clean up context storage before and after each test run.
"""
monkeypatch.delattr("botocore.session.Session.get_credentials")
xray_recorder.configure(sampling=False)
xray_recorder.clear_trace_entities()
yield
Expand Down

0 comments on commit 324d185

Please sign in to comment.