This is an automated email from the ASF dual-hosted git repository.

absurdfarce pushed a commit to branch 4.x
in repository https://gitbox.apache.org/repos/asf/cassandra-java-driver.git


The following commit(s) were added to refs/heads/4.x by this push:
     new 52117be64 CASSJAVA-68 Improve DefaultCodecRegisry.CacheKey#hashCode() 
to eliminate Object[] allocation (found via profiler)
52117be64 is described below

commit 52117be640c5b16e37fe4da236fd58a1d7fcfab8
Author: janehe <siya...@uci.edu>
AuthorDate: Mon May 5 19:37:32 2025 -0700

    CASSJAVA-68 Improve DefaultCodecRegisry.CacheKey#hashCode() to eliminate 
Object[] allocation (found via profiler)
---
 .../driver/internal/core/type/codec/registry/DefaultCodecRegistry.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/core/src/main/java/com/datastax/oss/driver/internal/core/type/codec/registry/DefaultCodecRegistry.java
 
b/core/src/main/java/com/datastax/oss/driver/internal/core/type/codec/registry/DefaultCodecRegistry.java
index 4334f22b6..cc14740e1 100644
--- 
a/core/src/main/java/com/datastax/oss/driver/internal/core/type/codec/registry/DefaultCodecRegistry.java
+++ 
b/core/src/main/java/com/datastax/oss/driver/internal/core/type/codec/registry/DefaultCodecRegistry.java
@@ -162,7 +162,7 @@ public class DefaultCodecRegistry extends 
CachingCodecRegistry {
       // NOTE: inlined Objects.hash for performance reasons (avoid Object[] 
allocation
       // seen in profiler allocation traces)
       return ((31 + Objects.hashCode(cqlType)) * 31 + 
Objects.hashCode(javaType)) * 31
-              + Boolean.hashCode(isJavaCovariant);
+          + Boolean.hashCode(isJavaCovariant);
     }
   }
 }


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org
For additional commands, e-mail: commits-h...@cassandra.apache.org

Reply via email to