You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please suggest a way to get around the streaming-creditials , Please advise how to get around this or any Mock Servers you have for dowjones service which we can use for our load testing purpose.
And I setup the Lister some thing like below listener = Listener(user_key=api_key) # if ENV == 'perf' or 'local': listener.config.DEFAULT_HOST = os.getenv('MOCK_DJ_HOST')
and I am passing MOCK_DJ_HOST connection details from a docker-compose via environmen t
- PUBSUB_EMULATOR_HOST=mock-dowjones:8085
listener.listen(callback, subscription_id=subscription_id, maximum_messages=100) dowjones | File "/app/listener.py", line 61, in listen dowjones | pubsub_client = pubsub_service.get_client(self.config) dowjones | File "/usr/local/lib/python3.6/site-packages/dnaStreaming/services/pubsub_service.py", line 10, in get_client dowjones | streaming_credentials = credentials_service.fetch_credentials(config) dowjones | File "/usr/local/lib/python3.6/site-packages/dnaStreaming/services/credentials_service.py", line 9, in fetch_credentials dowjones | headers=config.get_headers()) dowjones | File "/usr/local/lib/python3.6/site-packages/requests/api.py", line 75, in get dowjones | return request('get', url, params=params, **kwargs) dowjones | File "/usr/local/lib/python3.6/site-packages/requests/api.py", line 60, in request dowjones | return session.request(method=method, url=url, **kwargs) dowjones | File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 533, in request dowjones | resp = self.send(prep, **send_kwargs) dowjones | File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 640, in send dowjones | adapter = self.get_adapter(url=request.url) dowjones | File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 731, in get_adapter dowjones | raise InvalidSchema("No connection adapters were found for '%s'" % url) dowjones | requests.exceptions.InvalidSchema: No connection adapters were found for 'mock-dowjones:8085/alpha/accounts/streaming-credentials'
The text was updated successfully, but these errors were encountered:
for your information my mock-dowjones is a googlepubsub docker container FROM google/cloud-sdk:alpine RUN apk add --no-cache openjdk7-jre RUN gcloud components install beta pubsub-emulator --quiet RUN gcloud components update --quiet RUN mkdir -p /tmp/emulators/pubsub VOLUME /tmp/emulators/pubsub EXPOSE 8085 CMD ["gcloud", "beta", "emulators", "pubsub", "start", "--data-dir", "/tmp/emulators/pubsub", "--host-port", "0.0.0.0:8085", "--verbosity", "info", "--quiet"]
Dear DowJones Team,
I am working with a project where we consuming data from Dowjones using Listner along with a Mock Dowjones server ( created using google pub sub ).
Facing a connection issue with in listen method ( https://github.com/dowjones/dj-dna-streams-python/blob/master/dnaStreaming/listener.py#L60-L96)
Please suggest a way to get around the streaming-creditials , Please advise how to get around this or any Mock Servers you have for dowjones service which we can use for our load testing purpose.
where my python script calling
listener.listen(callback, subscription_id=subscription_id, maximum_messages=100)
And I setup the Lister some thing like below
listener = Listener(user_key=api_key) # if ENV == 'perf' or 'local': listener.config.DEFAULT_HOST = os.getenv('MOCK_DJ_HOST')
and I am passing MOCK_DJ_HOST connection details from a docker-compose via environmen t
- PUBSUB_EMULATOR_HOST=mock-dowjones:8085
listener.listen(callback, subscription_id=subscription_id, maximum_messages=100) dowjones | File "/app/listener.py", line 61, in listen dowjones | pubsub_client = pubsub_service.get_client(self.config) dowjones | File "/usr/local/lib/python3.6/site-packages/dnaStreaming/services/pubsub_service.py", line 10, in get_client dowjones | streaming_credentials = credentials_service.fetch_credentials(config) dowjones | File "/usr/local/lib/python3.6/site-packages/dnaStreaming/services/credentials_service.py", line 9, in fetch_credentials dowjones | headers=config.get_headers()) dowjones | File "/usr/local/lib/python3.6/site-packages/requests/api.py", line 75, in get dowjones | return request('get', url, params=params, **kwargs) dowjones | File "/usr/local/lib/python3.6/site-packages/requests/api.py", line 60, in request dowjones | return session.request(method=method, url=url, **kwargs) dowjones | File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 533, in request dowjones | resp = self.send(prep, **send_kwargs) dowjones | File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 640, in send dowjones | adapter = self.get_adapter(url=request.url) dowjones | File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 731, in get_adapter dowjones | raise InvalidSchema("No connection adapters were found for '%s'" % url) dowjones | requests.exceptions.InvalidSchema: No connection adapters were found for 'mock-dowjones:8085/alpha/accounts/streaming-credentials'
The text was updated successfully, but these errors were encountered: