<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Manos Batsis on Medium]]></title>
        <description><![CDATA[Stories by Manos Batsis on Medium]]></description>
        <link>https://medium.com/@manosbatsis?source=rss-2255ac54ee08------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/2*uC4LVJNr6uQGCCoZBjoz8w.jpeg</url>
            <title>Stories by Manos Batsis on Medium</title>
            <link>https://medium.com/@manosbatsis?source=rss-2255ac54ee08------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 16:41:06 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@manosbatsis/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Corda5 Integration Testing]]></title>
            <link>https://medium.com/@manosbatsis/corda5-integration-testing-4e98d6a195cd?source=rss-2255ac54ee08------2</link>
            <guid isPermaLink="false">https://medium.com/p/4e98d6a195cd</guid>
            <category><![CDATA[corda]]></category>
            <category><![CDATA[r3]]></category>
            <category><![CDATA[integration-testing]]></category>
            <category><![CDATA[cordapp]]></category>
            <category><![CDATA[github-actions]]></category>
            <dc:creator><![CDATA[Manos Batsis]]></dc:creator>
            <pubDate>Fri, 05 Jan 2024 06:19:29 GMT</pubDate>
            <atom:updated>2024-01-05T06:19:29.887Z</atom:updated>
            <content:encoded><![CDATA[<p>with Gradle, JUnit5, <a href="https://github.com/manosbatsis/corda5-testutils">Corda5-Testutils</a> and <a href="https://github.com/manosbatsis/corda5-cli-action">Corda5-CLI-Action</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HS9bvUHeeteH2lzzWRoHHQ.png" /><figcaption>Corda5 CLI in GitHub Actions</figcaption></figure><p>This is a quick HOWTO for Corda5 integration testing, both local and CI with GitHub Actions. You can find the working code in this <a href="https://github.com/manosbatsis/CSDE-cordapp-integration-testing">CSDE fork</a>, specifically in <a href="https://github.com/manosbatsis/CSDE-cordapp-integration-testing/pull/1">this PR</a>.</p><blockquote>Note: seems corda-runtime-os release-5.0.0 disappeared from GitHub. Our sample is based on CSDE release/corda-5–0, only updated to use Corda 5.0.1 and Java 17.</blockquote><h4>Prerequisites</h4><p>Same as <a href="https://docs.r3.com/en/tools-corda5/csde/prerequisites.html">CSDE</a>:</p><ul><li>Azul Zulu JDK 17</li><li>Git ~v2.24.1</li><li>Docker Engine ~v20.X.Y or Docker Desktop ~v3.5.X</li><li>Corda CLI, see <a href="https://docs.r3.com/en/platform/corda/5.0/developing-applications/tooling/installing-corda-cli.html">Installing the Corda CLI</a></li></ul><h4>Gradle Setup</h4><p>The <a href="https://github.com/manosbatsis/corda5-testutils">corda5-testutils</a> dependency includes a JUnit5 extension <br>for starting the Combined Worker and an API for calling flows etc.</p><p>Let’s add the dependency version to gradle.properties:</p><pre># Corda 5 Test Utils<br>corda5TestutilsVersion=1.2.1</pre><p>Now into <a href="https://github.com/manosbatsis/CSDE-cordapp-integration-testing/blob/v5.0.1-integration-tests/workflows/build.gradle">workflows/build.gradle</a>, we add separate configuration, sourceSets etc. for integration tests:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/8d9afeef0abd4aad525f768ff177289c/href">https://medium.com/media/8d9afeef0abd4aad525f768ff177289c/href</a></iframe><p>And the corda5-testutils dependency for launching Corda’s Combined Worker:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1c2a52add58e1a23d43c2ffeb1541a46/href">https://medium.com/media/1c2a52add58e1a23d43c2ffeb1541a46/href</a></iframe><h4>Create a Test</h4><p>Here’s how our <a href="https://github.com/manosbatsis/CSDE-cordapp-integration-testing/blob/v5.0.1-integration-tests/workflows/src/integrationTest/kotlin/com/r3/developers/csdetemplate/flowexample/workflows/IntegrationTests.kt">Integration Test</a> looks like:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/21edf0850201d58e1a73b3af2b92c3d9/href">https://medium.com/media/21edf0850201d58e1a73b3af2b92c3d9/href</a></iframe><h4>Test with Gradle</h4><p>We have to call integration tests explicitly:</p><pre>./gradlew build integrationTest </pre><h4>Test with GitHub Actions</h4><p>The <a href="https://github.com/manosbatsis/corda5-cli-action">corda5-cli-action</a> will download, install and cache the Corda5 CLI, so the Gradle build will just work. The workflow <a href="https://github.com/manosbatsis/CSDE-cordapp-integration-testing/blob/v5.0.1-integration-tests/.github/workflows/ci.yml">file</a> contains the following:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/dc1ecdee89a84d7e986d21444dc62366/href">https://medium.com/media/dc1ecdee89a84d7e986d21444dc62366/href</a></iframe><p>You can see the workflow runs in the repository’s <a href="https://github.com/manosbatsis/CSDE-cordapp-integration-testing/actions">actions area</a>.</p><h4>Build Successful</h4><p>All done. You can find the code in <a href="https://github.com/manosbatsis/CSDE-cordapp-integration-testing">CSDE-cordapp-integration-testing</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4e98d6a195cd" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Vaultaire: Corda Vault Queries  Made Simple]]></title>
            <link>https://medium.com/@manosbatsis/vaultaire-corda-vault-queries-made-simple-d13db4147298?source=rss-2255ac54ee08------2</link>
            <guid isPermaLink="false">https://medium.com/p/d13db4147298</guid>
            <category><![CDATA[kotlin]]></category>
            <category><![CDATA[cordapp]]></category>
            <category><![CDATA[corda]]></category>
            <category><![CDATA[kotlin-dsl]]></category>
            <category><![CDATA[r3]]></category>
            <dc:creator><![CDATA[Manos Batsis]]></dc:creator>
            <pubDate>Mon, 21 Oct 2019 09:26:45 GMT</pubDate>
            <atom:updated>2019-10-21T14:03:05.140Z</atom:updated>
            <cc:license>https://creativecommons.org/licenses/by-nd/4.0/</cc:license>
            <content:encoded><![CDATA[<h3>Vaultaire: Corda Vault Queries Made Simple</h3><h4>Upgrade to a clean and easy to use query DSL generated just for you.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rM3Wnogztfzt2sXtDOk6-w.png" /><figcaption>Sample Vaultaire DSL Query</figcaption></figure><h3>Feeling Lucky</h3><p>If you are in a hurry and want to quickly try Vaultaire with your project skip ahead to “<em>Testing the Solution”</em>, otherwise read on.</p><h3>Admitting the Problem</h3><p>A few months ago, I was looking for a bug in a Corda vault query. The code had grown over time to support more criteria and was increasingly difficult to maintain. <br>The same problem was spreading throughout the code-base for some time and no easy solution was readily available. I was wasting too much time trying to read my own code instead of dealing with the issue.<br>If you don’t know what I’m talking about, Corda ’s Query DSL is rather easy to use but a bit verbose:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/30042ede104fe35f5f66a43c987c102c/href">https://medium.com/media/30042ede104fe35f5f66a43c987c102c/href</a></iframe><h3>Setting the Objectives</h3><p>In short, Vaultaire’s DSL APIs were designed with the following requirements:</p><ul><li>Utilize the standard Corda APIs for interoperability</li><li>Provide a compact syntax for readability</li><li>Maintain type safety and require minimal configuration for ease of use</li></ul><h3>Testing the Solution</h3><p>Here’s how to quickly setup your project build to automatically generate and maintain a query DSL specific to your Corda States.</p><h4>Adding Dependencies</h4><p>Update your <strong>Cordapp</strong>’s Gradle dependencies:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/9989817ff07d31bb3e01c95735530a27/href">https://medium.com/media/9989817ff07d31bb3e01c95735530a27/href</a></iframe><p><em>Optional</em>: The core module can also be useful outside a cordapp, e.g. in a Spring app querying a Corda node vault via RPC:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/e9deb41daf54246853ae7cdda2fd8969/href">https://medium.com/media/e9deb41daf54246853ae7cdda2fd8969/href</a></iframe><h4>Creating a DSL</h4><p>To create a query DSL for your state, simply annotate the corresponding schema’s<strong> PersistentState </strong>subclass with <em>@VaultaireGenerate</em>:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/996e6531520a0b023ada6a04a048f1cc/href">https://medium.com/media/996e6531520a0b023ada6a04a048f1cc/href</a></iframe><p>Vaultaire’s annotation processor will pick that up and automatically generate and maintain a DSL for you at e.g. <em>projectname/build/generated/source/kaptKotlin/main/example/BookStateVaultaireGenerated.kt</em></p><h4>Querying the Vault</h4><p>Start with converting a simple query like the example at the top of this post:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7e722522c1615455bd2bf308a2c7807b/href">https://medium.com/media/7e722522c1615455bd2bf308a2c7807b/href</a></iframe><h3>Getting Back to Work</h3><p>Well, that’s it. There’s more to Vaultaire’s features, including aggregate queries with the DSL and generation of DAO-style state services that are not covered in this article, see the <a href="https://manosbatsis.github.io/vaultaire/">github project</a> for details and support.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d13db4147298" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>