Tagged articles
35 articles
Page 1 of 1
Tech Freedom Circle
Tech Freedom Circle
Jan 27, 2026 · Interview Experience

Netease Interview: Write a BlockingQueue in 5 Minutes and Explain Design Patterns & Principles

The article breaks down a common Netease interview task—hand‑coding a BlockingQueue in five minutes—by explaining the underlying lock‑and‑condition mechanism, the relevant design patterns and principles, common pitfalls such as spurious wakeups, and provides a concise, 50‑line Java implementation with step‑by‑step commentary.

BlockingQueueDesign PatternsInterview Preparation
0 likes · 20 min read
Netease Interview: Write a BlockingQueue in 5 Minutes and Explain Design Patterns & Principles
Su San Talks Tech
Su San Talks Tech
Jan 5, 2026 · Backend Development

Master Java ThreadPool Interview Questions: Core Concepts, Parameters, and Best Practices

This guide compiles the most common Java thread‑pool interview questions, explains why and how thread pools are used, details the core parameters and execution flow of ThreadPoolExecutor, explores internal locks, usage patterns, monitoring, rejection policies, common pitfalls, and introduces the DynamicTp management framework.

BlockingQueueJUCJavaInterview
0 likes · 32 min read
Master Java ThreadPool Interview Questions: Core Concepts, Parameters, and Best Practices
Java Backend Full-Stack
Java Backend Full-Stack
Sep 10, 2025 · Backend Development

How a Misconfigured ThreadPool Caused Data Loss in Production – A Step‑by‑Step Troubleshooting Guide

The article recounts a real production incident where a recent deployment triggered loss of third‑party order data, traces the root cause to an improperly configured ThreadPoolExecutor that used a local memory queue, and walks through the systematic investigation and remediation steps.

BackendBlockingQueueProductionDebugging
0 likes · 6 min read
How a Misconfigured ThreadPool Caused Data Loss in Production – A Step‑by‑Step Troubleshooting Guide
Sanyou's Java Diary
Sanyou's Java Diary
Apr 24, 2025 · Fundamentals

Master Java’s Concurrent Containers: Deep Dive into ConcurrentHashMap and Queues

This article provides an in‑depth exploration of Java’s concurrent collection classes, covering the design and implementation of ConcurrentHashMap, ConcurrentLinkedQueue, and the seven blocking queue variants, complete with code analysis, performance considerations, and practical usage scenarios for high‑throughput multithreaded applications.

BlockingQueueConcurrentHashMapConcurrentLinkedQueue
0 likes · 50 min read
Master Java’s Concurrent Containers: Deep Dive into ConcurrentHashMap and Queues
Xuanwu Backend Tech Stack
Xuanwu Backend Tech Stack
Jan 9, 2025 · Fundamentals

Master Java Thread Communication: wait/notify, Locks, Conditions & BlockingQueue

This article explores Java's thread communication techniques—including the basic wait/notify mechanism, advanced Lock and Condition usage, and the thread‑safe BlockingQueue—providing detailed explanations, producer‑consumer examples, and additional concurrency utilities like CountDownLatch, illustrating how to coordinate threads efficiently in multithreaded applications.

BlockingQueueConditionCountDownLatch
0 likes · 18 min read
Master Java Thread Communication: wait/notify, Locks, Conditions & BlockingQueue
FunTester
FunTester
Dec 19, 2024 · Backend Development

Mastering Custom Thread Pools: Choosing the Right Queue in Java

This article walks through Java thread‑pool queue options—LinkedBlockingQueue, SynchronousQueue, LinkedBlockingDeque, and PriorityBlockingQueue—explaining their characteristics, demonstrating code examples, and showing how to build multi‑priority executors with concrete output analysis.

BlockingQueueLinkedBlockingDequePriorityQueue
0 likes · 12 min read
Mastering Custom Thread Pools: Choosing the Right Queue in Java
Architect Chen
Architect Chen
Feb 24, 2024 · Backend Development

Understanding Java Queues: Types, Blocking vs Non‑Blocking, and Practical Examples

This article explains what a queue is, classifies Java queue implementations—including blocking, non‑blocking, and double‑ended queues—provides detailed descriptions of each type, and offers code snippets and usage scenarios to help developers choose the right queue for their applications.

BlockingQueueConcurrentQueueDataStructure
0 likes · 6 min read
Understanding Java Queues: Types, Blocking vs Non‑Blocking, and Practical Examples
Full-Stack Internet Architecture
Full-Stack Internet Architecture
Dec 26, 2023 · Backend Development

Understanding Java Thread Pools: Creation, Execution Flow, Advantages, and Common Implementations

This article introduces Java thread pools, explaining their purpose, creation using ThreadPoolExecutor, execution flow, advantages such as resource reuse and management, common blocking queues, rejection policies, and provides multiple code examples of various pool types and a comprehensive monitoring example.

BlockingQueueExecutorServiceRejectionPolicy
0 likes · 11 min read
Understanding Java Thread Pools: Creation, Execution Flow, Advantages, and Common Implementations
Selected Java Interview Questions
Selected Java Interview Questions
Sep 7, 2023 · Backend Development

Understanding Blocking Queues in Java: Concepts, Types, and Core Methods

Blocking queues are thread‑safe data structures in Java that support blocking operations, enabling producer‑consumer coordination; this article explains their definition, differences from List/Set and regular queues, various implementations such as ArrayBlockingQueue and LinkedBlockingQueue, core methods like take and put, and bounded versus unbounded capacities.

BlockingQueueDataStructureProducerConsumer
0 likes · 11 min read
Understanding Blocking Queues in Java: Concepts, Types, and Core Methods
Selected Java Interview Questions
Selected Java Interview Questions
May 5, 2023 · Backend Development

High‑Frequency Java Concurrency Questions: AQS, Locks, Thread Pools, Blocking Queues, CountDownLatch, Semaphore, CopyOnWriteArrayList, and ConcurrentHashMap

This article explains the core concepts and common pitfalls of Java's AbstractQueuedSynchronizer (AQS) and its derived utilities such as ReentrantLock, ReentrantReadWriteLock, CountDownLatch, Semaphore, as well as the design and behavior of blocking queues, thread‑pool parameters, CopyOnWriteArrayList, and ConcurrentHashMap, providing code examples and practical guidance.

AQSBlockingQueueConcurrentHashMap
0 likes · 21 min read
High‑Frequency Java Concurrency Questions: AQS, Locks, Thread Pools, Blocking Queues, CountDownLatch, Semaphore, CopyOnWriteArrayList, and ConcurrentHashMap
Cognitive Technology Team
Cognitive Technology Team
Jun 26, 2022 · Backend Development

AsyncAppender OOM, Log Loss, and Blocking Issues – Configuration Guide

The article explains how AsyncAppender uses a BlockingQueue with a default size of 256, how an oversized queue can cause OOM, how the discardingThreshold can lead to loss of TRACE/DEBUG/INFO logs, and provides configuration tips such as adjusting queueSize, setting discardingThreshold to zero, or enabling neverBlock to avoid blocking.

AsyncAppenderBlockingQueueOOM
0 likes · 5 min read
AsyncAppender OOM, Log Loss, and Blocking Issues – Configuration Guide
IT Services Circle
IT Services Circle
Jun 2, 2022 · Fundamentals

Comprehensive Guide to Java Concurrency: Threads, Locks, Executors, and Synchronization Primitives

This article provides an in-depth overview of Java concurrency, covering thread creation, lifecycle, synchronization mechanisms such as locks, semaphores, barriers, atomic classes, concurrent collections, executor frameworks, fork/join, CompletableFuture, and various blocking queues, with code examples and implementation details.

BlockingQueueExecutorServiceLocks
0 likes · 52 min read
Comprehensive Guide to Java Concurrency: Threads, Locks, Executors, and Synchronization Primitives
Senior Brother's Insights
Senior Brother's Insights
Nov 1, 2021 · Backend Development

Mastering Java ThreadPoolExecutor: Design, Configuration, and Best Practices

This article explains why using ThreadPoolExecutor directly is preferred over Executors, details the thread pool's purpose, internal architecture, task handling flow, state management, API parameters, queue choices, rejection policies, sizing formulas, and provides practical code examples for custom thread pool implementations.

BlockingQueueCustomThreadFactoryExecutorService
0 likes · 22 min read
Mastering Java ThreadPoolExecutor: Design, Configuration, and Best Practices
Wukong Talks Architecture
Wukong Talks Architecture
Aug 1, 2021 · Backend Development

Types of Blocking Queues Used in Java Thread Pools

This article explains the different blocking queue implementations—ArrayBlockingQueue, LinkedBlockingQueue, SynchronousQueue, and PriorityBlockingQueue—used by Java thread pools, describing their structures, behavior, fairness settings, and performance characteristics for concurrent task execution.

ArrayBlockingQueueBackendBlockingQueue
0 likes · 6 min read
Types of Blocking Queues Used in Java Thread Pools
Programmer DD
Programmer DD
Jun 27, 2021 · Backend Development

Mastering Java Thread Pools: Core Pool, BlockingQueue, and Real-World Tuning

This article explains how Java thread pools work, clarifies common misconceptions about core thread creation, details the role of BlockingQueue, and provides practical guidelines for sizing core, max threads, and queue capacity based on concurrency and GC considerations.

BlockingQueueconcurrencyperformance
0 likes · 11 min read
Mastering Java Thread Pools: Core Pool, BlockingQueue, and Real-World Tuning
JavaEdge
JavaEdge
Apr 28, 2021 · Backend Development

How to Build a Blocking Queue with Two Condition Variables in Java

The article explains the role of Java's Condition interface as a monitor's condition variable, contrasts it with synchronized's wait/notify, and walks through using two Condition objects to implement a blocking queue that handles empty and full states, illustrating key await/signal patterns.

BlockingQueueConditionMonitor
0 likes · 3 min read
How to Build a Blocking Queue with Two Condition Variables in Java
Top Architect
Top Architect
Apr 27, 2021 · Backend Development

Common Misunderstandings in Thread Pool Configuration and How to Avoid Them

This article explains the inner workings of Java thread pools, clarifies common misconceptions about core pool sizing, BlockingQueue behavior, concurrency calculation, and runtime factors such as GC, providing practical guidance and code examples for correctly configuring thread pools in backend systems.

BlockingQueueJVMThreadPool
0 likes · 12 min read
Common Misunderstandings in Thread Pool Configuration and How to Avoid Them
Selected Java Interview Questions
Selected Java Interview Questions
Nov 24, 2020 · Backend Development

Understanding Java BlockingQueue: Concepts, Implementations, and a Custom Example

This article explains the fundamentals of queues and blocking queues, describes how Java's java.util.concurrent.BlockingQueue works, outlines its main methods and common implementations, and provides a complete custom BlockingQueue source code example for multithreaded producer‑consumer scenarios.

BlockingQueuebackend-developmentconcurrency
0 likes · 10 min read
Understanding Java BlockingQueue: Concepts, Implementations, and a Custom Example
Wukong Talks Architecture
Wukong Talks Architecture
Sep 9, 2020 · Fundamentals

Comprehensive Guide to Java Queue Family: 18 Types, Interfaces, and Implementations

This article provides an in‑depth, illustrated overview of Java's Queue hierarchy, covering 18 concrete queue classes, their inheritance relationships, core methods, blocking and non‑blocking variants, practical usage examples, and code snippets to help developers master queue-based data structures and concurrency utilities.

BlockingQueueData StructuresQueue
0 likes · 26 min read
Comprehensive Guide to Java Queue Family: 18 Types, Interfaces, and Implementations
macrozheng
macrozheng
Sep 3, 2020 · Backend Development

Mastering Java Concurrent Queues: When to Use Blocking, Non‑Blocking, and Transfer Queues

This article provides a comprehensive overview of Java's concurrent queue implementations, explaining the differences between blocking and non‑blocking queues, their underlying mechanisms, typical use‑cases, and code examples for classes such as ArrayBlockingQueue, LinkedBlockingQueue, PriorityBlockingQueue, DelayQueue, SynchronousQueue, LinkedTransferQueue, and LinkedBlockingDeque.

BlockingQueueJUCThreadPool
0 likes · 16 min read
Mastering Java Concurrent Queues: When to Use Blocking, Non‑Blocking, and Transfer Queues
Programmer DD
Programmer DD
Aug 29, 2020 · Backend Development

Mastering Java's Blocking Queues: When to Use Each JUC Queue

This article categorizes the tools in java.util.concurrent, explains the six major groups of JUC utilities, dives deep into the design and behavior of various blocking and non‑blocking queues, shows their core methods, typical use‑cases, and provides code examples for practical implementation.

BlockingQueueJUCThreadPool
0 likes · 15 min read
Mastering Java's Blocking Queues: When to Use Each JUC Queue
Big Data Technology & Architecture
Big Data Technology & Architecture
Dec 26, 2019 · Fundamentals

Java Thread Interview Questions and Answers with Code Examples

This article provides a comprehensive guide to common Java multithreading interview questions, covering thread ordering with join, lock vs synchronized, read‑write locks, wait vs sleep, blocking queues, producer‑consumer patterns, deadlock detection, thread dumps, thread states, and immutable objects, all illustrated with runnable code samples.

BlockingQueueLockThread
0 likes · 33 min read
Java Thread Interview Questions and Answers with Code Examples
Big Data Technology & Architecture
Big Data Technology & Architecture
Feb 16, 2019 · Fundamentals

Understanding LinkedBlockingQueue: Implementation, Principles, and Usage

This article provides a comprehensive overview of Java's LinkedBlockingQueue, covering its FIFO behavior, internal linked‑list structure, concurrency controls with separate put and take locks, detailed method implementations, and a multithreaded example demonstrating safe usage versus non‑thread‑safe alternatives.

BlockingQueueDataStructureThreadSafety
0 likes · 14 min read
Understanding LinkedBlockingQueue: Implementation, Principles, and Usage
Programmer DD
Programmer DD
Nov 9, 2018 · Backend Development

How Java’s Producer‑Consumer Problem Evolved: From Classic Locks to BlockingQueue and Thread Pools

This article walks through the classic Java producer‑consumer synchronization challenge, shows its traditional lock‑based solution, then demonstrates modern approaches using BlockingQueue and ExecutorService thread pools to simplify code, improve reliability, and avoid common pitfalls like deadlocks and thread starvation.

BlockingQueueProducer ConsumerThreadPool
0 likes · 15 min read
How Java’s Producer‑Consumer Problem Evolved: From Classic Locks to BlockingQueue and Thread Pools
Programmer DD
Programmer DD
Aug 17, 2018 · Fundamentals

How LinkedTransferQueue Works: The Smart Lock‑Free Queue Behind Java Concurrency

LinkedTransferQueue, introduced in JDK 7, combines the capacity of traditional BlockingQueues with the lock‑free behavior of SynchronousQueue, using a sophisticated node‑based algorithm that matches producers and consumers without locking the whole queue, offering high‑performance concurrent data transfer.

BlockingQueueLinkedTransferQueueconcurrency
0 likes · 16 min read
How LinkedTransferQueue Works: The Smart Lock‑Free Queue Behind Java Concurrency
Programmer DD
Programmer DD
Aug 13, 2018 · Backend Development

Deep Dive into Java’s SynchronousQueue: How It Works and Its Implementation

This article provides a comprehensive analysis of Java's SynchronousQueue, detailing its unique zero-capacity behavior, differences from other BlockingQueue implementations, internal structures such as TransferQueue and TransferStack, fair and non‑fair modes, and the core transfer algorithm with code examples.

BlockingQueueFairnessSynchronousQueue
0 likes · 19 min read
Deep Dive into Java’s SynchronousQueue: How It Works and Its Implementation
Programmer DD
Programmer DD
Aug 10, 2018 · Fundamentals

Mastering Java’s DelayQueue: How It Works and When to Use It

This article explains Java's DelayQueue—a blocking queue that releases elements only after their delay expires—covering its primary use cases, core components like ReentrantLock, Condition, and PriorityQueue, the Delayed interface, internal structure, and detailed implementations of the offer() and take() methods, including a discussion of potential memory‑leak pitfalls.

BlockingQueueDelayQueueDelayed Interface
0 likes · 7 min read
Mastering Java’s DelayQueue: How It Works and When to Use It
Programmer DD
Programmer DD
Jul 23, 2018 · Fundamentals

How Does Java’s ArrayBlockingQueue Work Under the Hood?

This article explains the internal design of Java’s ArrayBlockingQueue—a fixed‑size, FIFO blocking queue that uses a ReentrantLock and Condition objects to coordinate producers and consumers, detailing its fields, fairness option, and the concrete implementations of add, offer, poll, and take methods.

ArrayBlockingQueueBlockingQueueReentrantLock
0 likes · 10 min read
How Does Java’s ArrayBlockingQueue Work Under the Hood?
ZhiKe AI
ZhiKe AI
Feb 22, 2017 · Fundamentals

Understanding Java’s java.util.concurrent Package and Thread Pools

This article introduces the java.util.concurrent package introduced since JDK 5, explains the five thread‑pool creation methods, demonstrates how to use Runnable and Callable, details BlockingQueue operations and implementations, and summarizes best practices for building robust, high‑concurrency Java applications.

BlockingQueueconcurrencyjava
0 likes · 10 min read
Understanding Java’s java.util.concurrent Package and Thread Pools
Architect
Architect
Jun 14, 2016 · Backend Development

Custom Rejection Policies and Blocking Strategies for Java ThreadPoolExecutor

The article explains how to design a producer‑consumer model using Java's BlockingQueue, customize ThreadPoolExecutor's rejection policies—especially replacing the default AbortPolicy with a blocking strategy via a custom RejectedExecutionHandler—to safely handle full queues and improve concurrency control.

BlockingQueueProducer ConsumerRejectedExecutionHandler
0 likes · 5 min read
Custom Rejection Policies and Blocking Strategies for Java ThreadPoolExecutor