[CDRIVER-731] Custom log handler cannot capture tracing on sasl_set_mutex callbacks Created: 01/Jul/15 Updated: 17/Aug/15 Resolved: 06/Jul/15 |
|
| Status: | Closed |
| Project: | C Driver |
| Component/s: | libmongoc |
| Affects Version/s: | 1.1.9, 1.2.0 |
| Fix Version/s: | 1.2-beta0 |
| Type: | Bug | Priority: | Minor - P4 |
| Reporter: | Jeremy Mikola | Assignee: | Jeremy Mikola |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Description |
|
Since c3c14f4 in the 1.1.x branch, entry/exit tracing apppears on SASL mutex callbacks that are initalized in MONGOC_ONCE_FUN() in mongoc-init.c. MONGOC_ONCE_FUN() is in turn called before any custom log handlers can be configured, which means output like the following ends up on stderr before a user of the driver can capture it elsewhere:
Looking at other code invoked by the init methods, I see that the SSL and SCRAM init functions don't use any tracing, nor are there any tests for trace output for these SASL mutex functions. Should we simply remove the traces, or is there a more elaborate solution to be considered? |
| Comments |
| Comment by Githook User [ 05/Aug/15 ] |
|
Author: {u'username': u'bjori', u'name': u'Hannes Magnusson', u'email': u'bjori@php.net'}Message: Merge branch 'master' into 1.2.0-dev
Conflicts: |
| Comment by Githook User [ 05/Aug/15 ] |
|
Author: {u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@emptysquare.net'}Message: Merge pull request #246 from jmikola/patch-1
|
| Comment by Githook User [ 05/Aug/15 ] |
|
Author: {u'username': u'jmikola', u'name': u'Jeremy Mikola', u'email': u'jmikola@gmail.com'}Message: These callbacks may be invoked before users have a chance to set their own log handler, so we should avoid tracing them (akin to the SSL and SCRAM init functions). |
| Comment by A. Jesse Jiryu Davis [ 06/Jul/15 ] |
|
jmikola you can resolve (but not close) this. |
| Comment by Githook User [ 06/Jul/15 ] |
|
Author: {u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@emptysquare.net'}Message: Merge pull request #246 from jmikola/patch-1
|
| Comment by Githook User [ 06/Jul/15 ] |
|
Author: {u'username': u'jmikola', u'name': u'Jeremy Mikola', u'email': u'jmikola@gmail.com'}Message: These callbacks may be invoked before users have a chance to set their own log handler, so we should avoid tracing them (akin to the SSL and SCRAM init functions). |
| Comment by Jeremy Mikola [ 01/Jul/15 ] |
|
PR for consideration: https://github.com/mongodb/mongo-c-driver/pull/246 |