Skip to content

[3.x] Fix always call connection logQuery function to broadcast QueryExecuted event #2069

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

Merged
merged 2 commits into from
Jul 22, 2020

Conversation

StevePorter92
Copy link
Contributor

fixes #2068

Queries will only be added to the in memory connection query log if
the query log is enabled using DB::connection('mongodb')->enableQueryLog();

fixes mongodb#2068

Queries *will only* be added to the in memory connection query log if
the query log is enabled using `DB::connection('mongodb')->enableQueryLog();`
@StevePorter92 StevePorter92 changed the title always log queries always call connection logQuery function to broadcast QueryExecuted event Jul 22, 2020
@codecov-commenter
Copy link

codecov-commenter commented Jul 22, 2020

Codecov Report

Merging #2069 into master will decrease coverage by 0.00%.
The diff coverage is 81.81%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #2069      +/-   ##
============================================
- Coverage     86.90%   86.89%   -0.01%     
+ Complexity      672      671       -1     
============================================
  Files            31       31              
  Lines          1558     1557       -1     
============================================
- Hits           1354     1353       -1     
  Misses          204      204              
Impacted Files Coverage Δ Complexity Δ
src/Jenssegers/Mongodb/Collection.php 88.88% <81.81%> (-0.59%) 5.00 <0.00> (-1.00)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0bf3f03...baa7332. Read the comment docs.

@divine divine merged commit 08f4995 into mongodb:master Jul 22, 2020
@divine
Copy link
Contributor

divine commented Jul 22, 2020

Thanks!

@divine divine changed the title always call connection logQuery function to broadcast QueryExecuted event [3.x] Fix always call connection logQuery function to broadcast QueryExecuted event Jul 23, 2020
mnphpexpert added a commit to mnphpexpert/laravel-mongodb that referenced this pull request Sep 2, 2024
always call connection logQuery function to broadcast QueryExecuted event
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Illuminate\Database\Events\QueryExecuted event only being fired when query log enabled
4 participants