Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature: merge tianmu.log into mysqld.log, just like innodb does. #609

Closed
hustjieke opened this issue Sep 29, 2022 · 3 comments
Closed

feature: merge tianmu.log into mysqld.log, just like innodb does. #609

hustjieke opened this issue Sep 29, 2022 · 3 comments
Assignees
Labels
A-feature feature with good idea B-infrastructure infrastructure, connection, security, log etc. B-storage data type, data storage, insert,update,delete, transactions C-stonedb-5.7 associated with stonedb 5.7 C-stonedb-8.0 associated with stonedb 8.0 prio: low Low priority

Comments

@hustjieke
Copy link
Collaborator

Is your feature request related to a problem? Please describe.

Now Tianmu engine has its own log file, see next:

root@gry:/github/stonedb/build/install8# ls log/
mysqld.log  query.log  slow.log  tianmu.log  trace.log

The log infos in tianmu.log:

[2022-09-28 08:34:16.036979] [375094] [INFO] [kv_store.cpp:55] MSG: First init rocksdb, create default cloum family
[2022-09-28 08:34:16.067569] [375094] [INFO] [mapped_circular_buffer.h:75] MSG: created delayed buffer file TIANMU_INSERT_BUFFER with size 512MB
[2022-09-28 08:34:16.067615] [375094] [INFO] [mapped_circular_buffer.h:211] MSG: insert buffer address 0x7f9d77fb0000
[2022-09-28 08:34:16.067721] [375094] [INFO] [memory_handling_policy.cpp:94] MSG: Adjusted Main Heap size = 16832790528
[2022-09-28 08:34:16.067749] [375094] [INFO] [memory_handling_policy.cpp:95] MSG: Adjusted LT Heap size = 0
[2022-09-28 08:34:16.106856] [375094] [INFO] [engine.cpp:930] MSG: Cachefolder cache does not exist. Trying to create it.
[2022-09-28 08:34:16.107099] [375094] [INFO] [engine.cpp:235] MSG: Tianmu engine started.
[2022-09-28 08:34:16.107157] [375094] [INFO] [engine.cpp:236] MSG: Tianmu data directories:
[2022-09-28 08:34:16.107166] [375094] [INFO] [engine.cpp:237] MSG:   {
[2022-09-28 08:34:16.107177] [375094] [INFO] [engine.cpp:239] MSG:     default
[2022-09-28 08:34:16.107185] [375094] [INFO] [engine.cpp:246] MSG:   }
[2022-09-28 08:34:16.107195] [375094] [INFO] [engine.cpp:248] MSG: Tianmu thread pool for background load, size = 16
[2022-09-28 08:34:16.107204] [375094] [INFO] [engine.cpp:250] MSG: Tianmu thread pool for load, size = 32
[2022-09-28 08:34:16.107213] [375094] [INFO] [engine.cpp:251] MSG: Tianmu thread pool for query, size = 32
[2022-09-28 08:34:16.107565] [375094] [INFO] [tianmu_handler_com.cpp:227] MSG:  
-----------------------------------------------------------------------------------------------------------
    ######  ########  #######  ##     ## ######## ######   ######   
   ##    ##    ##    ##     ## ####   ## ##       ##    ## ##    ## 
   ##          ##    ##     ## ## ##  ## ##       ##    ## ##    ## 
    ######     ##    ##     ## ##  ## ## ######   ##    ## ######## 
         ##    ##    ##     ## ##   #### ##       ##    ## ##    ##  
   ##    ##    ##    ##     ## ##    ### ##       ##    ## ##    ##    
    ######     ##     #######  ##     ## ######## ######   ######    
-----------------------------------------------------------------------------------------------------------

Describe the solution you'd like

We should merge Tianmu log infos into mysqld.log, like innodb does:

2022-09-28T08:35:18.761967Z 0 [System] [MY-010116] [Server] /github/stonedb/build/install8/bin/mysqld (mysqld 8.0.30-debug) starting as process 376652
2022-09-28T08:35:18.765872Z 0 [Warning] [MY-010339] [Server] Using pre 5.5 semantics to load error messages from /github/stonedb/build/install8/share/english/. If this is not intended, refer to the documentation for valid usage of --lc-messages-dir and --language parameters.
2022-09-28T08:35:18.895935Z 0 [Warning] [MY-013267] [InnoDB] The setting INNODB_UNDO_TABLESPACES is deprecated and is no longer used.  InnoDB always creates 2 undo tablespaces to start with. If you need more, please use CREATE UNDO TABLESPACE.
2022-09-28T08:35:18.896063Z 0 [Warning] [MY-013907] [InnoDB] Deprecated configuration parameters innodb_log_file_size and/or innodb_log_files_in_group have been used to compute innodb_redo_log_capacity=2147483648. Please use innodb_redo_log_capacity instead.
2022-09-28T08:35:18.904708Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2022-09-28T08:35:20.268891Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.

Describe alternatives you've considered

Additional context

@hustjieke hustjieke added A-feature feature with good idea C-stonedb-5.7 associated with stonedb 5.7 C-stonedb-8.0 associated with stonedb 8.0 labels Sep 29, 2022
@hustjieke hustjieke added this to the stonedb_8.0_v1.0.0 milestone Sep 29, 2022
@hustjieke hustjieke self-assigned this Sep 29, 2022
@hustjieke
Copy link
Collaborator Author

After merge tianmu.log into mysqld.log, port this change into stonedb-5.7-dev branch.

@hustjieke
Copy link
Collaborator Author

  1. First we should remove hard code on tianmu_handler_com.cpp.
214     std::string log_file = mysql_home_ptr;
215     log_setup(log_file + "/log/tianmu.log");
216     rc_control_.addOutput(new system::FileOut(log_file + "/log/trace.log"));
217     rc_querylog_.addOutput(new system::FileOut(log_file + "/log/query.log"));

hustjieke added a commit to hustjieke/stonedb-8.0.30-upgrade that referenced this issue Nov 9, 2022
…/ to $mysqlhome/data/ stoneatom#609

[summary]
1. "log/tianmu.log" --> "tianmu_engine.log"
2. "trace.log" --> "tianmu_trace.log"
3. "query.log" --> "tianmu_query.log"
hustjieke added a commit to hustjieke/stonedb-8.0.30-upgrade that referenced this issue Nov 10, 2022
…toneatom#609

[summary]
1. "log/tianmu.log" --> "tianmu_engine.log"
2. "trace.log" --> "tianmu_trace.log"
3. "query.log" --> "tianmu_query.log"
hustjieke added a commit to hustjieke/stonedb-8.0.30-upgrade that referenced this issue Nov 11, 2022
hustjieke added a commit to hustjieke/stonedb-8.0.30-upgrade that referenced this issue Nov 11, 2022
mergify bot pushed a commit that referenced this issue Nov 14, 2022
…/ to $mysqlhome/data/ #609

[summary]
1. "log/tianmu.log" --> "tianmu_engine.log"
2. "trace.log" --> "tianmu_trace.log"
3. "query.log" --> "tianmu_query.log"
mergify bot pushed a commit that referenced this issue Nov 14, 2022
mergify bot pushed a commit that referenced this issue Nov 14, 2022
…609

[summary]
1. "log/tianmu.log" --> "tianmu_engine.log"
2. "trace.log" --> "tianmu_trace.log"
3. "query.log" --> "tianmu_query.log"
mergify bot pushed a commit that referenced this issue Nov 14, 2022
@hustjieke hustjieke modified the milestone: stonedb_5.7_v1.0.2 Nov 30, 2022
@hustjieke hustjieke added the prio: low Low priority label Nov 30, 2022
@wisehead wisehead added the B-infrastructure infrastructure, connection, security, log etc. label Jan 9, 2023
@hustjieke hustjieke moved this from In Progress to Todo in StoneDB for MySQL 5.7 Jan 30, 2023
@hustjieke hustjieke added the B-storage data type, data storage, insert,update,delete, transactions label Jan 30, 2023
@hustjieke
Copy link
Collaborator Author

This issue no longer use anymore, close it now.
If we continue working on it, a new issue will be better!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-feature feature with good idea B-infrastructure infrastructure, connection, security, log etc. B-storage data type, data storage, insert,update,delete, transactions C-stonedb-5.7 associated with stonedb 5.7 C-stonedb-8.0 associated with stonedb 8.0 prio: low Low priority
Projects
Development

No branches or pull requests

3 participants