darkgoon83 / log4jdbc-remix

Automatically exported from code.google.com/p/log4jdbc-remix
0 stars 0 forks source link

ResultSet#getStatement() should not return new StatementSpy and ConnectionSpy on each invocation #18

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
This is pretty important issue for the following reasons:

1). Connection number tracking is broken:
    private final Integer connectionNumber @ ConnectionSpy is assigned on each new instance creation
2). HashMap usage is broken:
    equals() and hashCode() are different for each new StatementSpy object. This breaks statement caching in hashmaps. This leads to upredictable behavior for certain tools (like hibernate 4.2.0 -> HHH000387: ResultSet's statement was not registered).

Plz apply patch in trunk and 0.2.7 branch (if possible).

Thanks in advance.

Original issue reported on code.google.com by Oleh.Fai...@gmail.com on 26 Apr 2013 at 8:47

Attachments:

GoogleCodeExporter commented 8 years ago
Should be fixed on trunk after a resync with log4jdbc. Please let me know.

Original comment by tim.azzo...@gmail.com on 28 Apr 2013 at 1:12

GoogleCodeExporter commented 8 years ago

Original comment by tim.azzo...@gmail.com on 28 Apr 2013 at 1:14

GoogleCodeExporter commented 8 years ago
It works. Thanks

Original comment by Oleh.Fai...@gmail.com on 28 Apr 2013 at 6:43

GoogleCodeExporter commented 8 years ago

Original comment by tim.azzo...@gmail.com on 30 Apr 2013 at 8:01