Commit 02e2153a authored by dasharatha.vamshi's avatar dasharatha.vamshi

init

parent 5cdb5a24
......@@ -58,7 +58,7 @@ class RequestComponent:
self.s.mount(RequestConstants.HTTP, adapter)
# ---------------------- Sending Request -----------------------------------------------------------------------
print(query)
logger.info(query)
try:
if query[RequestConstants.Request_method].upper() == RequestConstants.Method_get:
# response = requests.request(RequestConstants.Method_get, url=request_url, headers=request_headers,
......
......@@ -22,13 +22,13 @@ if not os.path.exists(os.path.join(os.getcwd(), 'logs')):
LOG_LEVEL = os.environ.get("LOG_LEVEL", _config.get('SERVICE_CONFIG', {}).get("LOG_LEVEL", "INFO")).upper()
LOG_HANDLER_NAME = _config.get('SERVICE_CONFIG', {}).get("LOG_HANDLER_NAME", "HttpRequestComponent")
os.environ['shared_volume'] = 'test'
os.environ['method'] = 'POST'
os.environ['url'] = 'http://localhost:5000/get'
os.environ['headers'] = '{"content-type":"application/json"}'
os.environ['payload'] = '{"name": "vamshi", "gender": "male"}'
os.environ['max_retries'] = '1'
os.environ['authentication'] = '{"username":"vamshi","password":"sai"}'
# os.environ['shared_volume'] = 'test'
# os.environ['method'] = 'POST'
# os.environ['url'] = 'http://localhost:5000/get'
# os.environ['headers'] = '{"content-type":"application/json"}'
# os.environ['payload'] = '{"name": "vamshi", "gender": "male"}'
# os.environ['max_retries'] = '1'
# os.environ['authentication'] = '{"username":"vamshi","password":"sai"}'
config = {
"shared_volume": os.environ.get("shared_volume"),
"method": os.environ.get("method"),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment