[ 
https://issues.apache.org/jira/browse/IGNITE-15103?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan Daschinsky updated IGNITE-15103:
-------------------------------------
    Description: 
Currently, there is no logging at all, should be added using {{logging}} module
Also, optional handler to {{stderr}} should be added if env variable is set, 
[i.e.|https://github.com/aio-libs/aioredis-py/blob/bb0dcebed350a5f764dc84c5b6bcb44a3bf98c6b/aioredis/log.py]
{code:python}
logger = logging.getLogger("pyignite")

if os.environ.get("PYIGNITE_DEBUG"):
    logger.setLevel(logging.DEBUG)
    handler = logging.StreamHandler(stream=sys.stderr)
    handler.setFormatter(
        logging.Formatter("%(asctime)s %(name)s %(levelname)s %(message)s")
    )
    logger.addHandler(handler)
    os.environ["PYIGNITE_DEBUG"] = ""
{code}


  was:Currently, there is no logging at all, should be added using {{logging}} 
module


> Add logging to pyignite client
> ------------------------------
>
>                 Key: IGNITE-15103
>                 URL: https://issues.apache.org/jira/browse/IGNITE-15103
>             Project: Ignite
>          Issue Type: Improvement
>          Components: python, thin client
>            Reporter: Ivan Daschinsky
>            Assignee: Ivan Daschinsky
>            Priority: Major
>              Labels: python, thin
>
> Currently, there is no logging at all, should be added using {{logging}} 
> module
> Also, optional handler to {{stderr}} should be added if env variable is set, 
> [i.e.|https://github.com/aio-libs/aioredis-py/blob/bb0dcebed350a5f764dc84c5b6bcb44a3bf98c6b/aioredis/log.py]
> {code:python}
> logger = logging.getLogger("pyignite")
> if os.environ.get("PYIGNITE_DEBUG"):
>     logger.setLevel(logging.DEBUG)
>     handler = logging.StreamHandler(stream=sys.stderr)
>     handler.setFormatter(
>         logging.Formatter("%(asctime)s %(name)s %(levelname)s %(message)s")
>     )
>     logger.addHandler(handler)
>     os.environ["PYIGNITE_DEBUG"] = ""
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to