<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>JavaScript on miti99</title><link>https://miti99.com/en/tags/javascript/</link><description>Recent content in JavaScript on miti99</description><generator>Hugo</generator><language>en</language><lastBuildDate>Mon, 16 Nov 2026 17:39:19 +0700</lastBuildDate><atom:link href="https://miti99.com/en/tags/javascript/index.xml" rel="self" type="application/rss+xml"/><item><title>Newsletter #68</title><link>https://miti99.com/en/post/2025/12/11/</link><pubDate>Thu, 11 Dec 2025 00:00:00 +0700</pubDate><guid>https://miti99.com/en/post/2025/12/11/</guid><description>&lt;p&gt;&lt;em&gt;Enjoy Newsletter #68. &lt;del&gt;This post was created using &lt;a href="https://github.com/anthropics/claude-code" rel="noopener noreferrer"&gt;Claude Code&lt;/a&gt;, &lt;a href="https://github.com/musistudio/claude-code-router" rel="noopener noreferrer"&gt;Claude Code Router&lt;/a&gt;, &lt;a href="https://platform.iflow.cn" rel="noopener noreferrer"&gt;iFlow Open Platform&lt;/a&gt; &amp;amp; GLM-4.6 (For this post I configured CCR to use multiple models on iFlow Platform)&lt;/del&gt;&lt;/em&gt;&lt;/p&gt;
&lt;h2 id="conscious-debugging-10-effective-strategies-that-actually-work-"&gt;&lt;a href="https://thetshaped.dev/p/conscious-debugging-10-effective-debugging-strategies-debug-like-pro" rel="noopener noreferrer"&gt;Conscious Debugging: 10 Effective Strategies That Actually Work 🐛&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Petar Ivanov argues that debugging isn&amp;rsquo;t a matter of luck, but a trainable skill—and mastering it saves time, effort, money, and stress. The article organizes 10 debugging strategies into three groups. The first group lays the groundwork: reproduce the bug consistently with concrete steps, shorten the reproduction cycle so you can test more hypotheses quickly, and gather full context from logs, session recordings, or user reports before diving into the code. In microservice architectures, sketching the end-to-end request flow across services gives you a clear mental map of the system.&lt;/p&gt;
&lt;p&gt;The second group covers active debugging techniques: narrow down the culprit via binary search (commenting out half the suspected code path to see whether the bug persists), use a real debugger to set breakpoints and inspect variables, explain the code line by line to a &amp;ldquo;rubber duck&amp;rdquo; or a teammate, and work like a scientist—form a hypothesis, test it, observe the outcome, fix, and verify. When you hit a wall, write down everything you&amp;rsquo;ve tried so far, take an intentional break, and use AI smartly by feeding it full context—AI isn&amp;rsquo;t magic, but it&amp;rsquo;s a valuable assistant when given complete information.&lt;/p&gt;
&lt;h2 id="the-fate-of"&gt;&lt;a href="https://nolanlawson.com/2025/11/16/the-fate-of-small-open-source/" rel="noopener noreferrer"&gt;The fate of &amp;ldquo;small&amp;rdquo; open source&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Nolan Lawson looks back at &lt;code&gt;blob-util&lt;/code&gt;, a small npm library he wrote roughly 10 years ago that still gets over 5 million weekly downloads. Now that around 80% of developers use AI in their workflow, tiny utilities like this can be generated on demand by an LLM—he asked Claude to write a &lt;code&gt;Blob&lt;/code&gt;-to-&lt;code&gt;ArrayBuffer&lt;/code&gt; helper and got code nearly identical to his own. Many see this as pure progress: fewer dependencies and less performance, maintenance, and supply-chain risk. Yet Lawson argues something valuable is being lost: &lt;code&gt;blob-util&lt;/code&gt; was written in the spirit of a teacher, complete with documentation that helped developers understand how to work effectively with binary data in JavaScript. When we prioritize instant answers over learning and understanding, the motivation to publish small libraries and explain underlying concepts fades too.&lt;/p&gt;
&lt;p&gt;His conclusion: the era of small, low-complexity open-source packages is over—a decline that started as Node.js and browsers built more features into the platform, with LLMs serving as the final nail in the coffin. Even so, open source still has a bright future in larger, more ambitious projects or niche domains outside an LLM&amp;rsquo;s training distribution, such as his memory-leak hunter &lt;code&gt;fuite&lt;/code&gt; or Dominic Gannaway&amp;rsquo;s Ripple.js framework—work that demands original research and creative engineering.&lt;/p&gt;
&lt;h2 id="programming-languages-in-the-age-of-ai-agents"&gt;&lt;a href="https://alexn.org/blog/2025/11/16/programming-languages-in-the-age-of-ai-agents/" rel="noopener noreferrer"&gt;Programming Languages in the Age of AI Agents&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Alexandru Nedelcu asks: when AI agents write our code, does programming language choice still matter, or will everyone converge on a handful of mainstream languages simply because AI has the most training data for them? He acknowledges the feedback loop is real—Python is popular, so AI writes good Python, making Python even more popular—but offers two reasons for optimism. First, compilers with expressive static type systems (Scala, Haskell, Rust) give AI agents faster, tighter feedback than unit tests alone, helping them iterate toward a working solution and curbing hallucinations. For example, AI can successfully write Scala 3 macros despite scarce public training examples by iteratively fixing compiler errors.&lt;/p&gt;
&lt;p&gt;Second, humans still have to review and understand AI-generated code, because merely running a program and eyeballing the output is far too shallow a check. Nedelcu warns of &amp;ldquo;comprehension debt&amp;rdquo;—when no one on the team understands how the system actually works anymore—and cites Peter Naur&amp;rsquo;s view that programming is fundamentally about building a shared human &amp;ldquo;theory&amp;rdquo; of the problem. Because source code remains the ultimate source of truth, good code must clearly express design intent and invariants; high-level expressive languages preserve that specification without loss. Deductive and equational reasoning from functional programming therefore become even more valuable when collaborating with AI.&lt;/p&gt;
&lt;h2 id="heading"&gt;&lt;a href="https://brenocon.com/dean_perf.html" rel="noopener noreferrer"&gt;&amp;ldquo;Numbers Everyone Should Know&amp;rdquo; from Jeff Dean&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;This page collects Jeff Dean&amp;rsquo;s famous &amp;ldquo;Numbers Everyone Should Know&amp;rdquo; table from Google—reference latencies for fundamental computer operations meant as historical order-of-magnitude rules of thumb rather than benchmarks for today&amp;rsquo;s hardware. An L1 cache reference takes ~0.5 ns, L2 cache ~7 ns, a branch mispredict ~5 ns, and a mutex lock/unlock or main memory reference ~100 ns. Compressing 1 KB with Zippy or sending 1 KB over a 1 Gbps network takes ~10,000 ns (0.01 ms); reading 1 MB sequentially from memory takes 0.25 ms, while a round trip within the same datacenter takes 0.5 ms. A disk seek takes 10 ms, reading 1 MB sequentially from disk takes 30 ms, and sending a packet from California to the Netherlands and back takes 150 ms.&lt;/p&gt;
&lt;p&gt;The lasting value of the table lies in the relative orders of magnitude between operations rather than the exact numbers: main memory is roughly 200x slower than L1 cache, and a disk seek is tens of millions of times slower than L1. For engineers, internalizing these gaps lets you do quick back-of-the-envelope performance estimates during design, understand why caching and minimizing I/O matter so much, and avoid common performance traps when building distributed or data-intensive systems.&lt;/p&gt;
&lt;h2 id="the-internet-is-cool-thank-you-tcp"&gt;&lt;a href="https://cefboud.com/posts/tcp-deep-dive-internals/" rel="noopener noreferrer"&gt;The Internet is Cool. Thank you, TCP&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Moncef Abboud explains why TCP is the workhorse of the Internet, underpinning HTTP, SMTP, and SSH. Underlying networks are inherently unreliable: packets can be dropped, corrupted, duplicated, or delivered out of order. While IP routes packets from host to host, the transport layer uses ports to deliver data to the right process—like a building&amp;rsquo;s street address versus an apartment number. TCP handles retransmissions, checksums, and ordering right at the two endpoints so intermediate routers stay simple and application developers don&amp;rsquo;t have to reinvent reliability. Alongside that, flow control (the &lt;code&gt;window&lt;/code&gt; field) tells the sender how much room remains in the receiver&amp;rsquo;s buffer, while congestion control was born after the &amp;ldquo;congestion collapse&amp;rdquo; of 1986, when throughput across an early Internet link plunged to just 40 bits per second.&lt;/p&gt;
&lt;p&gt;On the hands-on side, the post walks through C code for a TCP echo server and a minimal &amp;ldquo;fake&amp;rdquo; HTTP server just complete enough to fool &lt;code&gt;curl&lt;/code&gt;, illustrating Berkeley socket calls like &lt;code&gt;socket&lt;/code&gt;, &lt;code&gt;bind&lt;/code&gt;, &lt;code&gt;listen&lt;/code&gt;, &lt;code&gt;accept&lt;/code&gt;, &lt;code&gt;send&lt;/code&gt;, and &lt;code&gt;recv&lt;/code&gt;. The author also dissects the TCP segment header: how every connection is uniquely identified by a 5-tuple (protocol, source IP and port, destination IP and port), how the &lt;code&gt;SYN&lt;/code&gt; → &lt;code&gt;SYN-ACK&lt;/code&gt; → &lt;code&gt;ACK&lt;/code&gt; three-way handshake establishes a connection, how &lt;code&gt;FIN&lt;/code&gt; or &lt;code&gt;RST&lt;/code&gt; tears it down, and how sequence numbers and acknowledgment numbers keep byte streams intact and in order.&lt;/p&gt;
&lt;h2 id="myths-programmers-believe-about-cpu-caches"&gt;&lt;a href="https://software.rajivprab.com/2018/04/29/myths-programmers-believe-about-cpu-caches/" rel="noopener noreferrer"&gt;Myths Programmers Believe about CPU Caches&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Drawing on experience working on CPU caches at Intel and Sun, the author debunks a widespread misconception: that concurrency is hard because &amp;ldquo;each CPU core can hold different, stale values in its private cache,&amp;rdquo; and that Java&amp;rsquo;s &lt;code&gt;volatile&lt;/code&gt; keyword exists to force reads and writes straight to main memory. In reality, caches on modern x86 CPUs are kept coherent automatically by hardware cache-coherency protocols like MESI, where every cache line is tagged as Modified, Exclusive, Shared, or Invalid. If a &lt;code&gt;volatile&lt;/code&gt; read actually had to go all the way to RAM every time, it would be ~200x slower; in practice, a &lt;code&gt;volatile&lt;/code&gt; read can be as cheap as an L1 cache hit.&lt;/p&gt;
&lt;p&gt;Why, then, do we still need &lt;code&gt;volatile&lt;/code&gt; and atomics? Because CPU registers are &lt;em&gt;not&lt;/em&gt; coherent across cores, and compilers are free to keep variables in registers or reorder instructions under the assumption of single-threaded execution. In Java, a &lt;code&gt;volatile&lt;/code&gt; write establishes a happens-before relationship with subsequent reads of that same variable. That guarantee governs both compiler optimizations and hardware memory ordering; single-cache-line coherency alone does not guarantee that all threads observe changes across multiple variables in the same order. Misunderstanding this leads to flawed designs, such as assuming a single-core machine is immune to race conditions. The author also shows how hardware cache-coherency principles map directly onto distributed systems and database isolation levels.&lt;/p&gt;
&lt;h2 id="why-nan--nan-in-javascript-and-the-ieee-754-story-behind-it"&gt;&lt;a href="https://pzarycki.com/en/posts/js-nan/" rel="noopener noreferrer"&gt;Why NaN !== NaN in JavaScript (and the IEEE 754 story behind it)&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;In JavaScript, &lt;code&gt;typeof NaN&lt;/code&gt; returns &lt;code&gt;&amp;quot;number&amp;quot;&lt;/code&gt;, and many operations like addition, subtraction, or &lt;code&gt;Math.max&lt;/code&gt; propagate &lt;code&gt;NaN&lt;/code&gt;—though not every operation does. Tracing through the source code of Firefox and V8, the author finds that both delegate to C++&amp;rsquo;s &lt;code&gt;std::isnan&lt;/code&gt;, a clue that &lt;code&gt;NaN&lt;/code&gt;&amp;rsquo;s behavior wasn&amp;rsquo;t invented by JavaScript at all, but comes from the 1985 IEEE 754 floating-point standard. Rewriting the example in C produces the exact same result—&lt;code&gt;x != x&lt;/code&gt; evaluates to true when &lt;code&gt;x&lt;/code&gt; is &lt;code&gt;NaN&lt;/code&gt;—and inspecting the compiled assembly shows the comparison is executed directly by the CPU via the &lt;code&gt;ucomisd&lt;/code&gt; instruction on x86. In other words, &lt;code&gt;NaN !== NaN&lt;/code&gt; is intentional hardware-level behavior, not a JavaScript quirk.&lt;/p&gt;
&lt;p&gt;Before IEEE 754, every hardware vendor handled arithmetic errors differently, often causing expressions like &lt;code&gt;0/0&lt;/code&gt; to trap and crash the program immediately, making portable numerical code a nightmare—imagine that happening inside flight-control software. &lt;code&gt;NaN&lt;/code&gt; solved this by propagating quietly through a chain of calculations so programmers can check for errors once at the end rather than after every single arithmetic step. In JavaScript, the reliable ways to check for &lt;code&gt;NaN&lt;/code&gt; are &lt;code&gt;Number.isNaN()&lt;/code&gt; or &lt;code&gt;x !== x&lt;/code&gt;.&lt;/p&gt;
&lt;h2 id="towards-interplanetary-quic-traffic"&gt;&lt;a href="https://ochagavia.nl/blog/towards-interplanetary-quic-traffic/" rel="noopener noreferrer"&gt;Towards interplanetary QUIC traffic&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Adolfo Ochagavía recounts a consulting project to prove that QUIC—the reliable transport protocol underlying HTTP/3—can operate across deep space, such as communicating between Earth and a rover on Mars. The challenges are extreme: one-way signal delay ranges from 3 to 23 minutes, and links drop regularly as relay satellites pass out of view. With default settings, QUIC times out long before completing a handshake. The limitation, however, lies in default parameters tuned for terrestrial broadband rather than in the protocol itself: QUIC allows deep tuning of initial RTT estimates, idle timeouts, and congestion control algorithms, whereas TCP is fundamentally ill-suited for deep space.&lt;/p&gt;
&lt;p&gt;Testing against virtual machines with real simulated delays would be painfully slow when a single Mars round trip takes up to 46 minutes. Ochagavía solved this by running both client and server inside a single process, routing packets through a custom in-memory network simulator, and enabling Tokio&amp;rsquo;s time-skipping test clock. Thanks to the modular design of &lt;code&gt;quinn&lt;/code&gt;—Rust&amp;rsquo;s most popular QUIC implementation—everything plugged together cleanly: tests run almost instantaneously, behave deterministically (identical seeds yield identical runs), and dump &lt;code&gt;.pcap&lt;/code&gt; packet captures at both endpoints for inspection in Wireshark. Mars rovers still transmit images over CFDP today, but in a few years the answer might well be QUIC.&lt;/p&gt;
&lt;h2 id="bloom-filters-the-niche-trick-behind-a-16-faster-api"&gt;&lt;a href="https://incident.io/blog/bloom-filters" rel="noopener noreferrer"&gt;Bloom filters: the niche trick behind a 16× faster API&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;The engineering team at incident.io shares how they cut the P95 latency of an alert-filtering API from 5 seconds down to 0.3 seconds. Alerts are stored in PostgreSQL, with customer-defined custom attributes like &lt;code&gt;&amp;quot;team&amp;quot;&lt;/code&gt; or &lt;code&gt;&amp;quot;feature&amp;quot;&lt;/code&gt; packed inside a &lt;code&gt;JSONB&lt;/code&gt; column. Their old algorithm fetched batches of 500 rows, deserialized the &lt;code&gt;JSONB&lt;/code&gt; payloads into Go structs, and filtered them in memory, looping until it filled a single page of results. For large enterprise customers with millions of alerts, this forced the API to scan and deserialize massive amounts of irrelevant data. The team weighed two options: a PostgreSQL GIN index—the standard textbook choice for &lt;code&gt;JSONB&lt;/code&gt;—or a Bloom filter, a probabilistic data structure that tells you whether an element is &amp;ldquo;definitely not in the set&amp;rdquo; or &amp;ldquo;possibly in the set.&amp;rdquo;&lt;/p&gt;
&lt;p&gt;They chose a Bloom filter out of concern that a GIN index would balloon disk and memory usage while slowing down writes. Each alert&amp;rsquo;s attribute key-value pairs are hashed into a &lt;code&gt;bit(512)&lt;/code&gt; column sized for a ~1% false-positive rate at their attribute cardinality. At query time, Postgres performs a fast bitwise AND check (&lt;code&gt;bitmap &amp;amp; bitmask == bitmask&lt;/code&gt;) to discard non-matching rows cheaply, then runs the exact &lt;code&gt;JSONB&lt;/code&gt; check on the surviving candidates to filter out false positives. Combined with a mandatory time-window filter (defaulting to 30 days) that exploits the chronological sort order of ULID primary keys, query performance became fast and predictable even for their largest customers. The takeaway: sometimes a niche computer science trick beats the standard off-the-shelf index.&lt;/p&gt;
&lt;h2 id="making-things-true"&gt;&lt;a href="https://threadreaderapp.com/thread/1990057444253241545.html" rel="noopener noreferrer"&gt;making things true&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;In this thread, Ryo Lu argues that design isn&amp;rsquo;t about surface aesthetics like picking colors or polishing UI chrome, but about seeing through the surface to the underlying structure: decomposing a complex domain into fundamental building blocks, understanding how they relate, and recombining them into something simpler and more powerful. When building Notion, the team didn&amp;rsquo;t set out to make yet another note-taking app or project tracker; instead, they searched for the &amp;ldquo;atoms&amp;rdquo; of software: blocks, databases, views, and relations. Viewed through that lens, Asana, Linear, Evernote, and Airtable are just rigid presets of the same underlying concepts, whereas Notion hands users Lego bricks to assemble whatever tool they need. Cursor does something similar one layer deeper, removing friction between human intent and working software: you describe what you want, and AI handles the decomposition into code.&lt;/p&gt;
&lt;p&gt;Lu zooms out further: human language, music, and DNA are all finite sets of primitives that combine in infinite ways. The true turning points in computing history weren&amp;rsquo;t flashy features, but new primitives—the command line, the GUI, the hyperlink, mobile sensors—and AI is the newest primitive of that kind. For software builders, the lesson is to practice spotting the core primitives of a system by asking what a thing truly is at its core and how much you can strip away before it stops being itself.&lt;/p&gt;
&lt;h2 id="what-good-execution-looks-like"&gt;&lt;a href="https://yusufaytas.com/what-good-execution-looks-like/" rel="noopener noreferrer"&gt;What Good Execution Looks Like&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Yusuf Aytas observes that great execution feels &amp;ldquo;quiet&amp;rdquo;—not slow or passive, but smooth enough that people coordinate naturally and management&amp;rsquo;s presence almost fades into the background. Poor execution, by contrast, is loud and full of heroics: projects stall, approval layers multiply, processes calcify, status updates turn defensive, and meetings explode. In Aytas&amp;rsquo;s view, strong execution rests on a handful of foundations: clear direction (what matters, where we&amp;rsquo;re going, and why), stable priorities, unambiguous ownership with a single directly responsible individual, lightweight process designed solely to reduce uncertainty, maintain momentum, and surface problems early, mutual trust, a steady cadence, and fast, honest feedback loops.&lt;/p&gt;
&lt;p&gt;Signs of healthy execution include low operational noise, psychological safety to raise risks early without fear of blame, and genuine autonomy where leaders clear roadblocks instead of micromanaging details. Execution is measurable, too: predictable lead times and throughput, small frequent releases, high-signal alerts instead of pager fatigue, and a low change-failure rate. The core message: quietness isn&amp;rsquo;t a lack of urgency—it&amp;rsquo;s the sound of an organization that isn&amp;rsquo;t fighting itself.&lt;/p&gt;
&lt;h3 id="bonus"&gt;Bonus&lt;/h3&gt;&lt;p&gt;&lt;strong&gt;Images:&lt;/strong&gt;
&lt;img src="https://substackcdn.com/image/fetch/$s_!tANe!,w_1100,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7f80d730-11c4-4d55-81bf-fa4629cc2f0f_2360x2960.png" alt="How to Design Good APIs"&gt;
&lt;img src="https://substackcdn.com/image/fetch/$s_!gReB!,w_1100,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc2e93eb2-84ab-427f-b587-e14b599e0fee_2360x2960.png" alt="Types of Virtualization"&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Videos:&lt;/strong&gt;
&lt;a href="https://www.youtube.com/watch?v=7_wkWQ9rB5I" rel="noopener noreferrer"&gt;Why is Kafka Popular?&lt;/a&gt;&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;&lt;em&gt;This post was rewritten by Claude Code with Opus 5.5 on 27/09/2026; reviewed and edited by Codex with GPT 6.1 Sol on 09/11/2026, and re-verified by Claude Code with Sonnet 5.5 on 16/11/2026.&lt;/em&gt;&lt;/p&gt;</description></item><item><title>Newsletter #33</title><link>https://miti99.com/en/post/2025/07/22/</link><pubDate>Tue, 22 Jul 2025 00:00:00 +0700</pubDate><guid>https://miti99.com/en/post/2025/07/22/</guid><description>&lt;p&gt;&lt;em&gt;Enjoy Newsletter #33.&lt;/em&gt;&lt;/p&gt;
&lt;h2 id="how-zgc-allocates-memory-for-the-java-heap"&gt;&lt;a href="https://joelsiks.com/posts/zgc-heap-memory-allocation/" rel="noopener noreferrer"&gt;How ZGC allocates memory for the Java heap&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;ZGC is Java&amp;rsquo;s low-latency garbage collector, and this post dives into how it allocates memory for the heap. ZGC divides the heap into logical &amp;ldquo;pages&amp;rdquo; of three sizes: small 2 MB pages for most objects, medium pages dynamically sized between 4 and 32 MB, and large pages that hold a single object each. Crucially, ZGC decouples physical memory from virtual memory and reserves virtual address space up to 16 times the maximum heap size (32 times on NUMA machines) so it can easily find contiguous virtual ranges and minimize fragmentation.&lt;/p&gt;
&lt;p&gt;Free memory is tracked in a mapped cache organized as a red-black tree. When an allocation is needed, ZGC tries in order: grabbing an existing contiguous range from the cache (the fastest path), committing more physical memory, &amp;ldquo;harvesting&amp;rdquo; by remapping multiple discontiguous regions into a single contiguous virtual range, or combining the latter two; only if all of those fail does it trigger garbage collection or throw an &lt;code&gt;OutOfMemoryError&lt;/code&gt;. On NUMA systems, the heap is partitioned evenly across nodes to favor local memory allocation. The post also highlights a practical trade-off: setting minimum heap size equal to maximum heap size pre-allocates all memory at startup, whereas dynamic allocation at runtime adds latency.&lt;/p&gt;
&lt;h2 id="optimizing-the-garbage-collector-when-migrating-cloud-workloads"&gt;&lt;a href="https://foojay.io/today/optimizing-the-garbage-collector-when-migrating-cloud-workloads/" rel="noopener noreferrer"&gt;Optimizing the Garbage Collector when Migrating Cloud Workloads&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Java&amp;rsquo;s &amp;ldquo;write once, run anywhere&amp;rdquo; promise makes moving applications from x86 machines to Arm-based cloud instances like AWS Graviton or Azure Cobalt fairly smooth, but getting peak performance on Arm Neoverse still requires tuning the garbage collector (GC). The post recommends using OpenJDK 11 or newer to pick up optimizations for modern Arm platforms, starting with G1 as a safe default for most server workloads thanks to its balance of throughput and latency, and considering ZGC or Shenandoah (Java 17+) for latency-sensitive applications with large heaps.&lt;/p&gt;
&lt;p&gt;On configuration, the author suggests setting &lt;code&gt;-XX:MaxGCPauseMillis&lt;/code&gt; to define a pause-time target and let the JVM self-tune, enabling &lt;code&gt;-XX:+UseAdaptiveSizePolicy&lt;/code&gt; so the JVM adjusts heap and generation sizes to real traffic, and sizing the heap carefully to balance collection frequency against pause duration. Finally, turn on GC logging with &lt;code&gt;-Xlog:gc&lt;/code&gt; and use Java Flight Recorder to inspect GC behavior, because only testing under realistic production workloads will tell you which settings meet your performance goals.&lt;/p&gt;
&lt;h2 id="how-javascript-works-behind-the-scenes"&gt;&lt;a href="https://www.deepintodev.com/blog/how-javascript-works-behind-the-scenes" rel="noopener noreferrer"&gt;How JavaScript Works Behind the Scenes&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;JavaScript is single-threaded, so how does it handle asynchronous work without freezing up? This post explains the internals of a JavaScript engine (such as V8 in Chrome and Node.js), which centers on two components: the heap, where objects and variables live in memory, and the call stack, which tracks program execution and reflects JavaScript&amp;rsquo;s single thread of control. Every function call pushes a new execution context onto the stack containing local variables, arguments, the &lt;code&gt;this&lt;/code&gt; binding, and a reference to the outer scope; because contexts run sequentially, a heavy loop on the stack blocks everything behind it.&lt;/p&gt;
&lt;p&gt;To avoid blocking, slow operations are handed off to browser Web APIs like &lt;code&gt;fetch&lt;/code&gt;, &lt;code&gt;setTimeout&lt;/code&gt;, or geolocation. When they finish, their callbacks land in the task queue, whereas Promise-based continuations (&lt;code&gt;.then&lt;/code&gt;, &lt;code&gt;.catch&lt;/code&gt;, &lt;code&gt;async/await&lt;/code&gt;) go into the microtask queue. The event loop continuously watches the call stack, and whenever the stack is empty it drains the entire microtask queue before pulling the next regular task. That is why Promise callbacks typically run before &lt;code&gt;setTimeout&lt;/code&gt; callbacks, and how JavaScript stays non-blocking without extra execution threads—even though a CPU-heavy loop can still freeze the UI.&lt;/p&gt;
&lt;h2 id="why-embedding-models-should-match--advice-for-starting-a-blog"&gt;&lt;a href="https://foojay.io/today/breaktime-tech-talks-ep39-why-embedding-models-should-match-advice-for-starting-a-blog/" rel="noopener noreferrer"&gt;Why embedding models should match + Advice for starting a blog&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;In this episode of Breaktime Tech Talks, Jennifer Reif shares a practical lesson on why embedding models have to match. She generated vectors in Pinecone and Neo4j using two different OpenAI models (&lt;code&gt;text-embedding-ada-002&lt;/code&gt; and &lt;code&gt;text-embedding-3-small&lt;/code&gt;), then queried them from her application using a mismatched model. Even within the same provider family, the vector representations differed enough that similarity search returned nonsensical matches or nothing at all. The fix is to use the exact same embedding model for both stored documents and application queries; even then, different vector databases can return slightly different results due to their own similarity-search implementations—something to keep in mind when building RAG systems.&lt;/p&gt;
&lt;p&gt;The second half offers advice for starting a technical blog: write for yourself first, documenting your learning journey and how you solved problems so you can look them up later; keep a natural, conversational tone; let completed projects serve as a ready-made outline and edit just enough without over-polishing; remember that readers will skim for the section they need; and prioritize writing about problems you struggled to find answers for online, since others are likely searching for the exact same thing.&lt;/p&gt;
&lt;h2 id="hula-human-in-the-loop-llm-based-agents-for-software-development"&gt;&lt;a href="https://www.atlassian.com/blog/atlassian-engineering/hula-blog-autodev-paper-human-in-the-loop-software-development-agents" rel="noopener noreferrer"&gt;HULA: Human-in-the-loop LLM-based agents for software development&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Atlassian introduces HULA, a human-in-the-loop LLM agent framework designed to automate routine development tasks while keeping engineers in control. Accepted to the ICSE 2025 SEIP track, the workflow runs in four stages: an engineer selects a Jira issue and adds context; HULA drafts a plan listing the files and changes required for the engineer to approve or revise; HULA generates code, using compiler and linter feedback to iterate until it passes checks before waiting for engineer review; and finally the approved changes are opened as a pull request following the team&amp;rsquo;s normal process. At the time of writing, Atlassian reported that roughly 900 HULA-generated pull requests had been merged.&lt;/p&gt;
&lt;p&gt;In a September 2024 evaluation on SWE-bench Verified, HULA passed unit tests on 31% of issues, and a GPT-based metric judged its patches highly similar to human solutions in 45% of cases. Across 663 real Jira issues over two months, HULA produced a plan for 79% of items (82% of which engineers approved), generated code for 87% of approved plans, reached a pull request on 25%, and saw 59% of those PRs merged. Surveying 109 engineers showed 62% agreed HULA identified the right files to change and 61% found its code easy to understand, though only 33% felt the generated code fully solved the task. Engineers valued the time savings and better documentation, but still had to manually finish functionality and wanted a smoother UX.&lt;/p&gt;
&lt;h2 id="refactoring-gone-wild-avoiding-code-smells-and-cleaning-up-the-mess"&gt;&lt;a href="https://techhub.iodigital.com/articles/refactoring-gone-wild-avoiding-code-smells-and-cleaning-up-the-mess" rel="noopener noreferrer"&gt;Refactoring Gone Wild: Avoiding Code Smells and Cleaning Up the Mess&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Refactoring is a core engineering skill, but doing it well starts with spotting code smells. Using Kotlin examples, this article walks through more than ten common smells: the Pyramid of Doom (deeply nested conditionals), inconsistent naming, mysterious parameters, god functions, forests of null checks, tangled boolean expressions, chaotic error handling, overuse of mutable collections, duplicated validation logic, and misused coroutines. Each smell makes code harder to read, harder to maintain, and more complex than it needs to be.&lt;/p&gt;
&lt;p&gt;For every smell, the author pairs a concrete remedy: flatten nesting with guard clauses, standardize naming conventions, group related parameters into a &lt;code&gt;data class&lt;/code&gt;, split large functions into small testable ones, use safe-call and Elvis operators for nulls, extract named helper functions for complex boolean conditions, centralize error handling and validation, default to immutability, adopt structured concurrency, and lean on standard-library helpers like &lt;code&gt;groupBy&lt;/code&gt;, &lt;code&gt;takeIf&lt;/code&gt;, and &lt;code&gt;runCatching&lt;/code&gt;. The closing message is that &amp;ldquo;small, incremental improvements add up to a big difference&amp;rdquo;: you don&amp;rsquo;t need a massive rewrite—just steady cleanup to keep code readable and maintainable.&lt;/p&gt;
&lt;h2 id="how-to-write-error-messages-that-actually-help-users-rather-than-frustrate-them"&gt;&lt;a href="https://piccalil.li/blog/how-to-write-error-messages-that-actually-help-users-rather-than-frustrate-them/" rel="noopener noreferrer"&gt;How to write error messages that actually help users rather than frustrate them&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Error messages show up at the exact moment a user is already stuck, yet they are often written in robotic jargon. This post lays out a practical approach to writing error messages that genuinely help: start by auditing every place an error can occur—form fields, validation checks, 404 and 500 pages, empty search results, and dropped connections. Then write as if you were sitting next to the person and walking them through it: instead of &amp;ldquo;Invalid input,&amp;rdquo; write &amp;ldquo;Please enter the 6-digit code we emailed you&amp;rdquo;; instead of &amp;ldquo;No WiFi connection detected,&amp;rdquo; write &amp;ldquo;It looks like you&amp;rsquo;re offline—connect to WiFi and try again.&amp;rdquo;&lt;/p&gt;
&lt;p&gt;The author advises skipping cute or joking copy, which makes frustrated users feel their problem isn&amp;rsquo;t being taken seriously; the post cites a shopper who abandoned their cart after a typo triggered a message calling them a &amp;ldquo;silly sausage.&amp;rdquo; Use active voice to state clearly what went wrong and why—for example, &amp;ldquo;We couldn&amp;rsquo;t process your application because that file format isn&amp;rsquo;t supported; please re-attach it as a JPEG.&amp;rdquo; When users can fix the issue themselves, tell them the exact step to take; when they can&amp;rsquo;t, offer a clear fallback such as a retry button, support contact details, or reassurance that their work was saved. Finally, document message patterns for common scenarios to keep tone and clarity consistent across the product.&lt;/p&gt;
&lt;h2 id="the-difficulty-in-big-tech"&gt;&lt;a href="https://www.seangoedecke.com/difficulty-in-big-tech/" rel="noopener noreferrer"&gt;The difficulty in big tech&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Many people assume big tech companies move slowly because of bad processes or lazy engineers, but Sean Goedecke argues the real culprit is accumulated feature complexity. Every new feature can interact with every existing feature, causing the number of interactions engineers must reason about to explode as a product matures. Worse are &amp;ldquo;evil&amp;rdquo; cross-cutting features that touch the entire system: adding a new user type, for instance, forces engineers to audit permissions across every existing feature and remember that constraint forever after. The resulting cognitive load is so heavy that &amp;ldquo;getting anything done at all is really, really hard,&amp;rdquo; making it easy for engineers to miss even seemingly obvious edge cases.&lt;/p&gt;
&lt;p&gt;So why do big companies keep shipping features anyway? Because they make money: as Dan Luu has noted, seemingly minor features can each add a few percentage points of revenue, and 1% of revenue on products like Google Ads or AWS S3 is an enormous sum. In Goedecke&amp;rsquo;s view, big-tech slowness isn&amp;rsquo;t a sign of organizational dysfunction—it is a deliberate trade-off that accepts slower development velocity in exchange for the revenue of a densely featured product.&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;&lt;em&gt;This post was rewritten by Claude Code with Opus 5.5 on 27/09/2026; reviewed and edited by Codex with GPT 6.1 Sol on 09/11/2026, and re-verified by Claude Code with Sonnet 5.5 on 16/11/2026.&lt;/em&gt;&lt;/p&gt;</description></item><item><title>Newsletter #30</title><link>https://miti99.com/en/post/2025/05/17/</link><pubDate>Sat, 17 May 2025 00:00:00 +0700</pubDate><guid>https://miti99.com/en/post/2025/05/17/</guid><description>&lt;p&gt;&lt;em&gt;Welcome to Newsletter #30 - Today&amp;rsquo;s tech news roundup.&lt;/em&gt;&lt;/p&gt;
&lt;h2 id="what-i"&gt;&lt;a href="https://muratbuffalo.blogspot.com/2025/04/what-id-do-as-college-freshman.html" rel="noopener noreferrer"&gt;What I&amp;rsquo;d do as a College Freshman in 2025&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Computer science professor Murat Demirbas asks what he would do if he were starting college over as a freshman in 2025, and his first answer is still to study Computer Science. Against the claim that &amp;ldquo;nobody needs to learn programming anymore,&amp;rdquo; he argues that AI tools cannot replace real mastery: debugging skills, abstract thinking, and fast adaptability have to be forged firsthand. He advises building a strong foundation in both computer science and AI, then pairing AI with a deep domain such as systems, databases, or programming languages—aiming to become &amp;ldquo;π-shaped,&amp;rdquo; with depth in two areas and broad literacy across many others.&lt;/p&gt;
&lt;p&gt;Beyond technical depth, soft skills are indispensable: clear communication powers remote work, learning in public, and even working with LLMs, while management starts with managing yourself. Demirbas still views the US as the best launchpad for a tech career and university as the best place to meet talented peers and build projects together. Borrowing a friend&amp;rsquo;s metaphor, he says you should either be an all-terrain Jeep with an entrepreneurial mindset, or a specialized, high-speed Ferrari when a paved track exists—just don&amp;rsquo;t be an easily replaceable Corolla, because in the AI era that is what gets automated away. Finally, play the long game, compounding skills and relationships rather than chasing trends.&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="llms-are-weird-computers"&gt;&lt;a href="https://www.phillipcarter.dev/posts/llms-computers" rel="noopener noreferrer"&gt;LLMs Are Weird Computers&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Phillip Carter proposes a useful mental model for large language models (LLMs): treat them as a &amp;ldquo;weird&amp;rdquo; or &amp;ldquo;inverted&amp;rdquo; kind of computer alongside the &amp;ldquo;normal&amp;rdquo; computers we already know. Traditional computers execute with exact precision but struggle with ambiguity, whereas LLMs do the opposite: they excel at handling ambiguity but struggle when absolute precision is required.&lt;/p&gt;
&lt;p&gt;Viewing LLMs as a new class of computer with its own distinct properties helps developers better understand their strengths and limits, making it clearer which tasks to hand to an LLM and when traditional computation is still the right tool.&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="every-caching-strategy-explained-in-5-minutes"&gt;&lt;a href="https://www.swequiz.com/blog/every-caching-strategy-explained-in-5-minutes" rel="noopener noreferrer"&gt;Every Caching Strategy Explained in 5 Minutes&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;This SWE Quiz post gives a quick tour of common caching strategies, a foundational topic for optimizing application performance. With Cache-Aside (also called lazy loading), the application manages the cache directly: it checks the cache first and queries the database only on a miss, which fits read-heavy systems that can tolerate briefly stale data. Read-Through instead has the application talk only to the cache while the cache itself loads missing data from the database, keeping application code cleaner.&lt;/p&gt;
&lt;p&gt;On the write side, Write-Through writes synchronously to both the cache and the database, guaranteeing consistency at the cost of slower writes. Write-Behind (Write-Back) writes only to the cache and flushes to the database asynchronously later, speeding up writes but risking data loss if the cache fails before syncing. Write-Around bypasses the cache on writes and uses it only for reads, which suits data that is rarely re-read immediately after being written. Choosing the right strategy depends on an application&amp;rsquo;s specific trade-offs across performance, consistency, and fault tolerance.&lt;/p&gt;
&lt;h2 id="some-features-that-every-javascript-developer-should-know-in-2025"&gt;&lt;a href="https://waspdev.com/articles/2025-04-06/features-that-every-js-developer-must-know-in-2025" rel="noopener noreferrer"&gt;Some features that every JavaScript developer should know in 2025&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;This WaspDev article rounds up modern JavaScript features every developer should know to write cleaner, more efficient code. Standouts include iterator helper methods like &lt;code&gt;drop()&lt;/code&gt;, &lt;code&gt;take()&lt;/code&gt;, and &lt;code&gt;filter()&lt;/code&gt;, which process large datasets lazily one element at a time without allocating memory-hungry intermediate arrays. The &lt;code&gt;at()&lt;/code&gt; method supports negative indexing on arrays, such as &lt;code&gt;arr.at(-1)&lt;/code&gt; to grab the last element, while &lt;code&gt;Promise.withResolvers()&lt;/code&gt; cleanly exposes &lt;code&gt;resolve&lt;/code&gt; and &lt;code&gt;reject&lt;/code&gt; alongside a newly created Promise.&lt;/p&gt;
&lt;p&gt;The post also highlights underused techniques: passing a callback function to &lt;code&gt;replace()&lt;/code&gt; and &lt;code&gt;replaceAll()&lt;/code&gt; for complex string substitutions, swapping two variables via &lt;code&gt;[a, b] = [b, a]&lt;/code&gt; instead of a temporary variable, and deep-cloning objects with &lt;code&gt;structuredClone()&lt;/code&gt; rather than &lt;code&gt;JSON.parse(JSON.stringify())&lt;/code&gt;. Rounding out the list are tagged templates for flexible template-literal processing, &lt;code&gt;WeakMap&lt;/code&gt;/&lt;code&gt;WeakSet&lt;/code&gt; for attaching metadata to objects without preventing garbage collection, and new &lt;code&gt;Set&lt;/code&gt; operations like &lt;code&gt;union()&lt;/code&gt;, &lt;code&gt;intersection()&lt;/code&gt;, and &lt;code&gt;difference()&lt;/code&gt;.&lt;/p&gt;
&lt;h2 id="what-makes-a-great-developer-experience"&gt;&lt;a href="https://www.codesimplicity.com/post/what-makes-a-great-developer-experience/" rel="noopener noreferrer"&gt;What Makes a Great Developer Experience?&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Max Kanat-Alexander, who has spent over 20 years working on developer experience (DX) and helped design key parts of DX at Google and LinkedIn, distills the field&amp;rsquo;s core principles. In his view, a great DX optimizes three things: cycle time, the elapsed time from when a developer forms an intent to when that intent is fulfilled; focus, the ability to work in uninterrupted flow; and cognitive load, the amount of knowledge required and the number of decisions a developer must make to get something done.&lt;/p&gt;
&lt;p&gt;Most of the post focuses on the practical challenges of improving DX: understanding the real problem through data and developer feedback, managing change through gradual rollouts and driving adoption, building high-leverage tools that save human time rather than just machine resources, saying &amp;ldquo;no&amp;rdquo; or &amp;ldquo;not yet&amp;rdquo; kindly to requests that don&amp;rsquo;t fit, and placing the burden on the party actually causing the problem. The overarching lesson is that the hardest part of DX is usually human rather than technical.&lt;/p&gt;
&lt;h2 id="when-life-gives-you-java"&gt;&lt;a href="https://oblac.rs/when-life-gives-you-java/" rel="noopener noreferrer"&gt;When Life Gives You Java&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Igor Spasić shares how he writes Java when he has to use the language but still wants clean code, borrowing ideas from more expressive functional languages. He makes classes package-private by default and exposes them publicly only when strictly necessary, treating each package as a module. Roughly 95% of references are marked &lt;code&gt;final&lt;/code&gt; to embrace immutability, which makes &lt;code&gt;null&lt;/code&gt; nearly disappear outside very narrow boundaries. He no longer uses inheritance in his own code, favoring object composition instead, while still accepting inheritance where external libraries require it.&lt;/p&gt;
&lt;p&gt;Spasić thinks in terms of &amp;ldquo;input, process, output&amp;rdquo; functions: because Java lacks true first-class functions, each class typically wraps a single function or a small group of closely related ones. Algebraic data types (ADTs) are modeled as &lt;code&gt;record&lt;/code&gt;s implementing a &lt;code&gt;sealed interface&lt;/code&gt;, and domain errors are returned as part of the result via dedicated ADTs, reserving exceptions for genuine runtime failures like out-of-memory errors, I/O failures, or lost database connections. That produces more small classes, which he considers a worthwhile trade-off for more modular code with fewer surprises.&lt;/p&gt;
&lt;h2 id="just-throw-it-into-postgres"&gt;&lt;a href="https://simonsafar.com/2025/throw_it_into_postgres/" rel="noopener noreferrer"&gt;Just Throw It Into Postgres&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;Simon Safar argues that between the two extremes of forcing all data into a strictly normalized relational schema and dumping raw data into countless files in a directory tree, there is a practical middle ground: just throw the data straight into PostgreSQL without overthinking upfront organization. Thanks to &lt;code&gt;JSONB&lt;/code&gt;, PostgreSQL can query fields inside JSON documents directly, while indexes and dedicated columns can be added later once the data is already there.&lt;/p&gt;
&lt;p&gt;He illustrates this with three examples. First, he built a custom Java code-navigation tool for Emacs: it parsed compiled class files to record relationships like &amp;ldquo;function A calls function B,&amp;rdquo; then loaded hundreds of thousands of records into PostgreSQL via &lt;code&gt;COPY&lt;/code&gt; in a few dozen seconds—fast enough to invoke &lt;code&gt;psql&lt;/code&gt; multiple times per second for autocomplete. Second, he loaded tens of thousands of Chinese character SVGs from the Make Me a Hanzi project into a table with a &lt;code&gt;JSONB&lt;/code&gt; column and joined it against a dictionary table for fast lookups. Third, he stored temperature sensor readings arriving over MQTT so Grafana could chart them. The takeaway: get the data stored first and organize it later, rather than trying to design the perfect schema on day one.&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;&lt;em&gt;This post was rewritten by Claude Code with Opus 5.5 on 27/09/2026; reviewed and edited by Codex with GPT 6.1 Sol on 09/11/2026, and re-verified by Claude Code with Sonnet 5.5 on 16/11/2026.&lt;/em&gt;&lt;/p&gt;</description></item></channel></rss>