简体   繁体   中英

Cassandra cqlengine increase logging verbosity

I am new to cassandra python client. I am currently debugging an issue that I am having with my local cassandra client. For the same, I want to increase the logging verbosity on the cassandra cqlengine client. I want to see detailed logs on what the client is doing as its making database calls. I couldn't find anyway to do it using the client api's that are defined in the documentation.

I am using cassandra cqlengine version 3.3.0 with python 2.6 . Thanks in advance.

cqlengine uses standard Python logging. You can enable by configuring logging for the entire driver package, or select modules.

This log statement will show you statements going out of cqlengine (but not the actual bound attribute values. To setup basic console logging:

import logging
logging.basicConfig()
logger = logging.getLogger('cassandra.cqlengine.connection')
logger.setLevel(logging.DEBUG)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM