<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Laputa</title>
    <link>https://chenjianyong.com/</link>
    <description>Recent content on Laputa</description>
    <generator>Hugo</generator>
    <language>en-GB</language>
    <lastBuildDate>Sun, 07 Sep 2025 00:00:00 +0000</lastBuildDate>
    <atom:link href="https://chenjianyong.com/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Durable Object Write Coalesce</title>
      <link>https://chenjianyong.com/blog/2025/durable-object-write-coalesce/</link>
      <pubDate>Sun, 07 Sep 2025 00:00:00 +0000</pubDate>
      <guid>https://chenjianyong.com/blog/2025/durable-object-write-coalesce/</guid>
      <description>&lt;p&gt;In the blog post &lt;a href=&#34;https://blog.cloudflare.com/durable-objects-easy-fast-correct-choose-three/&#34;&gt;Durable Objects: Easy, Fast, Correct — Choose Three&lt;/a&gt;, Kenton introduces two critical implementation concepts of Durable Objects: the input gate and the output gate. These mechanisms work in tandem to address data races and enable seamless in-memory caching, ensuring both correctness and performance.&lt;/p&gt;&#xA;&lt;p&gt;However, I&amp;rsquo;m particularly intrigued by another feature Kenton highlighted as a bonus of the output gate implementation: automatic write coalescing.&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;    &lt;p&gt;&amp;ldquo;First, writes are automatically coalesced. That is, if you perform multiple &lt;code&gt;put()&lt;/code&gt; or &lt;code&gt;delete()&lt;/code&gt; operations without &lt;code&gt;await&lt;/code&gt;ing them or anything else in between, then the operations are automatically grouped together and stored atomically.&amp;rdquo;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Write Atomicity in MongoDB</title>
      <link>https://chenjianyong.com/blog/2025/write-atomicity-in-mongodb/</link>
      <pubDate>Wed, 16 Jul 2025 00:00:00 +0000</pubDate>
      <guid>https://chenjianyong.com/blog/2025/write-atomicity-in-mongodb/</guid>
      <description>&lt;p&gt;Recently, I’ve been building a task system with the following workflow:&lt;/p&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;A user submits a task.&lt;/li&gt;&#xA;&lt;li&gt;The task is immediately stored in MongoDB.&lt;/li&gt;&#xA;&lt;li&gt;The task ID is returned to the user, who can poll for its status.&lt;/li&gt;&#xA;&lt;li&gt;A background worker periodically fetches pending tasks and executes them.&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;p&gt;This model is quite common when task execution can take a long time.&lt;/p&gt;&#xA;&lt;p&gt;However, here’s the catch: the service is deployed across multiple instances, and they may all fetch the same pending tasks from MongoDB. This creates a race condition — a task could be executed multiple times, and the final result becomes unpredictable.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Way back to China</title>
      <link>https://chenjianyong.com/blog/2025/way-back-to-china/</link>
      <pubDate>Sat, 12 Jul 2025 00:00:00 +0000</pubDate>
      <guid>https://chenjianyong.com/blog/2025/way-back-to-china/</guid>
      <description>&lt;p&gt;Jing and I used to enjoy Japanese anime on BiliBili during lunch or dinner. However, due to political and commercial restrictions, many resources on Chinese platforms are inaccessible from overseas. Ironically, when we lived in China, we often used VPNs to bypass the GFW and access foreign platforms—now it&amp;rsquo;s the other way around.&lt;/p&gt;&#xA;&lt;p&gt;Fortunately, ChatGPT has once again proven to be a great companion for building small tools. With its help, I established a reliable connection that bridges the UK, Germany, and China—without writing a single line of code myself.&lt;/p&gt;</description>
    </item>
    <item>
      <title>California Trip</title>
      <link>https://chenjianyong.com/photos/california/</link>
      <pubDate>Thu, 15 May 2025 00:00:00 +0000</pubDate>
      <guid>https://chenjianyong.com/photos/california/</guid>
      <description>&lt;p&gt;Photos from my trip across California — from the Bay Area to Santa Cruz, Carmel, and more.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;golden-gate-bridge&#34;&gt;Golden Gate Bridge&lt;/h3&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/GoldenGateBridge-1.jpg&#34; alt=&#34;Golden Gate Bridge&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/GoldenGateBridge-2.jpg&#34; alt=&#34;Golden Gate Bridge 2&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;palace-of-fine-arts-san-francisco&#34;&gt;Palace of Fine Arts, San Francisco&lt;/h3&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/PalaceOfFineArts-1.jpg&#34; alt=&#34;Palace of Fine Arts 1&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/PalaceOfFineArts-2.jpg&#34; alt=&#34;Palace of Fine Arts 2&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;pier-39-and-the-san-francisco-waterfront&#34;&gt;Pier 39 and the San Francisco Waterfront&lt;/h3&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/Pier39-1.jpg&#34; alt=&#34;Pier 39&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/Pier39-2.jpg&#34; alt=&#34;Pier 39&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/Pier39-3.jpg&#34; alt=&#34;Pier 39&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;san-francisco-chinatown&#34;&gt;San Francisco Chinatown&lt;/h3&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/Chinatown-1.jpg&#34; alt=&#34;Chinatown 1&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/Chinatown-2.jpg&#34; alt=&#34;Chinatown 2&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;17-mile-drive-pebble-beach--carmel&#34;&gt;17-Mile Drive: Pebble Beach &amp;amp; Carmel&lt;/h3&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/17Miles-PebbleBeach.jpg&#34; alt=&#34;Pebble Beach&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/17Miles-Carmel.jpg&#34; alt=&#34;Carmel&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;santa-cruz-wharf&#34;&gt;Santa Cruz Wharf&lt;/h3&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/SantaCruzWharf-1.jpg&#34; alt=&#34;Santa Cruz 1&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/california/SantaCruzWharf-2.jpg&#34; alt=&#34;Santa Cruz 2&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Nanjing Trip</title>
      <link>https://chenjianyong.com/photos/nanjing/</link>
      <pubDate>Sat, 28 Dec 2024 00:00:00 +0000</pubDate>
      <guid>https://chenjianyong.com/photos/nanjing/</guid>
      <description>&lt;p&gt;A brief walk through Nanjing, an ancient capital rich with history and natural beauty — from the peaceful Jiming Temple to the scenic views of Purple Mountain.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;-nanjing&#34;&gt;🏞️ Nanjing&lt;/h3&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://chenjianyong.com/images/gallery/nanjing/jimingsi-1.jpg&#34; alt=&#34;Jiming Temple&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/nanjing/Lingu-Scenic-Area.jpg&#34; alt=&#34;Linggu Scenic Area&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/nanjing/zijingshan.jpg&#34; alt=&#34;Purple Mountain&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Japan Trip</title>
      <link>https://chenjianyong.com/photos/japan/</link>
      <pubDate>Thu, 04 Apr 2024 00:00:00 +0000</pubDate>
      <guid>https://chenjianyong.com/photos/japan/</guid>
      <description>&lt;p&gt;A journey across Japan — from historic temples in Kyoto and deer in Nara, to the streets of Tokyo, Osaka, and the harbors of Kobe.&lt;/p&gt;&#xA;&lt;p&gt;We started in Kobe and made our way northeast through Osaka, Nara, Kyoto, and finally Tokyo — a classic route across the Kansai and Kanto regions of Japan.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;-tokyo&#34;&gt;🗼 Tokyo&lt;/h3&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Chiyoda-Sotokanda.jpg&#34; alt=&#34;Chiyoda, Sotokanda&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Shinjuku-Kabukicho-1.jpg&#34; alt=&#34;Shinjuku, Kabukicho&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Shinjuku-Kabukicho-2.jpg&#34; alt=&#34;Shinjuku, Kabukicho&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Shinjuku-Kabukicho-3.jpg&#34; alt=&#34;Shinjuku, Kabukicho&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Taito-Asakusa.jpg&#34; alt=&#34;Asakusa, Taito&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Senso-ji.jpg&#34; alt=&#34;Senso-ji Temple&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;-meiji-jingu-shrine&#34;&gt;⛩️ Meiji Jingu Shrine&lt;/h3&gt;&#xA;&lt;figure class=&#34;post-figure&#34;&gt;&#xA;    &lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Meiji-Jingu-3.jpg&#34; alt=&#34;Meiji Jingu&#34;loading=&#34;lazy&#34;&#xA;      decoding=&#34;async&#34;&gt;&lt;/figure&gt;&lt;hr&gt;&#xA;&lt;h3 id=&#34;-kyoto&#34;&gt;🏯 Kyoto&lt;/h3&gt;&#xA;&lt;p&gt;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Kiyomizu-dera-Temple-1.jpg&#34; alt=&#34;Kiyomizu-dera Temple&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Kiyomizu-dera-Temple-2.jpg&#34; alt=&#34;Kiyomizu-dera Temple&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Kyoto-National-Museum.jpg&#34; alt=&#34;Kyoto National Museum&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Kyot-Minoyacho.jpg&#34; alt=&#34;Kyoto, Minoyacho&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Kyoto-Hishiyacho.jpg&#34; alt=&#34;Kyoto, Hishiyacho&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Kyoto-Kawabatacho.jpg&#34; alt=&#34;Kyoto, Kawabatacho&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Kyoto-Tennocho.jpg&#34; alt=&#34;Kyoto, Tennocho&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&#xA;&lt;img src=&#34;https://chenjianyong.com/images/gallery/japan/Keyto-Ichinocho.jpg&#34; alt=&#34;Ichinocho, Kyoto&#34;loading=&#34;lazy&#34;&#xA;    decoding=&#34;async&#34;&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>My first English post</title>
      <link>https://chenjianyong.com/blog/2023/my-first-english-post/</link>
      <pubDate>Sat, 01 Apr 2023 00:00:00 +0000</pubDate>
      <guid>https://chenjianyong.com/blog/2023/my-first-english-post/</guid>
      <description>&lt;p&gt;This is my first English post, but won&amp;rsquo;t be the last, I promise &amp;ndash; all future posts will be written in English first from now on (may include an optional Chinese version, if I decide to make this site bilingual). Though my English is not very good yet(especially in terms of oral communication and writing skills), it won&amp;rsquo;t be always this case.&lt;/p&gt;&#xA;&lt;p&gt;I&amp;rsquo;ve thought a lot about it, and it&amp;rsquo;s undeniable that English is the de facto universal language around this world, not Chinese. And the English-speaking world is much more extensive and innovative compared to the Chinese-speaking world for some well-known reasons(at least in my field &amp;ndash; Computer Science, or Technology, many Chinese practitioners are fed with second-hand knowledge), so sad but true. As a person unwilling to be trapped by a single country (yeah, global citizen), I have no choice but to try to acquire English.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Life in Shenzhen</title>
      <link>https://chenjianyong.com/photos/shenzhen/</link>
      <pubDate>Sun, 18 Jul 2021 00:00:00 +0000</pubDate>
      <guid>https://chenjianyong.com/photos/shenzhen/</guid>
      <description>&lt;p&gt;Photographs taken around Shenzhen — from mountain trails to city skylines, parks, and bayside views.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;shenzhen-skyline-during-the-day&#34;&gt;Shenzhen skyline during the day&lt;/h3&gt;&#xA;&lt;figure class=&#34;post-figure&#34;&gt;&#xA;    &lt;img src=&#34;https://chenjianyong.com/images/gallery/shenzhen/shenzhen.jpg&#34; alt=&#34;Shenzhen skyline in daylight&#34;loading=&#34;lazy&#34;&#xA;      decoding=&#34;async&#34;&gt;&lt;/figure&gt;&lt;hr&gt;&#xA;&lt;h3 id=&#34;evening-from-nanshan-peak&#34;&gt;Evening from Nanshan Peak&lt;/h3&gt;&#xA;&lt;figure class=&#34;post-figure&#34;&gt;&#xA;    &lt;img src=&#34;https://chenjianyong.com/images/gallery/shenzhen/shenzhen-night.jpg&#34; alt=&#34;Night view from Nanshan&#34;loading=&#34;lazy&#34;&#xA;      decoding=&#34;async&#34;&gt;&lt;/figure&gt;</description>
    </item>
    <item>
      <title>Scenes from Beijing</title>
      <link>https://chenjianyong.com/photos/beijing/</link>
      <pubDate>Thu, 07 Nov 2019 00:00:00 +0000</pubDate>
      <guid>https://chenjianyong.com/photos/beijing/</guid>
      <description>&lt;p&gt;A collection of photographs from Beijing — from historic landmarks to modern cityscapes.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;shichahai-at-dusk&#34;&gt;Shichahai at dusk&lt;/h3&gt;&#xA;&lt;figure class=&#34;post-figure&#34;&gt;&#xA;    &lt;img src=&#34;https://chenjianyong.com/images/gallery/beijing/shichahai.jpg&#34; alt=&#34;Shichahai at dusk&#34;loading=&#34;lazy&#34;&#xA;      decoding=&#34;async&#34;&gt;&lt;/figure&gt;&lt;hr&gt;&#xA;&lt;h3 id=&#34;tiananmen-square&#34;&gt;Tiananmen Square&lt;/h3&gt;&#xA;&lt;figure class=&#34;post-figure&#34;&gt;&#xA;    &lt;img src=&#34;https://chenjianyong.com/images/gallery/beijing/tiananmen.jpg&#34; alt=&#34;Tiananmen Square&#34;loading=&#34;lazy&#34;&#xA;      decoding=&#34;async&#34;&gt;&lt;/figure&gt;&lt;hr&gt;&#xA;&lt;h3 id=&#34;ruins-of-yuanmingyuan&#34;&gt;Ruins of Yuanmingyuan&lt;/h3&gt;&#xA;&lt;figure class=&#34;post-figure&#34;&gt;&#xA;    &lt;img src=&#34;https://chenjianyong.com/images/gallery/beijing/yuanmingyuan-ruins.jpg&#34; alt=&#34;Ruins of Yuanmingyuan&#34;loading=&#34;lazy&#34;&#xA;      decoding=&#34;async&#34;&gt;&lt;/figure&gt;&lt;hr&gt;&#xA;&lt;h3 id=&#34;zhichunlu-at-night&#34;&gt;Zhichunlu at night&lt;/h3&gt;&#xA;&lt;figure class=&#34;post-figure&#34;&gt;&#xA;    &lt;img src=&#34;https://chenjianyong.com/images/gallery/beijing/zhichunlu-night.jpg&#34; alt=&#34;Zhichunlu night view&#34;loading=&#34;lazy&#34;&#xA;      decoding=&#34;async&#34;&gt;&lt;/figure&gt;&lt;hr&gt;&#xA;&lt;h3 id=&#34;zhichunlu-station&#34;&gt;Zhichunlu Station&lt;/h3&gt;&#xA;&lt;figure class=&#34;post-figure&#34;&gt;&#xA;    &lt;img src=&#34;https://chenjianyong.com/images/gallery/beijing/zhichunlu-station.jpg&#34; alt=&#34;Zhichunlu subway station&#34;loading=&#34;lazy&#34;&#xA;      decoding=&#34;async&#34;&gt;&lt;/figure&gt;</description>
    </item>
  </channel>
</rss>
