[JAVA-505] Performance regression due to increased memory allocation Created: 13/Jan/12 Updated: 18/Jun/12 Resolved: 30/Jan/12 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | None |
| Affects Version/s: | 2.7.2 |
| Fix Version/s: | 2.7.3 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Antoine Girbal | Assignee: | Jeffrey Yemin |
| Resolution: | Done | Votes: | 1 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||
| Description |
|
use MongoPerfTest.java to reproduce antoine@agAntec:~/tengen/support$ java -cp "mongo_2-6-5.jar:." MongoPerfTest inserts are marginally slower (about 5%) but queries are 37.5% slower. commit 66c54120c56f9329b392264ec5efba0b2a292217
|
| Comments |
| Comment by auto [ 20/Jan/12 ] |
|
Author: {u'login': u'jyemin', u'name': u'Jeff Yemin', u'email': u'jeff.yemin@10gen.com'}Message: |
| Comment by auto [ 20/Jan/12 ] |
|
Author: {u'login': u'jyemin', u'name': u'Jeff Yemin', u'email': u'jeff.yemin@10gen.com'}Message: |
| Comment by Jeffrey Yemin [ 19/Jan/12 ] |
|
To keep things dead simple for a patch release, I'm not going to add any pooling of custom decoders just yet. |
| Comment by Jeffrey Yemin [ 19/Jan/12 ] |
|
The previous behavior was to cache an instance of the decoder with each instance of DBPort (which are themselves cached in the connection pool). It can't be a singleton because DefaultDBDecoder is not thread-safe. |
| Comment by Leo Kim [ 19/Jan/12 ] |
|
Can the DefaultDBDecoder.FACTORY return a DefaultDBDecoder singleton? |
| Comment by Antoine Girbal [ 19/Jan/12 ] |
|
right ideally if using the default decoder, there should be 1 global. |
| Comment by Jeffrey Yemin [ 19/Jan/12 ] |
|
Commit 66c54120c56f9329b392264ec5efba0b2a292217 (fix for But after rolling back this change, there's a second half of the problem, in commit 673beed75fc347054328afaa2841d43410ee0f28. In the commit, the driver is creating many more decoders. Instead of creating one per DBPort, it's creating one per call/say. This is a lot more work for the garbage collector. This commit will also have to be rolled back or modified. |
| Comment by auto [ 17/Jan/12 ] |
|
Author: {u'login': u'bwmcadams', u'name': u'Brendan W. McAdams', u'email': u'brendan@10gen.com'}Message: |
| Comment by auto [ 17/Jan/12 ] |
|
Author: {u'login': u'bwmcadams', u'name': u'Brendan W. McAdams', u'email': u'brendan@10gen.com'}Message: |