Skip to content

Commit 313a91e

Browse files
authored
[AINode] Enable log record by default (#15654)
1 parent ab653b4 commit 313a91e

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

iotdb-core/ainode/ainode/core/log.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
# specific language governing permissions and limitations
1616
# under the License.
1717
#
18+
1819
import inspect
1920
import logging
2021
import multiprocessing
@@ -24,6 +25,7 @@
2425
import threading
2526

2627
from ainode.core.constant import (
28+
AINODE_LOG_DIR,
2729
AINODE_LOG_FILE_LEVELS,
2830
AINODE_LOG_FILE_NAMES,
2931
STD_LEVEL,
@@ -76,7 +78,7 @@ class Logger:
7678
_lock: process lock for logger. This is just a precaution, we currently do not have multiprocessing
7779
"""
7880

79-
def __init__(self, log_dir=None):
81+
def __init__(self, log_dir=AINODE_LOG_DIR):
8082

8183
self.logger_format = logging.Formatter(
8284
fmt="%(asctime)s %(levelname)s %(" "message)s", datefmt="%Y-%m-%d %H:%M:%S"
@@ -114,7 +116,7 @@ def __init__(self, log_dir=None):
114116
for file_handler in self.file_handlers:
115117
self.logger.addHandler(file_handler)
116118
else:
117-
log_dir = "default path"
119+
log_dir = "None"
118120

119121
self.logger.addFilter(LoggerFilter())
120122
self._lock = threading.Lock()

iotdb-core/ainode/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ build-backend = "poetry.core.masonry.api"
2121

2222
[tool.poetry]
2323
name = "apache-iotdb-ainode"
24-
version = "2.0.4.dev"
24+
version = "2.0.5.dev"
2525
description = "Apache IoTDB AINode"
2626
readme = "README.md"
2727
authors = ["Apache Software Foundation <[email protected]>"]

0 commit comments

Comments
 (0)