Comments (6)
Hi,
It seems that this has already been fixed into the master (commit 8d74338 PR #125), at least for the equals() part.
Is there a point returning 0 on hashCode() when con is null?
Regards
from pgjdbc.
Not sure right now about the 0 if con is null. It's just a safety pattern I am used to type automatically ;)
from pgjdbc.
Oh, and yes, I saw the equals()-Part in the Master, however the hashCode() part is also important.
And I don't like branching from an unreleased version, and we are currently using my patched version in production.
from pgjdbc.
Unless the zero-if-null thing is useful for a case that might happen and for which we can write a test, I think the issue is fixed.
Letting hashCode() fall into method.invoke(con, args) will do the job as two proxies with the same underlying connection will return the same consistent value.
The only remaining question is: should 8d74338 be backported to older branches?
from pgjdbc.
Yes, it probably should be backported.
Dave Cramer
On 1 July 2014 06:48, Alexis Meneses [email protected] wrote:
Unless the zero-if-null thing is useful for a case that might happen
and for which we can write a test, I think the issue is fixed.Letting hashCode() fall into method.invoke(con, args) will do the job as
two proxies with the same underlying connection will return the same
consistent value.The only remaining question is: should 8d74338
8d74338
be backported to older branches?—
Reply to this email directly or view it on GitHub
#162 (comment).
from pgjdbc.
historic, if this still exists in the latest driver please advise
from pgjdbc.
Related Issues (20)
- Prevent fetchFieldMetaData() from being run when unnecessary. HOT 11
- setMaxRows doesn't limit rows HOT 3
- Move PGStream.receiveInteger2 and receiveInteger4 to VisibleBufferedInputStream, and remove int2Buf, int4Buf HOT 1
- Reuse buffers and reduce allocations in GSSInputStream
- Connection.rollback should cancel in-flight queries HOT 1
- Connection.abort should cancel in-flight queries HOT 3
- Test against PostgreSQL head. HOT 2
- DDL batch commit, pg_stat_activity displays execution one by one, not batch execution HOT 4
- Multiple BEGIN ATOMIC ... END; not supported for prepared statement. HOT 5
- Feature: please support getObject(int, byte[].class) for bytea HOT 3
- batched updates + reWriteBatchedInserts + transactions does not return row count of affected rows HOT 10
- ResultSetMetaData.getColumnType() java.sql.Types.BOOLEAN field misidentified as BIT HOT 1
- 42.7.3 GitHub release jar is different from the jar on maven HOT 1
- NamedParameterJdbcTemplate execute complex Insert Query HOT 1
- feature request: Add support for native java unix sockets without needing JNI
- Postgres explain plan is not correctly optimezed if the data is a "double" but the collumn is a "numeric" HOT 10
- ResultSet.getObject throws exeception for 'Infinity'::numeric values HOT 4
- ARRAY() function return result problem HOT 2
- capitalization matters for PGInterval HOT 1
- PgStatement.executeWithFlags(sql, QueryMode.Simple) does not execute in Simple mode
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pgjdbc.