<?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 Priya Roul on Medium]]></title>
        <description><![CDATA[Stories by Priya Roul on Medium]]></description>
        <link>https://medium.com/@priyaroul99?source=rss-7f74771f14ff------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*aTJL_xScoAXcUXkw5-CIkg@2x.jpeg</url>
            <title>Stories by Priya Roul on Medium</title>
            <link>https://medium.com/@priyaroul99?source=rss-7f74771f14ff------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Thu, 03 Dec 2026 20:35:45 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@priyaroul99/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[AI Didn’t Make Me a Faster Programmer. Programming stopped being the bottleneck.]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://medium.com/@priyaroul99/ai-didnt-make-me-a-faster-programmer-programming-stopped-being-the-bottleneck-b91a6c5eaa40?source=rss-7f74771f14ff------2"><img src="https://cdn-images-1.medium.com/max/2472/1*4etMygvPEmXObcB5iR50IQ.png" width="2472"></a></p><p class="medium-feed-snippet">A few months ago my workflow started to feel strangely inefficient, and the reason caught me off guard. Coding had become much faster. The&#x2026;</p><p class="medium-feed-link"><a href="https://medium.com/@priyaroul99/ai-didnt-make-me-a-faster-programmer-programming-stopped-being-the-bottleneck-b91a6c5eaa40?source=rss-7f74771f14ff------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://medium.com/@priyaroul99/ai-didnt-make-me-a-faster-programmer-programming-stopped-being-the-bottleneck-b91a6c5eaa40?source=rss-7f74771f14ff------2</link>
            <guid isPermaLink="false">https://medium.com/p/b91a6c5eaa40</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[ai-agent]]></category>
            <dc:creator><![CDATA[Priya Roul]]></dc:creator>
            <pubDate>Sat, 06 Jun 2026 09:00:29 GMT</pubDate>
            <atom:updated>2026-06-06T09:00:29.210Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[How Databases Store Data]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://medium.com/@priyaroul99/how-databases-store-data-2f3a48c3d650?source=rss-7f74771f14ff------2"><img src="https://cdn-images-1.medium.com/max/2600/0*HfuJ6mR5U9kLl3Gq" width="2600"></a></p><p class="medium-feed-snippet">We use databases every day. We define schemas, add indexes, and everything just works. I got curious to know how it works under the hood&#x2026;</p><p class="medium-feed-link"><a href="https://medium.com/@priyaroul99/how-databases-store-data-2f3a48c3d650?source=rss-7f74771f14ff------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://medium.com/@priyaroul99/how-databases-store-data-2f3a48c3d650?source=rss-7f74771f14ff------2</link>
            <guid isPermaLink="false">https://medium.com/p/2f3a48c3d650</guid>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[computer-science]]></category>
            <category><![CDATA[database]]></category>
            <dc:creator><![CDATA[Priya Roul]]></dc:creator>
            <pubDate>Tue, 21 Apr 2026 19:18:28 GMT</pubDate>
            <atom:updated>2026-04-21T19:18:28.637Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[From Career Break to GSoC: My Open Source Journey ]]></title>
            <link>https://medium.com/@priyaroul99/from-career-break-to-gsoc-my-open-source-journey-24b908416ac5?source=rss-7f74771f14ff------2</link>
            <guid isPermaLink="false">https://medium.com/p/24b908416ac5</guid>
            <category><![CDATA[typescript]]></category>
            <category><![CDATA[google-summer-of-code]]></category>
            <category><![CDATA[gsoc]]></category>
            <category><![CDATA[swift]]></category>
            <category><![CDATA[gsoc-2025]]></category>
            <dc:creator><![CDATA[Priya Roul]]></dc:creator>
            <pubDate>Sun, 22 Jun 2025 16:35:17 GMT</pubDate>
            <atom:updated>2025-06-22T16:35:17.448Z</atom:updated>
            <content:encoded><![CDATA[<blockquote>From wiping my disk while installing Ubuntu in 2020 to writing Swift and TypeScript code used by thousands in 2025</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TdQYYdJLekUwgCfaiIsBEw.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@vladimir_d?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">Volodymyr Dobrovolskyy</a> on <a href="https://unsplash.com/photos/a-cat-sitting-in-front-of-a-computer-monitor-KrYbarbAx5s?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">Unsplash</a></figcaption></figure><p>This year, in March, I decided to take a break and explore new career opportunities. When I was in college, I always aspired to learn and contribute to open-source projects. I tried a few things, but I felt confused and made little progress.</p><p>I installed Ubuntu, made mistakes, and lost all my data during the disk partitioning process 💥. I continued to work on setting up development environments for the projects I liked, but soon got stuck. I didn’t have any mentors at that time to guide me, so I left it for another time and focused on getting a job after graduating.</p><p>So, on my break this time, I wanted to give it a shot again. Luckily, I got to know about mentorship programmes like LFX and Google Summer of Code, which were previously student-only but are now open to everyone. They are designed for beginners to open source. I thought to give it a try.</p><h3>🎯 Selecting projects</h3><p>I have <em>some</em> experience in writing software. I am well-versed in software architecture and design patterns. Open source requires different skills for communication and collaboration. Learning to work collaboratively became my goal. Learning a new piece of technology was my side quest.</p><p>I began by exploring the projects listed for GSoC 2024 to understand the types of organisations that typically participate in the program. I gained insight into the organisations and their directions, as well as project ideas, from their discussion forums. Once GSoC released the 2025 project ideas, I narrowed my focus to three that aligned with my interests: Checkstyle, Kotlin, and Swift.</p><p>First, I started with Checkstyle, <em>a </em>static code analysis tool for Java. I was already very familiar with Java, so it was easier for me to get started contributing to Checkstyle. As one of the organisations participating in Google Summer of Code for over a decade, they see a lot of interest from contributors (some of whom are not genuine).</p><p>Checkstyle had a traditional way to filter potential GSoC contributors by having them complete good first, second, and third issues, just like collecting starter Pokémon! After submitting PRs against my starter issues, I contributed a Remainder Bot for stale pull requests and issues using GitHub Actions, upgraded several outdated dependencies, and modernised a few Java APIs, such as migrating java.io.File usages to java.nio.file.Path API and learned about mutation testing using pitest, and <em>killed</em> a few <em>mutants</em> in the Checkstyle test suite.</p><p>In Checkstyle, I chose to contribute to Javadoc Markdown Support because it was an interesting project that allowed me to learn about linters by exploring how Abstract Syntax Trees (ASTs) work and by building grammars for language lexing and parsing. I studied JEP of the Markdown Javadoc, learnt Antlr, and got to know the internals of Checkstyle checks while authoring my proposal.</p><p>The other project I was interested in was The Swift Project, a general-purpose language that compiles native code, commonly used to build iOS apps. The project aims to integrate <a href="https://github.com/swiftlang/swiftly">Swiftly</a>, Swift Projects’ official toolchain manager, with the <a href="https://marketplace.visualstudio.com/items?itemName=swiftlang.swift-vscode">Swift Extension for VS Code</a>. It would allow users to install Swiftly and Swift toolchains directly within the VS Code editor, enabling them to switch the SourceKit-LSP and build steps to use the selected toolchain.</p><p>Swift did not have a formal “contributor’s rite-of-passage” like Checkstyle; it expected new contributors to contribute to Swift projects and be comfortable writing basic Swift code. I started by sending a few PRs to <a href="https://github.com/swiftlang/vscode-swift/pulls?q=is%3Apr+author%3Aroulpriya+is%3Aclosed">the extension</a>, then to <a href="https://github.com/swiftlang/swift-docc-render/pulls?q=is%3Apr+author%3Aroulpriya+is%3Aclosed">Swift Doc Renderer</a> and <a href="https://github.com/swiftlang/swiftly/pulls?q=is%3Apr+author%3Aroulpriya+is%3Aclosed">Swiftly</a>.</p><p>After familiarising myself with the codebases, I started drafting my proposal. Swift has an amazing community, and they have a forum where you can reach out to seek help. I was introduced to Chris and Matthew as my project mentors, who helped clarify my doubts regarding the project and assisted in drafting my final proposal.</p><p>Here is the conversation if you are interested in taking a look: <a href="https://forums.swift.org/t/gsoc-2025-swiftly-integration-in-vs-code/78285">https://forums.swift.org/t/gsoc-2025-swiftly-integration-in-vs-code/78285</a>. You will also find my GSOC Proposal for VSCode Extension for Swiftly in the discussion, and see how it evolved.</p><p>At the end of April, I finalised the requirements and implementation details and submitted proposals for both project ideas.</p><p>On May 8th, 2025, I received an email stating that I had been selected as a GSoC Contributor for Swift. I spent the first few weeks on community bonding, during which I met with Chris and Matthew again, this time face-to-face via video calls. We discussed the plans for completing the project in detail, and I continued to work on a few more open issues in Swiftly.</p><h3>📈 Learning Curve</h3><p>Initially, I thought it would not be easy to code in Swift as the language was new to me — Just weeks earlier, I was building simple apps in Swift Playgrounds for fun. However, later, as I started contributing, I realised that Swift was much simpler than I thought. Being a successor to Objective-C, Swift’s syntax is similar to Java and Python. I had been learning the basic syntax and core concepts of Swift from H<a href="https://www.hackingwithswift.com/">acking With Swift</a>, as well as some uncommon patterns from Swiftly’s codebase.</p><p>Earlier, I used to believe that I could only code in Java and Python or JavaScript, and learning anything new would be a mammoth task. GSoC allowed me to challenge myself. Now I can build something meaningful and <em>production-ready</em> code in less than a week in any new language 💪.</p><p>One of the best things about open-source is that communication is much more straightforward, and people are there to help you out if you’re stuck.</p><h3>⚡ Progress</h3><p>As I outlined in my Swift Proposal, I began executing my proposal task by task. My first task was to add JSON output format to the Swiftly CLI. Here, I learned a lot more about the CLI, JSON output, progress files, interfaces, and Swift tests.</p><p>Last week, I had a meeting with extraordinary people working on Swift and the VS Code Swift Extension. I was excited to learn new things from each one of them. Some of them have been working for decades at Apple, and a few of them are as new as I am.</p><p>This week, I will begin using VS Code for Swift development and will code in both TypeScript and Swift. Now, it will be more fun juggling between two languages, learning how VS Code extensions work, and building features that hundreds of thousands of users will use 🌟.</p><p>In my next post, I will be writing about my work in VS Code Extension with Swiftly.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=24b908416ac5" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The Internal Workings of a HashMap: A Deep Dive]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://medium.com/@priyaroul99/the-internal-workings-of-a-hashmap-a-deep-dive-15bf0580babb?source=rss-7f74771f14ff------2"><img src="https://cdn-images-1.medium.com/max/2600/1*HqsuPKxoX-Xo-3NtpwqgNw.jpeg" width="4062"></a></p><p class="medium-feed-snippet">Have you ever wondered how a HashMap gives you fast access to your data? Let&#x2019;s peek under the hood and see how hashmap works internally.</p><p class="medium-feed-link"><a href="https://medium.com/@priyaroul99/the-internal-workings-of-a-hashmap-a-deep-dive-15bf0580babb?source=rss-7f74771f14ff------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://medium.com/@priyaroul99/the-internal-workings-of-a-hashmap-a-deep-dive-15bf0580babb?source=rss-7f74771f14ff------2</link>
            <guid isPermaLink="false">https://medium.com/p/15bf0580babb</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[computer-science]]></category>
            <category><![CDATA[interview]]></category>
            <category><![CDATA[software-engineering]]></category>
            <dc:creator><![CDATA[Priya Roul]]></dc:creator>
            <pubDate>Thu, 06 Mar 2025 18:14:59 GMT</pubDate>
            <atom:updated>2025-03-07T07:12:54.924Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[REWORK: The Must-Read Business Book for 2025]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://medium.com/@priyaroul99/rework-the-must-read-business-book-for-2025-08ade2e647c4?source=rss-7f74771f14ff------2"><img src="https://cdn-images-1.medium.com/max/1142/1*d8w0zINZBOXQFbow0rtu5Q.png" width="1142"></a></p><p class="medium-feed-snippet">Stop Planning, Start Building: The Essential Guide for Modern Entrepreneurs</p><p class="medium-feed-link"><a href="https://medium.com/@priyaroul99/rework-the-must-read-business-book-for-2025-08ade2e647c4?source=rss-7f74771f14ff------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://medium.com/@priyaroul99/rework-the-must-read-business-book-for-2025-08ade2e647c4?source=rss-7f74771f14ff------2</link>
            <guid isPermaLink="false">https://medium.com/p/08ade2e647c4</guid>
            <category><![CDATA[growth]]></category>
            <category><![CDATA[startup]]></category>
            <category><![CDATA[business]]></category>
            <category><![CDATA[work]]></category>
            <category><![CDATA[productivity]]></category>
            <dc:creator><![CDATA[Priya Roul]]></dc:creator>
            <pubDate>Tue, 04 Feb 2025 11:18:42 GMT</pubDate>
            <atom:updated>2025-02-04T11:53:28.741Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[Introduction to Redis: The in-memory powerhouse]]></title>
            <link>https://medium.com/next-level-coding/introduction-to-redis-the-in-memory-powerhouse-8950265802e3?source=rss-7f74771f14ff------2</link>
            <guid isPermaLink="false">https://medium.com/p/8950265802e3</guid>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[caching]]></category>
            <category><![CDATA[tech]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[python]]></category>
            <dc:creator><![CDATA[Priya Roul]]></dc:creator>
            <pubDate>Sat, 26 Oct 2024 08:10:42 GMT</pubDate>
            <atom:updated>2024-11-04T10:11:00.994Z</atom:updated>
            <content:encoded><![CDATA[<h3>Introduction to Redis: The In-Memory Powerhouse</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*avJkPE5y6QCqm2BDy9fBQw.png" /></figure><h3>What is Redis?</h3><p>Redis is an open-source tool for storing data in memory for high-performance data retrieval and storage. Redis is a key-value store that can store multiple data types and quickly retrieve and store data, enabling applications to serve data to users speedily.</p><p>Think of Redis as your application’s turbocharged memory bank. While traditional databases, like PostgreSQL and SQL, are great for permanent storage, they can feel like waiting in line at a busy coffee shop — sometimes taking 30–60 seconds to serve up data. Redis changes this by keeping your most-wanted data readily available and serving it in milliseconds — like having your favourite coffee waiting for you when you walk in.</p><p>Imagine you’re building a popular e-commerce site. Here’s how Redis makes it blazing fast:</p><p>When a customer views a product:</p><ul><li>First, your app checks Redis (the speed layer)</li><li>If the data is there (cache hit) → instant response ⚡</li><li>If not (cache miss) → fetch from the database and store in Redis for next time.</li></ul><h3>Redis Data Structures: More Than Just Key-Value Storage</h3><p>Redis isn’t just fast — it’s versatile. Here’s what you can store:</p><h4>String</h4><p>The most basic and versatile data type in Redis. Think of it as a simple key-value pair, like storing a user’s name or a counter.</p><ul><li>SET key value - Store a value</li><li>GET key - Retrieve a value</li><li>INCR key - Increment a number by 1</li><li>DECR key - Decrement a number by 1</li><li>SETEX key seconds value - Set with expiration time</li><li>SETNX key value - Set only if the key doesn&#39;t exist</li><li>DELETE key - Remove a key</li></ul><pre># Storing user profile<br>SET user:123 &quot;John Doe&quot;<br>GET user:123        # Returns: &quot;John Doe&quot;<br><br># Counter example<br>SET page:views 0<br>INCR page:views     # Returns: 1<br>INCR page:views     # Returns: 2</pre><h4>Lists:</h4><p>Think of lists like a queue or stack — perfect for timelines, logs, or task queues.</p><ul><li>LPUSH key value - Add to the start (left) of the list.</li><li>RPUSH key value - Add to the end (right) of the list.</li><li>LPOP key - Remove &amp; return the first item from the list.</li><li>RPOP key - Remove &amp; return the last item from the list.</li><li>LRANGE key start stop - Get items within range</li></ul><pre># Todo list example <br>LPUSH todos &quot;Buy groceries&quot; <br>LPUSH todos &quot;Write code&quot; <br>LPUSH todos &quot;Exercise&quot;  <br><br># Get all todos (0 to -1 means everything) <br>LRANGE todos 0 -1    # Returns: [&quot;Exercise&quot;, &quot;Write code&quot;, &quot;Buy groceries&quot;]<br><br># Add to end of the list<br>RPUSH todos &quot;Clean Room&quot;<br>LRANGE todos 0 -1 # Returns: [&quot;Exercise&quot;, &quot;Write code&quot;, &quot;Buy groceries&quot;, &quot;Clean Room&quot;]</pre><h4>Sets:</h4><p>Managing unique, unordered elements.</p><ul><li>SADD key member - Add item to set</li><li>SREM key member - Remove from set</li><li>SMEMBERS key - Get all items</li><li>SISMEMBER key member - Check if exists</li></ul><pre>SADD fruits &quot;apple&quot; &quot;banana&quot; &quot;orange&quot; <br>SMEMBERS fruits  # Returns all the elements in the set <br>SISMEMBER fruits &quot;apple&quot;  # Checks if &quot;apple&quot; is a member, returns 1</pre><h4>Sorted Sets:</h4><p>Like sets, each item has a score for ranking — perfect for leaderboards or priority queues.</p><ul><li>ZADD key score member - Add scored item</li><li>ZRANGE key start stop [WITHSCORES] - Get range</li><li>ZREM key member - Remove item</li><li>ZSCORE key member - Get the item&#39;s score</li></ul><pre>ZADD leaderboard 100 &quot;Player1&quot; 200 &quot;Player2&quot; <br>ZRANGE leaderboard 0 -1 WITHSCORES  # Lists players ordered by scor</pre><h4>Hashes:</h4><p>Like a mini-database for a single object — ideal for user profiles or product details.</p><ul><li>HSET key field value - A set field in the hash</li><li>HGET key field - Get field value</li><li>HGETALL key - Get all fields &amp; values</li></ul><pre>HSET user:100 name &quot;John&quot; email &quot;john@example.com&quot; HGET user:100</pre><h3>How is Redis so fast?</h3><ul><li>Redis is an in-memory database 1000 times faster than random disk access.</li><li>Redis multiplexes IO operations in multiple threads and queues them into a single-threaded execution loop for simplified lock-free operations.</li></ul><h3>How can Redis persist the data?</h3><p>Redis is mainly used as an in-memory cache but can also behave as a strongly consistent data store if necessary.</p><ul><li>Snapshotting: Produces single-file point-in-time snapshots of your dataset at specified intervals.</li><li>AOF: This logs every write operation received, offering more durability at the cost of performance.</li><li>Snapshotting+AOF: Combining both balances durability, performance, and recovery granularity.</li></ul><h3>Managing Redis High Availability</h3><h4>Running Redis as a Replica Set</h4><p>We can create read replicas for redundancy. If one instance fails, others can continue serving data, although a complete shutdown leads to data loss.</p><h4>Running Redis in Clustered Mode</h4><p>We can also create and run Redis in cluster mode, where one or more shards divide the key space.</p><p>Each shard has its own replica. If any of the shards are unavailable, we don’t lose the entire key space. Also, by having shards, we can have more shards to accommodate the growing load by scaling horizontally.</p><h3>Deploying Redis</h3><h4>Running Redis for Development</h4><p>If you start with Redis or want to run it in your local environment, you can create a Redis docker container. Redis is easily deployed as a standalone docker container.</p><pre>docker run --name some-redis -d -p 6379:6379 redis</pre><h4>Running Redis in Production</h4><p>You can also run Redis independently. First, you deploy a primary node, and then you can add one or more secondary nodes.</p><p>Similarly, you can configure Redis in clustered modes in which you decide on topology and configure Redis accordingly.</p><p>Cloud providers also provide Redis-managed offerings, simplifying cluster creation, administration, and maintenance. It is a great way to run Redis in production.</p><h3>What’s Next?</h3><p>Stay tuned for the next part of this series, which is about different ways of using Redis in production.</p><h4>Thanks for reading!</h4><p>If you found this article helpful<strong>☕️ </strong><a href="https://www.buymeacoffee.com/priyaroul"><strong>Buy me a coffee</strong></a><strong> :)</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8950265802e3" width="1" height="1" alt=""><hr><p><a href="https://medium.com/next-level-coding/introduction-to-redis-the-in-memory-powerhouse-8950265802e3">Introduction to Redis: The in-memory powerhouse</a> was originally published in <a href="https://medium.com/next-level-coding">Next Stack</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Writing CSV files using OpenCSV and Spring Boot]]></title>
            <link>https://medium.com/@priyaroul99/writing-csv-files-using-opencsv-and-spring-boot-02e141dcba10?source=rss-7f74771f14ff------2</link>
            <guid isPermaLink="false">https://medium.com/p/02e141dcba10</guid>
            <category><![CDATA[spring-boot]]></category>
            <category><![CDATA[design]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[learning]]></category>
            <dc:creator><![CDATA[Priya Roul]]></dc:creator>
            <pubDate>Sun, 17 Dec 2023 10:36:20 GMT</pubDate>
            <atom:updated>2025-06-23T05:35:07.665Z</atom:updated>
            <content:encoded><![CDATA[<h4>In this article we will implement a CSV download feature using OpenCSV library and Spring Boot using StreamingResponseBody.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*a5e5Qx20GKTyi2KvK_E7CQ.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@neonbrand?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">Kenny Eliason</a> on <a href="https://unsplash.com/photos/pile-of-book-lot-uEcSKKDB1pg?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">Unsplash</a></figcaption></figure><p>CSV stands for Comma-Separated Values. It’s a simple file format that stores tabular data, where each line represents a row and commas separate values.</p><p>📃 CSV is popular due to its simplicity, universality, and ease of use. It is widely supported, facilitating data interchange between different systems. CSV files are human-readable, lightweight, and flexible, making storing and transmitting tabular data efficient.</p><p>You will find the use of CSV where you want the user to export a large amount of tabular data.</p><p>Before proceeding with the implementation, lets first understand what is OpenCSV and StreamingResponseBody.</p><p>💡 OpenCSV is a Java library for parsing and generating CSV files. OpenCSV handles most of the operations on .csv files, such as using the handy CSVReader and CSVWriter objects for low-level CSV operations or using CsvToBean to convert .csv files into Java beans.</p><pre>//Reading a CSV file <br><br>Reader reader = new FileReader(&quot;example.csv&quot;);<br><br>CSVReader csvReader = new CSVReader(reader);<br>String[] line = csvReader.readNext();</pre><pre>//Writing into a CSV file <br><br>Writer writer = new FileWriter(&quot;example.csv&quot;);<br><br>CSVWriter csvWriter = new CSVWriter(writer);<br>csvWriter.writeNext({&quot;id&quot;, &quot;name&quot;});<br>csvWriter.writeNext({&quot;1&quot;,&quot;abc&quot;});</pre><pre><br>//Bean based reading<br>Reader reader = new FileReader(&quot;example.csv&quot;);<br><br> CsvToBean&lt;Book&gt; cb = new CsvToBeanBuilder&lt;Book&gt;(reader)<br>         .withType(Book.class)<br>         .build();<br>List&lt;Book&gt; book = cb.parse();</pre><pre>//Bean based writing<br>Writer writer= new FileWriter(&quot;example.csv&quot;);<br>  new StatefulBeanToCsvBuilder&lt;Book&gt;(writer)<br>   .build()<br>   .write(books);</pre><h4>How to generate a CSV for download in Spring Boot.</h4><p>We can use StatefulBeanToCsv from OpenCSV and StreamingResponseBody to directly write a CSV and send it as a response.</p><p>💡StreamingResponseBody is an interface provided by spring framework that represents a response body that can be written directly to the output stream. It is particularly useful when you want to stream large amount of data.</p><p>StreamingResponseBody helps to off-load the task of stream generation to a different thread so that our request handlers are free to handle other incoming requests and are not impacted if a stream generation takes a long time.</p><p>👉 Let’s implement the “Download book details as CSV”.</p><p>Assume we have a BookRepository that stores a Book model. Here’s the implementation of the DownloadController.</p><pre>@RestController<br>@RequestMapping(&quot;/download&quot;)<br>public class DownloadController {<br>    private final BookRepository bookRepository;<br><br>    @Autowired<br>    public DownloadController(BookRepository bookRepository) {<br>        this.bookRepository = bookRepository;<br>    }<br><br>    @GetMapping(&quot;/bookDetails&quot;)<br>    public ResponseEntity&lt;StreamingResponseBody&gt; downloadCsv() {<br><br>        StreamingResponseBody stream = outputStream -&gt; {<br>            List&lt;Book&gt; books = bookRepository.findAll();<br>            try (Writer writer = new OutputStreamWriter(outputStream, StandardCharsets.UTF_8)) {<br>                try {<br>                    new StatefulBeanToCsvBuilder&lt;Book&gt;(writer)<br>                            .build().write(books);<br>                } catch (CsvDataTypeMismatchException | CsvRequiredFieldEmptyException e) {<br>                    throw new ResponseStatusException(HttpStatus.INTERNAL_SERVER_ERROR);<br>                }<br>            }<br>        };<br><br>        return ResponseEntity.ok()<br>                .contentType(MediaType.parseMediaType(&quot;text/csv; charset=UTF-8&quot;))<br>                .header(HttpHeaders.CONTENT_DISPOSITION, String.format(&quot;attachment; filename=%s&quot;, &quot;book_details.csv&quot;))<br>                .header(HttpHeaders.ACCESS_CONTROL_EXPOSE_HEADERS, HttpHeaders.CONTENT_DISPOSITION)<br>                .body(stream);<br>    }<br>}</pre><p>First we fetch all the book details from the repository, we create a writer to write our CSV in UTF-8 format. Using the StatefulBeanToCsv we convert bean to string and write into the response.</p><p>📌 Note: Here we have used a List&lt;Book&gt; but if your result set is large, you should use a Stream and make sure to perform database operation inside the StreamingResponseBody.</p><p>You can find the complete source code here on <a href="https://github.com/roulpriya/csv_download">Github</a>.</p><h4>Thanks for reading! If you found this article helpful :-</h4><ul><li><strong>☕️ </strong><a href="https://www.buymeacoffee.com/priyaroul"><strong>Buy me a coffee</strong></a><strong> : )</strong></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=02e141dcba10" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[My Journey of Leading a Project: Lessons Learned and Future Growth]]></title>
            <link>https://medium.com/@priyaroul99/my-journey-of-leading-a-project-track-lessons-learned-and-future-growth-2ae249200682?source=rss-7f74771f14ff------2</link>
            <guid isPermaLink="false">https://medium.com/p/2ae249200682</guid>
            <category><![CDATA[opportunity]]></category>
            <category><![CDATA[tech]]></category>
            <category><![CDATA[journey]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[skills]]></category>
            <dc:creator><![CDATA[Priya Roul]]></dc:creator>
            <pubDate>Sun, 24 Sep 2023 20:19:18 GMT</pubDate>
            <atom:updated>2023-09-26T17:56:36.026Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_yiZUiinals4sN1JI9F-CQ.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@goian?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Ian Schneider</a> on <a href="https://unsplash.com/photos/TamMbr4okv4?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Unsplash</a></figcaption></figure><p>👋🏻 Hello! I have been working as a software engineer at Baton Systems for a year. I am thrilled to share my journey of leading a project for the first time. It was a significant moment in my career, and I had a mix of excitement and worry as I was given a leadership role and put in charge of a new project.</p><p>Taking on this project meant that other people trusted me to lead them. I wasn’t sure if I could handle it. This experience made me think about how I got to where I am and the challenges I faced.</p><h4><strong>1. The Planning Phase:</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VLuM7HN0live4V4UMLueSw.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@cathrynlavery?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Cathryn Lavery</a> on <a href="https://unsplash.com/photos/fMD_Cru6OTk?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Unsplash</a></figcaption></figure><p>I began by comprehensively grasping the product team’s requirements in the initial stage. I meticulously formulated a preliminary design flow, transposing my thoughts onto paper, and sought clarification by actively engaging in discussions whenever any aspect remained unclear. I learned more about the project’s details by talking with my co-workers. Simultaneously, I contemplated the array of services that should ideally be integrated into this process and carefully strategized the code approach to be pursued.</p><p><em>What I could have done better is:</em></p><ul><li><em>Adopting a customer-centric approach</em></li><li><em>Enhancing communication with the product team</em></li><li><em>Seeking guidance from codebase owners</em></li><li><em>Streamlining flow design to eliminate loopholes</em></li></ul><h4><strong>2. The Design Phase:</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jsFEIV_6eWgEDudJ43NCUA.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@wocintechchat?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Christina @ wocintechchat.com</a> on <a href="https://unsplash.com/photos/tYVkjjMYFBo?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Unsplash</a></figcaption></figure><p>During the design phase, I admit to rushing through the process without fully grasping the feature’s intricacies and potential consequences. I encountered challenges when attempting to apply system design concepts and principles. Fortunately, my mentors played a pivotal role in enhancing my understanding of the requirements and the design.</p><p>For instance, I encountered difficulties in utilizing application events or queues, and they provided much-needed clarification on these aspects.</p><p>I presented my design proposal to the team, and they collectively agreed on the chosen approach.</p><p><em>What I could have done better is:</em></p><ul><li><em>Gain a comprehensive understanding of core product requirements</em></li><li><em>Collaborate with product teams and leads to identify and address corner cases</em></li><li><em>Optimize system design choices for improved results</em></li></ul><h4><strong>3. The Implementation Phase:</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BP7Jy0-Om-9mgRxdNvf_cw.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@zanilic?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Zan</a> on <a href="https://unsplash.com/photos/X_JsI_9Hl7o?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Unsplash</a></figcaption></figure><p>I took responsibility for the entire project, assigning tasks to my mentee and providing guidance as we navigated our code base. After we broke the project into manageable tasks we established deadlines, and then started coding!</p><p>Throughout coding and testing, we uncovered various complex edge cases. At one point, we revisited our approach, which was time-consuming, and we continued to discover new edge cases later on.</p><p>What I could have done better is:</p><ul><li><em>Thoroughly reviewing feature requirements and design</em></li><li><em>Enhancing mentorship and support for my mentee</em></li><li><em>Preemptively addressing and managing edge cases</em></li><li><em>Rigorous testing for all implementations</em></li><li><em>Allocating dedicated time for testing</em></li></ul><h4>The fruit of my labours</h4><p>The feature release went smoothly, and I received praise for achieving my first milestone. However, a sense of dissatisfaction lingered within me, recognizing the potential for improvement. It was my initial venture into a new role, having previously been solely an individual contributor.</p><p>This experience provided me with valuable lessons and learning opportunities. In the future, I hope to transform everything I could have done differently into what I would have accomplished.</p><p>Thanks for reading!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2ae249200682" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What is Constructor Injection, and why should you use it in Spring]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://medium.com/@priyaroul99/what-is-constructor-injection-and-why-should-you-use-it-in-spring-bdb3e1857c58?source=rss-7f74771f14ff------2"><img src="https://cdn-images-1.medium.com/max/2600/1*UIjCTbGvBfql9vcGm8bFPg.jpeg" width="5727"></a></p><p class="medium-feed-snippet">This article explains why you should prefer constructor injection over field injection.</p><p class="medium-feed-link"><a href="https://medium.com/@priyaroul99/what-is-constructor-injection-and-why-should-you-use-it-in-spring-bdb3e1857c58?source=rss-7f74771f14ff------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://medium.com/@priyaroul99/what-is-constructor-injection-and-why-should-you-use-it-in-spring-bdb3e1857c58?source=rss-7f74771f14ff------2</link>
            <guid isPermaLink="false">https://medium.com/p/bdb3e1857c58</guid>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[design]]></category>
            <category><![CDATA[startup]]></category>
            <dc:creator><![CDATA[Priya Roul]]></dc:creator>
            <pubDate>Fri, 16 Jun 2023 14:38:21 GMT</pubDate>
            <atom:updated>2024-08-22T11:38:18.032Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[30 Life Lessons That Will Change Your Life]]></title>
            <link>https://medium.com/@priyaroul99/30-life-lessons-that-will-change-your-life-5b6eaf4ee3bb?source=rss-7f74771f14ff------2</link>
            <guid isPermaLink="false">https://medium.com/p/5b6eaf4ee3bb</guid>
            <category><![CDATA[travel]]></category>
            <category><![CDATA[self-improvement]]></category>
            <category><![CDATA[life-lessons]]></category>
            <category><![CDATA[tech]]></category>
            <category><![CDATA[startup]]></category>
            <dc:creator><![CDATA[Priya Roul]]></dc:creator>
            <pubDate>Wed, 14 Jun 2023 16:13:07 GMT</pubDate>
            <atom:updated>2023-06-14T16:13:07.646Z</atom:updated>
            <content:encoded><![CDATA[<blockquote>Easy choices: hard life, hard choices: easy life. It’s your choice!</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GbxYYIhyZgb8oQk0cRKxHw.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@teus_prome?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Vladimir Visotsky</a> on <a href="https://unsplash.com/t/business-work?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Unsplash</a></figcaption></figure><ol><li>The only audience you should look for is one that aligns with your interests.</li><li>Being attractive(in business and in life) is within your control.</li><li>Ask for what you want.</li><li>Tell people you appreciate them, often and now.</li><li>Show your personality.</li><li>Drive in sports mode.</li><li>Bank a year’s living expenses as fast as you can.</li><li>Your outcomes are bound by your appetite for risk.</li><li>Run your career like a business.</li><li>Charge more for your work every year.</li><li>Save your best hours for creative work.</li><li>Meetings before and after work only.</li><li>If you want a stressful life, schedule everything.</li><li>A personal website is the simplest way to stand out.</li><li>Perfect condition never exists.</li><li>Learn to code.</li><li>Learn to sell.</li><li>The only partner you should look for is one that aligns with your values.</li><li>If you find a partner who supports your endeavours hold on to them for dear life.</li><li>If you’re overwhelmed, exercise today and do something small tomorrow.</li><li>Keep a close circle of local friends and a network around the world.</li><li>Focus on the people you want to help.</li><li>To understand the benefits of doing something for a longtime, do something for a longtime.</li><li>The freedm to choose where you work from, who you work with and what you work on is worth a lot of money.</li><li>There’s a middle ground between billion dollar foundation and 9–5 office job that will make you very happy.</li><li>Go to the gym.</li><li>Get a dog.</li><li>Share your work.</li><li>Get comfortable talking about money or it will give you headaches, resentment and anxiety for life.</li><li>The best time to start is now.</li></ol><p>Thanks for Reading!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5b6eaf4ee3bb" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>