<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="/assets/atom.xsl"?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <id>https://blog.shinya.click/en/</id>
  <title>Shinya&apos;s Blog</title>
  <updated>2026-09-20T14:19:56.734+00:00[UTC]</updated>
  <description>A corner of the internet. Shinya&apos;s personal blog on tinkering, projects, notes and daily life — networking and proxies, self-hosted services, Go and systems internals, and things that somehow ate an entire weekend.</description>
  <author>
    <name>shinya</name>
    <email>kobayashi_shinya@outlook.com</email>
    <uri>https://github.com/senshinya</uri>
  </author>
  <link href="https://blog.shinya.click/en/atom.xml" rel="self"></link>
  <link href="https://blog.shinya.click/en/" rel="alternate"></link>
  <language>en-US</language>
  <generator uri="https://github.com/L33Z22L11/blog-v3" version="3.8.0">Clarity</generator>
  <icon>/icons/favicon.png</icon>
  <logo>https://github.com/senshinya.png</logo>
  <rights>© 2026 shinya</rights>
  <subtitle>Someone who writes code</subtitle>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/steamdeck-switch-60fps</id>
    <title>A Second Life for the Steam Deck: Switch Emulation and Frame Generation at 60 FPS</title>
    <updated>2026-09-09T15:59:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/NDPUwc.webp" alt="A Second Life for the Steam Deck: Switch Emulation and Frame Generation at 60 FPS" /> <p>This counts as NTR too, surely.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/steamdeck-switch-60fps" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/steamdeck-switch-60fps"></link>
    <summary>This counts as NTR too, surely.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2026-09-09T15:59:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/xiaomi17-root-and-hide-root</id>
    <title>Making the Xiaomi 17 My Daily Driver: Unlocking, Flashing, Rooting, and Hiding Root</title>
    <updated>2026-08-17T15:59:21Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/qfxB0h.webp" alt="Making the Xiaomi 17 My Daily Driver: Unlocking, Flashing, Rooting, and Hiding Root" /> <p>The more I tinker, the more I want to tinker. Still going strong in my old age, still going strong!</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/xiaomi17-root-and-hide-root" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/xiaomi17-root-and-hide-root"></link>
    <summary>The more I tinker, the more I want to tinker. Still going strong in my old age, still going strong!</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2026-08-17T15:59:21Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/macos-27-apple-intelligence-chatgpt</id>
    <title>Getting Apple Intelligence Working on a China-Market Mac: Region Changes and Extracting ChatGPT</title>
    <updated>2026-06-11T02:00:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/fOFucm.webp" alt="Getting Apple Intelligence Working on a China-Market Mac: Region Changes and Extracting ChatGPT" /> <p>Another WWDC brings new Apple Intelligence features in macOS 27. The workarounds from macOS 26 no longer get through, so the battle of wits with Apple continues.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/macos-27-apple-intelligence-chatgpt" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/macos-27-apple-intelligence-chatgpt"></link>
    <summary>Another WWDC brings new Apple Intelligence features in macOS 27. The workarounds from macOS 26 no longer get through, so the battle of wits with Apple continues.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2026-06-11T02:00:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/one-trek-twenty-stacks</id>
    <title>One TREK, Twenty Stacks</title>
    <updated>2026-05-11T14:43:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/BBdDWW.webp" alt="One TREK, Twenty Stacks" /> <p>I found a trip-planning tool on GitHub Trending and wanted to host my own instance. Since I was getting a new VPS anyway, I might as well install a little extra. Well, quite a lot extra.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/one-trek-twenty-stacks" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/one-trek-twenty-stacks"></link>
    <summary>I found a trip-planning tool on GitHub Trending and wanted to host my own instance. Since I was getting a new VPS anyway, I might as well install a little extra. Well, quite a lot extra.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2026-05-11T14:43:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/msfs2024-joystick-and-pico</id>
    <title>Adventures with Microsoft Flight Simulator 2024</title>
    <updated>2025-12-14T06:31:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/lfhEuE.webp" alt="Adventures with Microsoft Flight Simulator 2024" /> <p>A friend’s comment got me interested in simulation games. After buying Microsoft Flight Simulator, I discovered streamed maps and models, another account login, oddly hidden tutorials, and awkward keyboard controls. A flight stick and some tinkering with Pico VR finally rounded out the experience.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/msfs2024-joystick-and-pico" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/msfs2024-joystick-and-pico"></link>
    <summary>A friend’s comment got me interested in simulation games. After buying Microsoft Flight Simulator, I discovered streamed maps and models, another account login, oddly hidden tutorials, and awkward keyboard controls. A flight stick and some tinkering with Pico VR finally rounded out the experience.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2025-12-14T06:31:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/moontv-vibe-coding</id>
    <title>MoonTV: An Experiment in Vibe Coding</title>
    <updated>2025-07-20T15:32:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/nIeONi.webp" alt="MoonTV: An Experiment in Vibe Coding" /> <p>MoonTV is a new video aggregation platform built with Next.js and React to make following shows convenient. It began as an attempt to improve LibreTV and has attracted substantial attention and usage over several months of development. Cursor made development efficient, although multi-platform support and complex data dependencies posed challenges. As its user base grows, MoonTV continues improving in response to feedback.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/moontv-vibe-coding" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/moontv-vibe-coding"></link>
    <summary>MoonTV is a new video aggregation platform built with Next.js and React to make following shows convenient. It began as an attempt to improve LibreTV and has attracted substantial attention and usage over several months of development. Cursor made development efficient, although multi-platform support and complex data dependencies posed challenges. As its user base grows, MoonTV continues improving in response to feedback.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2025-07-20T15:32:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/macos-26-trial</id>
    <title>Trying Out macOS 26 and iPadOS 26</title>
    <updated>2025-06-10T12:18:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/TPSaLE.webp" alt="Trying Out macOS 26 and iPadOS 26" /> <p>macOS and iPadOS 26 introduce the Liquid Glass design language, refreshing icons and windows with a more modern look. Windowed apps on iPad are a step toward making it a productivity device. The transparent Control Center and the integration of Launchpad have been controversial, however, and the experience still needs work. Despite its shortcomings, this update lays groundwork for a promising future.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/macos-26-trial" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/macos-26-trial"></link>
    <summary>macOS and iPadOS 26 introduce the Liquid Glass design language, refreshing icons and windows with a more modern look. Windowed apps on iPad are a step toward making it a productivity device. The transparent Control Center and the integration of Launchpad have been controversial, however, and the experience still needs work. Despite its shortcomings, this update lays groundwork for a promising future.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2025-06-10T12:18:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/one-month-using-android</id>
    <title>One Month After Switching to Android</title>
    <updated>2025-06-05T15:26:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/19NIhZ.webp" alt="One Month After Switching to Android" /> <p>My frequent phone changes took me from OnePlus to iPhone, and from enjoying tinkering to relying on an ecosystem. At my girlfriend’s suggestion, I recently bought an OPPO Find X8 Ultra to improve my photos. Migrating apps out of Apple’s ecosystem reminded me how uneven Android’s app selection remains and how difficult finding replacements can be. A month of migration has been an exercise in friction and adaptation between platforms.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/one-month-using-android" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/one-month-using-android"></link>
    <summary>My frequent phone changes took me from OnePlus to iPhone, and from enjoying tinkering to relying on an ecosystem. At my girlfriend’s suggestion, I recently bought an OPPO Find X8 Ultra to improve my photos. Migrating apps out of Apple’s ecosystem reminded me how uneven Android’s app selection remains and how difficult finding replacements can be. A month of migration has been an exercise in friction and adaptation between platforms.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2025-06-05T15:26:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/astro-google-tag-manager</id>
    <title>Adding Google Analytics to Astro with Tag Manager</title>
    <updated>2025-05-28T14:09:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/Q0w4RN.webp" alt="Adding Google Analytics to Astro with Tag Manager" /> <p>After moving my blog to Astro, the usual Google Analytics integration no longer fit its performance goals. Adding event-reporting JavaScript directly to the head works, but hurts page performance. I used partytown to move the scripts off the main thread so they would not interfere with loading. With a few adjustments to the example code, Google Analytics finally worked, balancing performance with analytics.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/astro-google-tag-manager" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/astro-google-tag-manager"></link>
    <summary>After moving my blog to Astro, the usual Google Analytics integration no longer fit its performance goals. Adding event-reporting JavaScript directly to the head works, but hurts page performance. I used partytown to move the scripts off the main thread so they would not interfere with loading. With a few adjustments to the example code, Google Analytics finally worked, balancing performance with analytics.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2025-05-28T14:09:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/cross-city-network-setup</id>
    <title>Connecting My Shanghai and Hangzhou Networks</title>
    <updated>2025-04-18T08:43:12Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/O6cAGh.webp" alt="Connecting My Shanghai and Hangzhou Networks" /> <p>My girlfriend moved from Beijing to Shanghai for work, and I helped arrange broadband too. Shanghai Telecom’s 500M connection costs more than a 1000M line in Hangzhou, frustratingly. I set out to connect the two cities’ networks: transparent proxying in Shanghai, selected traffic exiting through Hangzhou, and access between both LANs. Hangzhou already had a simple setup with a software router and an AP, configured to route my everyday traffic home and ready for the next networking adventure.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/cross-city-network-setup" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/cross-city-network-setup"></link>
    <summary>My girlfriend moved from Beijing to Shanghai for work, and I helped arrange broadband too. Shanghai Telecom’s 500M connection costs more than a 1000M line in Hangzhou, frustratingly. I set out to connect the two cities’ networks: transparent proxying in Shanghai, selected traffic exiting through Hangzhou, and access between both LANs. Hangzhou already had a simple setup with a software router and an AP, configured to route my everyday traffic home and ready for the next networking adventure.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2025-04-18T08:43:12Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/heart-rate-to-grafana</id>
    <title>My Heart Beats for U: Visualizing Heart Rate in Grafana</title>
    <updated>2025-03-31T15:51:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/F4qD2T.webp" alt="My Heart Beats for U: Visualizing Heart Rate in Grafana" /> <p>Periodically syncing heart-rate data from Apple Health to a server and visualizing it in Grafana provides an intuitive way to monitor it. Health Auto Export sends the data to an HTTP endpoint through its REST API automation, the server stores it in InfluxDB, and Grafana presents a clear dashboard for tracking and analyzing personal heart-rate changes.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/heart-rate-to-grafana" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/heart-rate-to-grafana"></link>
    <summary>Periodically syncing heart-rate data from Apple Health to a server and visualizing it in Grafana provides an intuitive way to monitor it. Health Auto Export sends the data to an HTTP endpoint through its REST API automation, the server stores it in InfluxDB, and Grafana presents a clear dashboard for tracking and analyzing personal heart-rate changes.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2025-03-31T15:51:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/parser-type-variable-ambiguity</id>
    <title>Resolving Type Name and Variable Name Ambiguity in Parsing</title>
    <updated>2025-03-15T12:35:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/2VKHK9.webp" alt="Resolving Type Name and Variable Name Ambiguity in Parsing" /> <p>Distinguishing user-defined type names from ordinary variables is a challenge during parsing. A statement such as `a*b;` can be either an arithmetic expression or a declaration. Grammar rules, especially those involving type specifiers, can misidentify variables as types, affecting correctness and readability. The prevalence of declarations without initializers makes this ambiguity especially common.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/parser-type-variable-ambiguity" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/parser-type-variable-ambiguity"></link>
    <summary>Distinguishing user-defined type names from ordinary variables is a challenge during parsing. A statement such as `a*b;` can be either an arithmetic expression or a declaration. Grammar rules, especially those involving type specifiers, can misidentify variables as types, affecting correctness and readability. The prevalence of declarations without initializers makes this ambiguity especially common.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2025-03-15T12:35:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/vps-warp-ipv6</id>
    <title>Routing Selected VPS Traffic Through WARP over IPv6</title>
    <updated>2025-03-15T08:24:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/McjrrF.webp" alt="Routing Selected VPS Traffic Through WARP over IPv6" /> <p>A Telegram notification on an ordinary afternoon introduced a tempting VPS deal: a direct China Telecom CN2 route and 2.5G bandwidth. The plan includes IPv6, useful for unlocking streaming services, but not every connection needs to go through WARP. My previous script was convenient, yet its effects on speed and traffic routing called for a more flexible solution.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/vps-warp-ipv6" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/vps-warp-ipv6"></link>
    <summary>A Telegram notification on an ordinary afternoon introduced a tempting VPS deal: a direct China Telecom CN2 route and 2.5G bandwidth. The plan includes IPv6, useful for unlocking streaming services, but not every connection needs to go through WARP. My previous script was convenient, yet its effects on speed and traffic routing called for a more flexible solution.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2025-03-15T08:24:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/vitepress-memos-component</id>
    <title>Adding a Microblog to VitePress</title>
    <updated>2025-01-29T13:58:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/hZX6hr.webp" alt="Adding a Microblog to VitePress" /> <p>A microblog lets you share short thoughts whenever they occur, without the overhead of publishing a full static-blog post. This implementation uses Cloudflare Workers for the backend and KV for storage and management. A Vue component embedded in VitePress displays the updates, adding a lively, interactive element to the blog.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/vitepress-memos-component" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/vitepress-memos-component"></link>
    <summary>A microblog lets you share short thoughts whenever they occur, without the overhead of publishing a full static-blog post. This implementation uses Cloudflare Workers for the backend and KV for storage and management. A Vue component embedded in VitePress displays the updates, adding a lively, interactive element to the blog.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2025-01-29T13:58:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/opnsense-transparent-proxy</id>
    <title>Transparent Proxying and Traffic Routing with OPNsense</title>
    <updated>2025-01-16T15:09:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/xA8C1E.webp" alt="Transparent Proxying and Traffic Routing with OPNsense" /> <p>OPNsense is an open-source firewall and router with an attractive interface and a comprehensive feature set. After trying several routing setups, I came to appreciate its potential for transparent proxying and traffic routing. Combining it with BGP-based routing offers better security and stability, while its automatically updated IP lists make network management more convenient.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/opnsense-transparent-proxy" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/opnsense-transparent-proxy"></link>
    <summary>OPNsense is an open-source firewall and router with an attractive interface and a comprehensive feature set. After trying several routing setups, I came to appreciate its potential for transparent proxying and traffic routing. Combining it with BGP-based routing offers better security and stability, while its automatically updated IP lists make network management more convenient.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2025-01-16T15:09:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/more-accurate-chnroute</id>
    <title>More Accurate Routing for Chinese and Overseas IPs with BGP</title>
    <updated>2024-10-07T08:51:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/MOmM1s.webp" alt="More Accurate Routing for Chinese and Overseas IPs with BGP" /> <p>BGP-based routing for Chinese and overseas IPs makes transparent proxying more efficient and accurate. Marking overseas destinations with FakeIP lets the main router route traffic more intelligently for smoother connectivity. The sing-box DNS configuration is also refined to handle queries more flexibly and efficiently, improving the overall network experience.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/more-accurate-chnroute" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/more-accurate-chnroute"></link>
    <summary>BGP-based routing for Chinese and overseas IPs makes transparent proxying more efficient and accurate. Marking overseas destinations with FakeIP lets the main router route traffic more intelligently for smoother connectivity. The sing-box DNS configuration is also refined to handle queries more flexibly and efficiently, improving the overall network experience.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2024-10-07T08:51:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/daily/work-for-3-years</id>
    <title>Working at ByteDance for Three Years and Staying Somewhat Sane Is Not Entirely Impossible</title>
    <updated>2024-09-28T08:26:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/hnCaht.webp" alt="Working at ByteDance for Three Years and Staying Somewhat Sane Is Not Entirely Impossible" /> <p>Three years at ByteDance have made time feel strangely accelerated. Amid the changes, I have still managed to hold on to some mental balance. Looking back at the new graduate gazing at distant mountains from the balcony of our Hangzhou office, I can trace how curiosity, workplace challenges, and shifting expectations taught me to find a rhythm of my own.</p> <a class="view-full" href="https://blog.shinya.click/en/daily/work-for-3-years" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/daily/work-for-3-years"></link>
    <summary>Three years at ByteDance have made time feel strangely accelerated. Amid the changes, I have still managed to hold on to some mental balance. Looking back at the new graduate gazing at distant mountains from the balcony of our Hangzhou office, I can trace how curiosity, workplace challenges, and shifting expectations taught me to find a rhythm of my own.</summary>
    <category term="daily" label="Daily"></category>
    <published>2024-09-28T08:26:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/daily/anti-chronic-gastritis</id>
    <title>My Journey with Chronic Gastritis</title>
    <updated>2024-09-01T14:03:10Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/0Hr9l5.webp" alt="My Journey with Chronic Gastritis" /> <p>Chronic gastritis has been a long, uneven journey: stomach trouble throughout childhood, a surprising reprieve at university, then a return of symptoms after years of late nights and drinking. Frequent nausea and reflux eventually became too much to live with. After repeated examinations and some reflection, I finally began taking the recovery process seriously.</p> <a class="view-full" href="https://blog.shinya.click/en/daily/anti-chronic-gastritis" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/daily/anti-chronic-gastritis"></link>
    <summary>Chronic gastritis has been a long, uneven journey: stomach trouble throughout childhood, a surprising reprieve at university, then a return of symptoms after years of late nights and drinking. Frequent nausea and reflux eventually became too much to live with. After repeated examinations and some reflection, I finally began taking the recovery process seriously.</summary>
    <category term="daily" label="Daily"></category>
    <published>2024-09-01T14:03:10Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/fake-ip-based-transparent-proxy</id>
    <title>Routing Transparent Proxy Traffic with FakeIP</title>
    <updated>2024-08-16T15:53:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/S2HHD5.webp" alt="Routing Transparent Proxy Traffic with FakeIP" /> <p>This FakeIP-based transparent proxy design addresses the single point of failure, poor performance, and awkward port forwarding of a traditional side router. Switching to the sing-box proxy core improves forwarding performance and simplifies configuration, with broader protocol support and better optimization than the previous Clash setup. Clash can implement the same design, but sing-box provides a flexible alternative.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/fake-ip-based-transparent-proxy" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/fake-ip-based-transparent-proxy"></link>
    <summary>This FakeIP-based transparent proxy design addresses the single point of failure, poor performance, and awkward port forwarding of a traditional side router. Switching to the sing-box proxy core improves forwarding performance and simplifies configuration, with broader protocol support and better optimization than the previous Clash setup. Clash can implement the same design, but sing-box provides a flexible alternative.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2024-08-16T15:53:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/fix-port-forward-in-bypass-router</id>
    <title>Fixing Port Forwarding with a Side Router</title>
    <updated>2024-08-15T15:50:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/mRqws9.webp" alt="Fixing Port Forwarding with a Side Router" /> <p>Port forwarding on the main router often stops working when a side router is introduced. Setting the side router as the gateway changes the forwarding path, breaking mappings that previously relied on the main router. A gateway translates addresses and forwards traffic from the internal network to the outside, and each internal device needs one to communicate externally. Understanding this mechanism helps explain how to fix the forwarding problem.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/fix-port-forward-in-bypass-router" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/fix-port-forward-in-bypass-router"></link>
    <summary>Port forwarding on the main router often stops working when a side router is introduced. Setting the side router as the gateway changes the forwarding path, breaking mappings that previously relied on the main router. A gateway translates addresses and forwards traffic from the internal network to the outside, and each internal device needs one to communicate externally. Understanding this mechanism helps explain how to fix the forwarding problem.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2024-08-15T15:50:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/debian-as-bypass-router</id>
    <title>Using Debian as a Side Router</title>
    <updated>2024-07-13T09:49:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/pPRU5x.webp" alt="Using Debian as a Side Router" /> <p>Using Debian as a side router offers a more stable and flexible alternative without depending on OpenWrt and LuCI. Configuring Debian directly gives you greater control over the system and avoids the limitations and instability of a GUI. Compared with common side-router setups, this approach makes transparent proxying more reliable and offers another option for those who value performance and efficiency.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/debian-as-bypass-router" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/debian-as-bypass-router"></link>
    <summary>Using Debian as a side router offers a more stable and flexible alternative without depending on OpenWrt and LuCI. Configuring Debian directly gives you greater control over the system and avoids the limitations and instability of a GUI. Compared with common side-router setups, this approach makes transparent proxying more reliable and offers another option for those who value performance and efficiency.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2024-07-13T09:49:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/tech-about-gfw</id>
    <title>How the Great Firewall Works</title>
    <updated>2024-06-23T07:31:32Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/sOpJuL.webp" alt="How the Great Firewall Works" /> <p>The GFW does more than monitor an exit gateway: it inspects international traffic through passive taps, copying inbound and outbound IP packets to a cluster for analysis and filtering. Understanding where and how this happens matters when studying censorship circumvention. Examining the GFW’s network topology helps explain its blocking mechanisms and how to work around them.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/tech-about-gfw" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/tech-about-gfw"></link>
    <summary>The GFW does more than monitor an exit gateway: it inspects international traffic through passive taps, copying inbound and outbound IP packets to a cluster for analysis and filtering. Understanding where and how this happens matters when studying censorship circumvention. Examining the GFW’s network topology helps explain its blocking mechanisms and how to work around them.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2024-06-23T07:31:32Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/daily/plan2024</id>
    <title>My Learning Plan for 2024</title>
    <updated>2024-01-03T18:06:51Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/V3rSQC.webp" alt="My Learning Plan for 2024" /> <p>My learning goals for 2024: reach N2 in Japanese, finish SICP and TAPL, build a kernel with full POSIX support, and update the blog theme. A challenging list, but a clear direction for the year.</p> <a class="view-full" href="https://blog.shinya.click/en/daily/plan2024" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/daily/plan2024"></link>
    <summary>My learning goals for 2024: reach N2 in Japanese, finish SICP and TAPL, build a kernel with full POSIX support, and update the blog theme. A challenging list, but a clear direction for the year.</summary>
    <category term="daily" label="Daily"></category>
    <published>2024-01-03T18:06:51Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/spike-install</id>
    <title>Installing the RISC-V Toolchain and Emulator</title>
    <updated>2023-05-24T09:51:09Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/rWNOKx.webp" alt="Installing the RISC-V Toolchain and Emulator" /> <p>To install the RISC-V toolchain, first obtain the riscv-gnu-toolchain source. Using `--depth=1` when cloning reduces the download size. Check the README’s Prerequisites section and install the required dependencies. On Debian, a simple package installation command prepares the environment for building the toolchain.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/spike-install" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/spike-install"></link>
    <summary>To install the RISC-V toolchain, first obtain the riscv-gnu-toolchain source. Using `--depth=1` when cloning reduces the download size. Check the README’s Prerequisites section and install the required dependencies. On Debian, a simple package installation command prepares the environment for building the toolchain.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2023-05-24T09:51:09Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/chitchat-about-programming-language</id>
    <title>Some Thoughts on Programming Languages</title>
    <updated>2023-04-08T05:16:36Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/uO420B.webp" alt="Some Thoughts on Programming Languages" /> <p>Designing a new programming language is challenging and fun. Setting aside complicated compiler theory and implementation details to focus on where code runs helps clarify how languages are built. Starting from the RISC-VI instruction set, this discussion explores the underlying architecture, layered computer systems, and virtual-machine model, reflecting on the nature of programming languages as well as their implementation.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/chitchat-about-programming-language" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/chitchat-about-programming-language"></link>
    <summary>Designing a new programming language is challenging and fun. Setting aside complicated compiler theory and implementation details to focus on where code runs helps clarify how languages are built. Starting from the RISC-VI instruction set, this discussion explores the underlying architecture, layered computer systems, and virtual-machine model, reflecting on the nature of programming languages as well as their implementation.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2023-04-08T05:16:36Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/go-os</id>
    <title>A Project That Failed: Seven Not-So-Happy Days over Chinese New Year</title>
    <updated>2023-02-02T15:24:55Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/xB1Ni5.webp" alt="A Project That Failed: Seven Not-So-Happy Days over Chinese New Year" /> <p>Inspiration struck during Chinese New Year: an article read on the train about running Go on bare metal sparked an interest in low-level system interfaces. Its successful implementation suggested exciting possibilities for combining a high-level language with an OS. Further research revealed earlier work on the idea, and that growing enthusiasm became a project full of anticipation that ultimately did not work out.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/go-os" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/go-os"></link>
    <summary>Inspiration struck during Chinese New Year: an article read on the train about running Go on bare metal sparked an interest in low-level system interfaces. Its successful implementation suggested exciting possibilities for combining a high-level language with an OS. Further research revealed earlier work on the idea, and that growing enthusiasm became a project full of anticipation that ultimately did not work out.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2023-02-02T15:24:55Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/notes/65840/raftlab2a</id>
    <title>6.5840 Lab 2A: Leader Election</title>
    <updated>2022-12-15T18:06:10Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/c11Uk4.webp" alt="6.5840 Lab 2A: Leader Election" /> <p>Lab 2A focuses on implementing Raft leader election and heartbeats so that elections and term changes work correctly even under extreme conditions. The lab has four stages and lays the foundation for the distributed key-value store that follows. A design without explicit locks simplifies the Raft struct. The lab instructions provide the necessary background, but compared with the previous lab, this one relies on almost no reference material and places greater emphasis on implementing the system independently.</p> <a class="view-full" href="https://blog.shinya.click/en/notes/65840/raftlab2a" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/notes/65840/raftlab2a"></link>
    <summary>Lab 2A focuses on implementing Raft leader election and heartbeats so that elections and term changes work correctly even under extreme conditions. The lab has four stages and lays the foundation for the distributed key-value store that follows. A design without explicit locks simplifies the Raft struct. The lab instructions provide the necessary background, but compared with the previous lab, this one relies on almost no reference material and places greater emphasis on implementing the system independently.</summary>
    <category term="notes" label="Notes"></category>
    <published>2022-12-15T18:06:10Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/notes/65840/reftextendedpaper</id>
    <title>Reading the Raft Paper</title>
    <updated>2022-12-03T13:40:09Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/7mmvIZ.webp" alt="Reading the Raft Paper" /> <p>Raft is a consensus algorithm designed to improve the efficiency of log replication. It is particularly suited to clusters of machines, allowing them to keep providing service even when some machines fail. It uses the replicated state machine model: logs record the order of commands so that every machine in the cluster can reach the same state. In Search of an Understandable Consensus Algorithm explores Raft’s design and compares it with Paxos, highlighting its understandability and providing a foundation for building reliable large-scale software systems. These reading notes aim to help explain the paper’s core concepts and their applications.</p> <a class="view-full" href="https://blog.shinya.click/en/notes/65840/reftextendedpaper" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/notes/65840/reftextendedpaper"></link>
    <summary>Raft is a consensus algorithm designed to improve the efficiency of log replication. It is particularly suited to clusters of machines, allowing them to keep providing service even when some machines fail. It uses the replicated state machine model: logs record the order of commands so that every machine in the cluster can reach the same state. In Search of an Understandable Consensus Algorithm explores Raft’s design and compares it with Paxos, highlighting its understandability and providing a foundation for building reliable large-scale software systems. These reading notes aim to help explain the paper’s core concepts and their applications.</summary>
    <category term="notes" label="Notes"></category>
    <published>2022-12-03T13:40:09Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/golang-deepcopy-between-different-type</id>
    <title>Deep Copying Between Different Struct Types in Go</title>
    <updated>2022-08-14T17:05:01Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/Blhm0I.webp" alt="Deep Copying Between Different Struct Types in Go" /> <p>While refactoring a system, converting entities between layers made deep copying surprisingly awkward. A product VO in the view layer, an entity in the domain layer, and a PO in the persistence layer can look nearly identical, yet small type differences complicate direct conversion. I used reflection to build a general conversion method, reducing repetitive assembler methods and making the code more maintainable and flexible.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/golang-deepcopy-between-different-type" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/golang-deepcopy-between-different-type"></link>
    <summary>While refactoring a system, converting entities between layers made deep copying surprisingly awkward. A product VO in the view layer, an entity in the domain layer, and a PO in the persistence layer can look nearly identical, yet small type differences complicate direct conversion. I used reflection to build a general conversion method, reducing repetitive assembler methods and making the code more maintainable and flexible.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2022-08-14T17:05:01Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/this-in-javac-string-concat</id>
    <title>How Java’s this Keyword Can Prevent Compile-Time Constant Propagation</title>
    <updated>2022-04-15T16:01:28Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/gKtkYe.webp" alt="How Java’s this Keyword Can Prevent Compile-Time Constant Propagation" /> <p>In Java, using `this` can prevent the compiler from optimizing constants. Although `ab1` and `ab2` in this example appear to refer to the same static final variable `s`, comparing them produces different results. `ab1` concatenates a direct reference to the static variable, while `ab2` accesses it through `this`, preventing the same constant propagation optimization. This illustrates how a small syntactic difference can change compilation behavior.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/this-in-javac-string-concat" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/this-in-javac-string-concat"></link>
    <summary>In Java, using `this` can prevent the compiler from optimizing constants. Although `ab1` and `ab2` in this example appear to refer to the same static final variable `s`, comparing them produces different results. `ab1` concatenates a direct reference to the static variable, while `ab2` accesses it through `this`, preventing the same constant propagation optimization. This illustrates how a small syntactic difference can change compilation behavior.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2022-04-15T16:01:28Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/daily/people-in-three-body</id>
    <title>The “Majority” in The Three-Body Problem</title>
    <updated>2022-04-10T16:13:13Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/LTzbFP.webp" alt="The “Majority” in The Three-Body Problem" /> <p>In The Three-Body Problem, Liu Cixin uses an immense historical canvas to explore the relationship between individuals and the collective. His doubts about Western democracy and the majority’s ability to determine its own fate run through the trilogy. Heroes struggle and sacrifice, only to see their work swept aside by history. Beginning with the Cultural Revolution, the story sets up a conflict between exceptional individuals and the ordinary masses, raising uncomfortable questions about humanity and society.</p> <a class="view-full" href="https://blog.shinya.click/en/daily/people-in-three-body" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/daily/people-in-three-body"></link>
    <summary>In The Three-Body Problem, Liu Cixin uses an immense historical canvas to explore the relationship between individuals and the collective. His doubts about Western democracy and the majority’s ability to determine its own fate run through the trilogy. Heroes struggle and sacrifice, only to see their work swept aside by history. Beginning with the Cultural Revolution, the story sets up a conflict between exceptional individuals and the ordinary masses, raising uncomfortable questions about humanity and society.</summary>
    <category term="daily" label="Daily"></category>
    <published>2022-04-10T16:13:13Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/notes/65840/mapreducelab</id>
    <title>6.5840 Lab 1: MapReduce</title>
    <updated>2022-01-20T14:29:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/ibVwPJ.webp" alt="6.5840 Lab 1: MapReduce" /> <p>Lab 1 asks us to implement a MapReduce system with two core components: a master and workers. This requires a good command of Go RPC and concurrent programming, along with a thorough understanding of the MapReduce workflow. I built two versions, starting with mutex locks and then moving to a more elegant channel-based implementation without explicit locks, whose design is simpler and clearer. The key to understanding the lab is to read the relevant documentation carefully, especially the flowcharts and explanations.</p> <a class="view-full" href="https://blog.shinya.click/en/notes/65840/mapreducelab" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/notes/65840/mapreducelab"></link>
    <summary>Lab 1 asks us to implement a MapReduce system with two core components: a master and workers. This requires a good command of Go RPC and concurrent programming, along with a thorough understanding of the MapReduce workflow. I built two versions, starting with mutex locks and then moving to a more elegant channel-based implementation without explicit locks, whose design is simpler and clearer. The key to understanding the lab is to read the relevant documentation carefully, especially the flowcharts and explanations.</summary>
    <category term="notes" label="Notes"></category>
    <published>2022-01-20T14:29:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/notes/65840/mapreducepaper</id>
    <title>Reading the MapReduce Paper</title>
    <updated>2022-01-16T09:32:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/ApIDdC.webp" alt="Reading the MapReduce Paper" /> <p>MapReduce is an efficient parallel computing model designed to simplify processing large datasets. By defining the two key functions, Map and Reduce, users can break complex tasks into simple operations. The framework automatically handles data distribution and task scheduling, allowing developers to focus on the algorithm rather than low-level details. Its widespread use in distributed systems demonstrates its flexibility and practical value.</p> <a class="view-full" href="https://blog.shinya.click/en/notes/65840/mapreducepaper" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/notes/65840/mapreducepaper"></link>
    <summary>MapReduce is an efficient parallel computing model designed to simplify processing large datasets. By defining the two key functions, Map and Reduce, users can break complex tasks into simple operations. The framework automatically handles data distribution and task scheduling, allowing developers to focus on the algorithm rather than low-level details. Its widespread use in distributed systems demonstrates its flexibility and practical value.</summary>
    <category term="notes" label="Notes"></category>
    <published>2022-01-16T09:32:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/fiddling/csapplab0</id>
    <title>Setting Up the CSAPP Lab Environment</title>
    <updated>2021-12-26T16:09:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/vqOC7N.webp" alt="Setting Up the CSAPP Lab Environment" /> <p>The labs are an essential part of learning CSAPP, but setting up Linux can be discouraging. Virtual machines bring installation errors, compatibility problems, and broken networking. WSL (Windows Subsystem for Linux), especially on Windows 10 version 2004 and later, provides a simpler, more direct Linux environment without the complexity and performance bottlenecks of a traditional VM.</p> <a class="view-full" href="https://blog.shinya.click/en/fiddling/csapplab0" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/fiddling/csapplab0"></link>
    <summary>The labs are an essential part of learning CSAPP, but setting up Linux can be discouraging. Virtual machines bring installation errors, compatibility problems, and broken networking. WSL (Windows Subsystem for Linux), especially on Windows 10 version 2004 and later, provides a simpler, more direct Linux environment without the complexity and performance bottlenecks of a traditional VM.</summary>
    <category term="fiddling" label="Tinkering"></category>
    <published>2021-12-26T16:09:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/projects/mydb/mydb10</id>
    <title>MYDB 10. Implementing the Server, Client, and Wire Protocol</title>
    <updated>2021-12-25T10:26:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/PAHrUZ.webp" alt="MYDB 10. Implementing the Server, Client, and Wire Protocol" /> <p>MYDB uses a client/server architecture similar to MySQL, allowing multiple clients to connect to a server over sockets, execute SQL queries, and receive results. Communication uses a special binary format, though plain text would also be an option for a simpler implementation. The basic transport structure supports effective communication and processing between client and server.</p> <a class="view-full" href="https://blog.shinya.click/en/projects/mydb/mydb10" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/projects/mydb/mydb10"></link>
    <summary>MYDB uses a client/server architecture similar to MySQL, allowing multiple clients to connect to a server over sockets, execute SQL queries, and receive results. Communication uses a special binary format, though plain text would also be an option for a simpler implementation. The basic transport structure supports effective communication and processing between client and server.</summary>
    <category term="projects" label="Projects"></category>
    <published>2021-12-25T10:26:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/projects/mydb/mydb9</id>
    <title>MYDB 9. Field and Table Management</title>
    <updated>2021-12-25T07:44:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/zOMyv5.webp" alt="MYDB 9. Field and Table Management" /> <p>The Table Manager (TBM) manages field and table structures. Parser turns SQL-like statements into structured representations, wrapping their information in the corresponding classes to simplify subsequent operations. This chapter also covers MYDB’s SQL syntax as a foundation for understanding the management process.</p> <a class="view-full" href="https://blog.shinya.click/en/projects/mydb/mydb9" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/projects/mydb/mydb9"></link>
    <summary>The Table Manager (TBM) manages field and table structures. Parser turns SQL-like statements into structured representations, wrapping their information in the corresponding classes to simplify subsequent operations. This chapter also covers MYDB’s SQL syntax as a foundation for understanding the management process.</summary>
    <category term="projects" label="Projects"></category>
    <published>2021-12-25T07:44:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/projects/mydb/mydb8</id>
    <title>MYDB 8. Index Management</title>
    <updated>2021-12-24T13:01:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/f92X4o.webp" alt="MYDB 8. Index Management" /> <p>MYDB implements a clustered index using a B+ tree. IM interacts directly with the Data Manager (DM), bypassing the Version Manager (VM), so index data is written directly to the database file. This chapter details the binary-tree index structure and its basic node fields, including the leaf flag, key count, and sibling identifier, establishing the framework for indexed lookups.</p> <a class="view-full" href="https://blog.shinya.click/en/projects/mydb/mydb8" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/projects/mydb/mydb8"></link>
    <summary>MYDB implements a clustered index using a B+ tree. IM interacts directly with the Data Manager (DM), bypassing the Version Manager (VM), so index data is written directly to the database file. This chapter details the binary-tree index structure and its basic node fields, including the leaf flag, key count, and sibling identifier, establishing the framework for indexed lookups.</summary>
    <category term="projects" label="Projects"></category>
    <published>2021-12-24T13:01:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/projects/mydb/mydb7</id>
    <title>MYDB 7. Deadlock Detection and the Version Manager</title>
    <updated>2021-12-23T13:20:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/BF3yDW.webp" alt="MYDB 7. Deadlock Detection and the Version Manager" /> <p>VM must handle version skipping introduced by MVCC as well as deadlocks. By simply marking a transaction, MYDB can cancel or roll it back and keep data from aborted transactions from affecting others. This design makes concurrent transaction handling more efficient and reliable, avoids the deadlock risks common with traditional 2PL, and improves overall stability and performance.</p> <a class="view-full" href="https://blog.shinya.click/en/projects/mydb/mydb7" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/projects/mydb/mydb7"></link>
    <summary>VM must handle version skipping introduced by MVCC as well as deadlocks. By simply marking a transaction, MYDB can cancel or roll it back and keep data from aborted transactions from affecting others. This design makes concurrent transaction handling more efficient and reliable, avoids the deadlock risks common with traditional 2PL, and improves overall stability and performance.</summary>
    <category term="projects" label="Projects"></category>
    <published>2021-12-23T13:20:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/projects/mydb/mydb6</id>
    <title>MYDB 6. Record Versions and Transaction Isolation</title>
    <updated>2021-12-18T06:58:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/8YzotA.webp" alt="MYDB 6. Record Versions and Transaction Isolation" /> <p>VM uses two-phase locking to ensure serializable schedules and introduces multiversion concurrency control (MVCC) to eliminate blocking between reads and writes. This chapter also defines conflicts between database operations, focusing on the interaction between updates and reads as a foundation for understanding transaction isolation levels.</p> <a class="view-full" href="https://blog.shinya.click/en/projects/mydb/mydb6" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/projects/mydb/mydb6"></link>
    <summary>VM uses two-phase locking to ensure serializable schedules and introduces multiversion concurrency control (MVCC) to eliminate blocking between reads and writes. This chapter also defines conflicts between database operations, focusing on the interaction between updates and reads as a foundation for understanding transaction isolation levels.</summary>
    <category term="projects" label="Projects"></category>
    <published>2021-12-18T06:58:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/projects/mydb/mydb5</id>
    <title>MYDB 5. The Page Index and the Data Manager</title>
    <updated>2021-12-11T07:16:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/22PSG1.webp" alt="MYDB 5. The Page Index and the Data Manager" /> <p>The page index is an important part of DM, optimizing insertions by caching the free space available on each page. It lets higher-level modules quickly locate a suitable page without a lengthy search, making data operations more efficient. Its implementation works closely with the DataItem abstraction to support efficient database operation.</p> <a class="view-full" href="https://blog.shinya.click/en/projects/mydb/mydb5" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/projects/mydb/mydb5"></link>
    <summary>The page index is an important part of DM, optimizing insertions by caching the free space available on each page. It lets higher-level modules quickly locate a suitable page without a lengthy search, making data operations more efficient. Its implementation works closely with the DataItem abstraction to support efficient database operation.</summary>
    <category term="projects" label="Projects"></category>
    <published>2021-12-11T07:16:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/projects/mydb/mydb4</id>
    <title>MYDB 4. Log Files and Recovery Strategies</title>
    <updated>2021-12-08T14:55:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/TRcbsj.webp" alt="MYDB 4. Log Files and Recovery Strategies" /> <p>Log files are essential to MYDB’s design, allowing data to be recovered after a crash. DM logs every operation on underlying data, forming a continuous sequence of records. Stored in a specific binary format with checksums and individual operation records, these logs let the database accurately reconstruct its data on restart and maintain consistency and integrity.</p> <a class="view-full" href="https://blog.shinya.click/en/projects/mydb/mydb4" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/projects/mydb/mydb4"></link>
    <summary>Log files are essential to MYDB’s design, allowing data to be recovered after a crash. DM logs every operation on underlying data, forming a continuous sequence of records. Stored in a specific binary format with checksums and individual operation records, these logs let the database accurately reconstruct its data on restart and maintain consistency and integrity.</summary>
    <category term="projects" label="Projects"></category>
    <published>2021-12-08T14:55:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/projects/mydb/mydb3</id>
    <title>MYDB 3. Caching and Managing Data Pages</title>
    <updated>2021-12-05T07:28:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/jlFC4E.webp" alt="MYDB 3. Caching and Managing Data Pages" /> <p>DM abstracts the filesystem into pages and uses them as the unit of reading, writing, and caching. The default page size is 8K, with larger pages available to improve write performance under heavy loads. With the general-purpose cache framework already in place, we now define the page structure and implement efficient page caching.</p> <a class="view-full" href="https://blog.shinya.click/en/projects/mydb/mydb3" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/projects/mydb/mydb3"></link>
    <summary>DM abstracts the filesystem into pages and uses them as the unit of reading, writing, and caching. The default page size is 8K, with larger pages available to improve write performance under heavy loads. With the general-purpose cache framework already in place, we now define the page structure and implement efficient page caching.</summary>
    <category term="projects" label="Projects"></category>
    <published>2021-12-05T07:28:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/projects/mydb/mydb2</id>
    <title>MYDB 2. A Reference-Counted Cache Framework and Shared Byte Arrays</title>
    <updated>2021-11-30T15:18:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/WdIGoG.webp" alt="MYDB 2. A Reference-Counted Cache Framework and Shared Byte Arrays" /> <p>The Data Manager (DM) bridges higher-level modules and the filesystem, handling paging and caching while ensuring data safety and recovery. Its cache uses reference counting rather than traditional LRU, aiming for a reusable, efficient foundation for subsequent data operations.</p> <a class="view-full" href="https://blog.shinya.click/en/projects/mydb/mydb2" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/projects/mydb/mydb2"></link>
    <summary>The Data Manager (DM) bridges higher-level modules and the filesystem, handling paging and caching while ensuring data safety and recovery. Its cache uses reference counting rather than traditional LRU, aiming for a reusable, efficient foundation for subsequent data operations.</summary>
    <category term="projects" label="Projects"></category>
    <published>2021-11-30T15:18:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/projects/mydb/mydb1</id>
    <title>MYDB 1. Starting with the Transaction Manager</title>
    <updated>2021-11-28T08:10:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/H4zZAK.webp" alt="MYDB 1. Starting with the Transaction Manager" /> <p>MYDB manages transactions through an XID file. Each transaction has a unique XID, incrementing from 1; XID 0 denotes a super transaction whose state is always committed. TransactionManager maintains this file and records three states: active, committed, and aborted. This mechanism supports accurate transaction state queries and management, providing a foundation for system stability and reliability.</p> <a class="view-full" href="https://blog.shinya.click/en/projects/mydb/mydb1" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/projects/mydb/mydb1"></link>
    <summary>MYDB manages transactions through an XID file. Each transaction has a unique XID, incrementing from 1; XID 0 denotes a super transaction whose state is always committed. TransactionManager maintains this file and records three states: active, committed, and aborted. This mechanism supports accurate transaction state queries and management, providing a foundation for system stability and reliability.</summary>
    <category term="projects" label="Projects"></category>
    <published>2021-11-28T08:10:00Z</published>
  </entry>
  <entry>
    <id>https://blog.shinya.click/en/projects/mydb/mydb0</id>
    <title>MYDB 0. Project Structure and a Few Things I Had to Say</title>
    <updated>2021-11-27T06:43:00Z</updated>
    <author>
      <name>shinya</name>
    </author>
    <content type="html">
      <![CDATA[<img src="https://blog-img.774352199.xyz/xfci2J.webp" alt="MYDB 0. Project Structure and a Few Things I Had to Say" /> <p>MYDB is a personal project exploring and implementing the fundamentals of databases, built in my spare time over a little more than half a month. I picked up some basic knowledge in my university database systems course, though during my internship I mostly used the classes as an excuse to slack off. My candid answers in an interview did not cause too much trouble, but they did make me reconsider what I knew about databases and decide to learn through hands-on practice. That was how this project began.</p> <a class="view-full" href="https://blog.shinya.click/en/projects/mydb/mydb0" target="_blank">Read the full post</a>]]>
    </content>
    <link href="https://blog.shinya.click/en/projects/mydb/mydb0"></link>
    <summary>MYDB is a personal project exploring and implementing the fundamentals of databases, built in my spare time over a little more than half a month. I picked up some basic knowledge in my university database systems course, though during my internship I mostly used the classes as an excuse to slack off. My candid answers in an interview did not cause too much trouble, but they did make me reconsider what I knew about databases and decide to learn through hands-on practice. That was how this project began.</summary>
    <category term="projects" label="Projects"></category>
    <published>2021-11-27T06:43:00Z</published>
  </entry>
</feed>
