Java Companion
Author

Java Companion

A highly professional Java public account

88
Articles
0
Likes
8
Views
0
Comments
Recent Articles

Latest from Java Companion

88 recent articles
Java Companion
Java Companion
Dec 29, 2025 · Backend Development

Avoid OOM: EasyExcel Best Practices for Exporting Millions of Rows (with Ready‑to‑Use Helper)

This article explains why exporting large Excel files with EasyExcel can cause OOM, CPU blockage, and slow responses, and demonstrates a pagination‑query plus batch‑write solution with reusable helper classes, performance benchmarks, dynamic page sizing, async export, multi‑sheet and template techniques, and a concise best‑practice checklist.

AsyncEasyExcelExcel Export
0 likes · 15 min read
Avoid OOM: EasyExcel Best Practices for Exporting Millions of Rows (with Ready‑to‑Use Helper)
Java Companion
Java Companion
Dec 28, 2025 · Backend Development

SpringBoot vs Nginx: Five Implementation Options vs One Directive – Which Is the True Anti‑Hotlinking Champion?

An in‑depth comparison of anti‑hotlinking techniques shows how Nginx can enforce protection with a single directive in milliseconds, while SpringBoot offers five approaches—Filter, Interceptor, Nginx config, signed URL, and hybrid strategy—each with different performance, security, and maintenance trade‑offs.

FilterInterceptorNginx
0 likes · 14 min read
SpringBoot vs Nginx: Five Implementation Options vs One Directive – Which Is the True Anti‑Hotlinking Champion?
Java Companion
Java Companion
Dec 27, 2025 · Cloud Native

Is Minio Turning Paid? 5 Free Distributed Storage Alternatives You Should Consider

The article explains Minio's recent licensing shift to AGPLv3, why it matters for SaaS and proprietary software vendors, and presents five open‑source distributed storage systems—SeaweedFS, Garage, Ceph, GlusterFS, and OpenStack Swift—detailing their licenses, deployment complexity, performance characteristics, and suitable use cases.

CephGlusterFSMinIO
0 likes · 21 min read
Is Minio Turning Paid? 5 Free Distributed Storage Alternatives You Should Consider
Java Companion
Java Companion
Dec 25, 2025 · Backend Development

Druid Crashed in Production? How to Optimize the Spring Boot Connection Pool

The article explains why Druid can fail in a live Spring Boot service and provides a comprehensive, step‑by‑step optimization guide covering core pool parameters, monitoring setup, security hardening, leak detection, dynamic tuning, and best‑practice pitfalls to achieve stable, high‑performance database connections.

Connection PoolDruidJava
0 likes · 12 min read
Druid Crashed in Production? How to Optimize the Spring Boot Connection Pool
Java Companion
Java Companion
Dec 23, 2025 · Backend Development

Three Spring Async Streaming APIs to Eliminate Timeout Issues

This article explains how to handle long‑running Spring endpoints by using three asynchronous streaming tools—ResponseBodyEmitter, SseEmitter, and StreamingResponseBody—showing their appropriate scenarios, configuration details, and complete code examples that keep the servlet thread free and avoid timeout problems.

AsyncResponseBodyEmitterSpring
0 likes · 9 min read
Three Spring Async Streaming APIs to Eliminate Timeout Issues
Java Companion
Java Companion
Dec 21, 2025 · Backend Development

Eliminate Messy Login Logic: Unified Multi‑Channel Authentication with Spring Boot Factory & Strategy Patterns

This article demonstrates how to replace tangled if‑else login code with a clean Spring Boot solution that combines the Factory and Strategy patterns, enabling easy addition of multiple authentication methods such as password, WeChat, SMS, and future providers while improving extensibility, readability, and testability.

AuthenticationFactory PatternJava
0 likes · 12 min read
Eliminate Messy Login Logic: Unified Multi‑Channel Authentication with Spring Boot Factory & Strategy Patterns
Java Companion
Java Companion
Dec 19, 2025 · Backend Development

Spring ApplicationEvent Listeners: A Lightweight Asynchronous Alternative to MQ

This article explains how Spring ApplicationEvent listeners can replace heavyweight message queues for high‑traffic scenarios, showing event class design, publishing and handling code, real‑world performance data, common pitfalls, and best‑practice guidelines for reliable asynchronous processing.

ApplicationEventEventListenerPerformance
0 likes · 9 min read
Spring ApplicationEvent Listeners: A Lightweight Asynchronous Alternative to MQ
Java Companion
Java Companion
Dec 18, 2025 · Backend Development

Building a High‑Performance Sensitive‑Word Filter with SpringBoot and DFA

This article explains why traditional string‑search and regex methods struggle with large keyword sets, introduces the deterministic finite automaton (DFA) approach using a Trie structure for linear‑time matching, provides full Java implementations, and discusses real‑world applications and advanced optimizations such as double‑array Tries, Aho‑Corasick, and sharding with Bloom filters.

DFAJavaSensitiveWordFilter
0 likes · 17 min read
Building a High‑Performance Sensitive‑Word Filter with SpringBoot and DFA