ScheduledExecutorService CPU Spikes to 100% Due to Thread Pool Bug
When using ScheduledExecutorService with a core pool size of 0, a JDK bug can cause CPU usage to spike to 100%. This occurs due to an infinite loop in the getTask method of ThreadPoolExecutor when keepAliveTime is set to 0 nanoseconds.
Problem Demonstration
public static void main(String[] args) {
ScheduledExecutorService executor = Executo ...
Posted on Thu, 04 Jun 2026 19:18:20 +0000 by skhale
Implementing Server Communication and Code Quality Practices with jQuery
Server Communication with jQuery
Modern web applications require seamless data exchange with servers without full page reloads. jQuery provides several methods to facilitate asynchronous HTTP requests.
Loading HTML Content
The .load() method retrieves HTML from a server URL and inserts it into selected elements:
$('#contentArea').load('page-con ...
Posted on Thu, 04 Jun 2026 18:19:32 +0000 by russia5
Performance Benchmark of C++ Input Methods for Competitive Programming
We evaluated the performance of various C++ input methods by processing 1,000,000 randomly generated integers (within INT32 range) on an Intel Core i5-12400 system running Windows 11.
Tested Input Methods
Standard scanf
Standard cin
Custom fast read
Bitwise optimized fast read
fread + bitwise optimized read
cin with sync disabled
cin with sync ...
Posted on Wed, 03 Jun 2026 17:50:53 +0000 by smellicus
Practical Techniques for Creating and Managing MySQL Indexes
Creating Indexes in MySQL
Sample Table Definition
DROP TABLE IF EXISTS tag_info;
CREATE TABLE tag_info (
rec_id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT COMMENT 'Record ID',
creator VARCHAR(64) DEFAULT '' COMMENT 'Creator',
create_ts DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT 'Creation time',
updater VARCHAR(64) DEFAULT ...
Posted on Sat, 30 May 2026 22:51:38 +0000 by frost
Implementing High-Performance Queues with Disruptor
Disruptor is a high-performence inter-thread messaging library developed by LMAX. It's widely used in projects like Log4j2 and Storm for its exceptional throughput characteristics.
Ring Buffer Architecture
Disruptor employs a ring buffer structure with several performence advantages:
Array-based storage: Uses fixed-size arrays instead of linke ...
Posted on Sat, 30 May 2026 19:12:15 +0000 by dustinnoe
Comparing Activator.CreateInstance and Type.InvokeMember for Dynamic Object Instantiation
Dynamic Instance Creation via Activator.CreateInstance
Activator.CreateInstance enables instantiation of types at runtime without compile-time knowledge. It belongs to System.Activator and suits scenarios such as plugin loading or assembly resolution where the concrete type is determined dynamically.
Benefits
Supports late-bound creation when ...
Posted on Mon, 25 May 2026 20:30:17 +0000 by keziah
Core Enhancements Introduced in Java JDK 17
Oracle releases new feature versions every six months, yet enterprise applications typically prioritize Long Term Support (LTS) builds. The current stable LTS options include versions 11 and 17. Modern frameworks dictate higher baseline requirements; for instance, Spring Framework 6.x mandates Java 17, and Spring Boot 3.0 enforces this as the m ...
Posted on Mon, 25 May 2026 17:04:06 +0000 by Goose87
Core Java Concepts and Implementation Details
Classpath Configuration
Classpath defines locations where the JVM searches for compiled classes, libraries, and resources during execution. It can be specified via:
Command line: java -cp app.jar;libs/* com.sample.MainApp
Environment variable: set CLASSPATH=app.jar;libs/*
Executable JAR manifest:
Class-Path: libs/dep1.jar libs/dep2.jar
Tomca ...
Posted on Fri, 22 May 2026 20:41:36 +0000 by (RL)Ian
MySQL CPU Performance Troubleshooting
Understanding CPU Utilization in MySQL
High CPU usage often indicates underlying performance issues. Analyzing resource consumption helps identify bottlenecks and optimize server operations. MySQL can cause CPU spikes due to inefficient queries, IO bottlenecks, or configuration issues.
CPU States Explained
$ top
top - 10:24:03 up 36 days, 28 mi ...
Posted on Thu, 21 May 2026 18:42:17 +0000 by sBForum
Exploring Python Dictionaries and Sets: Performance, Operations, and Ordering
Python's dictionaries and sets offer significant performance advantages over lists and tuples, particularly for operations like lookup, insertion, and deletion, which are typically performed in constant time complexity.
Sets are conceptually similar to dictionaries, with the key distinction being thier lack of key-value pairs. They represent co ...
Posted on Tue, 19 May 2026 05:53:26 +0000 by nthomthom