Tag

JMH

0 views collected around this technical thread.

Architect's Guide
Architect's Guide
Mar 16, 2025 · Backend Development

Understanding Java Object Pooling with Commons Pool 2 and HikariCP: Concepts, Configuration, and Performance Testing

This article explains Java object pooling using Commons Pool 2 and HikariCP, covering their core classes, configuration parameters, practical examples with Redis and JDBC, interview questions, and JMH performance benchmarks that demonstrate significant throughput improvements.

Commons Pool 2Database Connection PoolHikariCP
0 likes · 14 min read
Understanding Java Object Pooling with Commons Pool 2 and HikariCP: Concepts, Configuration, and Performance Testing
Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Jan 3, 2025 · Backend Development

Which Java String Concatenation Method Is Fastest? JMH Benchmarks Reveal Surprising Results

This article examines eight common Java string concatenation techniques, benchmarks them with JMH, presents the performance results—including a clear ranking where the '+' operator outperforms others—and provides a downloadable Spring Boot 3 case collection for deeper learning.

JMHJavaSpring Boot
0 likes · 9 min read
Which Java String Concatenation Method Is Fastest? JMH Benchmarks Reveal Surprising Results
Java Architect Essentials
Java Architect Essentials
Dec 25, 2024 · Backend Development

Understanding Java Connection Pools: Commons Pool 2, Jedis, and HikariCP Performance

This article explains the principles of object pooling in Java, introduces the Commons Pool 2 library and its use in Redis client Jedis, compares pool and non‑pool performance with JMH benchmarks, and details the fast HikariCP database connection pool along with configuration tips and interview questions.

Commons PoolConnection PoolHikariCP
0 likes · 15 min read
Understanding Java Connection Pools: Commons Pool 2, Jedis, and HikariCP Performance
Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Dec 5, 2024 · Fundamentals

Unlock Java’s Functional Power: Real‑World Examples and Performance Insights

This article explains functional programming concepts in Java, including immutability, stateless functions, higher‑order functions, closures, currying, recursion, lazy evaluation, and referential transparency, and demonstrates each with practical code samples and JMH performance benchmarks.

Functional ProgrammingHigher-order FunctionsJMH
0 likes · 13 min read
Unlock Java’s Functional Power: Real‑World Examples and Performance Insights
Spring Full-Stack Practical Cases
Spring Full-Stack Practical Cases
Jun 25, 2024 · Backend Development

Master Java Performance Testing with JMH: From Setup to Advanced Benchmarks

This article introduces JMH, explains why it outperforms simple loops or other tools, and provides step‑by‑step Maven setup, benchmark creation, execution, and advanced annotations such as @Warmup, @Fork, @Setup, Blackhole usage, and SpringBoot integration for accurate Java micro‑benchmarking.

BenchmarkingJMHJava
0 likes · 12 min read
Master Java Performance Testing with JMH: From Setup to Advanced Benchmarks
FunTester
FunTester
Apr 15, 2024 · Fundamentals

Using JMH to Benchmark GUID Generation Strategies in Java

This article introduces JMH, explains its key features, and presents microbenchmark results comparing thread‑exclusive, thread‑shared, Snowflake, UUID, and Snowflake‑algorithm GUID generation methods under various thread counts, accompanied by the full Java test code.

BenchmarkingGUIDJMH
0 likes · 8 min read
Using JMH to Benchmark GUID Generation Strategies in Java
政采云技术
政采云技术
Jan 25, 2024 · Fundamentals

Java JDK 12‑17 New Features and Enhancements Overview

This article provides a comprehensive overview of the major language and runtime enhancements introduced in JDK 12 through JDK 17, covering switch expressions, micro‑benchmarking with JMH, class‑data sharing, garbage‑collector improvements, new String methods, hidden and sealed classes, records, and unified asynchronous logging, all illustrated with code examples.

Garbage CollectionJDKJMH
0 likes · 23 min read
Java JDK 12‑17 New Features and Enhancements Overview
Rare Earth Juejin Tech Community
Rare Earth Juejin Tech Community
Nov 18, 2023 · Backend Development

Why List.sort() Is Faster Than Stream.sorted() in Java: Benchmarks and Analysis

This article investigates the performance difference between Java's List.sort() and Stream.sorted(), providing simple demos, JMH benchmark results, and analysis of underlying overheads to explain why the native list sorting is generally faster than sorting via streams.

JMHJavaStream.sorted
0 likes · 8 min read
Why List.sort() Is Faster Than Stream.sorted() in Java: Benchmarks and Analysis
Java Architect Essentials
Java Architect Essentials
Aug 29, 2023 · Fundamentals

Why List.sort() Is Faster Than Stream.sorted() in Java: Benchmarks and Analysis

This article examines the performance difference between Java's List.sort() and Stream.sorted() by presenting simple demos, discussing JIT warm‑up effects, and using JMH benchmarks to show that native list sorting generally outperforms the stream‑based approach.

JMHJavaStream.sorted
0 likes · 9 min read
Why List.sort() Is Faster Than Stream.sorted() in Java: Benchmarks and Analysis
macrozheng
macrozheng
Aug 24, 2023 · Backend Development

Why Reusing a Single Jackson ObjectMapper Boosts JSON Performance 10×

This article explains how repeatedly creating Jackson ObjectMapper instances hurts performance, demonstrates a JMH benchmark comparing new, singleton, and ThreadLocal ObjectMapper usages, and concludes that a single globally shared ObjectMapper can achieve up to ten times faster JSON parsing.

JMHJacksonJava
0 likes · 8 min read
Why Reusing a Single Jackson ObjectMapper Boosts JSON Performance 10×
Architect's Tech Stack
Architect's Tech Stack
Aug 22, 2023 · Backend Development

Why List.sort() Is Faster Than Stream.sorted() in Java: Benchmarks and Analysis

An in‑depth comparison shows that Java's native List.sort() outperforms Stream.sorted() due to lower overhead, demonstrated through simple demos, JMH micro‑benchmarks across various collection sizes, and analysis of stream processing costs, concluding that the performance gap, while measurable, is often negligible in typical use.

JMHJavaStream.sorted
0 likes · 11 min read
Why List.sort() Is Faster Than Stream.sorted() in Java: Benchmarks and Analysis
Top Architect
Top Architect
Aug 13, 2023 · Backend Development

Why List.sort() Is Faster Than Stream.sorted() in Java

This article investigates the performance difference between Java's native List.sort() method and the Stream.sorted() approach, provides simple demos, explains JIT warm‑up effects, and presents JMH benchmark results that show List.sort() consistently outperforms Stream.sorted() for typical collection sizes.

JMHJavaStream.sorted
0 likes · 11 min read
Why List.sort() Is Faster Than Stream.sorted() in Java
Java Architect Essentials
Java Architect Essentials
Jun 11, 2023 · Backend Development

Understanding Java Object Pooling: Commons Pool 2, Jedis Integration, and HikariCP Performance

This article explains Java object pooling concepts, introduces the Commons Pool 2 library, demonstrates its use with Redis via Jedis, compares performance with JMH benchmarks, and discusses the high‑performance HikariCP database connection pool, including configuration tips and common interview questions.

Connection PoolHikariCPJMH
0 likes · 15 min read
Understanding Java Object Pooling: Commons Pool 2, Jedis Integration, and HikariCP Performance
Selected Java Interview Questions
Selected Java Interview Questions
Jun 2, 2023 · Backend Development

Java Connection Pooling: Commons Pool 2, Jedis, and HikariCP

This article explains the principles of object pooling in Java, introduces the Commons Pool 2 library, demonstrates its use with Redis client Jedis, compares performance with JMH benchmarks, and discusses the high‑performance HikariCP database connection pool, including configuration tips and interview questions.

Commons PoolConnection PoolHikariCP
0 likes · 14 min read
Java Connection Pooling: Commons Pool 2, Jedis, and HikariCP
Architect's Tech Stack
Architect's Tech Stack
May 24, 2023 · Backend Development

Understanding Java Connection Pools: Commons Pool 2, Jedis, and HikariCP

This article explains the principles of object pooling in Java, introduces the Commons Pool 2 library, demonstrates its use with Redis client Jedis, compares performance with JMH benchmarks, and details the configuration and advantages of the high‑performance HikariCP database connection pool.

Commons PoolConnection PoolHikariCP
0 likes · 17 min read
Understanding Java Connection Pools: Commons Pool 2, Jedis, and HikariCP
Top Architect
Top Architect
Apr 19, 2023 · Backend Development

Using JMH for Java Microbenchmarking: Demo Project, Annotations and Result Analysis

This article explains why simple timing is unreliable in Java due to JIT compilation, introduces the official JMH tool for microbenchmarking, outlines best‑practice tips, demonstrates how to set up a Maven project, write benchmark code, run tests, interpret results, and details each JMH annotation.

AnnotationsBenchmarkingJMH
0 likes · 14 min read
Using JMH for Java Microbenchmarking: Demo Project, Annotations and Result Analysis
FunTester
FunTester
Apr 19, 2023 · Backend Development

Performance Comparison of Groovy 'as' Keyword and Java Conversion Methods Using JMH

This article benchmarks the Groovy 'as' type‑conversion keyword against native Java conversion methods for String‑to‑double, double‑to‑String, and double‑to‑int operations using JMH, revealing that Java's built‑in approaches consistently outperform Groovy's 'as' keyword across various test cases.

GroovyJMHJava
0 likes · 8 min read
Performance Comparison of Groovy 'as' Keyword and Java Conversion Methods Using JMH
Java Architect Essentials
Java Architect Essentials
Feb 21, 2023 · Backend Development

Performance Benchmark of Common Java JSON Libraries Using JMH

This article benchmarks the serialization and deserialization performance of four popular Java JSON libraries—Gson, Fastjson, Jackson, and Json‑lib—using JMH, analyzes the results across different operation counts, and provides guidance on selecting the most suitable library for high‑performance applications.

GsonJMHJSON
0 likes · 11 min read
Performance Benchmark of Common Java JSON Libraries Using JMH