<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>jmespath — Observations with Alecks</title>
    <link>https://write.agates.io/tag:jmespath</link>
    <description>a different perspective</description>
    <pubDate>Tue, 24 Nov 2026 00:24:22 +0000</pubDate>
    <item>
      <title>Podcasting 2.0 – The Last Mile</title>
      <link>https://write.agates.io/podcasting-2-0-the-last-mile?pk_campaign=rss-feed</link>
      <description>RSS Delivery No one likes polling. Ever since the dawn of the open RSS ecosystem, applications poll RSS feeds. That&#39;s how it works, right...</description>
      <content:encoded><![CDATA[<h2 id="rss-delivery">RSS Delivery</h2>

<p>No one likes <a href="https://en.wikipedia.org/wiki/Polling_(computer_science)">polling</a>.</p>

<p>Ever since the dawn of the open RSS ecosystem, applications poll RSS feeds.  That&#39;s how it works, right?  They check a feed for updates on some kind of schedule.  Maybe, if they feel like tackling an <a href="https://stackoverflow.com/a/1732454/4875332">unsolvable problem</a> out of sheer curiosity, they add some learning algorithm to figure out when the feed actually changes to save resources.</p>

<p>Polling, most of which is done in regular intervals, is the most reliable method of knowing when a feed is updated <em>within a decentralized ecosystem no one controls</em>.  Even today this is how most RSS feed aggregation runs because it&#39;s the only way to avoid missing anything.  This isn&#39;t a problem in its own right, but it&#39;s inefficient.</p>

<p>It becomes an issue when:</p>
<ol><li>A feed gets extremely popular, which can easily cause unwanted bandwidth costs or even take down smaller operations.</li>
<li>A single host manages a significant amount of RSS feeds.  They add up!</li>
<li>Time-sensitive content is released.  Say one wants to publish a breaking news story or a live steam.  Polling will catch it late, and increased polling frequencies are frowned upon (often rate-limited) due to the above issues.</li></ol>

<p>Until now, users and services have often relied on other options for updates, particularly for time-sensitive content:</p>
<ol><li>Outside systems like social media have always offered a means to notify users of updates, but it&#39;s not a great user experience for anyone.  This helps #3, but still requires polling.  Often it causes <strong>more</strong> polling with the user refreshing rapidly.</li>
<li>Centralized systems, usually implemented by podcast services as back-ends for client applications — <em>especially on mobile</em> — offer a way to hide polling from users.  It helps #1 &amp; #2, and works, but it&#39;s still polling and hiding this from users can cause confusion.</li>
<li>Otherwise entirely closed systems with their own notifications (YouTube, Twitch ... the list goes on).  These usually solve the issues for users, but it&#39;s no longer open!  I&#39;m not going to discuss the philosophical implications of closed systems, but they <strong>still</strong> get real time updates wrong, because <em>real time updates are hard</em>.</li></ol>

<h2 id="what-about-websub">What about WebSub?</h2>

<p>Yes, WebSub helps with some of the above issues.  It has two main problems:</p>
<ol><li>WebSub attempts to move the problem from polling feeds to maintaining WebSub subscriptions.  It&#39;s great in theory.  In practice it&#39;s just another problem to solve and it&#39;s ultimately just another unreliable link in the chain.  Applications frequently fall back to polling.</li>
<li>WebSub <em>requires a server to obtain updates</em>.  This isn&#39;t an issue for podcast applications that run their own services, but what about standalone applications as intended by the spirit of open RSS?  <strong>What about the last mile?</strong>  Standalone applications still end up polling, and especially get left out of time-sensitive content.</li></ol>

<h2 id="the-last-mile">The Last Mile</h2>

<p>The last mile is a relatively new problem within the scope of the open RSS ecosystem.  Every application used to poll for content.  Live streams, outside of obscure internet radio, didn&#39;t even exist or weren&#39;t widespread enough to be relevant.</p>

<p>Fast forward to today, most podcast applications run their own services and/or depend on large aggregators to do the heavy lifting.  Many trusted Apple for this task, until they couldn&#39;t, and the <a href="https://podcastindex.org/">Podcast Index</a> only stepped up as an alternative because it&#39;s still such a difficult problem.  Even more, the aggregators still have to be polled!  They don&#39;t have the resources to become a notification system <em>en masse</em>.</p>

<h2 id="podping-cloud">Podping.cloud</h2>

<p>Enter <a href="https://github.com/Podcastindex-org/podping.cloud">Podping.cloud</a>:</p>

<blockquote><p>Podping is a blockchain based global notification system for podcasting. Feed urls are written by the publisher to the blockchain within seconds of a new episode being published. Anyone can monitor for those updates and only pull a copy of that feed when it shows up on the chain.</p></blockquote>

<p><img src="https://github.com/Podcastindex-org/podping.cloud/raw/main/framework1.png" alt="Podping.cloud architecture"/></p>

<p>What does that mean?  It consists of two parts:</p>
<ol><li>An on-boarding mechanism for hosts to migrate to with ease — something similar to WebSub but simpler to manage.</li>
<li>A standardization of data interchange mechanisms — the “podping” namespace — to broadcast podcast updates onto the Hive* blockchain.</li></ol>

<p>*<em>Note: This is really just a specification of a JSON schema.  Hive is an implementation detail.</em></p>

<h2 id="decentralized-podcast-updates">Decentralized podcast updates!</h2>

<p>Given Podping, a standardized way to communicate podcast updates into Hive, anyone can listen for them on the Hive blockchain.  An important characteristic of what the Hive community has developed is a standardized HTTP API for applications to utilize, as opposed to having to download and manage the Hive blockchain themselves (though they could if they wanted to).</p>

<p>What does this look like for an application?  Below are a few real transactions from the Hive blockchain:</p>

<pre><code class="language-json">{&#34;_id&#34;: &#34;cabd5cc591662b4cb131fb546ae9189d104a00ee&#34;,
 &#34;block_num&#34;: 54014222,
 &#34;id&#34;: &#34;podping&#34;,
 &#34;json&#34;: &#34;{\&#34;version\&#34;:\&#34;0.2\&#34;,\&#34;num_urls\&#34;:3,\&#34;reason\&#34;:\&#34;feed_update\&#34;,\&#34;urls\&#34;:[\&#34;https://feeds.buzzsprout.com/981862.rss\&#34;,\&#34;https://feeds.buzzsprout.com/1722601.rss\&#34;,\&#34;https://feeds.buzzsprout.com/1287197.rss\&#34;]}&#34;,
 &#34;required_auths&#34;: [],
 &#34;required_posting_auths&#34;: [&#34;hivehydra&#34;],
 &#34;timestamp&#34;: &#34;2021-05-19T02:39:06Z&#34;,
 &#34;trx_id&#34;: &#34;ebd5b45772e119c38f75e246d4b70d60ee527716&#34;,
 &#34;trx_num&#34;: 23,
 &#34;type&#34;: &#34;custom_json&#34;}
{&#34;_id&#34;: &#34;6b7fe74973283bf99d76ef9b81ced193c43ebe84&#34;,
 &#34;block_num&#34;: 54014229,
 &#34;id&#34;: &#34;podping&#34;,
 &#34;json&#34;: &#34;{\&#34;version\&#34;:\&#34;0.2\&#34;,\&#34;num_urls\&#34;:2,\&#34;reason\&#34;:\&#34;feed_update\&#34;,\&#34;urls\&#34;:[\&#34;https://media.rss.com/njb/feed.xml\&#34;,\&#34;https://feeds.buzzsprout.com/1749995.rss\&#34;]}&#34;,
 &#34;required_auths&#34;: [],
 &#34;required_posting_auths&#34;: [&#34;hivehydra&#34;],
 &#34;timestamp&#34;: &#34;2021-05-19T02:39:27Z&#34;,
 &#34;trx_id&#34;: &#34;394ecb5449f6a7d9472432915ed2241628e0716e&#34;,
 &#34;trx_num&#34;: 20,
 &#34;type&#34;: &#34;custom_json&#34;}
{&#34;_id&#34;: &#34;c6ed805969a3c86634f34352e44a232e907336e1&#34;,
 &#34;block_num&#34;: 54014236,
 &#34;id&#34;: &#34;podping&#34;,
 &#34;json&#34;: &#34;{\&#34;version\&#34;:\&#34;0.2\&#34;,\&#34;num_urls\&#34;:1,\&#34;reason\&#34;:\&#34;feed_update\&#34;,\&#34;urls\&#34;:[\&#34;https://feeds.buzzsprout.com/1575751.rss\&#34;]}&#34;,
 &#34;required_auths&#34;: [],
 &#34;required_posting_auths&#34;: [&#34;hivehydra&#34;],
 &#34;timestamp&#34;: &#34;2021-05-19T02:39:48Z&#34;,
 &#34;trx_id&#34;: &#34;b3a97ec7bf97604194755913953b28b6de21c403&#34;,
 &#34;trx_num&#34;: 12,
 &#34;type&#34;: &#34;custom_json&#34;}
 {&#34;_id&#34;: &#34;73c63d127e040049f0d6c2f118c1c00e46da17da&#34;,
 &#34;allow_curation_rewards&#34;: True,
 &#34;allow_votes&#34;: True,
 &#34;author&#34;: &#34;&lt;redacted&gt;&#34;,
 &#34;block_num&#34;: 54015435,
 &#34;extensions&#34;: [{&#34;type&#34;: &#34;comment_payout_beneficiaries&#34;,
                 &#34;value&#34;: {&#34;beneficiaries&#34;: [{&#34;account&#34;: &#34;hiveonboard&#34;,
                                              &#34;weight&#34;: 100},
                                             {&#34;account&#34;: &#34;tipu&#34;,
                                              &#34;weight&#34;: 100}]}}],
 &#34;max_accepted_payout&#34;: {&#34;amount&#34;: &#34;1000000000&#34;,
                         &#34;nai&#34;: &#34;@@000000013&#34;,
                         &#34;precision&#34;: 3},
 &#34;percent_hbd&#34;: 10000,
 &#34;permlink&#34;: &#34;&lt;redacted&gt;&#34;,
 &#34;timestamp&#34;: &#34;2021-05-19T03:39:54Z&#34;,
 &#34;trx_id&#34;: &#34;7d4012b4b7e4901bbaf910a71166a78f5ac9b186&#34;,
 &#34;trx_num&#34;: 22,
 &#34;type&#34;: &#34;comment_options&#34;}
{&#34;_id&#34;: &#34;502ddccc9a1e4bb86b7379497e6b17e943c869d4&#34;,
 &#34;block_num&#34;: 54014474,
 &#34;id&#34;: &#34;sm_find_match&#34;,
 &#34;json&#34;: &#34;{\&#34;match_type\&#34;:\&#34;Ranked\&#34;,\&#34;app\&#34;:\&#34;steemmonsters/0.7.89\&#34;}&#34;,
 &#34;required_auths&#34;: [],
 &#34;required_posting_auths&#34;: [&#34;nandito&#34;],
 &#34;timestamp&#34;: &#34;2021-05-19T02:51:45Z&#34;,
 &#34;trx_id&#34;: &#34;b41cf36a88d798d15e31b1d2b718cd7fa4176b1b&#34;,
 &#34;trx_num&#34;: 49,
 &#34;type&#34;: &#34;custom_json&#34;}
{&#34;_id&#34;: &#34;1dc0e544c25978fcf868e40623e930d5bbdc97fa&#34;,
 &#34;block_num&#34;: 54014474,
 &#34;id&#34;: &#34;sm_submit_team&#34;,
 &#34;json&#34;: &#34;{\&#34;trx_id\&#34;:\&#34;8a965173a51cf0457264196066febf3040d9c720\&#34;,\&#34;team_hash\&#34;:\&#34;946c2011bd2ec8844fcdc2bbf946a738\&#34;,\&#34;summoner\&#34;:\&#34;C1-49-SM0LILHETC\&#34;,\&#34;monsters\&#34;:[\&#34;C1-64-TPHW58AV34\&#34;,\&#34;C1-50-1AMDZHJ7OG\&#34;,\&#34;C1-47-S6HDP0EA5S\&#34;,\&#34;C1-62-AQOTC401J4\&#34;,\&#34;C1-46-1BP1BKEY3K\&#34;],\&#34;secret\&#34;:\&#34;TZte3wNaM7\&#34;,\&#34;app\&#34;:\&#34;steemmonsters/0.7.24\&#34;}&#34;,
 &#34;required_auths&#34;: [],
 &#34;required_posting_auths&#34;: [&#34;postme&#34;],
 &#34;timestamp&#34;: &#34;2021-05-19T02:51:45Z&#34;,
 &#34;trx_id&#34;: &#34;8ff17c754ff1d9621e9e0014439e720086ab5e85&#34;,
 &#34;trx_num&#34;: 50,
 &#34;type&#34;: &#34;custom_json&#34;}

</code></pre>

<p>A few interesting things to note here.  It&#39;s nice to have all of the information, but it&#39;s a bit of a fire hose.  How can we clean this up?  We can hide it within our application, which might be acceptable for some servers... however it&#39;s still all unnecessary bandwidth.  Particularly the last two non-Podping operations as well as the non-<code>custom_json</code> type.</p>

<h2 id="walking-the-last-mile">Walking the last mile</h2>

<p>In order for this to be efficient for client applications — especially mobile applications with limited resources — there&#39;s a couple things we need to address.  <em>Note: I am only familiar with the beem python library at this moment in time, so it&#39;s possible these two points are moot.</em></p>
<ol><li>Server side filtering of <code>custom_json</code> operations.  Currently the python implementation, <code>beem</code> does this on the client side, hiding it from the user.  It still pulls in every block even if you tell it to only look for the <code>custom_json</code> operation.</li>
<li>Server side filtering of the <code>custom_json</code> <code>id</code> — even if we pulled in only <code>custom_json</code> operations, we&#39;re still getting other data from other applications.  Really, we only care about <code>id=&#39;podping&#39;</code>.</li></ol>

<p>Given those two changes, we can size down the fire hose to the following podping operations:</p>

<pre><code class="language-json">{&#34;_id&#34;: &#34;cabd5cc591662b4cb131fb546ae9189d104a00ee&#34;,
 &#34;block_num&#34;: 54014222,
 &#34;id&#34;: &#34;podping&#34;,
 &#34;json&#34;: &#34;{\&#34;version\&#34;:\&#34;0.2\&#34;,\&#34;num_urls\&#34;:3,\&#34;reason\&#34;:\&#34;feed_update\&#34;,\&#34;urls\&#34;:[\&#34;https://feeds.buzzsprout.com/981862.rss\&#34;,\&#34;https://feeds.buzzsprout.com/1722601.rss\&#34;,\&#34;https://feeds.buzzsprout.com/1287197.rss\&#34;]}&#34;,
 &#34;required_auths&#34;: [],
 &#34;required_posting_auths&#34;: [&#34;hivehydra&#34;],
 &#34;timestamp&#34;: &#34;2021-05-19T02:39:06Z&#34;,
 &#34;trx_id&#34;: &#34;ebd5b45772e119c38f75e246d4b70d60ee527716&#34;,
 &#34;trx_num&#34;: 23,
 &#34;type&#34;: &#34;custom_json&#34;}
{&#34;_id&#34;: &#34;6b7fe74973283bf99d76ef9b81ced193c43ebe84&#34;,
 &#34;block_num&#34;: 54014229,
 &#34;id&#34;: &#34;podping&#34;,
 &#34;json&#34;: &#34;{\&#34;version\&#34;:\&#34;0.2\&#34;,\&#34;num_urls\&#34;:2,\&#34;reason\&#34;:\&#34;feed_update\&#34;,\&#34;urls\&#34;:[\&#34;https://media.rss.com/njb/feed.xml\&#34;,\&#34;https://feeds.buzzsprout.com/1749995.rss\&#34;]}&#34;,
 &#34;required_auths&#34;: [],
 &#34;required_posting_auths&#34;: [&#34;hivehydra&#34;],
 &#34;timestamp&#34;: &#34;2021-05-19T02:39:27Z&#34;,
 &#34;trx_id&#34;: &#34;394ecb5449f6a7d9472432915ed2241628e0716e&#34;,
 &#34;trx_num&#34;: 20,
 &#34;type&#34;: &#34;custom_json&#34;}
{&#34;_id&#34;: &#34;c6ed805969a3c86634f34352e44a232e907336e1&#34;,
 &#34;block_num&#34;: 54014236,
 &#34;id&#34;: &#34;podping&#34;,
 &#34;json&#34;: &#34;{\&#34;version\&#34;:\&#34;0.2\&#34;,\&#34;num_urls\&#34;:1,\&#34;reason\&#34;:\&#34;feed_update\&#34;,\&#34;urls\&#34;:[\&#34;https://feeds.buzzsprout.com/1575751.rss\&#34;]}&#34;,
 &#34;required_auths&#34;: [],
 &#34;required_posting_auths&#34;: [&#34;hivehydra&#34;],
 &#34;timestamp&#34;: &#34;2021-05-19T02:39:48Z&#34;,
 &#34;trx_id&#34;: &#34;b3a97ec7bf97604194755913953b28b6de21c403&#34;,
 &#34;trx_num&#34;: 12,
 &#34;type&#34;: &#34;custom_json&#34;}
</code></pre>

<p>This on its own is a huge improvement, but we can do more...</p>

<h2 id="one-step-further">One step further</h2>

<p>See the <code>json</code> attribute?  That&#39;s our Podping schema!  What if we only subscribe to one or two podcasts?  We don&#39;t need the rest of the results.</p>

<p>Thankfully, there&#39;s a straightforward way to handle this: <a href="https://jmespath.org/">JMESPath</a></p>

<blockquote><p>JMESPath is a query language for JSON.</p></blockquote>

<p>Let&#39;s say we only want to get results from the podcast “Quality during Design” in the above list.  We can test this in a quick way with the <a href="https://github.com/jmespath/jp">jp</a> cli tool and the <a href="https://jmespath.readthedocs.io/en/latest/specification.html#contains">JMESPath contains function</a>.</p>

<pre><code class="language-sh">echo &#39;{&#34;version&#34;:&#34;0.2&#34;,&#34;num_urls&#34;:3,&#34;reason&#34;:&#34;feed_update&#34;,&#34;urls&#34;:[&#34;https://feeds.buzzsprout.com/981862.rss&#34;,&#34;https://feeds.buzzsprout.com/1722601.rss&#34;,&#34;https://feeds.buzzsprout.com/1287197.rss&#34;]}&#39; \
| jp &#34;contains(urls, &#39;https://feeds.buzzsprout.com/1722601.rss&#39;)&#34;
true
</code></pre>

<p>Behold!  We just defined a mechanism to query Podping json from a <code>custom_json</code> operation.  In this example, the <code>contains</code> function being run by <code>jp</code> is returning <code>true</code>, telling us that this example indeed includes the feed URL we care about.</p>

<p>Why is this important?  Couldn&#39;t we just parse the json object in our code and check for the URL?</p>

<p>Well, yes... but JMESPath provides us a way to run this query on the API server, <em>without the API server requiring knowledge of our dataset</em>.  Meaning, given an implementation of this query on the Hive API, we would happily only get the results we need from the API.</p>

<p>If we only subscribed to one podcast we could get update notifications for it without having to parse through all new Hive blockchain events.</p>

<p>This is truly potential for a whole new generation of a decentralized notification system, and Podcasting 2.0 is driving it.</p>

<p>Hopefully some of the above ideas can be incorporated into the Hive ecosystem in a way that will benefit everyone.</p>

<p><a href="https://remark.as/p/write.agates.io/podcasting-2-0-the-last-mile">Discuss...</a></p>

<p><a href="https://write.agates.io/tag:podcasting20" class="hashtag"><span>#</span><span class="p-category">podcasting20</span></a> <a href="https://write.agates.io/tag:podping" class="hashtag"><span>#</span><span class="p-category">podping</span></a> <a href="https://write.agates.io/tag:jmespath" class="hashtag"><span>#</span><span class="p-category">jmespath</span></a> <a href="https://write.agates.io/tag:rss" class="hashtag"><span>#</span><span class="p-category">rss</span></a> <a href="https://write.agates.io/tag:hive" class="hashtag"><span>#</span><span class="p-category">hive</span></a></p>
]]></content:encoded>
      <guid>https://write.agates.io/podcasting-2-0-the-last-mile</guid>
      <pubDate>Wed, 19 May 2021 11:59:17 +0000</pubDate>
    </item>
  </channel>
</rss>