<?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 Zulfiqar Ahmed on Medium]]></title>
        <description><![CDATA[Stories by Zulfiqar Ahmed on Medium]]></description>
        <link>https://medium.com/@zulfiqarjunejo?source=rss-ecfd822d484d------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*twdncio4dkMrsHVgxV_tCQ.jpeg</url>
            <title>Stories by Zulfiqar Ahmed on Medium</title>
            <link>https://medium.com/@zulfiqarjunejo?source=rss-ecfd822d484d------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 30 Nov 2026 22:37:43 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@zulfiqarjunejo/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[How Testcontainers Improved CI/CD Pipelines & Developer Experience]]></title>
            <link>https://medium.com/@zulfiqarjunejo/how-testcontainers-improved-ci-cd-pipelines-developer-experience-b3a7bd53e22f?source=rss-ecfd822d484d------2</link>
            <guid isPermaLink="false">https://medium.com/p/b3a7bd53e22f</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[test-automation]]></category>
            <category><![CDATA[pipeline]]></category>
            <category><![CDATA[testing]]></category>
            <category><![CDATA[docker]]></category>
            <dc:creator><![CDATA[Zulfiqar Ahmed]]></dc:creator>
            <pubDate>Fri, 23 Feb 2024 21:07:58 GMT</pubDate>
            <atom:updated>2024-02-23T21:07:58.969Z</atom:updated>
            <content:encoded><![CDATA[<p>Software engineers love to solve problems. Not a good opener. Software engineers love implementing business requirements, amazing algorithms, and well-thought-out automated tests. Wait… tests? Yep!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mHGimMhQczOEGpqglwg2pQ.png" /><figcaption>DALL.E generated the image for “single software engineer integration testing stressful”</figcaption></figure><p>Without sounding controversial right from the start, let me explain. Software engineers love to write tests, giving them peace of mind and freedom to refactor their code without worrying about breaking something. What is frowned upon in the engineering community is the experience surrounding automated tests. Let’s dive into it!</p><p>Most of the software landscape is dependent on container technology such as Docker, Podman, etc. This means that engineers would need to write unit tests, and integration tests in a way that they can be executed during CI/CD pipelines. For this example, I am using Github Actions, but you would be able to spot the patterns in almost every CI/CD platform.</p><pre>name: ci<br>run-name: continuous integration pipeline<br>on: [push]<br><br>jobs:<br>  lint-and-build-and-test:<br>    runs-on: ubuntu-latest<br>    steps:<br>      - uses: actions/checkout@v4<br>      - uses: actions/setup-node@v3<br>        with:<br>          node-version: &#39;18&#39;<br>      - run: npm run build<br>      - run: rm -rf dist<br>      - run: docker-compose up -d<br>      - run: grep -m 1 &quot;now running on port 4006&quot; &lt;(docker logs -f name_of_service)<br>      - run: docker exec -w /usr/src/app name_of_service npm run test<br>      - run: docker-compose stop</pre><p>Found problems? Picture this: you spin up a full-fledged application using docker compose up—a process that can easily eat up 1-2 minutes depending on the service&#39;s complexity. Then, you perform some fancy command to wait until your service whispers, &quot;Now running on port 4006&quot; in the logs. Finally, you dive into the running container and issue a npm run test command. Sounds tedious and resource-intensive, right?</p><p>Enter Testcontainers! I’ve been hearing rave reviews about Testcontainers since the start of the year, and now that I’ve given it a whirl, I must say, I’m impressed. Let’s take a peek at the revamped YAML file for Github Actions.</p><pre>name: ci<br>run-name: continuous integration pipeline<br>on: [push]<br><br>jobs:<br>  lint-and-build-and-test:<br>    runs-on: ubuntu-latest<br>    steps:<br>      - uses: actions/checkout@v4<br>      - uses: actions/setup-node@v3<br>        with:<br>          node-version: &#39;18&#39;<br>      - run: npm install<br>      - run: npm run build<br>      - run: rm -rf dist<br>      - run: TZ=Europe/Berlin npm run test -- --ci --maxWorkers=2</pre><p>Now, our test suite leverages the Testcontainers library to spawn lightweight containers and seamlessly integrate them into our service. Despite their featherweight nature, these containers pack all the functionality of their bulkier counterparts, ensuring our test cases run smoothly without missing a beat.</p><p>Curious about how it all works? Fear not — I’m brewing up another article to delve into Testcontainers in depth. But for now, feel free to explore my repository at <a href="https://github.com/zulfiqarjunejo/node-testcontainer-demo">https://github.com/zulfiqarjunejo/node-testcontainer-demo</a>.</p><p>P.S.: Eager to collaborate on learning new technologies? I’m all ears! Let’s dive into the world of possibilities together!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b3a7bd53e22f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[“Evolving Perspectives: A Journey into Golang, Testing Simplicity, and Breaking Comfort Zones”]]></title>
            <link>https://medium.com/@zulfiqarjunejo/title-evolving-perspectives-a-journey-into-golang-testing-simplicity-and-breaking-comfort-3c3852ced252?source=rss-ecfd822d484d------2</link>
            <guid isPermaLink="false">https://medium.com/p/3c3852ced252</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[testing]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[go]]></category>
            <dc:creator><![CDATA[Zulfiqar Ahmed]]></dc:creator>
            <pubDate>Thu, 11 Jan 2024 17:36:29 GMT</pubDate>
            <atom:updated>2024-01-11T17:37:44.553Z</atom:updated>
            <content:encoded><![CDATA[<p>Date: January 11, 2024</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YhfWIVUOREjyR-AwZtcLyA.png" /></figure><p>Today’s exploration into Golang’s unit testing capabilities sparked a revelation — a realization that I should have embraced this language much sooner. Delving into the intricacies, I uncovered two key factors that set Golang apart: built-in support for testing and a straightforward naming convention for test functions.</p><pre>// A simple Golang test function<br>func TestExample(t *testing.T) {<br>    result := ExampleFunction()<br>    expected := &quot;Hello, Golang!&quot;<br>    <br>    if result != expected {<br>        t.Errorf(&quot;Expected %s, but got %s&quot;, expected, result)<br>    }<br>}</pre><p>Reflecting on my reluctance to switch, I discovered it was rooted in a year of comfort with my existing tech stack. However, today marked a conscious decision to break free from this comfort zone, reigniting my commitment to active learning. In this comprehensive article, I share the simplicity of Golang’s unit testing, the benefits of the language’s built-in support, and the personal journey of transitioning from complacency to a proactive pursuit of knowledge. It’s a tale of evolution, adaptation, and the continuous quest for improvement in the dynamic realm of technology.</p><p>Ending the article with a question: what’s your strategy to keep learning new technologies?</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3c3852ced252" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Fail Early, Succeed Strong: Mastering Environment Variable Validation]]></title>
            <link>https://medium.com/@zulfiqarjunejo/fail-early-succeed-strong-mastering-environment-variable-validation-9e26f3a4e14f?source=rss-ecfd822d484d------2</link>
            <guid isPermaLink="false">https://medium.com/p/9e26f3a4e14f</guid>
            <category><![CDATA[backend]]></category>
            <category><![CDATA[go]]></category>
            <category><![CDATA[software]]></category>
            <category><![CDATA[environment-variables]]></category>
            <dc:creator><![CDATA[Zulfiqar Ahmed]]></dc:creator>
            <pubDate>Fri, 15 Dec 2023 14:30:51 GMT</pubDate>
            <atom:updated>2023-12-15T14:46:24.022Z</atom:updated>
            <content:encoded><![CDATA[<h3><strong>Introduction</strong></h3><p>As software engineers, our goal is to provide reliable and robust software systems that provide a guarantee of zero percent downtime. In such a setting where every line of code sets the stage for functionality, environment variables stand as crucial backstage players. These variables hold pivotal configuration settings, dictating an application’s behavior across various environments. Yet, their power comes with a caveat: a missed variable or an incorrectly formatted one can throw the entire performance off the hill.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*7gKpsIBxfQz7xdjgdsC6ow.jpeg" /><figcaption>His environment is validated ;)</figcaption></figure><p>Now that I have established that validation of the environment (- and variables) is a crucial part of software engineering, I would like to highlight the “Fail Early” principle to help us mitigate such errors as early in the SDLC as possible. At its core lies the proactive pursuit of problems before they morph into catastrophic bugs, fostering resilient systems through timely identification and resolution.</p><p>In this article, we delve into a specific facet of this principle: the art of validating environment variables. Join me on this journey as we decipher the intricacies of validating environment variables through the fail-early lens, empowering developers to preempt issues and fortify their code from its very foundation.</p><h3>Problem</h3><p>To address this challenge effectively, I am representing it as a validation problem. A software system must validate that:<br>1. all required environment variables are present<br>2. all environment variables are correctly formatted</p><h3>Solution</h3><p>I believe that the environment (- and variables) should be validated before everything else. As a personal rule, I validate my environment on line # 1, figuratively. Following is an example from one of my backend Golang-based services.</p><pre>func main() {<br> envConfig, err := environment.InitEnvironmentVariables()<br> if err != nil {<br>  log.Fatalf(&quot;Error initializing environment variables: %v\n&quot;, err)<br> }<br><br>  // setup database<br>  // setup schedulers<br><br> fmt.Printf(&quot;Pod %s listening on port %s...\n&quot;, envConfig.POD_NAME, envConfig.PORT)<br> log.Fatal(fasthttp.ListenAndServe(fmt.Sprintf(&quot;:%s&quot;, envConfig.PORT), handler))<br>}</pre><p>As you can see my service starts by validating the environment. It will only continue setting up the database, scheduler, and everything else IF and only IF the environment variables are present.</p><p>There are a lot of amazing libraries to help you to validate the environment in different programming languages. I created a Golang package called “gonvironment” just for learning purposes. You can check it out at <a href="https://github.com/zulfiqarjunejo/gonvironment">https://github.com/zulfiqarjunejo/gonvironment</a>. My package not only validates the environment but also provides you with all of the values in your interface.</p><p>I hope this article was helpful. It would be my pleasure to receive feedback from you.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9e26f3a4e14f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why blockchain should matter to layman?]]></title>
            <link>https://medium.com/@zulfiqarjunejo/why-blockchain-should-matter-to-layman-9bd815b33c45?source=rss-ecfd822d484d------2</link>
            <guid isPermaLink="false">https://medium.com/p/9bd815b33c45</guid>
            <category><![CDATA[blockchain]]></category>
            <category><![CDATA[cryptocurrency]]></category>
            <category><![CDATA[bitcoin]]></category>
            <dc:creator><![CDATA[Zulfiqar Ahmed]]></dc:creator>
            <pubDate>Sun, 03 Jun 2018 13:39:14 GMT</pubDate>
            <atom:updated>2018-06-03T13:44:28.893Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/415/1*HK_jBgfR6PwNC3DS1396ug.jpeg" /></figure><p>“Most of the good things begin with late night chitchat and a cup of tea” my friend said in a philosophical tone! :)) This was during our conversation at Chai Shai, a famous tea hotel, when I was introduced to Bitcoin and Ethereum. My journey in the world of cryptocurrency began as a small fish (investor) mostly motivated by greed. Greed to make money fast. Little did I know that one day this very journey will be fueled by the love for the blockchain technology. In this article I will present why I care for blockchain and people should too.</p><p>[Story behind this writing…]<br>Recently, a friend of mine paid €165 to uni-assist (an organization which handles admission in Germany) as fees for my application. It was agreed that I will send him the amount in a few days. *I’m a man of my word* Now there is only one question: how? I visited my bank and asked them to transfer the desired amount to a certain international account. The response hit me hard, really hard. I was told that such a SMALL amount will not be entertained. Additionally, almost every bank mentioned limitation of banks when dealing with international funds transfer. I was suggested to use Western Union (WU) money transfer. Alright! I took a ride to a nearby WU branch, I presented them details and asked if they can transfer €165 to my friend living in Germany? “Yes” was the reply. YES YES YES! But alas! *something went wrong* WU’s customer service representative proceeded with the transfer. I handed him all the details and was really happy to get it done quickly and go back to play FIFA 2018 when I heard “Sorry! We can’t do it”. Reason: due to security reasons international fund transfer is only possible for “Muslim to Muslim” or “Hindu to Hindu”. This absolute nonsense rules and regulations are the whole point of talk.</p><p>Centralized institutions such as banks, exchanges, payment gateways etc have plagued the economy to such levels that personal as well as business transactions have to go through many stages which are nothing but noise. I prefer not to get negative, but I should say that these organizations have literally hijacked the economy with weird rules and regulations. I’ll not discuss benefits of decentralization, instead I’ll stick to how cryptocurrency could help in my case. I could purchase X quantity of Y coin worth €165 and send it directly to the wallet of my friend. This simple step demonstrates the power of cryptocurrency and blockchain in general. Blockchain is not limited to money. Digital assets, copyrights, any form of value can be transferred and verified using blockchain. There are many great projects and dApps working days and nights to bring the much needed power back to the masses. The power that will bring the ownership of assets back to the owners.</p><p>In conclusion, I would plead everyone to dive deep into the technology to understand what, how and why of blockchain. This innovation will open the gates to sustainable economy, the one which we deserve :))</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9bd815b33c45" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Strip firebase’s control of routing — Angular 2]]></title>
            <link>https://medium.com/@zulfiqarjunejo/strip-firebases-control-of-routing-angular-2-845fdab3de47?source=rss-ecfd822d484d------2</link>
            <guid isPermaLink="false">https://medium.com/p/845fdab3de47</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[angular2]]></category>
            <category><![CDATA[firebase]]></category>
            <dc:creator><![CDATA[Zulfiqar Ahmed]]></dc:creator>
            <pubDate>Fri, 31 Mar 2017 22:28:00 GMT</pubDate>
            <atom:updated>2017-03-31T22:28:00.296Z</atom:updated>
            <content:encoded><![CDATA[<p>When a single page application (SPA) built using modern web frameworks like Angular 2/React is uploaded on firebase, it is usually firebase who has control over routing. In such conditions if a URL for a page that is <strong>not</strong> index is hit directly from a browser, firebase will respond with its traditional 404.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/317/1*jh8w2qfF6sY7yHhUd6Czrg.jpeg" /></figure><p>Don’t be sad. Firebase comes to the rescue. Inside firebase.json file add the snippet:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/9aa6bbb557c49402f59777a5c1593052/href">https://medium.com/media/9aa6bbb557c49402f59777a5c1593052/href</a></iframe><p>rewrites tells firebase the scheme to of URLs. Then we specify that,<br>“source”: “**”, “destination”: “/index.html” which essentially strips the control of routes from firebase and instead commands the firebase to take a chill pill and forward all the requests to index.html so that Angular 2 can take the charge!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/213/1*0EQMrNyHVHbJJ2SD1lhDkw.gif" /></figure><p>Yayyyyy! :) Now all the requests will be controlled by Angular 2.</p><p>Please feel free to talk to me at zulfiqarjunejo@live.com</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=845fdab3de47" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>