Skip to content

feat: trace sharding log#29

Open
a631807682 wants to merge 4 commits intogo-gorm:mainfrom
a631807682:feat_trace_sharding_sql
Open

feat: trace sharding log#29
a631807682 wants to merge 4 commits intogo-gorm:mainfrom
a631807682:feat_trace_sharding_sql

Conversation

@a631807682
Copy link
Member

  • Do only one thing
  • Non breaking API changes
  • Tested

What did this pull request do?

Even if we use the sharding model, the log will only print the original sql.
This feature is used to print the sql log of the actual execution.
This is similar to LastQuery, the difference is that in a model with an associated relationship, the log will be printed multiple times, while LastQuery records the last time.

User Case Description

@a631807682
Copy link
Member Author

Affects TestReadWriteSplitting, I'll try to fix it.

@a631807682
Copy link
Member Author

related to go-gorm/gorm#5304

@a631807682
Copy link
Member Author

It fixed in next gorm version

@jinzhu
Copy link
Member

jinzhu commented May 4, 2022

Hello @a631807682

Can you fix the file conflict?

Thank you.

@a631807682 a631807682 requested a review from jinzhu May 5, 2022 01:23
@marvinova marvinova requested review from marvinova and removed request for jinzhu and marvinova June 7, 2022 03:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants