<?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 Eugenius Mario on Medium]]></title>
        <description><![CDATA[Stories by Eugenius Mario on Medium]]></description>
        <link>https://medium.com/@eugeniusmario?source=rss-974c337fafb0------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*7EtpGscXAfarmatax5rjGw.jpeg</url>
            <title>Stories by Eugenius Mario on Medium</title>
            <link>https://medium.com/@eugeniusmario?source=rss-974c337fafb0------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 23 Nov 2026 01:53:30 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@eugeniusmario/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[Nani Agritech Series: A Reminder, Product Market Fit for Programmers: No Matter How Advanced The…]]></title>
            <link>https://eugeniusmario.medium.com/a-reminder-180d5fd09b07?source=rss-974c337fafb0------2</link>
            <guid isPermaLink="false">https://medium.com/p/180d5fd09b07</guid>
            <category><![CDATA[early-stage-startup]]></category>
            <category><![CDATA[adoption]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[product-validation]]></category>
            <category><![CDATA[product]]></category>
            <dc:creator><![CDATA[Eugenius Mario]]></dc:creator>
            <pubDate>Wed, 29 May 2024 16:41:40 GMT</pubDate>
            <atom:updated>2024-06-01T11:19:13.251Z</atom:updated>
            <content:encoded><![CDATA[<h3>Nani Agritech Series: A Reminder, Product Market Fit for Programmers: No Matter How Advanced The Technology is, it’s Useless if There’s No One Willing to Use it.</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HAJgewijBDFhmMKZ3R0uvQ.png" /><figcaption>A Reminder! Product Market Fit for Programmers by eugeniusmario.</figcaption></figure><p>In the fast-paced world of technology, where innovation is constant and advancements are relentless, one fundamental truth remains unchanged: <strong>the importance of product-market fit.</strong> This article serves as a poignant reminder to programmers and tech enthusiasts alike of the critical significance of aligning technological advancements with user needs and market demands.</p><p>As we embark on this exploration, we confront the sobering reality that even the most cutting-edge technologies are rendered futile if they fail to resonate with users. Through a journey of introspection and analysis, <strong>we delve into the essence of product-market fit, dissecting its components and implications for the tech industry.</strong></p><p>Join us as we unravel the complexities of this pivotal concept, <strong>shedding light on the challenges and opportunities it presents for programmers seeking to make meaningful contributions in today’s competitive landscape.</strong> Through anecdotes, insights, and practical advice, we aim to empower readers with the knowledge and awareness needed to navigate the ever-evolving intersection of technology and market dynamics.</p><p>I divide this article into <strong>3 chapters</strong> as follows:</p><ul><li><strong>Chapter 1</strong>: Understanding Product Market Fit</li><li><strong>Chapter 2:</strong> Strategies for Achieving Product Market Fit</li><li><strong>Chapter 3:</strong> Case Studies and Lessons Learned</li></ul><p>In each chapter I will explain how important it is to understand this aspect for people who want to make products. Let’s dive!</p><h3>Chapter 1: Understanding Product Market Fit</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FAC41zkTOCRkewZdGTWxHw.png" /><figcaption>Product Market Fit by eugeniusmario.</figcaption></figure><p>In the realm of software development, <strong>understanding product market fit is fundamental.</strong> This chapter delves into the core concepts and significance of product market fit for programmers. <strong>Product market fit refers to the alignment between a product’s features and the needs of its target market.</strong> It’s not merely about creating a product with advanced technology but ensuring that there’s a genuine demand for it in the market. <strong>Without achieving product market fit, even the most sophisticated technology may fail to gain traction.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FMDt6WxKkd4ZsppA3zglsA.png" /><figcaption>Market research Nani Agritech with team by eugeniusmario.</figcaption></figure><p><strong>To grasp the essence of product market fit, we need to delve into market research and customer validation. </strong>This involves identifying the pain points of the target audience, understanding their preferences, and validating whether the proposed solution adequately addresses their needs. It’s about more than just building a product; <strong>it’s about solving a real problem that resonates with users.</strong></p><p>For <a href="https://naniagritech.com/">Nani Agritech</a>’s case, several survey methods can be employed to gather feedback from users:</p><ol><li><strong>Face-to-Face Interviews</strong></li></ol><p>Conducting direct interviews with farmers or potential users to <strong>gain in-depth insights into their needs and challenges in their farming practices.</strong> Such interviews can be done in-person or via phone, and can help build personal relationships with users.</p><p><strong>2. Focus Group Discussions</strong></p><p>Hosting focus group discussions with small groups of farmers or potential users to hear their perspectives on the products or services offered by <a href="https://naniagritech.com/">Nani Agritech</a>. Such discussions allow for<strong> deeper sharing of experiences and ideas, facilitating collaboration among participants in developing better solutions.</strong></p><p><strong>3. Field Observations</strong></p><p>Directly observing farmers’ farming practices to better understand their <strong>workflow, challenges they face, and areas where technology can contribute to improving efficiency or productivity.</strong> Such observations can provide valuable insights into the best ways to design products or services that meet users’ needs.</p><p>By using a combination of these survey methods, <a href="https://naniagritech.com/">Nani Agritech</a> can obtain comprehensive insights into the needs and preferences of their users, which can help guide their product development and service offerings more effectively.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_bCGwUlkUmP1oNz5qbSZUw.png" /><figcaption>Competitor analysis for Nani Agritech by eugeniusmario.</figcaption></figure><p>Achieving product market fit <strong>requires a deep understanding of the target market’s dynamics, including competitors, industry trends, and user behavior. </strong>By gaining insights into the market landscape, programmers can tailor their product development efforts to meet the evolving demands of customers. <strong>Ultimately, the goal is to create a product that not only showcases technological prowess but also fulfills a genuine need in the market, thus laying the foundation for long-term success.</strong></p><p>In analyzing competitors for <a href="https://naniagritech.com/">Nani Agritech</a>’s case, the following points should be compared:</p><ol><li><strong>Product Offerings</strong></li></ol><p>Compare the features, functionalities, and specifications of competitors’ products or services with those of <a href="https://naniagritech.com/">Nani Agritech</a>. This includes assessing <strong>the range of products offered, their quality, and any unique selling points.</strong></p><p><strong>2. Market Presence</strong></p><p>Evaluate the <strong>market share, distribution channels, and geographic reach of competitors compared to </strong><a href="https://naniagritech.com/"><strong>Nani Agritech.</strong></a> This involves identifying key markets served by competitors and assessing their brand visibility and reputation.</p><p><strong>3. Customer Base</strong></p><p><strong>Analyze the customer segments targeted by competitors and their respective customer bases</strong>. This includes understanding the demographics, preferences, and needs of customers served by competitors and how they overlap with <a href="https://naniagritech.com/">Nani Agritech</a>’s target market.</p><p><strong>4. Pricing Strategy</strong></p><p>Compare the pricing strategies adopted by competitors, including pricing models, pricing tiers, and any promotional offers or discounts. Assess how competitors’ pricing aligns with <a href="https://naniagritech.com/">Nani Agritech</a>’s <strong>pricing strategy and perceived value proposition.</strong></p><p><strong>5. Technological Advancements</strong></p><p>Evaluate the technological capabilities and innovations of competitors’ <strong>products or services, including any patents or proprietary technologies.</strong> Compare these with <a href="https://naniagritech.com/">Nani Agritech</a>’s technological offerings and assess areas of differentiation or competitive advantage.</p><p><strong>6. Customer Experience</strong></p><p><strong>Assess the overall customer experience provided by competitors, including pre-sales support, post-sales service, and customer satisfaction levels.</strong> Compare this with <a href="https://naniagritech.com/">Nani Agritech’</a>s customer experience initiatives and identify areas for improvement.</p><p><strong>7. Marketing and Branding</strong></p><p>Analyze competitors’ marketing strategies, including branding, advertising campaigns, and online presence. Compare these with <a href="https://naniagritech.com/">Nani Agritech</a>’s <strong>marketing efforts and assess effectiveness in reaching and engaging target customers.</strong></p><p><strong>8. Business Model</strong></p><p>Evaluate the business models adopted by competitors,<strong> including revenue streams, partnerships, and sustainability.</strong> Compare this with <a href="https://naniagritech.com/">Nani Agritech</a>’s business model and assess scalability and long-term viability.</p><p><strong>9. Regulatory Compliance</strong></p><p>Assess competitors’ compliance with industry regulations, standards, and certifications. Compare this with <a href="https://naniagritech.com/">Nani Agritech</a>’s <strong>regulatory compliance efforts and identify any areas of risk or opportunity.</strong></p><p><strong>10. Financial Performance</strong></p><p>Analyze competitors’ financial statements, revenue growth, profitability, and investment activities. Compare this with <a href="https://naniagritech.com/">Nani Agritech</a>’s <strong>financial performance and assess relative strength and stability in the market.</strong></p><h3>Chapter 2: Strategies for Achieving Product Market Fit</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nyVJEgefXrXCzad8rQSlBg.png" /><figcaption>Strategy for achieving product market fit by eugeniusmario.</figcaption></figure><p>In the quest for product market fit, programmers must navigate through various strategies to ensure their creations resonate with the intended audience. <strong>Here are some key strategies to consider:</strong></p><ol><li><strong>Market Research and Validation</strong></li></ol><p>Referring to chapter 1, before diving headfirst into development, conduct thorough market research to understand the needs, pain points, and preferences of your target audience. Validate your assumptions by gathering feedback through surveys, interviews, or focus groups.<strong> This insight will guide your product development process and increase the likelihood of achieving market fit.</strong></p><p><strong>2. Agile Development and Iteration</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OQDYFz8ctvkzR4B6ehOPNQ.png" /><figcaption>Agile System: Task Planning Notion in Nani Agritech by eugeniusmario.</figcaption></figure><p><strong>Adopt an agile development approach that emphasizes flexibility and responsiveness to customer feedback</strong>. Break down your product roadmap into small, manageable iterations, allowing you to quickly test and iterate on features based on user feedback. This iterative process enables you to course-correct early and align your product with market demands.</p><p><strong>3. Minimum Viable Product (MVP) Development</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*x0gA-J4ha4cqVtqO26Sejg.png" /><figcaption>MVP development in Nani Agritech by eugeniusmario.</figcaption></figure><p>Build a minimum viable product (MVP) with essential features that address core user needs. By focusing on delivering value quickly and efficiently, you can gather early feedback from users and iterate on your product iteratively. <strong>This lean approach minimizes time and resources spent on developing features that may not resonate with the market.</strong></p><p><strong>4. User-Centric Design</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*k0fkcGNBKOlRT7AFqYGRAA.png" /><figcaption>A capture from Figma Nani Agritech by eugeniusmario.</figcaption></figure><p>Prioritize user experience (UX) and design principles throughout the development process. <strong>Invest in user-centric design practices, such as user testing, prototyping, and usability studies, to ensure your product is intuitive, accessible, and enjoyable to use.</strong> By placing users at the center of your design decisions, you can create a product that meets their needs and exceeds their expectations.</p><p><strong>5. Continuous Customer Engagement</strong></p><p>Referring to chapter 1, <strong>cultivate a culture of continuous customer engagement and feedback loops. </strong>Establish channels for users to provide feedback, such as customer support, community forums, or feedback forms within your product. Actively listen to user input, respond promptly to their needs, and incorporate their suggestions into future iterations of your product. This ongoing dialogue fosters a sense of ownership and loyalty among your user base.</p><p><strong>6. Competitive Analysis</strong></p><p>Referring to chapter 1, conduct thorough competitive analysis to understand the strengths, weaknesses, and strategies of your competitors. Identify gaps in the market and opportunities for differentiation that can inform your product development strategy. <strong>By learning from the successes and failures of competitors, you can position your product more effectively and capture market share.</strong></p><p>By implementing these strategies, <strong>programmers can increase their chances of achieving product market fit and building successful products that resonate with their target audience. </strong>Through a combination of market research, agile development, user-centric design, and continuous customer engagement, programmers can navigate the complexities of product development and emerge with a product that meets the needs of the market.</p><h3>Chapter 3: Case Studies and Lessons Learned</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Ueg5kR9Wljuu6XUL1HO8mA.png" /><figcaption>Case studies and lesson learned from product market fit by eugeniusmario.</figcaption></figure><p><strong>Case Study: SmartFarm Solutions</strong></p><p><strong><em>Overview:</em></strong></p><p>SmartFarm Solutions aims to revolutionize the agricultural industry with its flagship product, SmartCrop, an AI-powered crop monitoring system. However, the company <strong>faces challenges in gaining widespread adoption among farmers due to resistance to technology adoption, affordability concerns, and lack of awareness.</strong></p><p><strong><em>Tasks:</em></strong></p><p>As a team member of SmartFarm Solutions, your task is to <strong>develop a comprehensive strategy to address these challenges and increase adoption of SmartCrop among farmers.</strong> Here are some comments to guide you:</p><ol><li><strong>Market Research</strong></li></ol><ul><li>Conduct thorough market research to understand the needs, preferences, and pain points of different segments of farmers.</li><li>Use surveys, interviews, and focus groups to gather insights into farmers’ attitudes towards technology adoption and their willingness to pay for SmartCrop.</li></ul><p><strong>2. User-Centric Design</strong></p><ul><li>Develop user personas based on the insights gathered from market research.</li><li>Ensure that SmartCrop is intuitive, user-friendly, and addresses the specific needs of farmers, such as crop health monitoring, water management, and pest detection.</li></ul><p><strong>3. Pricing and Packaging</strong></p><ul><li>Explore different pricing models, such as subscription-based pricing or pay-per-use models, to make SmartCrop more affordable for farmers.</li><li>Consider offering tiered pricing options based on farm size or usage levels to cater to the needs of different types of farmers.</li></ul><p><strong>4. Education and Training</strong></p><ul><li>Develop educational materials, tutorials, and user guides to help farmers understand the benefits of SmartCrop and how to use it effectively.</li><li>Offer training programs and workshops to provide hands-on experience and support to farmers in adopting and implementing SmartCrop on their farms.</li></ul><p><strong>5. Marketing and Outreach</strong></p><ul><li>Develop a targeted marketing campaign to raise awareness of SmartCrop among farmers.</li><li>Utilize digital marketing channels, such as social media, email newsletters, and online forums, to reach farmers in rural areas.</li><li>Partner with agricultural publications, trade shows, and events to showcase SmartCrop and demonstrate its value to farmers.</li></ul><p><strong>6. Partnership and Collaboration</strong></p><ul><li>Identify potential partners, such as agricultural cooperatives, government agencies, and agritech organizations, to collaborate with in promoting SmartCrop.</li><li>Leverage existing networks and industry connections to establish partnerships that can provide additional support and resources to farmers adopting SmartCrop.</li></ul><p><strong><em>Deliverables:</em></strong></p><p><strong>Present a detailed strategy document outlining your proposed approach to addressing the challenges faced by SmartFarm Solutions</strong> and increasing adoption of SmartCrop among farmers. Include actionable steps for each component of the strategy, as well as metrics for monitoring and evaluating success.</p><p><strong><em>Hints:</em></strong></p><p>When conducting market research, it’s essential to dive deep into understanding the diverse landscape of farmers. Segmenting farmers based on variables like farm size, crop type, geographical location, and technological proficiency can provide invaluable insights. Analyzing patterns and trends within these segments can reveal nuanced preferences and pain points, guiding product development and marketing strategies. Additionally, don’t overlook competitor analysis and industry reports, as they offer valuable context for understanding market dynamics and identifying opportunities for differentiation.</p><p>User-centric design is paramount in ensuring the success of SmartCrop. Continuous usability testing and feedback gathering throughout the product development process are crucial. By involving farmers in usability tests, you can assess whether SmartCrop meets their needs and expectations effectively. Pay close attention to user interface design, ensuring that the system is intuitive and easy to navigate, even for farmers with limited technical expertise. Consider offering customizable features that empower farmers to tailor SmartCrop to their specific farming practices and preferences, enhancing its relevance and usability.</p><p>In marketing and outreach efforts, customization is key to resonating with different segments of farmers. Craft tailored messages and content that highlight the unique benefits and value propositions of SmartCrop for each group. Utilize testimonials and case studies from early adopters to build credibility and trust among potential customers. Explore grassroots marketing strategies, such as hosting local events or partnering with agricultural extension services, to reach farmers in remote areas effectively. By leveraging community engagement and localized initiatives, you can establish a strong presence and foster meaningful connections with your target audience.</p><h3>The End</h3><p>In conclusion, the journey to achieving product market fit is a crucial reminder for programmers and innovators alike. <strong>No matter how advanced the technology may be, its value ultimately lies in its adoption by users.</strong> Nani Agritech Series serves as a testament to the importance of aligning technological advancements with the needs and desires of the target market.</p><p>By prioritizing market research, agile development, user-centric design, and continuous customer engagement, <strong>programmers can navigate the path towards successful product adoption.</strong> Let us remain vigilant in our pursuit of innovation, ensuring that our technological creations serve a meaningful purpose and resonate with those who matter most — the users.</p><p>If you’re interested in connecting further with me, please visit my LinkedIn profile <a href="https://www.linkedin.com/in/eugenius-mario-s/"><strong>Eugenius Mario’s LinkedIn</strong></a><strong>.</strong></p><p>Happy to know you!</p><h3>References</h3><ol><li><a href="https://www.productplan.com/glossary/product-market-fit/#:~:text=Product%2Dmarket%20fit%20describes%20a,that%20product&#39;s%20growth%20and%20profitability">https://www.productplan.com/glossary/product-market-fit/#:~:text=Product%2Dmarket%20fit%20describes%20a,that%20product&#39;s%20growth%20and%20profitability</a>.</li><li><a href="https://glints.com/id/lowongan/product-market-fit/">https://glints.com/id/lowongan/product-market-fit/</a></li><li><a href="https://revou.co/kosakata/product-market-fit">https://revou.co/kosakata/product-market-fit</a></li><li><a href="https://www.binaracademy.com/blog/pentingnya-product-market-fit">https://www.binaracademy.com/blog/pentingnya-product-market-fit</a></li><li><a href="https://dibimbing.id/en/blog/detail/apa-itu-product-market-fit">https://dibimbing.id/en/blog/detail/apa-itu-product-market-fit</a></li><li><a href="https://sasanadigital.com/strategi-product-market-fit/">https://sasanadigital.com/strategi-product-market-fit/</a></li><li><a href="https://www.linkedin.com/pulse/pengertian-product-market-fit-faktor-penentu-cara-mencapainya-xq9yc/?originalSubdomain=id">https://www.linkedin.com/pulse/pengertian-product-market-fit-faktor-penentu-cara-mencapainya-xq9yc/?originalSubdomain=id</a></li><li><a href="https://runsystem.id/id/blog/product-market-fit/">https://runsystem.id/id/blog/product-market-fit/</a></li><li><a href="https://prasmul-eli.co/id/articles/Apa-Itu-Product-Market-Fit-dan-Cara-Mencapainya">https://prasmul-eli.co/id/articles/Apa-Itu-Product-Market-Fit-dan-Cara-Mencapainya</a></li><li><a href="https://penfriend.ai/blog/product-market-fit-case-studies">https://penfriend.ai/blog/product-market-fit-case-studies</a></li><li><a href="https://www.mindtheproduct.com/my-learnings-from-finding-product-market-fit-at-revolut/">https://www.mindtheproduct.com/my-learnings-from-finding-product-market-fit-at-revolut/</a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=180d5fd09b07" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Nani Agritech Series: Unlocking the Power of Servant Leadership: Building Personal Relationship…]]></title>
            <link>https://eugeniusmario.medium.com/unlocking-the-power-of-servant-leadership-building-personal-relationship-motivating-team-with-a7d9401a9c1c?source=rss-974c337fafb0------2</link>
            <guid isPermaLink="false">https://medium.com/p/a7d9401a9c1c</guid>
            <category><![CDATA[productivity]]></category>
            <category><![CDATA[leadership]]></category>
            <category><![CDATA[tracking]]></category>
            <category><![CDATA[personal-growth]]></category>
            <category><![CDATA[teamwork]]></category>
            <dc:creator><![CDATA[Eugenius Mario]]></dc:creator>
            <pubDate>Wed, 29 May 2024 16:28:13 GMT</pubDate>
            <atom:updated>2024-06-01T10:24:29.838Z</atom:updated>
            <content:encoded><![CDATA[<h3>Nani Agritech Series: Unlocking the Power of Servant Leadership: Building Personal Relationship, Motivating Team with Working Together, and Fostering Productivity. Oh also, Don’t Forget to Delegate ;)</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Tw52ynipvHeQghp9hFJetw.png" /><figcaption>Unlocking the Power of Servant Leadership by eugeniusmario.</figcaption></figure><p><strong>In the realm of leadership, the concept of servant leadership stands as a beacon of empowerment, collaboration, and trust. </strong>In this article, we embark on a journey to unlock the profound impact of servant leadership, exploring its ability to build personal relationships, motivate teams through collaboration, and ultimately foster productivity in the workplace.</p><p>Oh, and <strong>let’s not forget the crucial art of delegation</strong> — a cornerstone of effective leadership. Join us as we delve into the principles and practices of servant leadership, uncovering its transformative potential in today’s dynamic and interconnected work environments.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Jq_sc_0IBqu7Y3AtAPa5sg.png" /><figcaption>My identity card as CEO in Nani Agritech by eugeniusmario.</figcaption></figure><p>As the CEO of <a href="https://naniagritech.com/">Nani Agritech</a>, <strong>I’ve come to realize the critical role that effective leadership plays in the success of a startup</strong>. In this capacity, I’m eager to share my experiences and insights into what constitutes ideal leadership within the realm of technology, despite acknowledging my own shortcomings in this role.</p><p>Leadership in the tech sector demands qualities such as vision, adaptability, and resilience, which I continuously strive to embody. By fostering transparency, empathy, and a culture of continuous improvement, I aim to cultivate a leadership style that not only empowers my team but also drives Nani Agritech toward its strategic goals. <strong>Through this journey, I hope to inspire fellow leaders and aspiring entrepreneurs to embrace their leadership roles with humility, perseverance, and a commitment to growth.</strong></p><p>I divide this article into <strong>4 chapters + 1 bonus chapter </strong>as follows:</p><ul><li><strong>Chapter 1</strong>: Building Personal Relationship</li><li><strong>Chapter 2:</strong> Motivating Team with Working Together</li><li><strong>Chapter 3:</strong> Fostering Productivity</li><li><strong>Chapter 4:</strong> Don’t Forget to Delegate ;)</li><li><strong>Bonus Chapter:</strong> Everyone Wants to Develop ❤</li></ul><p>Each chapter can delve into its respective topic in more detail, providing examples, and tips to help readers understand and implement effectively. Let’s dive!</p><h3>Chapter 1: Building Personal Relationship</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7PBUx7vnso5F2NqXAq2Kkg.png" /><figcaption>Building personal relationship by eugeniusmario.</figcaption></figure><p>As the CEO of <a href="https://naniagritech.com/">Nani Agritech</a>, I’ve come to recognize the paramount importance of nurturing personal relationships within our organization. These relationships form the bedrock of our company culture, fostering trust, collaboration, and a sense of belonging among our team members. <strong>Here are some key insights I’ve gleaned along the way:</strong></p><ol><li><strong>Authentic Connections</strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VOwE-JmEi2UGmNgpoSteXA.png" /><figcaption>My chat with Ale (Nani Agritech’s CPO) by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/904/1*yIwgvPmFluv2SAWOTTTTnQ.png" /><figcaption>My chat with Jeje (Nani Agritech’s CFO) by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9EKDML-cRp6k7T9EV0cCfw.png" /><figcaption>My chat with Angel (Nani Agritech’s CMO) by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_JI3IMgS08Mu7Fn88GXpfw.png" /><figcaption>My chat with Vicky (Nani Agritech’s CTO) by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/793/1*2XqhpKib8TjubNcMjyEs_w.png" /><figcaption>My chat with Awan (Nani Agritech’s IoT Director) by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wP0wF69OUSuDN9MFtcWCJQ.png" /><figcaption>My chat with Diah (Nani Agritech’s Design Director) by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*l_wta0Smx3OXIu69pNH0Rw.png" /><figcaption>My chat with Iqbal (Nani Agritech’s AI Director) by eugeniusmario.</figcaption></figure><p>Building personal relationships <strong>isn’t just about exchanging pleasantries; it’s about forging genuine connections based on mutual respect and understanding.</strong> By taking the time to get to know each member of our team on a <strong>personal level</strong>, we create a supportive environment where individuals feel valued and appreciated.</p><p><strong>2. Open Communication</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/698/1*zEa1OIFTejFanp-Ce1awXQ.jpeg" /><figcaption>UI Incubate preparation by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*tgRbnc1gu1FGysIn-4mkxA.png" /><figcaption>Chat about integrating folders to one drive in Nani by eugeniusmario.</figcaption></figure><p>Effective communication is the cornerstone of any successful relationship. As the CEO, I make it a priority to maintain <strong>open lines of communication with my team, actively listening to their concerns, ideas, and feedback.</strong> This fosters a culture of transparency and encourages everyone to contribute their unique perspectives.</p><p><strong>3. Empathy and Support</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/636/1*CO9mj1Qxm-nh6wviZnQjFA.jpeg" /><figcaption>Empathy and support in Nani Agritech by eugeniusmario.</figcaption></figure><p>Empathy is a powerful tool for building personal relationships, allowing us to understand and empathize with the experiences and emotions of others. By demonstrating empathy and offering support during both triumphs and challenges, we cultivate a culture of compassion and camaraderie within our team.</p><p><strong>4. Celebrating Successes</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/738/1*unEr3S21P6RGgTnPPbz8OQ.jpeg" /><figcaption>UI Incubate announcement by eugeniusmario.</figcaption></figure><p>Recognizing and celebrating the achievements of our team members is essential for fostering personal relationships. Whether it’s a small milestone or a major accomplishment, acknowledging their efforts and contributions strengthens our bond and motivates everyone to strive for excellence.</p><p><strong>5. Investing in Development</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*OkLTiFcZEw-uT5Bw2cCluA.jpeg" /><figcaption>Planning system by eugeniusmario.</figcaption></figure><p>Personal relationships extend beyond the workplace; they encompass the growth and development of each individual. As the CEO, <strong>I’m committed to investing in the professional and personal development of our team members, providing opportunities for learning, growth, and advancement.</strong></p><p>By prioritizing the cultivation of personal relationships within Nani Agritech, we create a supportive and inclusive environment where every individual feels valued, respected, and empowered to succeed. These relationships not only enhance morale and teamwork but also drive innovation and propel our company forward on the path to success.</p><h3>Chapter 2: Motivating Team with Working Together</h3><p>In my role as CEO of Nani Agritech, one of my primary responsibilities is to motivate and inspire our team to achieve their full potential. One of the most effective ways to do this is <strong>by fostering a culture of collaboration and teamwork</strong>. Here’s how we motivate our team to work together towards our common goals:</p><ol><li><strong>Clear Vision and Goals</strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*emm73BneGtvr5CobhMrjUg.png" /><figcaption>Nani #siapbantupetani tagline by eugeniusmario.</figcaption></figure><p>We start by clearly articulating our company’s vision and goals to every member of the team. <strong>By ensuring that everyone understands the direction we’re headed and their role in achieving our objectives, </strong>we create a sense of purpose and alignment.</p><p><strong>2. Promoting Collaboration</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*81b-LE6PIjRAmS8BIi3Djw.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CTE_myMNX4ZyshUMa3S-cg.jpeg" /><figcaption>Collaboration in term of building prototype in Nani Agritech by eugeniusmario.</figcaption></figure><p>Collaboration is at the heart of everything we do at Nani Agritech. <strong>We encourage our team members to collaborate</strong> across departments and disciplines, leveraging each other’s strengths and expertise to solve problems and innovate.</p><p><strong>3. Recognition and Reward</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*217iFjdYGNGGAIp4C6wn9g.png" /><figcaption>Using banner designed by Diah, by eugeniusmario.</figcaption></figure><p>I believe in <strong>recognizing and rewarding the contributions of our team members.</strong> Whether it’s a simple “thank you” or a more formal recognition program, acknowledging their hard work and dedication motivates them to continue striving for excellence.</p><p><strong>4. Team Building Activities</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FogEvCmD1r5tC3u7hIZ7ig.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Km3Xl5AQxmUjv_NZEEj7vw.jpeg" /><figcaption>Bonding activities outside of work Nani Agritech by eugeniusmario.</figcaption></figure><p>We organize regular team building activities and events to strengthen bonds and foster camaraderie among our team members. <strong>Whether it’s a team lunch</strong>, a volunteer day, or a fun outing, these activities help build relationships and create a sense of belonging.</p><p><strong>5. Lead by Example</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lq7SrSEuNa05BZg33fPP5A.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kUc-Jst3EwmdWXvjt_kabg.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*NmldmZaquXHrGODmoixj2A.png" /><figcaption>Join survey, creating prototype, volunteering on UI Incubate 2024 by eugeniusmario.</figcaption></figure><p>As the leader of the team, I lead by example, <strong>demonstrating the values and behaviors we expect from our team members.</strong> By embodying qualities such as <strong>integrity, resilience, and a strong work ethic</strong>, I inspire our team to do the same.</p><p>By motivating our team to work together towards a common purpose, we create a culture of collaboration, innovation, and excellence at Nani Agritech. Together, we’re able to overcome challenges, seize opportunities, and achieve success beyond our individual capabilities.</p><h3>Chapter 3: Fostering Productivity</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hUvWlFgbN3Tg3oH_KSWTaw.png" /><figcaption>Fostering productivity by eugeniusmario.</figcaption></figure><p>As CEO of Nani Agritech, fostering productivity within our organization is a top priority. Here are some strategies we employ to <strong>create an environment where productivity thrives:</strong></p><ol><li><strong>Setting Clear Expectations for The Role</strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*8abpV-2cKXvBsTb2" /><figcaption>Structural position in Nani Agritech by eugeniusmario.</figcaption></figure><p>We start by setting <strong>clear expectations for our team members regarding their roles, responsibilities, and goals.</strong> By providing clarity on what is expected of them, we enable our team to focus their efforts and prioritize tasks effectively.</p><p>The CEO acts as the highest leader of the company and is responsible for the company’s development strategy. The CFO is responsible for strategy, analysis of the company’s financial statements, and funding. The CMO is responsible for marketing strategy and establishing relationships with the government and BUMDes. The CTO is responsible for developing IoT devices and applications and creating architectural development strategies. CPO is responsible for product market fit, research, and product development based on user needs.</p><p>The Engineering Manager has the role of executing software product planning with a team consisting of several software Engineers. The director of AI and the AI engineer play a role in conducting artificial intelligence technology research for analysis and improving product quality. The director of IoT and the engineer play a role in designing and manufacturing finished goods from IoT. The director of UI/UX, assisted by the team/UX Designer, conducts design research according to user needs visually and actively creates to make it easier for users to use the application.</p><p><strong>2. Providing the Right Tools and Resources</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*18qQNFfAnGR26VfMnAhaHQ.png" /><figcaption>Canva for Nani Agritech by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CYx8av0m7X7J2Ba6PrWLcQ.png" /><figcaption>GitHub for Nani Agritech by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YJDNs9aeMcMl2WHVq9iWCA.png" /><figcaption>Figma for Nani Agritech by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*aWxOyAu38693zd8Wx0Fqaw.png" /><figcaption>Postman for Nani Agritech by eugeniusmario.</figcaption></figure><p>We ensure that our team has <strong>access to the necessary tools, resources, and technology to perform their jobs efficiently.</strong> Whether it’s software, equipment, or training, investing in the right resources is essential for maximizing productivity.</p><p><strong>3. Encouraging Work-Life Balance</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*ehdwfnxgvhGJxiKNChYgTw.jpeg" /><figcaption>Balancing with holiday by eugeniusmario.</figcaption></figure><p>We recognize the importance of maintaining a healthy work-life balance for our team members. We encourage them to take breaks, prioritize self-care, and set boundaries to prevent burnout and maintain long-term productivity.</p><p><strong>4. Promoting Time Management Skills</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*z7MBlM8UVh9dvNGGRJ4apA.png" /><figcaption>Nani’s Notion about sprint by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LqkgvI0pEEbbYHtT3g2nPQ.png" /><figcaption>Target deadline Nani Agritech by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*p5cODYxsPlRz46Dtf7Nrcg.png" /><figcaption>Nani’s Task in Notion by eugeniusmario.</figcaption></figure><p>We provide training and support to <strong>help our team members develop effective time management skills. </strong>This includes techniques for prioritizing tasks, managing distractions, and optimizing workflow to maximize productivity.</p><p><strong>5. Streamlining Processes</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*XfdXpFLkY6ng-Oquotw8Qw.jpeg" /><figcaption>Cutting activity by eugeniusmario.</figcaption></figure><p>We regularly review our workflows and processes to identify inefficiencies and streamline operations. <strong>By eliminating unnecessary steps and automating repetitive tasks, we free up time and resources for more strategic activities.</strong></p><p>By implementing these strategies, we create a supportive and conducive environment where productivity flourishes, enabling us to achieve our goals and drive success at Nani Agritech.</p><h3>Chapter 4: Don’t Forget to Delegate ;)</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*tJQ3qXVhxWSB7UuBTXatBA.png" /><figcaption>Don’t forget to delegate by eugeniusmario.</figcaption></figure><p>Delegation is a crucial aspect of effective leadership, and as the CEO of <a href="https://naniagritech.com/">Nani Agritech</a>, I recognize its significance in driving organizational success. Delegating tasks allows me to focus on strategic initiatives and high-level decision-making, while empowering my team members to take ownership of their roles and contribute to our collective goals. By distributing responsibilities among capable individuals, we leverage the diverse skills and expertise within our team to achieve optimal results and drive innovation.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*gpE9CKj15yABghe5mzApdw.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*Btk4ilJKqYrnWlR5LTRRZg.jpeg" /><figcaption>The importance of delegating tasks by eugeniusmario.</figcaption></figure><p>Delegation fosters a culture of collaboration and teamwork, as team members work together to accomplish shared objectives. By entrusting tasks to those best suited to handle them, we encourage open communication, knowledge sharing, and the exchange of ideas, leading to greater creativity and problem-solving. Delegation promotes professional growth and development by providing opportunities for individuals to expand their skill sets and take on new challenges. As team members tackle new responsibilities and overcome obstacles, they gain valuable experience and confidence in their abilities, contributing to their long-term success and fulfillment.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*l69T4R8-Ja_9jSjhQ6D4aA.jpeg" /><figcaption>Delegating some tasks in Nani Agritech by eugeniusmario.</figcaption></figure><p>Delegation is essential for promoting work-life balance and preventing burnout among our team members. By distributing workload evenly and empowering individuals to manage their time effectively, we ensure that everyone has the opportunity to recharge and maintain their well-being. This not only enhances morale and job satisfaction but also improves overall productivity and performance. In conclusion, delegation is a foundational principle of effective leadership that enables us to maximize efficiency, foster collaboration, and support the growth and well-being of our team members at <a href="https://naniagritech.com/">Nani Agritech.</a></p><h3>Bonus Chapter: Everyone Wants to Develop ❤</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*g9hbk1M5rXrdgPYAxY0Ayg.png" /><figcaption>Everyone wants to develop by eugeniusmario.</figcaption></figure><p>We foster a<strong> culture of continuous improvement where our team members are encouraged to seek out opportunities for growth and development.</strong> Whether it’s through training, feedback, or mentorship, I support their efforts to enhance their skills and capabilities.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*o1QlF5ctoeMZL2VM5NHluA.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*l-0hCRkuOKY3CR8F-Qka0g.jpeg" /><figcaption>CMO &amp; CFO joined Nani Agritech, Nani’s CFO goes to IISMA-E, by eugeniusmario.</figcaption></figure><p>I ensure that each individual is beneficial, useful, and grows according to their respective roles; thus, I divide roles according to the direction in which they are best suited to develop. Each of us undoubtedly desires to progress and gain knowledge during our time here.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*lmehQVHnBrNnREqSHG9ZoA.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*FEGsr6ideFZWBcGCcAE0jA.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*Q4zTDFheHUBmKTnmnWraEg.jpeg" /><figcaption>Discuss with CTO about Git Flow, IoT Director learning to create IoT, CPO presenting user journey map, by eugeniusmario.</figcaption></figure><p>In conclusion, fostering individual growth and development is paramount in our organization. By aligning roles with each individual’s strengths and aspirations, <strong>we create an environment where everyone can thrive and contribute meaningfully to our collective success.</strong> As we continue on our journey, let us remain committed to supporting one another’s growth and learning, ensuring that each member of our team reaches their full potential. <strong>Together, we can achieve great things and pave the way for a brighter future.</strong></p><h3>The End</h3><p>In concluding the “Nani Agritech Series: Unlocking the Power of Servant Leadership,” it’s evident that embracing principles such as building personal relationships, motivating teamwork, fostering productivity, and delegating effectively are crucial for organizational success. By implementing these strategies, <strong>we not only empower our team members but also cultivate a culture of collaboration, innovation, and excellence.</strong></p><p>As we continue on our journey, let us remain committed to serving one another, nurturing relationships, and embracing growth opportunities. <strong>Together, we can unlock the full potential of servant leadership and propel Nani Agritech towards even greater heights of achievement.</strong></p><p>If you’re interested in connecting further with me, please visit my LinkedIn profile <a href="https://www.linkedin.com/in/eugenius-mario-s/"><strong>Eugenius Mario’s LinkedIn</strong></a><strong>.</strong></p><p>Happy to know you!</p><h3>References</h3><ol><li><a href="https://www.linkedin.com/pulse/working-building-relationship-your-ceo-deirdre-breakenridge/">https://www.linkedin.com/pulse/working-building-relationship-your-ceo-deirdre-breakenridge/</a></li><li><a href="https://genehammett.com/867-great-ceos-know-how-to-build-strong-relationships-with-david-nour/">https://genehammett.com/867-great-ceos-know-how-to-build-strong-relationships-with-david-nour/</a></li><li><a href="https://ceocoachinginternational.com/key-relationships-for-business-leaders/">https://ceocoachinginternational.com/key-relationships-for-business-leaders/</a></li><li><a href="https://peoplemanagingpeople.com/strategy-operations/hop-ceo-relationship/">https://peoplemanagingpeople.com/strategy-operations/hop-ceo-relationship/</a></li><li><a href="https://www.betterup.com/blog/motivating-a-team">https://www.betterup.com/blog/motivating-a-team</a></li><li><a href="https://clickup.com/blog/motivating-a-team/">https://clickup.com/blog/motivating-a-team/</a></li><li><a href="https://teambuildinghub.com/team-building/benefits/motivation/">https://teambuildinghub.com/team-building/benefits/motivation/</a></li><li><a href="https://www.inc.com/thehartford/7-tips-for-fostering-productivity-no-matter-where-your-team-is-working.html">https://www.inc.com/thehartford/7-tips-for-fostering-productivity-no-matter-where-your-team-is-working.html</a></li><li><a href="https://dextralabs.com/blog/increase-team-productivity-in-startups/#:~:text=Encourage%20Open%20Communication%3A%20Foster%20a,members%2C%20regardless%20of%20their%20location">https://dextralabs.com/blog/increase-team-productivity-in-startups/#:~:text=Encourage%20Open%20Communication%3A%20Foster%20a,members%2C%20regardless%20of%20their%20location</a>.</li><li><a href="https://www.hi5.team/blog/boost-productivity-startup-team">https://www.hi5.team/blog/boost-productivity-startup-team</a></li><li><a href="https://cmox.co/importance-of-delegation-in-leadership/#:~:text=Delegating%20as%20the%20CEO,the%20company&#39;s%20goals%20most%20effectively">https://cmox.co/importance-of-delegation-in-leadership/#:~:text=Delegating%20as%20the%20CEO,the%20company&#39;s%20goals%20most%20effectively</a>.</li><li><a href="https://www.startupgrind.com/blog/the-duties-every-new-ceo-needs-to-learn-to-delegate/">https://www.startupgrind.com/blog/the-duties-every-new-ceo-needs-to-learn-to-delegate/</a></li><li><a href="https://www.linkedin.com/pulse/importance-delegation-eliteventuresco">https://www.linkedin.com/pulse/importance-delegation-eliteventuresco</a></li><li><a href="https://www.linkedin.com/pulse/growing-together-how-startups-can-harness-power-entities-abbas">https://www.linkedin.com/pulse/growing-together-how-startups-can-harness-power-entities-abbas</a></li><li><a href="https://thebusinessparadox.com/startup-culture-building-a-team-that-grows-together/">https://thebusinessparadox.com/startup-culture-building-a-team-that-grows-together/</a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a7d9401a9c1c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Nani Agritech Series: I am a Computer Science Student Learning about Business, Finance, and…]]></title>
            <link>https://eugeniusmario.medium.com/i-am-a-computer-science-student-learning-about-business-finance-and-marketing-a-bridge-to-a-5b8837a836fc?source=rss-974c337fafb0------2</link>
            <guid isPermaLink="false">https://medium.com/p/5b8837a836fc</guid>
            <category><![CDATA[business]]></category>
            <category><![CDATA[techpreneur]]></category>
            <category><![CDATA[investors]]></category>
            <category><![CDATA[product-design]]></category>
            <category><![CDATA[marketing]]></category>
            <dc:creator><![CDATA[Eugenius Mario]]></dc:creator>
            <pubDate>Wed, 29 May 2024 16:16:00 GMT</pubDate>
            <atom:updated>2024-06-01T08:18:10.610Z</atom:updated>
            <content:encoded><![CDATA[<h3>Nani Agritech Series: I am a Computer Science Student Learning about Business, Finance, and Marketing: A Bridge to a Helicopter-View Product Development Approach</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nIzaJ0rCCjzdg4TBn8SBtA.png" /><figcaption>Helicopter-View product development approach by eugeniusmario.</figcaption></figure><p>As a computer science student, delving into the realms of business, finance, and marketing represents a pivotal bridge in your journey towards a holistic understanding of product development. In this chapter, we embark on a transformative exploration, <strong>traversing the intersection between technology and business acumen to adopt a helicopter-view approach to product development.</strong></p><p>In today’s rapidly evolving landscape, the success of a product hinges <strong>not only on its technical prowess</strong> but also on its alignment with market demands, financial viability, and strategic marketing initiatives. By embracing a multidisciplinary perspective, you pave the way for a comprehensive understanding of the intricacies involved in bringing a product to market.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Jq_sc_0IBqu7Y3AtAPa5sg.png" /><figcaption>My identity card as CEO in Nani Agritech by eugeniusmario.</figcaption></figure><p>As I embarked on my journey as the CEO of Nani Agritech, I quickly realized that wearing the CEO hat meant juggling a myriad of responsibilities, each intricately tied to the success and growth of the company. From overseeing day-to-day operations to charting long-term strategic visions, <strong>the role demanded a comprehensive understanding of not just the technology</strong> at the core of our products but also the intricate dance of business, finance, and marketing.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8T9KGjpyHRsCH8mEYQmNcA.png" /><figcaption>Nani’s Board of Director by eugeniusmario.</figcaption></figure><p>In the pursuit of excellence, I found myself seeking the expertise of a CFO and CMO to complement my technical background. Collaborating with these professionals, <strong>I delved deep into discussions, absorbing insights, and honing my understanding of the financial and marketing landscapes.</strong> Through this collaborative effort, I gained invaluable knowledge that transcended textbooks, learning firsthand the art of balancing budgets, crafting compelling marketing strategies, and navigating the dynamic market forces.</p><p>Furthermore, <strong>my journey into the realms of business, finance, and marketing was enriched by participation in business plan competitions.</strong> These experiences provided a real-world platform to apply theoretical knowledge, fine-tune entrepreneurial skills, and gain exposure to the competitive nature of the business world. From crafting meticulous proposals to delivering persuasive pitches, each stage of the competition offered lessons in resilience, innovation, and strategic thinking.</p><p>In this article,<strong> I aim to provide a holistic view of Nani Agritech’s products, transcending the confines of technology to explore the intricate synergy between technology and business. </strong>Through a lens that encompasses business strategy, financial analysis, and marketing tactics, I will unravel the multifaceted journey of product development, offering insights gleaned from both theoretical frameworks and practical experiences.</p><p>As we traverse the narrative arc, I will not only delve into the technical intricacies of our products but also illuminate the strategic decisions, financial considerations, and marketing endeavors that underpin their success. <strong>From inception to execution, I will walk you through the journey of bringing an idea to life,</strong> n<strong>avigating the complexities of the market landscape, and ultimately, striving for sustainable growth and impact.</strong></p><p>Through this comprehensive exploration,<strong> I hope to offer fellow computer science students a roadmap for bridging the gap between technology and business</strong>, empowering them to approach product development with a helicopter-view perspective that encompasses not only technical prowess but also business acumen and marketing savvy. Join me as we embark on this enlightening journey at the intersection of tech and business, where innovation meets entrepreneurship, and possibilities abound.</p><p>I divide this article into <strong>5 chapters</strong> as follows:</p><ul><li><strong>Chapter 1</strong>: Computer Science and Product</li><li><strong>Chapter 2:</strong> Business</li><li><strong>Chapter 3:</strong> Finance</li><li><strong>Chapter 4:</strong> Marketing</li><li><strong>Chapter 5: </strong>Conclusion</li></ul><p>In each chapter I will explain how important it is to understand this aspect for people who want to make products. Let’s dive!</p><h3>Chapter 1: Computer Science and Product</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6I6ylQJXitHaZvBcIfv6uA.png" /><figcaption>Computer Science and Product by eugeniusmario.</figcaption></figure><p>In the realm of computer science, <strong>we’re equipped with a toolbox brimming with the latest technologies, allowing us to craft products that seamlessly integrate innovation with functionality</strong>. From mastering the intricacies of frontend and backend development to delving into the realms of mobile development, DevOps, machine learning, and artificial intelligence, we’re well-versed in the myriad components that constitute modern product development.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kmorHSs4N-iZeGfZANZPIA.png" /><figcaption>Architecture Diagram of Nani by eugeniusmario.</figcaption></figure><p>At Nani Agritech, <strong>our product architecture is a testament to this complexity.</strong> We’ve meticulously crafted a framework comprised of various interconnected elements, each requiring specialized talent to ensure seamless integration and optimal performance. This modular approach enables us to leverage the expertise of individuals proficient in their respective domains, fostering a collaborative environment where innovation flourishes.</p><p>When it comes to technology, <strong>our mantra is simple: functionality is paramount</strong>. We prioritize the development of products that not only meet but exceed user expectations, ensuring that every feature serves a purpose and enhances the overall user experience. This emphasis on functionality forms the cornerstone of our product development philosophy, guiding us as we transform ideas into tangible solutions.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eNAOTQEI-yypvYQcmMp3wQ.png" /><figcaption>MVP development in Nani Agritech by eugeniusmario.</figcaption></figure><p>Central to our development process is the concept of the <strong>Minimum Viable Product (MVP)</strong>. By distilling our vision into its most essential components, we’re able to create a functional prototype that serves as the foundation for future iterations. This iterative approach allows us to gather valuable feedback, iterate rapidly, and refine our product until it meets the needs and desires of our target audience.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fbk9lzhwyR7hmgXegbtr1g.png" /><figcaption>PBI Nani Agritech by eugeniusmario.</figcaption></figure><p>Breaking down the MVP into its constituent parts — backend, frontend, mobile development, and beyond — we meticulously craft each component with precision and care. This modular approach not only facilitates efficient development but also allows us to prioritize features based on their impact and feasibility, ensuring that our <strong>MVP achieves its intended goals in the most effective manner possible.</strong></p><p>Once the MVP is realized, we embark on the final leg of our journey: deployment. Transitioning from the staging environment to live deployment, we ensure that our product is primed for success, meticulously testing and optimizing every aspect to guarantee a seamless user experience. <strong>It’s a culmination of months of hard work, dedication, and collaboration, culminating in the realization of our vision.</strong></p><p>Curious about the technical intricacies that underpin our product development process? <strong>Dive into my collection of articles,</strong> where I explore the nuances of technology-driven product development from inception to deployment. Discover insights, best practices, and innovative approaches as we unravel the mysteries of crafting cutting-edge solutions from scratch.</p><p><strong>My Articles about Technical Development in </strong><a href="https://naniagritech.com/"><strong>Nani Agritech</strong></a><strong>:</strong></p><ol><li><a href="https://medium.com/@eugeniusmario/automated-deployment-django-on-google-compute-engine-using-github-action-and-docker-662f84755c57">Automated Deployment Django on Google Compute Engine using GitHub Action and Docker</a></li><li><a href="https://medium.com/@eugeniusmario/become-a-tech-lead-master-of-review-a-deep-dive-into-github-pull-requests-bonus-teaching-your-23817210bbc2">Become a Tech Lead, Master of Review: A Deep Dive into GitHub Pull Requests (Bonus: Teaching Your Team to Use Better Commit Messages)</a></li><li><a href="https://medium.com/@eugeniusmario/migrate-monolithic-to-microservices-separation-of-concerns-soc-and-keep-it-simple-stupid-kiss-da16e730ebef">Migrate Monolithic to Microservices: Separation of Concerns (SoC) and Keep It Simple, Stupid (KISS) for Maintainable and Continuous Development</a></li><li><a href="https://medium.com/@eugeniusmario/time-traveling-to-prevent-future-failures-harnessing-test-driven-development-tdd-free-bonus-1785ae5de444">Time Traveling to Prevent Future Failures: Harnessing Test Driven Development (TDD), Free Bonus Session Using PyTest &amp; Sonarcloud for Django Test</a></li><li><a href="https://medium.com/@eugeniusmario/unlocking-program-perfection-a-journey-through-dynamic-static-analysis-and-quality-assurance-tools-812af8f7628e">Unlocking Program Perfection: A Journey through Dynamic Static Analysis and Quality Assurance Tools (Sonarcloud and Qodana)</a></li><li><a href="https://eugeniusmario.medium.com/sherlock-holmes-engineering-unraveling-data-with-deductive-engineering-skills-a-journey-into-50be82eb6a57">Sherlock Holmes Engineering: Unraveling Data with Deductive Engineering Skills, A Journey into Check Platform Performance, Error Haunts, and User Story</a></li></ol><h3>Chapter 2: Business</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*d0LwaT5-2OBIJwwDkt9VTw.png" /><figcaption>Business by eugeniusmario.</figcaption></figure><p>In the realm of product development, it’s easy for us, as computer scientists, to get lost in the intricacies of code and algorithms, often overlooking the critical role that business plays in the success of our creations. Yet, the reality is that a product’s viability extends far beyond its technical prowess; it hinges on its ability to address real-world needs and navigate the complex landscape of consumer behavior and market dynamics.</p><p>Here are some crucial points explaining why understanding business is essential for product success, especially from the perspective of a computer scientist:</p><ol><li><strong>Market Relevance</strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/806/1*WR789DHb_Y7JIh3SCJ0JNQ.png" /><figcaption>Market segmentation for Nani by eugeniusmario.</figcaption></figure><p>At the heart of every successful product lies a deep understanding of market needs and demands. As computer scientists, we possess the technical acumen to build groundbreaking solutions, but without a solid grasp of market trends and consumer preferences, our products risk becoming obsolete before they even hit the market. By immersing ourselves in the world of business, we can align our technical expertise with market needs, ensuring that our products resonate with users and fulfill genuine demand.</p><blockquote>In this case, <a href="https://naniagritech.com/">Nani Agritech</a> targets a crucial issue in agriculture through surveys conducted among farmers, revealing that 80% of agricultural activities are related to water utilization. It was found that if water is not optimally utilized, crop failure may occur. This is the issue we aim to prevent from happening. Therefore, the product we are introducing for the first time is an automatic water pump that can precisely measure the volume of water released, adjusted according to the size of the land.</blockquote><p><strong>2. User Adoption</strong></p><p>One of the most common pitfalls among developers is creating products in isolation, divorced from the realities of user behavior and adoption. It’s not enough to build a technically impressive solution; we must also consider factors such as usability, accessibility, and user experience. By understanding the principles of business, we can design products that are not only functional but also user-friendly and intuitive, increasing the likelihood of widespread adoption and success.</p><blockquote>In this case, Nani targets tech-savvy farmers aged 19–39. Since we utilize advanced technology, it’s essential to target a suitable market to drive user adoption. Of course, User Acceptance Testing (UAT) is required to ensure that the product meets user expectations.</blockquote><p><strong>3. Monetization Strategies</strong></p><p>Ultimately, businesses exist to generate revenue, and products are no exception. While we may be adept at crafting elegant code and innovative features, without a viable monetization strategy, our products may struggle to sustain themselves in the long run. Whether it’s through advertising, subscription models, or in-app purchases, understanding the intricacies of business allows us to monetize our products effectively, ensuring their continued growth and sustainability.</p><blockquote>Nani has several monetization schemes, such as B2B with private companies for bulk purchases of IoT devices in package systems. Or B2C schemes with direct customers. Monetization is achieved by selling IoT devices to companies or customers. Actually, many strategies are being developed, but they remain private to Nani.</blockquote><p><strong>4. Scalability and Growth</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/887/1*d1uLUkfwislMmA9z44Katw.png" /><figcaption>Scalability and growth for Nani by eugeniusmario.</figcaption></figure><p>Building a successful product is just the first step; sustaining its growth and scalability is equally important. By incorporating business principles into our development process, we can anticipate future challenges, identify opportunities for expansion, and devise strategies to scale our products effectively. Whether it’s entering new markets, diversifying revenue streams, or forging strategic partnerships, a solid understanding of business empowers us to navigate the complexities of growth with confidence and foresight.</p><blockquote>If your product cannot evolve, it will decline within 1–2 years, which is not favorable for you. Currently, investors are not only looking at a product’s short-term prospects; they focus on products with excellent long-term prospects and high user retention. Therefore, expansion schemes should be considered every time a certain milestone is reached. When you stop and create a product that cannot be developed further, it marks the beginning of decline. Nani focuses on long-term agricultural projects in Indonesia, which still lack technology.</blockquote><p>In essence, while technology forms the foundation of our creations, it’s our understanding of business that propels them to success. By embracing the principles of business alongside our technical expertise, we can build products that not only push the boundaries of innovation but also resonate with users, drive revenue, and leave a lasting impact on the world. As computer scientists, let us not only master the intricacies of code but also embrace the broader spectrum of business, paving the way for a new era of technological innovation and entrepreneurial success.</p><h3>B2B, B2C, B2G?</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0J5H86q2a_xXgg6eYY8F8A.png" /><figcaption>B2B, B2C, B2G by eugeniusmario.</figcaption></figure><p>Let’s delve into the fundamental concepts of B2B (Business-to-Business), B2C (Business-to-Consumer), and B2G (Business-to-Government):</p><ol><li><strong>B2B (Business-to-Business)</strong></li></ol><ul><li>B2B refers to transactions conducted between businesses, where one business sells products or services to another business.</li><li>In a B2B context, the customer is typically another company, such as a wholesaler, retailer, or service provider.</li><li>B2B transactions often involve larger volumes and higher values compared to B2C transactions.</li><li>Examples of B2B transactions include a manufacturer selling components to an assembly plant, a software company licensing its product to another business, or a consulting firm providing services to a corporation.</li></ul><p><strong>2. B2C (Business-to-Consumer)</strong></p><ul><li>B2C involves transactions between a business and individual consumers, where the business sells products or services directly to end-users.</li><li>In a B2C context, the customer is the end-user who purchases goods or services for personal use.</li><li>B2C transactions typically involve smaller volumes and lower values compared to B2B transactions but may occur more frequently.</li><li>Examples of B2C transactions include a retail store selling clothing to shoppers, an online streaming service offering subscriptions to individual users, or a restaurant serving meals to diners.</li></ul><p><strong>3. B2G (Business-to-Government)</strong></p><ul><li>B2G refers to transactions where businesses provide products or services to government agencies or entities.</li><li>In a B2G context, the government serves as the customer, procuring goods or services from businesses to fulfill its operational needs or public services.</li><li>B2G transactions often involve specialized requirements, such as compliance with government regulations or procurement processes.</li><li>Examples of B2G transactions include a construction company bidding for a government infrastructure project, a technology firm supplying software solutions to a government agency, or a healthcare provider offering medical services under a government contract.</li></ul><p>Understanding these fundamental concepts is crucial for businesses to tailor their strategies, marketing efforts, and operational processes to effectively serve their target customers, whether they are other businesses, individual consumers, or government entities. Each type of transaction comes with its unique challenges, opportunities, and considerations, necessitating a nuanced approach to meet the diverse needs of the market.</p><h3>Business Flow?</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VX2YAS4juqVrO0PbbUwHLQ.png" /><figcaption>Nani’s busines flow by eugeniusmario.</figcaption></figure><p>Understanding and creating a business flow is essential in product design for several reasons:</p><ol><li><strong>Clarity of Process</strong></li></ol><p>Developing a clear business flow helps in understanding the step-by-step process involved in bringing a product to market. It provides a structured roadmap that outlines the sequence of tasks and activities required for successful product development, from ideation to launch.</p><p><strong>2. Identification of Gaps and Redundancies</strong></p><p>By mapping out the business flow, potential gaps, redundancies, and inefficiencies in the process can be identified early on. This allows for timely adjustments and optimizations to streamline operations, improve productivity, and reduce costs.</p><p><strong>3. Alignment of Stakeholders</strong></p><p>A well-defined business flow facilitates alignment among stakeholders, including product developers, marketers, sales teams, and investors. It ensures that everyone involved understands their roles, responsibilities, and the overall objectives of the project, fostering collaboration and synergy across departments.</p><p><strong>4. Risk Mitigation</strong></p><p>Understanding the business flow enables the identification and mitigation of potential risks and challenges that may arise during the product development lifecycle. By proactively addressing these issues, such as supply chain disruptions, regulatory hurdles, or market shifts, the likelihood of project delays or failures can be minimized.</p><p><strong>5. Customer-Centric Design</strong></p><p>A thorough understanding of the business flow allows for a customer-centric approach to product design. By analyzing each stage of the process from the customer’s perspective, developers can identify pain points, preferences, and unmet needs, guiding the creation of solutions that resonate with the target audience.</p><p><strong>6. Continuous Improvement</strong></p><p>Business flow documentation serves as a foundation for continuous improvement. It provides a baseline for measuring performance, tracking progress, and identifying areas for enhancement or innovation. By regularly revisiting and refining the business flow, companies can adapt to changing market conditions, technology advancements, and customer feedback, ensuring ongoing relevance and competitiveness.</p><p>In summary, comprehending and designing a business flow is crucial for effective product development. It enables clarity of process, alignment of stakeholders, risk mitigation, customer-centric design, and continuous improvement, ultimately contributing to the success and sustainability of the product in the marketplace.</p><h3>Chapter 3: Finance</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2ZXBugToSNY_JtABNSnAsg.png" /><figcaption>Finance by eugeniusmario.</figcaption></figure><p>Understanding the importance of finance is akin to unlocking the key to sustainable business growth and longevity. Finance serves as the lifeblood of an organization, fueling its operations, investments, and strategic initiatives. Without a solid grasp of financial principles, businesses risk operating blindly, unable to effectively manage their resources, assess risks, or capitalize on opportunities.</p><p>Finance not only provides the means to acquire necessary assets and resources but also empowers decision-makers to allocate capital judiciously, optimize profitability, and navigate the dynamic landscape of economic uncertainties and market fluctuations. In essence, a thorough understanding of finance is essential for businesses to thrive in an increasingly competitive and volatile environment, serving as a guiding beacon for informed decision-making and strategic planning.</p><h3><strong>The Significance of a Solid Financial Blueprint</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BLqEyg_AWO-h2iEI_H3RUQ.png" /><figcaption>Financial blueprint by eugeniusmario.</figcaption></figure><p>The significance of a solid financial blueprint cannot be overstated in the realm of business sustainability and success. A well-crafted financial plan serves as the cornerstone of organizational stability, providing a roadmap for effective resource allocation, risk management, and goal attainment. Without a clear financial blueprint, businesses are akin to ships adrift in turbulent waters, susceptible to financial crises, misallocation of funds, and missed opportunities.</p><p>By establishing a comprehensive financial framework that delineates short-term objectives and long-term aspirations, businesses can proactively mitigate risks, optimize financial performance, and chart a course towards sustainable growth and prosperity. In essence, a solid financial blueprint is not just a document; it’s a strategic imperative that empowers businesses to navigate uncertainty, seize opportunities, and thrive in an ever-evolving marketplace.</p><h3>Designing a Financial Plan</h3><p>Designing a financial plan is a pivotal task for any organization aiming for sustainable growth and long-term success. This process involves a comprehensive analysis of the company’s financial landscape, strategic objectives, and market dynamics to chart a course for optimal resource utilization and financial stability.</p><p>At <a href="https://naniagritech.com/">Nani Agritech</a>, the responsibility of financial planning falls under the purview of our Chief Financial Officer (CFO), Jennifer Maydeline. With her keen analytical skills and forward-thinking approach, Jennifer ensures that Nani’s financial strategies are not only aligned with our short-term objectives but also poised to drive long-term growth and sustainability. Under her guidance, we prioritize prudent budgeting, optimize cash flow management, and strategically allocate resources to fuel innovation and expansion initiatives.</p><p>Moreover, Jennifer spearheads efforts to evaluate investment opportunities, manage financial risks, and enhance shareholder value, positioning Nani for continued success in today’s dynamic business landscape. In essence, Jennifer’s leadership in financial planning plays a pivotal role in steering Nani towards its strategic goals and ensuring our financial health and resilience in the face of evolving market challenges.</p><p>The following key components are integral to the design of an effective financial plan:</p><ol><li><strong>Budgeting and Forecasting</strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*waOLAFMPBHRO4PX78b7sVw.png" /><figcaption>Financial forecasting in Nani by eugeniusmario.</figcaption></figure><p>Budgeting lays the foundation for financial planning by allocating resources to various activities in alignment with organizational goals. Forecasting, on the other hand, involves predicting future financial performance based on historical data, market trends, and economic indicators. By combining these elements, businesses can create a roadmap for managing expenses, optimizing revenues, and achieving profitability targets.</p><p><strong>2. Cash Flow Management</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/804/1*taWlICL7Im-3AEDW3p94tQ.png" /><figcaption>Payback period calculations by eugeniusmario.</figcaption></figure><p>Effective cash flow management is essential for ensuring liquidity and operational continuity. This involves monitoring cash inflows and outflows, optimizing receivables and payables, and maintaining adequate reserves to cover short-term obligations. By implementing robust cash flow management practices, businesses can mitigate financial risks, seize investment opportunities, and navigate economic uncertainties with confidence.</p><p><strong>3. Investment Strategies</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/796/1*_jqsueohy9jK9zwH945idw.png" /><figcaption>Investment opportunities in Nani by eugeniusmario.</figcaption></figure><p>Strategic investments play a crucial role in driving long-term growth and value creation. Businesses must carefully evaluate investment opportunities, weighing factors such as risk, return potential, and alignment with organizational objectives. Diversification of investment portfolios can help mitigate risk and maximize returns, while prudent risk management practices safeguard the company’s financial health and resilience.</p><p><strong>4. Risk Assessment and Mitigation</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*49QU5OK0hmvbjiimM89rdg.png" /><figcaption>Risk mitigation in Nani by eugeniusmario.</figcaption></figure><p>Identifying and mitigating financial risks is paramount to the success of any financial plan. Businesses must conduct a comprehensive risk assessment to identify potential threats, such as market volatility, regulatory changes, or supply chain disruptions. By proactively addressing these risks through risk mitigation strategies, contingency planning, and insurance coverage, businesses can safeguard their financial well-being and protect against unforeseen challenges.</p><p>In essence, designing a financial plan requires a holistic approach that considers the organization’s strategic objectives, market dynamics, and risk profile. By incorporating budgeting, forecasting, cash flow management, investment strategies, and risk mitigation measures, businesses can create a roadmap for financial success and resilience in an increasingly complex and competitive environment.</p><h3>Chapter 4: Marketing</h3><p>Marketing plays a pivotal role in shaping the success and trajectory of any business venture. It encompasses a diverse array of strategies, techniques, and tools aimed at promoting products or services, attracting customers, and fostering brand loyalty.</p><p>At Nani, the responsibility of marketing planning falls under the expertise of our Chief Marketing Officer (CMO), Angeline Wijaya Limbergh, a visionary leader with a wealth of experience in brand management and strategic marketing. Under her guidance, we employ a data-driven approach to market research, leveraging insights to identify emerging trends, consumer preferences, and competitive landscapes.</p><p>Angeline’s strategic prowess and creative vision enable us to develop compelling marketing strategies that resonate with our target audience and amplify our brand messaging across various channels. Additionally, she spearheads efforts to enhance customer experiences, foster brand advocacy, and nurture long-term relationships with our valued customers. Angeline’s leadership in marketing planning is instrumental in propelling Nani towards its strategic objectives and establishing a strong foothold in the agricultural technology sector.</p><p>In this chapter, we will explore the multifaceted world of marketing and its significance in driving business growth and profitability.</p><ol><li><strong>Understanding the Foundations of Marketing</strong></li></ol><p>Marketing goes beyond mere advertising; it involves understanding customer needs, market dynamics, and competitive landscapes.By conducting market research, analyzing consumer behavior, and identifying target demographics, businesses can tailor their marketing efforts to resonate with their audience and differentiate themselves from competitors.</p><p><strong>2. Crafting Compelling Marketing Strategies</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ijTy64jgistF69_81i43Aw.png" /><figcaption>Marketing strategies in Nani by eugeniusmario.</figcaption></figure><p>Effective marketing strategies are rooted in a deep understanding of the product, its unique selling points, and the value proposition it offers to customers. From traditional advertising channels to digital marketing platforms, businesses have a myriad of options at their disposal to reach and engage with their target audience. By leveraging data analytics, social media, content marketing, and other innovative approaches, businesses can create personalized experiences, build brand awareness, and drive customer engagement.</p><p><strong>3. Building Brand Equity and Customer Relationships</strong></p><p>Branding is integral to marketing, encompassing the perception, reputation, and emotional connection that consumers have with a brand. Through consistent messaging, visual identity, and brand storytelling, businesses can cultivate brand equity and foster trust and loyalty among customers. Additionally, establishing strong customer relationships through effective communication, customer service, and engagement initiatives is essential for long-term success and advocacy.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*K0PM8YtFhfV5XAsWNEvTOw.png" /><figcaption>Instagram Nani for branding by eugeniusmario.</figcaption></figure><p>Instagram serves as a potent tool for enhancing brand equity and nurturing customer relationships through its visually immersive platform and interactive features. By leveraging captivating imagery, engaging storytelling, and direct interaction with followers, brands can effectively convey their identity, values, and offerings, fostering a sense of authenticity and connection.</p><p>User-generated content amplifies brand visibility and credibility, while influencer partnerships enable brands to reach new audiences and build trust. Furthermore, behind-the-scenes content and real-time updates on Instagram Stories humanize the brand, eliciting emotional responses and deepening customer loyalty. In essence, Instagram empowers brands to create compelling narratives, forge meaningful connections, and cultivate a loyal community of advocates, thereby strengthening brand equity and driving sustainable growth.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_qQmIalgD7wl9PkBDvIZwg.png" /><figcaption>Nani’s customer survey by eugeniusmario.</figcaption></figure><p>Customer surveys play a crucial role in building brand equity and nurturing customer relationships by providing valuable insights, fostering engagement, and demonstrating a commitment to customer satisfaction. Firstly, customer surveys enable brands to gather feedback directly from their audience, allowing them to understand customer needs, preferences, and pain points. By actively listening to customer feedback and addressing their concerns, brands can demonstrate their responsiveness and dedication to meeting customer expectations, thereby enhancing trust and credibility.</p><p>Involving customers in the feedback process makes them feel valued and heard, fostering a sense of loyalty and affinity towards the brand. Additionally, by implementing changes or improvements based on survey responses, brands can demonstrate their commitment to continuous improvement and customer-centricity, further strengthening brand equity and fostering long-term customer relationships. Overall, customer surveys serve as a powerful tool for brands to engage with their audience, gather actionable insights, and cultivate strong customer relationships built on trust, transparency, and mutual understanding.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5lrb_drMKjZ_dlFnoh_J2w.jpeg" /><figcaption>Exhibition with Nani shirt by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*B1iHrVQ712U-i47uF533aQ.png" /><figcaption>After Exhibition PPL Fasilkom UI 2024 by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*StuMeOV2CTOC1-A5MgBG_Q.jpeg" /><figcaption>Selfie after Exhibition PPL Fasilkom UI 2024 by eugeniusmario.</figcaption></figure><p>Exhibiting a startup at a trade show or exhibition with a prototype product, branded lanyards, and shirts specific to Nani can have significant effects on building brand equity and nurturing customer relationships. Firstly, showcasing a prototype product demonstrates the innovation and creativity of the brand, positioning Nani as a forward-thinking industry player committed to addressing real-world challenges in agriculture. The prototype serves as a tangible representation of Nani’s value proposition, sparking curiosity and interest among attendees and potential customers.</p><p>Branded lanyards and shirts further reinforce Nani’s brand identity and visibility at the exhibition. When attendees wear or carry these branded items, they effectively become brand ambassadors, spreading awareness of Nani to other event participants and beyond. This increased visibility helps to solidify Nani’s presence in the minds of attendees and establishes the brand as a reputable and recognizable player in the industry.</p><p>Offering these branded items as giveaways or incentives fosters positive associations with the Nani brand. Attendees perceive Nani as generous and customer-centric, enhancing brand likability and affinity. Additionally, these branded items serve as tangible reminders of the event and the positive interactions attendees had with Nani’s representatives, strengthening the emotional connection between customers and the brand.</p><p>Overall, exhibiting a startup with a prototype product, branded lanyards, and shirts at an industry event can have a profound impact on building brand equity and nurturing customer relationships. Through increased visibility, positive associations, and meaningful interactions, Nani can solidify its position in the market and cultivate a loyal customer base poised for future growth and engagement.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*G5dTw9-nDfc8nCva4WXaUA.png" /><figcaption>Tagline Nani #SiapBantuPetani by eugeniusmario.</figcaption></figure><p>The tagline “#SiapBantuPetani” (Ready to Help Farmers) can have a profound effect on building brand equity and nurturing customer relationships for Nani. Firstly, it conveys a clear message of Nani’s commitment to supporting farmers, aligning the brand with a noble cause that resonates with its target audience. By positioning itself as a partner and ally to farmers, Nani establishes a sense of empathy and trust, fostering positive associations with the brand.</p><p>The tagline serves as a powerful inspiring action and engagement among customers and stakeholders. It encourages individuals to join Nani in its mission to empower farmers and improve agricultural practices, creating a sense of community and shared purpose around the brand. This sense of belonging fosters loyalty and advocacy, as customers feel invested in Nani’s success and impact on the farming community.</p><p>The tagline “#SiapBantuPetani” encapsulates Nani’s commitment to making a positive difference in the lives of farmers, while also serving as a powerful tool for building brand equity and nurturing customer relationships. By aligning its messaging with a compelling cause and rallying customers around a shared mission, Nani strengthens its position as a trusted and respected brand in the agricultural industry.</p><p><strong>4. Embracing Digital Transformation and Innovation</strong></p><p>The digital landscape has transformed the marketing landscape, offering unprecedented opportunities for businesses to connect with customers in new and impactful ways.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wJnkDb1yy-aQSw5U8PfOCg.png" /><figcaption>Nani’s SEO comparing by eugeniusmario.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Abte6axieES_B-3vfaGnXA.png" /><figcaption>SEO Overview for Nani by eugeniusmario.</figcaption></figure><p>From search engine optimization (SEO) and pay-per-click (PPC) advertising to email marketing and influencer partnerships, digital marketing channels enable businesses to reach global audiences and track campaign performance with precision. Embracing innovation and staying abreast of emerging trends, such as artificial intelligence, virtual reality, and experiential marketing, allows businesses to stay ahead of the curve and remain competitive in an ever-evolving marketplace.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6UzLsVdWKxSxxtHZOddvPA.png" /><figcaption>Website performance <a href="https://naniagritech.com/">https://naniagritech.com</a> by eugeniusmario.</figcaption></figure><p>Embracing digital transformation and innovation, website performance plays a pivotal role. A well-performing website ensures a seamless user experience, optimized for fast load times and smooth navigation, thereby enhancing user engagement and driving conversions. Additionally, website performance directly influences search engine rankings, mobile responsiveness, and conversion rates, ultimately impacting a business’s digital presence, competitiveness, and ability to innovate in an ever-evolving digital landscape.</p><p>In essence, marketing serves as a dynamic and indispensable facet of business operations, driving brand visibility, customer acquisition, and revenue generation. By understanding the principles of marketing, harnessing the power of data and technology, and embracing creativity and innovation, businesses can unlock new avenues for growth, forge meaningful connections with customers, and carve out a distinct competitive advantage in today’s interconnected world.</p><h3>The End</h3><p>In conclusion, the journey of a computer science student delving into the realms of business, finance, and marketing within the context of Nani Agritech exemplifies the importance of interdisciplinary knowledge and a holistic approach to product development.</p><p>Through experiences as CEO of <a href="https://naniagritech.com/">Nani Agritech</a>, I recognizes the interconnectedness of technology with broader business strategies, underscoring the significance of understanding finance, marketing, and market dynamics in driving product innovation and market success.</p><p>By bridging the gap between technical expertise and business acumen, I leverages insights gained from discussions with the team, participation in business plan competitions, and hands-on experience in product development to adopt a helicopter-view approach. This approach transcends mere technological proficiency, emphasizing the integration of business, finance, and marketing considerations into the product development process.</p><p>It’s truly remarkable how our comprehensive understanding of product development, not just from a technological standpoint, has opened doors to numerous opportunities and accolades. By embracing a holistic approach that integrates business, finance, and marketing considerations into our product development process, we’ve achieved significant milestones.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eQK-wah9-NlVblL4OjT1VA.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WwKJrQ0Er4PmL2XlBzRtDw.jpeg" /><figcaption>Securing funding from UI Incubate 2024 by eugeniusmario.</figcaption></figure><p>Securing a spot in UI Incubate 2024 and receiving funding from the Directorate of Science Techno Park Universitas Indonesia in collaboration with Alpha JWC Ventures underscores the recognition of our innovative approach and potential for growth.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MMzO0-XLhtio0b9f7VXq6A.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*m1qct-i3pyNsQFCig-S63A.jpeg" /><figcaption>Nani became a finalist in the EURECA Business Plan Competition by eugeniusmario.</figcaption></figure><p>Nani became a finalist in the EURECA Business Plan Competition, a national competition hosted by Prasetya Mulya University, further validates the viability and impact of our business model.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iwrxpC_sjUkwdqrpwoK_YQ.jpeg" /><figcaption>Nani became Best Startup in PPL Fasilkom UI 2024 by eugeniusmario.</figcaption></figure><p>Nani awarded Best Startup in the “Software Project” category by the Faculty of Computer Science Universitas Indonesia in 2024 highlights our excellence and contributions to the field.</p><p>These achievements not only affirm our dedication to holistic product development but also inspire us to continue innovating and making a positive impact in the industry.</p><p>If you’re interested in connecting further with me, please visit my LinkedIn profile <a href="https://www.linkedin.com/in/eugenius-mario-s/"><strong>Eugenius Mario’s LinkedIn</strong></a><strong>.</strong></p><p>Happy to know you!</p><h3>Link &amp; References:</h3><ol><li><a href="https://naniagritech.com/">https://naniagritech.com/</a></li><li><a href="https://www.linkedin.com/company/naniagritech">https://www.linkedin.com/company/naniagritech</a></li><li><a href="https://www.linkedin.com/feed/update/urn:li:activity:7201880251348512769/">https://www.linkedin.com/feed/update/urn:li:activity:7201880251348512769/</a></li><li><a href="https://www.youtube.com/@NaniAgritech">https://www.youtube.com/@NaniAgritech</a></li><li><a href="https://www.instagram.com/naniagritech">https://www.instagram.com/naniagritech</a></li><li><a href="https://en.wikipedia.org/wiki/Minimum_viable_product">https://en.wikipedia.org/wiki/Minimum_viable_product</a></li><li><a href="https://www.gramedia.com/literasi/tujuan-bisnis/">https://www.gramedia.com/literasi/tujuan-bisnis/</a></li><li><a href="https://www.softwareseni.co.id/blog/5-model-bisnis-ecommerce-b2b-b2c-c2c-c2b-b2g">https://www.softwareseni.co.id/blog/5-model-bisnis-ecommerce-b2b-b2c-c2c-c2b-b2g</a></li><li><a href="https://skha.co.id/id/artikel/sektor-publik/lainnya/pengertian-strategi-bisnis-dan-contohnya/">https://skha.co.id/id/artikel/sektor-publik/lainnya/pengertian-strategi-bisnis-dan-contohnya/</a></li><li><a href="https://www.freshbooks.com/hub/finance/financial-projections#:~:text=A%20financial%20projection%20is%20essentially,income%2C%20and%20your%20balance%20sheet">https://www.freshbooks.com/hub/finance/financial-projections#:~:text=A%20financial%20projection%20is%20essentially,income%2C%20and%20your%20balance%20sheet</a>.</li><li><a href="https://acterys.com/blog/financial-budgeting/#:~:text=Financial%20budgeting%20is%20the%20process,control%20over%20expenses%20and%20revenue">https://acterys.com/blog/financial-budgeting/#:~:text=Financial%20budgeting%20is%20the%20process,control%20over%20expenses%20and%20revenue</a>.</li><li><a href="https://www.ocbc.id/id/article/2023/01/19/financial-projection-adalah">https://www.ocbc.id/id/article/2023/01/19/financial-projection-adalah</a></li><li><a href="https://www.investopedia.com/terms/c/cash-flow-financing.asp">https://www.investopedia.com/terms/c/cash-flow-financing.asp</a></li><li><a href="https://study.com/academy/lesson/what-is-a-financial-investment-definition-types-examples.html#:~:text=Definition%20of%20a%20Financial%20Investment,-Have%20you%20ever&amp;text=on%20your%20money.-,A%20financial%20investment%20is%20an%20asset%20that%20you%20put%20money,it%20while%20you%20own%20it">https://study.com/academy/lesson/what-is-a-financial-investment-definition-types-examples.html#:~:text=Definition%20of%20a%20Financial%20Investment,-Have%20you%20ever&amp;text=on%20your%20money.-,A%20financial%20investment%20is%20an%20asset%20that%20you%20put%20money,it%20while%20you%20own%20it</a>.</li><li><a href="https://www.simplilearn.com/financial-risk-and-types-rar131-article#:~:text=Financial%20risk%20refers%20to%20the,%2C%20liquidity%2C%20and%20operational%20risks">https://www.simplilearn.com/financial-risk-and-types-rar131-article#:~:text=Financial%20risk%20refers%20to%20the,%2C%20liquidity%2C%20and%20operational%20risks</a>.</li><li><a href="https://www.coursera.org/articles/marketing-strategy">https://www.coursera.org/articles/marketing-strategy</a></li><li><a href="https://www.adroll.com/blog/8-strategies-for-building-brand-equity">https://www.adroll.com/blog/8-strategies-for-building-brand-equity</a></li><li><a href="https://www.linkedin.com/pulse/embracing-digital-transformation-innovation-driving-success-4uilc">https://www.linkedin.com/pulse/embracing-digital-transformation-innovation-driving-success-4uilc</a></li><li><a href="https://kissflow.com/digital-transformation/embrace-digital-transformation/">https://kissflow.com/digital-transformation/embrace-digital-transformation/</a></li><li><a href="https://developers.google.com/search/docs/fundamentals/seo-starter-guide#:~:text=SEO%E2%80%94short%20for%20search%20engine,site%20through%20a%20search%20engine">https://developers.google.com/search/docs/fundamentals/seo-starter-guide#:~:text=SEO%E2%80%94short%20for%20search%20engine,site%20through%20a%20search%20engine</a>.</li><li><a href="https://glints.com/id/lowongan/seo-adalah/">https://glints.com/id/lowongan/seo-adalah/</a></li><li><a href="https://moz.com/beginners-guide-to-seo">https://moz.com/beginners-guide-to-seo</a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5b8837a836fc" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Sherlock Holmes Engineering: Unraveling Data with Deductive Engineering Skills, A Journey into…]]></title>
            <link>https://eugeniusmario.medium.com/sherlock-holmes-engineering-unraveling-data-with-deductive-engineering-skills-a-journey-into-50be82eb6a57?source=rss-974c337fafb0------2</link>
            <guid isPermaLink="false">https://medium.com/p/50be82eb6a57</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[performance]]></category>
            <category><![CDATA[user-experience]]></category>
            <category><![CDATA[sentry]]></category>
            <category><![CDATA[monitor]]></category>
            <dc:creator><![CDATA[Eugenius Mario]]></dc:creator>
            <pubDate>Wed, 29 May 2024 15:56:07 GMT</pubDate>
            <atom:updated>2024-05-30T05:38:02.960Z</atom:updated>
            <content:encoded><![CDATA[<h3>Sherlock Holmes Engineering: Unraveling Data with Deductive Engineering Skills, A Journey into Check Platform Performance, Error Haunts, and User Story</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DdzoInUudMkG3uofBgUXEw.png" /><figcaption>A journey into check platform performace by eugeniusmario.</figcaption></figure><p>Welcome to the world of Sherlock Holmes Engineering, where we don our metaphorical deerstalker hats and <strong>apply deductive engineering skills to unravel the mysteries hidden within our data</strong>. Join us on an intriguing journey as we delve deep into the realms of check platform performance, track down elusive error haunts, and unearth compelling user tales.</p><p>In this article, we’ll embark on a thrilling adventure reminiscent of Arthur Conan Doyle’s famous detective stories. Armed with our keen analytical minds and the latest engineering tools, <strong>we’ll navigate through the intricate web of data to uncover valuable insights and solve perplexing engineering challenges.</strong></p><p>Prepare to be captivated as we apply Sherlock Holmes’ legendary deductive reasoning techniques to the realm of software engineering. Together, we’ll decipher the clues, untangle the threads, and emerge victorious in our quest for knowledge and mastery. <strong>So, grab your magnifying glass and let’s embark on this exhilarating journey of discovery and enlightenment.</strong></p><p>I divide this article into <strong>5 chapters</strong> as follows:</p><ul><li><strong>Chapter 1</strong>: The Case of the Missing Data</li><li><strong>Chapter 2:</strong> Unraveling Platform Performance</li><li><strong>Chapter 3:</strong> Delving into Error Haunts</li><li><strong>Chapter 4:</strong> Deciphering User Stories</li><li><strong>Chapter 5:</strong> S__t_y! (you can check this section after read section 1–4)</li></ul><p>Each chapter can delve into its respective topic in more detail, providing practical examples, code snippets, and tips to help readers understand and implement effectively. Let’s dive!</p><h3>Chapter 1: The Case of the Missing Data</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NZI1OxHy41Itcse-v8uMoQ.png" /><figcaption>The case of the missing data by eugeniusmario.</figcaption></figure><p><strong>🔍 The Mystery Unfolds</strong></p><p>In the bustling world of software development, there arose a perplexing case: <strong>the vanishing data</strong>. Like a shadow in the fog, crucial information seemed to disappear into thin air, leaving behind baffled developers scratching their heads. But fear not, for our detective, armed with the keen observation skills of Sherlock Holmes and the analytical prowess of a seasoned software engineer, is on the case.</p><p><strong>🔎 A Closer Examination</strong></p><p>Our detective begins by scrutinizing the scene of the crime — lines of code strewn across the editor like clues waiting to be deciphered. <strong>With a magnifying glass in hand (or rather, a debugger), they meticulously trace the data’s journey through the labyrinth of functions and modules.</strong> Like Holmes combing through evidence at 221B Baker Street, they meticulously examine each variable, each method call, searching for any sign of foul play.</p><p><strong>🔑 Cracking the Code</strong></p><p>Ah, but what’s this? Aha! <strong>The culprit is revealed — a subtle logic flaw buried deep within the codebase, overlooked by the untrained eye.</strong> With a swift stroke of the keyboard, our detective rectifies the error, restoring order to the chaotic world of data. The missing pieces fall into place like the final clue in a Sherlockian mystery, and the once-elusive data emerges from the shadows, ready to fulfill its destiny.</p><p><strong>🎩 The Verdict</strong></p><p>And so, dear reader, another case is closed, thanks to the indomitable spirit of Sherlock Holmes and the meticulous methodology of software engineering. But let us not rest on our laurels, for the world of software development is rife with mysteries waiting to be solved. Until next time, when we embark on yet another thrilling adventure in the realm of technology.</p><h3>Chapter 2: Unraveling Platform Performance</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*g_9BsSDnf2C3zY1OHh39iQ.png" /><figcaption>Unraveling platform performance by eugeniusmario.</figcaption></figure><p><strong>🚀 Setting the Stage</strong></p><p>As our detective bids adieu to the enigmatic case of the missing data, a new puzzle presents itself — a performance conundrum lurking beneath the surface of our software platform. Like a well-worn violin in need of tuning, the platform’s performance falters, threatening to <strong>disrupt the harmony of user experience.</strong> But fear not, for our intrepid sleuth is undeterred, ready to delve into the intricacies of platform performance with the same fervor as a seasoned maestro preparing for a symphony.</p><p><strong>🔍 A Symphony of Metrics</strong></p><p>With the precision of a virtuoso conductor, our detective begins their investigation by orchestrating a symphony of performance metrics — response times, latency, throughput — all dancing to the rhythm of user interactions. Armed with monitoring tools akin to Holmes’ magnifying glass, they scrutinize every aspect of the platform’s behavior, <strong>seeking out inefficiencies and bottlenecks hiding in plain sight.</strong></p><p><strong>📊 Deciphering the Patterns</strong></p><p>Ah, but what do we spy amidst the cacophony of data? Patterns emerge, subtle fluctuations in performance hinting at underlying issues waiting to be uncovered. Like Holmes piecing together clues from seemingly unrelated events, our detective connects the dots, <strong>tracing the root causes of performance degradation with the precision of a master detective.</strong></p><p><strong>💡 Shedding Light on Solutions</strong></p><p>And lo, the fog begins to lift as our detective unveils solutions to the performance puzzle. <strong>Optimization strategies take shape, code refactoring, caching mechanisms, and scalability enhancements — all poised to elevate the platform to new heights of efficiency and reliability.</strong> With each solution implemented, the platform’s performance blossoms like a flower in the springtime, ready to dazzle users with its newfound speed and responsiveness.</p><p><strong>🎻 The Crescendo</strong></p><p>And thus, dear reader, our journey through the labyrinth of platform performance comes to a triumphant crescendo, guided by the indomitable spirit of Sherlock Holmes and the analytical acumen of software engineering. But let us not rest on our laurels, for the pursuit of perfection is an ongoing symphony, with each note played bringing us closer to the <strong>sublime harmony of technological excellence.</strong></p><h3>Chapter 3: Delving into Error Haunts</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ICZlaWP2S8E2S3YfplCMWQ.png" /><figcaption>Delving into error haunts by eugeniusmario.</figcaption></figure><p><strong>👻 Eerie Encounters</strong></p><p>As software engineers traverse the intricate corridors of code, they often encounter the spectral apparitions of errors lurking in the darkest recesses of their applications. These elusive anomalies, like phantoms haunting the night, have the uncanny ability to manifest at the most inopportune moments, <strong>disrupting the flow of operations</strong> and sending shivers down the spine of developers.</p><p><strong>🕵️‍♂️ Unraveling the Mystery</strong></p><p>Armed with the investigative prowess of a seasoned detective, software engineers embark on a quest to unravel the enigma of errors. <strong>With keen attention to detail, they meticulously examine stack traces, scrutinize log files, and analyze error reports, piecing together clues to uncover the underlying causes of these spectral anomalies.</strong></p><p><strong>🔍 Tracking the Phantom Menace</strong></p><p>Yet, errors prove to be elusive adversaries, evading capture with cunning and guile. Like Moriarty orchestrating a nefarious scheme, <strong>errors exploit vulnerabilities in our code, slipping through the cracks of our defenses.</strong> Undeterred, software engineers deploy a myriad of monitoring tools and error tracking mechanisms, striving to stay one step ahead of their spectral adversaries.</p><p><strong>💡 Shedding Light on Solutions</strong></p><p>With each revelation, the fog of uncertainty begins to lift, illuminating a path forward towards resolution. Armed with this newfound insight, <strong>software engineers implement robust error handling mechanisms and defensive coding practices, fortifying the application’s defenses against future incursions. </strong>Through perseverance and determination, they turn the tide against the forces of software imperfection, guiding their creations towards a future where errors are but a distant memory.</p><p><strong>👻 The Final Confrontation</strong></p><p>As our journey through the labyrinth of error haunts draws to a close, let us not grow complacent in our victory. <strong>The specter of errors may linger in the shadows, ready to strike when least expected.</strong> Yet, armed with the wisdom gained from our encounters, let us remain vigilant in our quest for error-free software, ever mindful of the lessons learned from our battles with the unknown.</p><h3>Chapter 4: Deciphering User Stories</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sl8nHC6MlWfCjSM9gn6fSA.png" /><figcaption>Dechipering user stories by eugeniusmario.</figcaption></figure><p><strong>📖 The Narrative Unfolds</strong></p><p>In the realm of software engineering, user stories serve as the narrative threads that weave together the fabric of our applications.<strong> Like pages in a detective novel, they unfold before us, revealing the desires, motivations, and needs of our users.</strong> Yet, beneath their surface lies a tapestry of complexity waiting to be unraveled.</p><p><strong>🔍 Analyzing Clues</strong></p><p>As software engineers embark on the task of deciphering user stories, they adopt the role of astute detectives, scrutinizing each detail for hidden meanings and underlying requirements. <strong>With a keen eye for detail, they parse through the narrative, identifying key features, functionalities, and acceptance criteria that lay the groundwork for their investigations.</strong></p><p><strong>🔑 Unlocking Insights</strong></p><p>Through careful analysis and collaboration with stakeholders,<strong> software engineers unlock invaluable insights into the minds of their users. </strong>They gain a deeper understanding of user personas, pain points, and preferences, allowing them to tailor their solutions to meet the unique needs of their audience. Armed with this knowledge, they chart a course towards crafting user-centric experiences that resonate with their target audience.</p><p><strong>🛠️ Building the Blueprint</strong></p><p>With user stories as their guide, <strong>software engineers set out to blueprint the architecture of their applications.</strong> They translate the abstract concepts and narratives into concrete features, functionalities, and workflows, mapping out the journey that users will undertake as they interact with the application. <strong>Through meticulous planning and iteration, they refine their designs, ensuring that each element aligns with the overarching vision of the project.</strong></p><p><strong>🌟 Empowering User Experiences</strong></p><p>As the pieces of the puzzle fall into place, software engineers witness the transformation of user stories into tangible realities. <strong>They breathe life into the narrative, infusing it with functionality, interactivity, and intuitive design. </strong>With each line of code, they empower users to navigate their digital landscapes with ease, fulfilling the promises embedded within the user stories.</p><p><strong>📜 The Saga Continues</strong></p><p>As our journey through the realm of user stories draws to a close, let us <strong>reflect on the lessons learned and the insights gained.</strong> Like detectives closing the case on a challenging investigation, let us celebrate our triumphs and embrace the challenges that lie ahead. For in the world of software engineering, the story never truly ends — it merely evolves with each new chapter, waiting to be written by those bold enough to embark on the next adventure.</p><h3>Chapter 5: Sentry!</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*EYAo-i58d_OWjyaokRQzGA.png" /><figcaption>Sentry by eugeniusmario.</figcaption></figure><p>As we bid adieu to the enigmatic world of Sherlock Holmes, <strong>we embark on a new journey — one that transcends the boundaries of fiction and delves into the realm of deductive software engineering. </strong>Just as Holmes employed his keen intellect and deductive reasoning to unravel the mysteries that crossed his path, so too shall we harness the power of logic and analysis to decipher the behavior of our digital protagonists.</p><p><strong>Enter Sentry, our trusted ally in the quest for software enlightenment. </strong>With its watchful gaze and unparalleled insights, Sentry stands as the guardian of our digital domains, ever vigilant against the specter of errors and anomalies that threaten to disrupt the harmony of our applications. Through its comprehensive monitoring and error tracking capabilities, Sentry provides us with a window into the inner workings of our software, allowing us to identify and address issues before they spiral out of control.</p><blockquote>“Sentry is a tool designed to detect and track errors occurring within software applications, providing valuable insights into user behavior and system performance.”</blockquote><h3>Implement Sentry on Your Project (Flutter)</h3><p><strong>Step 1: Create a Sentry Account:</strong></p><ul><li>Navigate to the Sentry website and sign up for a new account if you don’t already have one. You can sign up using your email address or by using your GitHub account.</li></ul><p><strong>Step 2: Create a New Project:</strong></p><ul><li>Once logged in to Sentry, create a new project by clicking on the “Create Project” button. Select the platform for your project (Flutter in this case) and give your project a name.</li></ul><p><strong>Step 3: Install Dependencies:</strong></p><ul><li>Open your Flutter project’s pubspec.yaml file.</li><li>Under the dependencies section, add sentry_flutter as a dependency and specify the version you want to use. For example:</li></ul><pre>dependencies: flutter: sdk: flutter sentry_flutter: ^5.0.0</pre><ul><li>Save the file and run flutter pub get to install the dependencies.</li></ul><p><strong>Step 4: Initialize Sentry:</strong></p><ul><li>In your Dart code, import the sentry_flutter package.</li><li>Initialize Sentry with your DSN (Data Source Name) obtained from your Sentry project settings. This typically involves calling SentryFlutter.init() with a callback function to configure options and the appRunner function to run your app.</li><li>Replace &#39;YOUR_DSN&#39; with the DSN provided by Sentry for your project.</li><li>Here’s an example of how you can initialize Sentry in your main() function:</li></ul><pre>import &#39;package:flutter/material.dart&#39;; <br>import &#39;package:sentry_flutter/sentry_flutter.dart&#39;;  <br>void main() {   <br>  SentryFlutter.init((options) =&gt; <br>  options.dsn = &#39;YOUR_DSN&#39;,     <br>  appRunner: () =&gt; runApp(MyApp()),   <br>  ); <br>}</pre><p><strong>Step 5: Capture Errors:</strong></p><ul><li>Sentry automatically captures uncaught errors and exceptions in your Flutter app. Additionally, you can manually capture errors using the Sentry.captureException() method.</li><li>Surround your code that might throw an error with a try-catch block, and use Sentry.captureException() to capture and report the error.</li><li>Here’s an example of capturing an error:</li></ul><pre>try {   // Your code that might throw an error <br>} catch (error, stackTrace) {   <br>  Sentry.captureException(error, stackTrace: stackTrace,); <br>}</pre><p><strong>Step 6: Customize Configuration (Optional):</strong></p><ul><li>Sentry allows you to customize various configuration options to suit your needs. For example, you can set tags, release versions, or environment information.</li><li>Use Sentry.configureScope() to customize the scope before capturing an error.</li><li>Here’s an example of how you can customize the configuration:</li></ul><pre>Sentry.configureScope((scope) {   <br>  scope.setTags({&#39;environment&#39;: &#39;development&#39;});   <br>  scope.setRelease(&#39;1.0.0&#39;); <br>});</pre><p><strong>Step 7: Test Sentry Integration:</strong></p><ul><li>Run your Flutter application on a device or emulator.</li><li>Intentionally trigger an error or exception in your app to verify that Sentry is correctly capturing and reporting errors.</li></ul><p><strong>Step 8: Monitor Sentry Dashboard:</strong></p><ul><li>Check your Sentry project dashboard to view captured errors, monitor their occurrences, and analyze user sessions.</li><li>You can access the Sentry dashboard from your web browser by logging in to your Sentry account and selecting your project.</li></ul><h3>The End</h3><p>Congratulations! You’ve now successfully integrated Sentry into your Flutter project to catch and report user errors effectively. By following the steps outlined in this guide, you’ve empowered your application to capture exceptions, track issues, and gain valuable insights into user experiences.</p><p><strong>Key Takeaways:</strong></p><ol><li><strong>Proactive Error Monitoring</strong></li></ol><p>With Sentry, you can proactively monitor and capture errors that occur in your Flutter app, ensuring that you’re aware of any issues affecting your users.</p><p><strong>2. Real-Time Alerts</strong></p><p>Sentry provides real-time alerts for errors, allowing you to stay informed and take immediate action to address issues as they arise.</p><p><strong>3. Improved User Experience</strong></p><p>By quickly identifying and resolving errors, you can enhance the overall user experience of your Flutter application, leading to higher user satisfaction and retention.</p><p><strong>4. Continuous Improvement</strong></p><p>Leveraging Sentry’s insights, you can continuously improve your app by identifying common error patterns, prioritizing fixes, and iterating on new features with confidence.</p><p><strong>Keep Evolving:</strong></p><p>As you continue to develop and enhance your Flutter application, remember to iterate on your error monitoring strategy with Sentry. Regularly review error reports, analyze user feedback, and make data-driven decisions to drive continuous improvement.</p><p>By harnessing the power of Sentry to catch user errors, you’re not only ensuring the stability and reliability of your Flutter app but also demonstrating your commitment to delivering a seamless and exceptional user experience.</p><p>Thank you for joining me on this enlightening expedition, and may your coding endeavors be filled with success and fulfillment!</p><p>If you’re interested in connecting further with me, please visit my LinkedIn profile <a href="https://www.linkedin.com/in/eugenius-mario-s/"><strong>Eugenius Mario’s LinkedIn</strong></a><strong>.</strong></p><p>Happy coding!</p><h3>References:</h3><ol><li><a href="https://en.wikipedia.org/wiki/Sherlock_Holmes">https://en.wikipedia.org/wiki/Sherlock_Holmes</a></li><li><a href="https://www.gramedia.com/best-seller/novel-sherlock-holmes/">https://www.gramedia.com/best-seller/novel-sherlock-holmes/</a></li><li><a href="https://www.goodreads.com/series/49996-sherlock-holmes">https://www.goodreads.com/series/49996-sherlock-holmes</a></li><li><a href="https://www.sciencedirect.com/topics/computer-science/user-performance">https://www.sciencedirect.com/topics/computer-science/user-performance</a></li><li><a href="https://sentry.io/_/tutorials/02/">https://sentry.io/_/tutorials/02/</a></li><li><a href="https://sentry.io/_/tutorials/03/">https://sentry.io/_/tutorials/03/</a></li><li><a href="https://docs.sentry.io/product/sentry-basics/integrate-backend/capturing-errors/">https://docs.sentry.io/product/sentry-basics/integrate-backend/capturing-errors/</a></li><li><a href="https://sentry.io/">https://sentry.io/</a></li><li><a href="https://docs.sentry.io/">https://docs.sentry.io/</a></li><li><a href="https://docs.sentry.io/platforms/dart/">https://docs.sentry.io/platforms/dart/</a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=50be82eb6a57" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Unlocking Program Perfection: A Journey through Dynamic Static Analysis and Quality Assurance Tools…]]></title>
            <link>https://eugeniusmario.medium.com/unlocking-program-perfection-a-journey-through-dynamic-static-analysis-and-quality-assurance-tools-812af8f7628e?source=rss-974c337fafb0------2</link>
            <guid isPermaLink="false">https://medium.com/p/812af8f7628e</guid>
            <category><![CDATA[sonarcloud]]></category>
            <category><![CDATA[qodana]]></category>
            <category><![CDATA[qa]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[quality-assurance]]></category>
            <dc:creator><![CDATA[Eugenius Mario]]></dc:creator>
            <pubDate>Wed, 29 May 2024 15:48:39 GMT</pubDate>
            <atom:updated>2024-05-30T04:53:46.447Z</atom:updated>
            <content:encoded><![CDATA[<h3>Unlocking Program Perfection: A Journey through Dynamic Static Analysis and Quality Assurance Tools (Sonarcloud and Qodana)</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LAPK7s7Ny7MN8S1LjN6RNw.png" /><figcaption>Program perfection with quality assurance tools by eugeniusmario.</figcaption></figure><p>In the ever-evolving landscape of software development, ensuring the quality and reliability of code is paramount. Enter dynamic static analysis and cutting-edge quality assurance tools like <strong>SonarCloud and Qodana</strong>. Join us on a transformative journey as we explore the intricacies of these powerful tools and unlock the path to program perfection.</p><p>In this article, we’ll delve deep into the realm of dynamic static analysis, a methodology that combines <strong>the rigor of static code analysis with the flexibility of dynamic testing</strong>. We’ll uncover the inner workings of SonarCloud, a cloud-based platform that offers comprehensive code quality and security analysis for projects of all sizes. Additionally, we’ll explore Qodana, a revolutionary quality assurance tool that provides intelligent code inspections and actionable insights to streamline the development process.</p><p>Get ready to embark on an enlightening expedition through the realms of code quality and software excellence. Together, we’ll unravel the mysteries of dynamic static analysis and harness the power of SonarCloud and Qodana to propel our projects towards perfection. Join us as we unlock the secrets to <strong>building robust, maintainable, and scalable software solutions.</strong></p><p>I divide this article into <strong>4 sections</strong> as follows:</p><ul><li><strong>Section 1</strong>: Introduction: Unveiling Program Perfection</li><li><strong>Section 2:</strong> Exploring Dynamic Static Analysis</li><li><strong>Section 3:</strong> Quality Assurance Tools in Focus: Sonarcloud and Qodana</li><li><strong>Section 4:</strong> Conclusion</li></ul><p>Each section can delve into its respective topic in more detail, providing practical examples, code snippets, and tips to help readers understand and implement. Let’s dive!</p><h3>Section 1: Introduction: Unveiling Program Perfection</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*bp4lIu7JhM0gMEtki0cFRg.png" /><figcaption>Unveiling program perfection by eugeniusmario.</figcaption></figure><p>Welcome to a journey through the realm of program perfection, where the pursuit of <strong>excellence in software development meets the transformative power of dynamic static analysis and quality assurance tools.</strong> In this introductory chapter, we embark on a quest to uncover the <strong>secrets behind achieving program perfection</strong>, a goal that has long eluded many software engineers and developers.</p><p><strong>Imagine a world where every line of code is meticulously crafted, every function flawlessly executed, and every software product exceeds user expectations.</strong> This is the vision that drives us as we delve into the intricacies of dynamic static analysis and explore the capabilities of cutting-edge quality assurance tools such as Sonarcloud and Qodana.</p><p><strong>But why is program perfection so elusive</strong>, and what role do these tools play in its attainment? We unravel the complexities of software development, navigating through the challenges and opportunities that lie ahead. Together, we will unlock the potential of dynamic static analysis and quality assurance, paving the way towards a future where program <strong>perfection is not just a dream, but a reality.</strong></p><h3>Section 2: Exploring Dynamic Static Analysis</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7dauscUbp9gQCelUv5kzNg.png" /><figcaption>Exploring dynamic static analysis by eugeniusmario.</figcaption></figure><p>In this chapter, we dive deep into the fascinating world of dynamic static analysis, a powerful technique that holds the key to uncovering hidden defects and vulnerabilities in software code. <strong>Dynamic static analysis represents a paradigm shift in the way developers approach code quality, offering real-time insights and actionable feedback to streamline the development process.</strong></p><p>Picture a scenario where every line of code is scrutinized with precision, every potential error identified before it has a chance to manifest, and every software project fortified against the onslaught of bugs and glitches. This is the <strong>promise of dynamic static analysis</strong>, a promise that has the potential to revolutionize the way we build and maintain software systems.</p><p><strong>But what exactly is dynamic static analysis, and how does it work? </strong>Join us as we unravel the mysteries of this cutting-edge technique, exploring its principles, methodologies, and practical applications. From <strong>detecting code smells to optimizing performance, dynamic static analysis empowers developers to write cleaner, more robust code and deliver higher-quality software products to their users.</strong></p><h3>Not using dynamic static analysis can lead to several drawbacks, including:</h3><ol><li><strong>Lack of Early Issue Detection</strong></li></ol><p>Without dynamic static analysis, development teams may not be aware of potential issues in their code until late in the development cycle. This can result in the <strong>accumulation of bugs and weaknesses that are difficult and costly to fix in the later stages of development.</strong></p><p><strong>2. Decreased Code Quality</strong></p><p>Without tools to detect code smells and anti-patterns, the likelihood of the code being <strong>less clean and less efficient increases.</strong> This can lead to difficulties in code maintenance, increased security vulnerabilities, and poor application performance.</p><p><strong>3. Risk of Low Performance</strong></p><p>Without dynamic static analysis, developers may not be aware of code areas that <strong>consume excessive resources or cause slow performance.</strong> This can result in less responsive and inefficient applications, which can degrade the end-user experience.</p><p><strong>4. Dependency on Manual Testing</strong></p><p>Without tools to analyze code automatically, development teams may have to rely on<strong> time-consuming manual testing to find bugs and issues in the code.</strong> This can hinder development speed and increase the risk of human error.</p><p><strong>5. Difficulty in Aligning with Industry Standards</strong></p><p>Dynamic static analysis often checks code against industry standards and best practices. Without these tools, development teams may struggle to ensure that their code <strong>complies with standards and meets industry expectations.</strong></p><h3>So, dynamic static analysis offers developers a wide range of benefits, including:</h3><ol><li><strong>Detecting Code Smells</strong></li></ol><p>Dynamic static analysis tools can identify common code smells or anti-patterns in the codebase. These include inefficiencies, redundancies, and violations of best practices. By <strong>detecting code smells early in the development process, developers can refactor their code to improve readability, maintainability, and performance.</strong></p><p><strong>2. Optimizing Performance</strong></p><p>Dynamic static analysis tools can <strong>analyze code for potential performance bottlenecks and inefficiencies. </strong>They can identify areas of the code that may be consuming excessive resources or causing slowdowns. By optimizing performance-critical sections of the code, developers can ensure that their software runs smoothly and efficiently, providing a better user experience.</p><p><strong>3. Empowering Developers</strong></p><p>Dynamic static analysis tools empower developers to write cleaner, more robust code. By providing <strong>real-time feedback and actionable insights, these tools help developers catch errors and issues before they become critical problems</strong>. This allows developers to iterate quickly, experiment with new features, and deliver high-quality software products to their users.</p><p><strong>4. Delivering Higher-Quality Software</strong></p><p>Ultimately, dynamic static analysis contributes to the overall quality of software products. By enabling developers to identify and address issues early in the development lifecycle, these tools help reduce the number of bugs, vulnerabilities, and technical debt in the codebase. This leads to <strong>higher-quality software that meets user expectations</strong> and delivers value to stakeholders.</p><h3>So what exactly does dynamic static analysis do, and what are its methods like?</h3><p><strong>Dynamic static analysis involves analyzing code without executing it.</strong> This analysis is performed by tools specifically designed to examine code for potential issues, vulnerabilities, and inefficiencies. The methods used in dynamic static analysis typically include:</p><ol><li><strong>Code Parsing</strong></li></ol><p>The tools parse the source code files to <strong>understand the structure, syntax, and semantics of the code.</strong> This parsing process allows the tools to extract meaningful information from the code, such as variable declarations, function definitions, and control flow structures.</p><p><strong>2. Pattern Matching</strong></p><p>Dynamic static analysis tools use predefined patterns or rules to identify common code smells, anti-patterns, and potential bugs. These patterns may include <strong>checks for null pointer dereferences, resource leaks, unused variables, and other common programming mistakes.</strong></p><p><strong>3. Data Flow Analysis</strong></p><p>The tools perform data flow analysis to t<strong>race the flow of data through the code and identify potential security vulnerabilities and privacy leaks</strong>. This analysis helps detect issues such as insecure data handling, cross-site scripting vulnerabilities, and sensitive data exposure.</p><p><strong>4. Control Flow Analysis</strong></p><p>Dynamic static analysis tools analyze the control flow of the code to <strong>detect potential logic errors, unreachable code, and dead code branches</strong>. This analysis helps ensure that the code behaves as expected under different conditions and inputs.</p><p><strong>5. Code Metrics Calculation</strong></p><p>The tools calculate various code metrics to <strong>assess the quality, complexity, and maintainability of the code</strong>. These metrics may include cyclomatic complexity, code duplication, code churn, and code coverage.</p><p>Overall, dynamic static analysis <strong>aims to improve code quality, security, and performance</strong> by identifying issues early in the development process, before the code is executed. This helps developers address potential problems proactively and deliver higher-quality software products to users.</p><h3>Section 3: Quality Assurance Tools in Focus: Sonarcloud and Qodana</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*e-eePmOLJ7NwALZgOiQ3Eg.png" /><figcaption>Sonarcloud &amp; Qodana by eugeniusmario.</figcaption></figure><p>Quality assurance (QA) is a critical aspect of software development aimed at ensuring that the final product meets specified quality standards and fulfills user expectations. <strong>It encompasses a range of activities, processes, and methodologies designed to identify, prevent, and rectify defects or inconsistencies in software applications.</strong></p><p>The primary goal of QA is to <strong>enhance the overall quality, reliability, and performance of software products, thereby enhancing user satisfaction and minimizing risks associated with software failures or malfunctions. </strong>QA encompasses various stages of the software development lifecycle, including requirements analysis, design, development, testing, deployment, and maintenance.</p><p>To achieve effective quality assurance, software development teams rely on a variety of tools and technologies specifically designed to automate, streamline, and enhance QA processes. These tools play a crucial role in facilitating code analysis, testing, debugging, performance monitoring, and security assessment, among other tasks.</p><h3>By leveraging QA tools, development teams can:</h3><ol><li><strong>Identify and address code issues</strong></li></ol><p>QA tools enable developers to detect bugs, code smells, vulnerabilities, and other potential issues early in the development process, allowing for timely resolution and preventing the escalation of problems.</p><p><strong>2. Ensure code quality and maintainability</strong></p><p>QA tools provide insights into code quality metrics, such as complexity, maintainability, readability, and adherence to coding standards. This helps developers write cleaner, more efficient code that is easier to maintain and extend over time.</p><p><strong>3. Enhance software reliability and stability</strong></p><p>By performing comprehensive testing, including unit testing, integration testing, and regression testing, QA tools help ensure that software applications function as intended and remain stable under various conditions and use cases.</p><p><strong>4. Improve productivity and efficiency</strong></p><p>QA tools automate repetitive tasks, such as code analysis, testing, and reporting, freeing up developers’ time to focus on more creative and value-added activities. This leads to greater productivity, faster time-to-market, and reduced development costs.</p><h3>Sonarcloud &amp; Qodana</h3><p>In this section, we’ll delve into two powerful quality assurance tools: Sonarcloud and Qodana. These tools play a crucial role in ensuring the quality, reliability, and security of software projects by providing comprehensive code analysis and actionable insights.</p><p><strong>1. Sonarcloud</strong></p><p>Sonarcloud is a cloud-based code quality and security analysis tool that helps developers <strong>detect and fix code issues early in the development process.</strong> It offers a wide range of features, including static code analysis, code smell detection, security vulnerability scanning, and code coverage tracking. Sonarcloud integrates seamlessly with popular version control systems like GitHub, GitLab, and Bitbucket, allowing developers to automatically analyze code on every commit and pull request. <strong>By providing continuous feedback on code quality and security, Sonarcloud enables teams to maintain high standards and deliver robust, reliable software.</strong></p><p><strong>2. Qodana</strong></p><p>Qodana is an intelligent quality assurance tool developed by JetBrains that focuses on code review and analysis. <strong>It offers advanced static code analysis capabilities, detecting code issues, performance bottlenecks, and potential bugs.</strong> Qodana also provides insights into code duplication, complexity, and maintainability, helping developers write cleaner, more maintainable code. One of Qodana’s standout features is its integration with JetBrains IDEs, such as IntelliJ IDEA and PyCharm, allowing developers to perform code analysis directly within their development environment. With Qodana, <strong>teams can streamline code review processes, identify and address issues early, and ensure the overall quality and stability of their software projects.</strong></p><p>In the following sections, we’ll explore the key features and benefits of each tool in more detail, highlighting how they contribute to improving software quality and driving development efficiency.</p><h3>Implement Sonarcloud to Your Project</h3><p>SonarCloud is a cloud-based code quality and security analysis platform that helps developers identify, track, and resolve issues in their codebase. It offers a range of features for static code analysis, code coverage tracking, security vulnerability detection, and more. In this tutorial, we’ll explore how to set up and use SonarCloud to improve the quality of your code.</p><h4>Step 1: Sign Up for SonarCloud</h4><ol><li>Visit the SonarCloud website at <a href="https://sonarcloud.io/">sonarcloud.io</a> and sign up for an account.</li><li>Follow the instructions to create a new organization and project within SonarCloud.</li></ol><h4>Step 2: Configure Your Project</h4><ol><li>Once your project is created, you’ll need to generate a token to authenticate your code analysis. Go to your project settings and navigate to the “Security” tab.</li><li>Click on “Generate Tokens” and follow the prompts to create a new token. Copy the token value as you’ll need it later.</li></ol><h4>Step 3: Integrate SonarCloud with Your Project</h4><p>SonarCloud supports integration with various build tools and CI/CD pipelines. Here’s how to integrate SonarCloud with popular tools like Maven and Gradle:</p><p>Maven Integration:</p><ol><li>Add the SonarCloud plugin to your pom.xml file:</li></ol><pre>&lt;project&gt;<br>  ...<br>  &lt;build&gt;<br>    &lt;plugins&gt;<br>      &lt;plugin&gt;<br>        &lt;groupId&gt;org.sonarsource.scanner.maven&lt;/groupId&gt;<br>        &lt;artifactId&gt;sonar-maven-plugin&lt;/artifactId&gt;<br>        &lt;version&gt;3.9.1.2184&lt;/version&gt;<br>      &lt;/plugin&gt;<br>    &lt;/plugins&gt;<br>  &lt;/build&gt;<br>  ...<br>&lt;/project&gt;</pre><ol><li>Configure the SonarCloud plugin with your project key and authentication token:</li></ol><pre>&lt;project&gt;<br>  ...<br>  &lt;properties&gt;<br>    &lt;sonar.projectKey&gt;your_project_key&lt;/sonar.projectKey&gt;<br>    &lt;sonar.organization&gt;your_organization&lt;/sonar.organization&gt;<br>    &lt;sonar.host.url&gt;https://sonarcloud.io&lt;/sonar.host.url&gt;<br>    &lt;sonar.login&gt;your_authentication_token&lt;/sonar.login&gt;<br>  &lt;/properties&gt;<br>  ...<br>&lt;/project&gt;</pre><p>Replace your_project_key, your_organization, and your_authentication_token with your actual values.</p><p>Gradle Integration:</p><ol><li>Add the SonarCloud plugin to your build.gradle file:</li></ol><pre>plugins {<br>  id &quot;org.sonarqube&quot; version &quot;3.3&quot;<br>}</pre><ol><li>Configure the SonarCloud plugin with your project key and authentication token:</li></ol><pre>sonarqube {<br>  properties {<br>    property &quot;sonar.projectKey&quot;, &quot;your_project_key&quot;<br>    property &quot;sonar.organization&quot;, &quot;your_organization&quot;<br>    property &quot;sonar.host.url&quot;, &quot;https://sonarcloud.io&quot;<br>    property &quot;sonar.login&quot;, &quot;your_authentication_token&quot;<br>  }<br>}</pre><p>Replace your_project_key, your_organization, and your_authentication_token with your actual values.</p><h4>Step 4: Run Code Analysis</h4><p>Once you’ve configured your project, you can run code analysis using the following command:</p><p>Maven:</p><pre>mvn clean verify sonar:sonar</pre><p>Gradle:</p><pre>./gradlew sonarqube</pre><h4>Step 5: View Analysis Results</h4><p>After the analysis completes, navigate to your SonarCloud project dashboard to view the analysis results. You’ll see information about code quality, bugs, vulnerabilities, code smells, and more.</p><h3>Implement Qodana to Your Project</h3><p>Qodana is a comprehensive code quality analysis tool that provides insights into code issues, security vulnerabilities, and performance bottlenecks. In this tutorial, we’ll walk through the steps to set up and use Qodana to improve the quality of your codebase.</p><h4>Step 1: Sign Up for Qodana</h4><ol><li>Visit the Qodana website at <a href="https://www.jetbrains.com/qodana/">qodana</a> and sign up for an account.</li><li>Follow the instructions to create a new organization and project within Qodana.</li></ol><h4>Step 2: Configure Your Project</h4><ol><li>Once your project is created, you’ll need to download and install the Qodana CLI tool. You can find the installation instructions in the Qodana documentation.</li><li>Generate an access token for your project. This token will be used to authenticate the Qodana CLI tool with your Qodana account.</li></ol><h4>Step 3: Run Code Analysis</h4><ol><li>Navigate to your project directory in the terminal or command prompt.</li><li>Run the following command to start code analysis:</li></ol><pre>qodana analyze</pre><ol><li>Follow the prompts to enter your access token and specify any additional configuration options for the analysis.</li></ol><h4>Step 4: View Analysis Results</h4><p>After the analysis completes, Qodana will generate a detailed report with insights into code issues, security vulnerabilities, and performance metrics. You can view the report directly in the terminal or command prompt, or you can upload it to the Qodana web interface for further analysis.</p><h4>Step 5: Integrate with CI/CD Pipelines (Optional)</h4><p>To automate code analysis as part of your CI/CD pipeline, you can integrate Qodana with popular CI/CD platforms like Jenkins, GitLab CI/CD, or GitHub Actions. Consult the Qodana documentation for instructions on how to set up these integrations.</p><h3>Section 4: Conclusion</h3><p>In conclusion, dynamic static analysis tools like SonarCloud and Qodana play a crucial role in ensuring the quality and reliability of software projects. By leveraging these tools, developers can detect code smells, optimize performance, and identify security vulnerabilities early in the development process. This proactive approach <strong>not only helps prevent issues from arising but also saves time and resources by addressing them before they escalate.</strong></p><p>Moreover, the insights provided by dynamic static analysis empower <strong>developers to write cleaner, more robust code and deliver higher-quality software products to their users</strong>. By continuously monitoring and improving code quality throughout the development lifecycle, teams can build trust with their users and maintain a competitive edge in the market.</p><h3>The End</h3><p>As technology continues to evolve and software projects become increasingly complex, the importance of quality assurance tools cannot be overstated. SonarCloud and Qodana, with their comprehensive features and user-friendly interfaces, are valuable assets for any development team striving for excellence in their software products. By incorporating these tools into their workflow, <strong>teams can foster a culture of quality and innovation, ultimately leading to greater success and customer satisfaction.</strong></p><p>Thank you for joining me on this enlightening expedition, and may your coding endeavors be filled with success and fulfillment!</p><p>If you’re interested in connecting further with me, please visit my LinkedIn profile <a href="https://www.linkedin.com/in/eugenius-mario-s/"><strong>Eugenius Mario’s LinkedIn</strong></a><strong>.</strong></p><p>Happy coding!</p><h3>References:</h3><ol><li><a href="https://www.veracode.com/blog/secure-development/static-testing-vs-dynamic-testing#:~:text=Static%20analysis%20is%20a%20test,a%20program%20is%20in%20operation">https://www.veracode.com/blog/secure-development/static-testing-vs-dynamic-testing#:~:text=Static%20analysis%20is%20a%20test,a%20program%20is%20in%20operation</a>.</li><li><a href="https://www.intel.com/content/www/us/en/docs/inspector/user-guide-windows/2022/dynamic-analysis-vs-static-analysis.html">https://www.intel.com/content/www/us/en/docs/inspector/user-guide-windows/2022/dynamic-analysis-vs-static-analysis.html</a></li><li><a href="https://www.checkpoint.com/cyber-hub/cloud-security/what-is-dynamic-code-analysis/">https://www.checkpoint.com/cyber-hub/cloud-security/what-is-dynamic-code-analysis/</a></li><li><a href="https://www.paloaltonetworks.com/cyberpedia/why-you-need-static-analysis-dynamic-analysis-machine-learning">https://www.paloaltonetworks.com/cyberpedia/why-you-need-static-analysis-dynamic-analysis-machine-learning</a></li><li><a href="https://www.harness.io/blog/static-vs-dynamic-code-analysis">https://www.harness.io/blog/static-vs-dynamic-code-analysis</a></li><li><a href="https://blog.skillacademy.com/tugas-dan-skill-quality-assurance">https://blog.skillacademy.com/tugas-dan-skill-quality-assurance</a></li><li><a href="https://www.techtarget.com/searchsoftwarequality/definition/quality-assurance">https://www.techtarget.com/searchsoftwarequality/definition/quality-assurance</a></li><li><a href="https://rikkeisoft.com/blog/importance-of-quality-assurance/">https://rikkeisoft.com/blog/importance-of-quality-assurance/</a></li><li><a href="https://www.canadianctb.ca/blog-and-news/top-5-reasons-why-quality-assurance-is-important">https://www.canadianctb.ca/blog-and-news/top-5-reasons-why-quality-assurance-is-important</a></li><li><a href="https://jatapp.co/blog/the-importance-of-qa/">https://jatapp.co/blog/the-importance-of-qa/</a></li><li><a href="https://www.sonarsource.com/products/sonarcloud/">https://www.sonarsource.com/products/sonarcloud/</a></li><li><a href="https://azuredevopslabs.com/labs/vstsextend/sonarcloud/">https://azuredevopslabs.com/labs/vstsextend/sonarcloud/</a></li><li><a href="https://www.tekcent.com/insights/engineering/how-to-choose-the-right-tool-for-your-code-quality-and-security-sonarcloud-vs-sonarqube/">https://www.tekcent.com/insights/engineering/how-to-choose-the-right-tool-for-your-code-quality-and-security-sonarcloud-vs-sonarqube/</a></li><li><a href="https://docs.sonarsource.com/sonarcloud/">https://docs.sonarsource.com/sonarcloud/</a></li><li><a href="https://www.jetbrains.com/qodana/">https://www.jetbrains.com/qodana/</a></li><li><a href="https://www.jetbrains.com/help/qodana/about-qodana.html">https://www.jetbrains.com/help/qodana/about-qodana.html</a></li><li><a href="https://www.aaronbruce.com/posts/qodana/">https://www.aaronbruce.com/posts/qodana/</a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=812af8f7628e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Time Traveling to Prevent Future Failures: Harnessing Test Driven Development (TDD), Free Bonus…]]></title>
            <link>https://eugeniusmario.medium.com/time-traveling-to-prevent-future-failures-harnessing-test-driven-development-tdd-free-bonus-1785ae5de444?source=rss-974c337fafb0------2</link>
            <guid isPermaLink="false">https://medium.com/p/1785ae5de444</guid>
            <category><![CDATA[sonarcloud]]></category>
            <category><![CDATA[tdd]]></category>
            <category><![CDATA[django]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[testing]]></category>
            <dc:creator><![CDATA[Eugenius Mario]]></dc:creator>
            <pubDate>Wed, 29 May 2024 15:36:47 GMT</pubDate>
            <atom:updated>2024-05-29T15:36:47.983Z</atom:updated>
            <content:encoded><![CDATA[<h3>Time Traveling to Prevent Future Failures: Harnessing Test Driven Development (TDD), Free Bonus Session Using PyTest &amp; Sonarcloud for Django Test</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-3_PxK8KxrAIOqQfg4ZhfA.png" /><figcaption>Time travel to Prevent a Failed Future with TDD by eugeniusmario.</figcaption></figure><p>In the ever-evolving landscape of software development, ensuring the reliability and stability of our applications remains a constant challenge. As developers, we strive not only to deliver functional software but also to safeguard it <strong>against future pitfalls and errors</strong>. In this quest for robustness, Test Driven Development (TDD) emerges as a beacon, offering a proactive approach to software quality assurance.</p><p>Coupled with powerful tools like PyTest and Sonarcloud, TDD equips developers with the ability to foresee and <strong>prevent potential failures before they ever materialize</strong>. Join us on a journey through the realms of TDD as we explore its principles, methodologies, and the invaluable tools that accompany it, particularly within the context of Django development.</p><p>I divide this article into <strong>5 sections</strong> as follows:</p><ul><li><strong>Section 1</strong>: Introduction to Test Driven Development (TDD)</li><li><strong>Section 2:</strong> Getting Started with PyTest</li><li><strong>Section 3:</strong> Harnessing the Power of Sonarcloud</li><li><strong>Section 4:</strong> Practical Application: TDD in Django Development</li><li><strong>Section 5:</strong> Advanced Techniques and Best Practices</li></ul><p>Each section can delve into its respective topic in more detail, providing practical examples, code snippets, and tips to help readers understand and implement TDD, PyTest, and Sonarcloud in their Django projects effectively. Let’s dive!</p><h3>Section 1: Introduction to Test Driven Development (TDD)</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3hrubt9U9iBzdAjBAjJpGw.png" /><figcaption>What is TDD? by eugeniusmario.</figcaption></figure><p>In this introductory section, we embark on a journey to understand the foundational principles and methodologies of Test Driven Development (TDD). TDD is not merely a testing technique but a holistic approach to software development that prioritizes writing tests before writing actual code. By following the TDD cycle of <strong>“red, green, refactor,” </strong>developers can iteratively build and enhance their codebase while ensuring its correctness and reliability.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iW3UA1Hu28uJPuQXkMyHaA.png" /><figcaption>Red, Green, Refactor by eugeniusmario.</figcaption></figure><ol><li><strong>Red:</strong></li></ol><ul><li>In the first phase of the cycle, developers start by writing a test that captures the desired behavior or functionality they want to implement. This test, by design, should fail initially because the corresponding code to fulfill its requirements hasn’t been written yet. The failing test is represented by the “red” state.</li><li>The red phase encourages developers to focus on the specific behavior they intend to implement, rather than getting caught up in writing production code prematurely. It helps in clarifying the requirements and guiding the development process in a testable direction.</li></ul><p><strong>2. Green:</strong></p><ul><li>After writing the failing test, developers proceed to write the minimum amount of code necessary to make the test pass. This code might be crude, inefficient, or incomplete, but its primary purpose is to satisfy the requirements of the test and transition it from a failing state to a passing one.</li><li>The passing test is represented by the “green” state, indicating that the implemented functionality meets the specified criteria outlined in the test. This phase provides immediate feedback on the correctness of the code and ensures that it fulfills the intended functionality.</li></ul><p><strong>3. Refactor:</strong></p><ul><li>Once the test is passing, developers move to the refactor phase. Here, they focus on improving the code’s structure, readability, and efficiency while keeping the tests passing. Refactoring aims to eliminate duplication, improve maintainability, and adhere to coding standards without altering the external behavior of the code.</li><li>The refactor phase is crucial for ensuring that the codebase remains clean, flexible, and easy to maintain as it evolves. By continuously refining the code while keeping the tests passing, developers can achieve a balance between functionality and maintainability.</li></ul><p>We delve into the significance of TDD in modern software engineering, emphasizing its role in <strong>improving code quality, reducing bugs, and fostering better design decisions</strong>. Through TDD, developers are empowered to anticipate potential issues and edge cases early in the development process, thereby saving time and resources in the long run.</p><p>Throughout this section, we explore the fundamental steps of the TDD process, from writing failing tests to gradually evolving them into passing ones. By adopting a <strong>test-first mindset</strong>, developers gain confidence in their codebase and create a <strong>safety net that guards</strong> against regressions and unintended side effects.</p><p>Readers will come away from this section with a clear understanding of why TDD is essential in today’s software development landscape and how it forms the cornerstone of reliable, maintainable codebases.</p><h3>Section 2: Getting Started with PyTest</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xoIFZizvrhy_hS5965yPAg.png" /><figcaption>Pytest by eugeniusmario.</figcaption></figure><p>PyTest is a robust testing framework for Python known for its simplicity and readability. It offers developers an intuitive syntax, allowing them to write clean and concise test code <strong>without the need for complex setup or teardown procedures</strong>. With powerful assertion helpers and support for fixtures, PyTest enables efficient management of test dependencies and initialization of test data.</p><p>Additionally, PyTest’s parameterization feature allows for running the same test with multiple input values, enhancing test coverage and ensuring code reliability. Its extensive plugin ecosystem further extends its capabilities, offering features like test coverage reporting and integration with other tools and frameworks. Overall, PyTest stands out as a <strong>versatile and user-friendly testing solution for Python projects of any size or complexity.</strong></p><h3><strong>(BONUS) Installing and Using PyTest for Basic Testing</strong></h3><p>To install PyTest, follow these steps:</p><ul><li>Open your terminal or command prompt.</li><li>If you haven’t already set up a virtual environment for your project, it’s recommended to do so to isolate your dependencies. You can create a virtual environment using venv or virtualenv.</li><li>Activate your virtual environment.</li><li>Once inside your virtual environment, use pip to install PyTest:</li></ul><pre>pip install pytest</pre><p><strong>Writing Basic Tests:</strong></p><p>Now that PyTest is installed, let’s write some basic tests. PyTest uses a simple syntax that makes writing tests intuitive and concise.</p><ul><li>Create a Python file for your tests. Conventionally, test files are prefixed with test_.</li></ul><pre># test_basic_operations.py<br>def test_addition():<br>    assert 1 + 1 == 2<br>def test_subtraction():<br>    assert 5 - 3 == 2<br>def test_multiplication():<br>    assert 2 * 3 == 6<br>def test_division():<br>    assert 8 / 4 == 2</pre><p>In this example, we’ve written four basic tests to verify addition, subtraction, multiplication, and division operations. Each test is a simple function that uses the assert statement to check if the expected result matches the actual result of the operation.</p><p><strong>Running Tests:</strong></p><p>To run your tests using PyTest, follow these steps:</p><ul><li>Navigate to the directory containing your test file.</li><li>In your terminal or command prompt, simply type pytest followed by the name of your test file:</li></ul><pre>pytest test_basic_operations.py</pre><p>PyTest will automatically discover and run all the test functions in the specified file. You’ll see a summary of the test results displayed in your terminal.</p><p><strong>Interpreting Test Results:</strong></p><p>After running your tests, PyTest provides clear and informative output to help you interpret the results.</p><ul><li>Each dot (.) represents a passing test.</li><li>If a test fails, PyTest will provide a detailed error message indicating which assertion failed and the expected versus actual values.</li><li>At the end of the test run, PyTest will display a summary showing the number of tests passed, failed, and skipped.</li></ul><p>With PyTest, writing and running basic tests for your Python code is straightforward and efficient. Its intuitive syntax and detailed test output make it a valuable tool for ensuring the correctness of your code. As you become more familiar with PyTest, <strong>you can explore its advanced features for more complex testing scenarios on </strong><a href="https://docs.pytest.org/en/latest/how-to/index.html">this documentation</a>.</p><h3>Section 3: Harnessing the Power of Sonarcloud</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rgF6ieSpdqCVtOm2DVp4Xw.png" /><figcaption>Sonarcloud by eugeniusmario.</figcaption></figure><p>In this section, we delve deeper into leveraging PyTest to enhance the effectiveness of our testing practices. We explore key features and techniques that PyTest offers, empowering developers to write robust and comprehensive tests.</p><ol><li><strong>Fixtures: Managing Test Dependencies</strong></li></ol><p>Fixtures are a cornerstone of PyTest, allowing developers to define <strong>reusable setup and teardown logic for tests</strong>. We discuss how fixtures streamline test setup, initialization of test data, and management of test dependencies. By utilizing fixtures effectively, developers can ensure consistent and reliable testing environments across their test suite.</p><p><strong>2. Parameterization: Increasing Test Coverage</strong></p><p>PyTest’s parameterization feature enables running the same test with different input values, thereby increasing test coverage and ensuring code reliability. We demonstrate how parameterized tests can be used to <strong>validate code behavior</strong> under various conditions, improving the thoroughness of test suites and enhancing code quality.</p><p><strong>3. Custom Assertions: Expressive Test Conditions</strong></p><p>We explore PyTest’s support for custom assertions, enabling developers to express test conditions in a clear and concise manner. By creating custom assertion helpers tailored to specific use cases, developers can enhance the <strong>readability and expressiveness</strong> of their test code, leading to more effective testing practices.</p><p><strong>4. Test Organization: Structuring Test Suites</strong></p><p>Effective organization of test suites is <strong>crucial for maintaining scalability and readability as projects grow</strong>. We discuss best practices for structuring test files and organizing test functions, ensuring clarity and maintainability across the test suite. By adopting a systematic approach to test organization, developers can streamline test maintenance and facilitate collaboration within development teams.</p><p><strong>5. Integration with Continuous Integration (CI) Systems</strong></p><p>Lastly, we examine how PyTest seamlessly integrates with Continuous Integration (CI) systems, such as Jenkins, Travis CI, and GitHub Actions. We highlight the importance of incorporating automated testing into the CI pipeline and demonstrate how PyTest can be configured to run tests automatically upon code commits, <strong>providing rapid feedback on code changes and promoting a culture of quality assurance and continuous improvement.</strong></p><p>In this section, we equip developers with the knowledge and tools needed to harness the full potential of PyTest for effective testing practices. By leveraging PyTest’s features and techniques, developers can enhance the reliability, scalability, and maintainability of their test suites, ultimately contributing to the delivery of high-quality software products.</p><h3>Section 4: Practical Application: TDD in Django Development</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*plikvTiGwXOqFhkZ6GOYOA.png" /><figcaption>Case study TDD in Django by eugeniusmario.</figcaption></figure><p>Case Study: Implementing Test-Driven Development (TDD) with PyTest in a Django Project</p><p><strong>Background</strong></p><p>A software development team is tasked with building a web application using the Django framework. The team aims to follow best practices, including Test-Driven Development (TDD), to ensure code quality, reliability, and maintainability throughout the project lifecycle. They decide to use PyTest as their testing framework due to its simplicity, flexibility, and seamless integration with Django.</p><p><strong>Challenge</strong></p><p>The team faces the challenge of implementing TDD effectively within the Django project while adhering to project deadlines and delivering high-quality code. They need to establish a robust testing strategy, write comprehensive test cases, and automate testing processes to streamline development workflows.</p><p><strong>Practice</strong></p><ol><li><strong>Setting Up PyTest</strong></li></ol><p>The team begins by setting up PyTest for their Django project. They install PyTest using pip and configure it to work with Django’s testing framework. They create a dedicated directory for tests within their project structure and organize test files according to Django app components.</p><p><strong>2. Writing Tests for Django Models</strong></p><p>Following the TDD approach, the team writes tests for Django models using PyTest. They create test cases to validate model fields, methods, and business logic.</p><p>Example:</p><pre># tests/test_models.py<br><br>import pytest<br>from myapp.models import MyModel  # Import your Django model here<br><br>@pytest.mark.django_db<br>def test_create_model_instance():<br>    # Test creating a model instance<br>    instance = MyModel.objects.create(name=&quot;Test&quot;, value=42)<br>    assert instance.name == &quot;Test&quot;<br>    assert instance.value == 42<br><br>@pytest.mark.django_db<br>def test_model_methods():<br>    # Test methods of the model<br>    instance = MyModel.objects.create(name=&quot;Test&quot;, value=42)<br>    assert instance.get_name_value() == &quot;Test: 42&quot;<br><br>@pytest.mark.django_db<br>def test_model_validations():<br>    # Test model validations<br>    with pytest.raises(ValueError):<br>        MyModel.objects.create(name=&quot;&quot;, value=42)  # Empty name should raise ValueError<br><br># Add more test cases for other model functionalities as needed</pre><p>By writing tests before implementing model functionality, they ensure that the models meet the project requirements and maintain data integrity.</p><p><strong>3. Testing Views and Forms</strong></p><p>The team proceeds to write tests for Django views and forms using PyTest. They create test cases to verify view rendering, URL routing, form validation, and user input processing.</p><p>Example:</p><pre># tests/test_views.py<br><br>import pytest<br>from django.urls import reverse<br>from myapp.forms import MyForm  # Import your Django form here<br>from myapp.views import MyView  # Import your Django view here<br>from django.test import RequestFactory<br><br>@pytest.fixture<br>def request_factory():<br>    return RequestFactory()<br><br>@pytest.mark.django_db<br>def test_view_rendering(request_factory):<br>    # Test view rendering<br>    request = request_factory.get(reverse(&#39;my-view-url&#39;))  # Replace &#39;my-view-url&#39; with your actual view URL name<br>    response = MyView.as_view()(request)<br>    assert response.status_code == 200<br>    assert &#39;my_template.html&#39; in response.template_name  # Replace &#39;my_template.html&#39; with your actual template name<br><br>@pytest.mark.django_db<br>def test_url_routing():<br>    # Test URL routing<br>    assert reverse(&#39;my-view-url&#39;) == &#39;/my-url/&#39;  # Replace &#39;my-view-url&#39; and &#39;/my-url/&#39; with your actual URL name and path<br><br>@pytest.mark.django_db<br>def test_form_validation():<br>    # Test form validation<br>    form_data = {&#39;name&#39;: &#39;Test&#39;, &#39;value&#39;: 42}  # Replace with valid form data<br>    form = MyForm(data=form_data)<br>    assert form.is_valid() is True<br><br>@pytest.mark.django_db<br>def test_user_input_processing():<br>    # Test user input processing in views<br>    request = request_factory.post(reverse(&#39;my-view-url&#39;), data={&#39;name&#39;: &#39;Test&#39;, &#39;value&#39;: 42})<br>    response = MyView.as_view()(request)<br>    assert response.status_code == 200  # Assuming successful processing<br>    assert &#39;success_message&#39; in response.content.decode()  # Assuming view returns success message</pre><p>By testing views and forms thoroughly, they ensure that the web application functions correctly and provides a seamless user experience.</p><p><strong>4. Automating Testing with CI</strong></p><p>To automate testing processes, the team integrates PyTest-based test suites into their Continuous Integration (CI) pipeline.</p><pre>name: Run Tests<br><br>on:<br>  push:<br>    branches: [ main ]  # Adjust branch name as needed<br>  pull_request:<br>    branches: [ main ]  # Adjust branch name as needed<br><br>jobs:<br>  test:<br>    runs-on: ubuntu-latest<br><br>    services:<br>      postgres:<br>        image: postgres:13<br>        ports: [&quot;5432:5432&quot;]<br>        env:<br>          POSTGRES_USER: postgres<br>          POSTGRES_PASSWORD: postgres<br>          POSTGRES_DB: test_db<br><br>    steps:<br>    - name: Checkout Repository<br>      uses: actions/checkout@v2<br><br>    - name: Set up Python<br>      uses: actions/setup-python@v2<br>      with:<br>        python-version: 3.9<br><br>    - name: Install Dependencies<br>      run: |<br>        python -m pip install --upgrade pip<br>        pip install -r requirements.txt<br><br>    - name: Run PyTest<br>      run: |<br>        python manage.py test</pre><p>We can configure CI platforms like GitHub Actions to run PyTest tests automatically upon code commits. They also generate test coverage reports to track code coverage metrics and identify areas for improvement.</p><p><strong>5. Best Practices and Tips</strong></p><p>Throughout the development process, the team follows best practices and tips for TDD in Django projects. They write testable code, keep test suites fast and focused, and refactor code based on test feedback. They also collaborate closely with stakeholders to ensure that tests reflect user requirements accurately.</p><p><strong>Results</strong></p><p>By implementing TDD with PyTest in their Django project, the development team achieves several key outcomes:</p><ul><li>Improved Code Quality: TDD helps identify and fix bugs early in the development process, resulting in higher code quality and fewer defects.</li><li>Increased Developer Confidence: Comprehensive test coverage and automated testing processes boost developer confidence in the project’s stability and reliability.</li><li>Streamlined Development Workflows: Automation of testing with CI reduces manual effort and accelerates development cycles, allowing the team to deliver features faster.</li><li>Enhanced Maintainability: TDD encourages modular, well-tested code that is easier to maintain and refactor, leading to long-term project maintainability and scalability.</li></ul><p>Overall, the adoption of TDD with PyTest empowers the development team to build a robust and reliable Django application that meets client expectations and user needs while adhering to project timelines and delivering high-quality code.</p><h3>Section 5: Advanced Techniques and Best Practices</h3><p>In this chapter, we delve into advanced techniques and best practices for leveraging PyTest effectively in Django development.</p><ol><li><strong>Parametrized Testing</strong></li></ol><p>Parametrized testing allows you to run the same test logic with different input data. PyTest provides a convenient way to parametrize tests using the @pytest.mark.parametrize decorator. This technique is particularly useful for testing edge cases and ensuring broad test coverage without writing repetitive code.</p><p><strong>2. Mocking and Patching</strong></p><p>Mocking and patching are essential techniques for isolating code under test from its dependencies. PyTest integrates seamlessly with Python’s unittest.mock module, allowing you to replace function calls or objects with mock equivalents during testing. By mocking external services or dependencies, you can control their behavior and focus on testing specific functionalities in isolation.</p><p><strong>3. Fixture Composition and Scope</strong></p><p>PyTest fixtures enable you to set up preconditions, such as database connections or test data, before executing tests. Understanding fixture composition and scope is crucial for managing dependencies and ensuring test isolation. PyTest offers flexible fixture scoping options, including function, module, class, and session scope, allowing you to tailor fixture behavior to your testing needs.</p><p><strong>4. Test Organization and Naming Conventions</strong></p><p>Organizing tests effectively and adhering to naming conventions improve readability and maintainability. PyTest follows a straightforward naming convention where test functions are prefixed with test_. Additionally, grouping related tests into test classes or modules and using descriptive names enhance test discoverability and clarity.</p><p><strong>5. Continuous Integration and Deployment (CI/CD) Integration</strong></p><p>Integrating PyTest-based test suites into CI/CD pipelines automates the testing process and ensures code quality throughout the development lifecycle. CI/CD platforms like GitHub Actions or Travis CI can execute tests automatically upon code commits, providing rapid feedback to developers. Additionally, integrating with coverage tracking services enables monitoring test coverage metrics and identifying areas for improvement.</p><p><strong>6. Performance Testing and Profiling</strong></p><p>PyTest supports performance testing and profiling through plugins and extensions. By measuring the execution time of test cases and profiling code performance, you can identify bottlenecks and optimize critical sections of your application. PyTest plugins like pytest-benchmark facilitate benchmarking and performance analysis, empowering you to build efficient and scalable Django applications.</p><p><strong>7. Documentation and Reporting</strong></p><p>Documenting test cases and generating comprehensive test reports enhance collaboration and transparency within development teams. PyTest offers built-in support for generating detailed test reports in various formats, including HTML, XML, and JSON. By documenting test scenarios, assumptions, and expected outcomes, you facilitate knowledge sharing and ensure the reproducibility of test results.</p><p>By mastering these advanced techniques and best practices, you can harness the full potential of PyTest in Django development, streamline the testing process, and deliver high-quality software with confidence.</p><h3>The End</h3><p>Thank you for embarking on this journey to explore the realm of Test-Driven Development (TDD) and leveraging PyTest and SonarCloud for Django testing. By embracing TDD principles and harnessing the power of PyTest and SonarCloud, we equip ourselves with robust tools to ensure code reliability, maintainability, and scalability.</p><p>As we delve deeper into the intricacies of software testing and quality assurance, let us remain steadfast in our commitment to <strong>continuous improvement and excellence in software development practices.</strong> By adhering to TDD methodologies and incorporating advanced testing techniques into our Django projects, we pave the way for resilient, high-quality software solutions.</p><p>Thank you for joining me on this enlightening expedition, and may your coding endeavors be filled with success and fulfillment!</p><p>If you’re interested in connecting further with me, please visit my LinkedIn profile <a href="https://www.linkedin.com/in/eugenius-mario-s/"><strong>Eugenius Mario’s LinkedIn</strong></a><strong>.</strong></p><p>Happy coding!</p><h3>References:</h3><ol><li><a href="https://martinfowler.com/bliki/TestDrivenDevelopment.html">https://martinfowler.com/bliki/TestDrivenDevelopment.html</a></li><li><a href="https://www.browserstack.com/guide/what-is-test-driven-development">https://www.browserstack.com/guide/what-is-test-driven-development</a></li><li><a href="https://startupstudio.id/manfaat-test-driven-development-bagi-perusahaan/">https://startupstudio.id/manfaat-test-driven-development-bagi-perusahaan/</a></li><li><a href="https://docs.pytest.org/en/8.2.x/">https://docs.pytest.org/en/8.2.x/</a></li><li><a href="https://docs.pytest.org/en/latest/how-to/index.html">https://docs.pytest.org/en/latest/how-to/index.html</a></li><li><a href="https://realpython.com/pytest-python-testing/">https://realpython.com/pytest-python-testing/</a></li><li><a href="https://www.sonarsource.com/products/sonarcloud/">https://www.sonarsource.com/products/sonarcloud/</a></li><li><a href="https://docs.sonarsource.com/sonarcloud/">https://docs.sonarsource.com/sonarcloud/</a></li><li><a href="https://azuredevopslabs.com/labs/vstsextend/sonarcloud/">https://azuredevopslabs.com/labs/vstsextend/sonarcloud/</a></li><li><a href="https://docs.sonarsource.com/sonarcloud/enriching/test-coverage/python-test-coverage/">https://docs.sonarsource.com/sonarcloud/enriching/test-coverage/python-test-coverage/</a></li><li><a href="https://www.freecodecamp.org/news/how-to-measure-django-code-quality-using-sonarqube-pytest-and-coverage/">https://www.freecodecamp.org/news/how-to-measure-django-code-quality-using-sonarqube-pytest-and-coverage/</a></li><li><a href="https://dev.to/pacheco/tdd-in-practice-tips-and-best-practices-for-success-2akl">https://dev.to/pacheco/tdd-in-practice-tips-and-best-practices-for-success-2akl</a></li><li><a href="https://dev.to/marciofrayze/how-i-started-practicing-tdd-aj5">https://dev.to/marciofrayze/how-i-started-practicing-tdd-aj5</a></li><li><a href="https://developnsolve.com/best-practices-for-test-driven-development">https://developnsolve.com/best-practices-for-test-driven-development</a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1785ae5de444" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Migrate Monolithic to Microservices: Separation of Concerns (SoC) and Keep It Simple, Stupid (KISS)…]]></title>
            <link>https://eugeniusmario.medium.com/migrate-monolithic-to-microservices-separation-of-concerns-soc-and-keep-it-simple-stupid-kiss-da16e730ebef?source=rss-974c337fafb0------2</link>
            <guid isPermaLink="false">https://medium.com/p/da16e730ebef</guid>
            <category><![CDATA[microservices]]></category>
            <category><![CDATA[engineering]]></category>
            <category><![CDATA[refactoring]]></category>
            <category><![CDATA[monolith]]></category>
            <category><![CDATA[software-development]]></category>
            <dc:creator><![CDATA[Eugenius Mario]]></dc:creator>
            <pubDate>Wed, 13 Mar 2024 04:19:47 GMT</pubDate>
            <atom:updated>2024-03-14T02:16:29.737Z</atom:updated>
            <content:encoded><![CDATA[<h3>Migrate Monolithic to Microservices: Separation of Concerns (SoC) and Keep It Simple, Stupid (KISS) for Maintainable and Continuous Development</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*duXtyp2ZnGjmeqOqZfWjwg.png" /><figcaption>Migrate monolithic to microservices by eugeniusmario.</figcaption></figure><p>In today’s rapidly evolving technological landscape, businesses are constantly seeking ways to adapt and innovate to stay competitive. One prevalent trend in software architecture is the migration from monolithic to microservices-based systems. This shift offers numerous benefits, including <strong>increased scalability, flexibility, and agility</strong>.</p><p>However, transitioning from a monolithic architecture to microservices is not without its challenges. In this article, we’ll explore the principles of <strong>Separation of Concerns (SoC) </strong>and <strong>Keep It Simple, Stupid</strong> <strong>(KISS)</strong> as essential guiding philosophies for ensuring a smooth and successful migration process. By adhering to these principles, organizations can achieve maintainable and continuous development practices while harnessing the power of microservices architecture.</p><p>I divide this article into <strong>4 sections</strong> as follows:</p><ul><li><strong>Section 1</strong>: Separation of Concerns (SoC)</li><li><strong>Section 2:</strong> Keep It Simple, Stupid (KISS)</li><li><strong>Section 3:</strong> Migrate Monolithic to Microservices App</li><li><strong>Section 4:</strong> Conclusion</li></ul><p>In each section, I include a <strong>definition, benefits, case study and summary</strong> section. Let’s dive!</p><h3>Section 1: Separation of Concerns (SoC)</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0_s5Tg2CqpFQEaigWpoSWg.png" /><figcaption>Separation of concerns by eugeniusmario.</figcaption></figure><h4><strong>Definition:</strong></h4><blockquote>In computer science, separation of concerns is a design principle for separating a computer program into distinct sections. Each section addresses a separate concern, a set of information that affects the code of a computer program. A program that embodies SoC well is called a <strong>modular program</strong>. (Wikipedia)</blockquote><h4><strong>Benefits:</strong></h4><p>The benefits of Separation of Concerns (SoC) in microservices migration are manifold and crucial for the successful transition from monolithic to microservices architecture:</p><ul><li><strong>Modularity and Scalability</strong></li></ul><p>SoC enables the decomposition of the monolithic codebase into smaller, independent modules, each addressing a specific concern. This modularity facilitates the <strong>scalability of the system</strong> as individual microservices can be <strong>scaled independently</strong> based on demand, leading to better resource utilization and improved performance.</p><ul><li><strong>Improved Maintainability</strong></li></ul><p>By isolating concerns and reducing dependencies between modules, SoC enhances the maintainability of the codebase. Developers can make changes to specific microservices <strong>without impacting other parts</strong> of the system, making it <strong>easier to debug, test, and update</strong> the application over time.</p><ul><li><strong>Enhanced Flexibility and Agility</strong></li></ul><p>Microservices built on SoC principles offer greater flexibility and agility in development. Teams can iterate on individual services independently, allowing for <strong>faster deployment</strong> of new features and updates. This agility enables organizations to respond quickly to changing market demands and customer requirements.</p><ul><li><strong>Easier Deployment and Continuous Integration</strong></li></ul><p>SoC simplifies the deployment process by breaking down the application into smaller, manageable components. Microservices can be <strong>deployed independently</strong>, reducing the risk of downtime and streamlining the release process. Additionally, SoC facilitates continuous integration and delivery practices, enabling automated testing and deployment of changes to production.</p><ul><li><strong>Isolation of Failures</strong></li></ul><p>In a microservices architecture with SoC, failures in one service are isolated from others, minimizing the impact on the overall system. This fault isolation improves system resilience and availability, ensuring that a <strong>failure in one microservice does not bring down the entire application</strong>.</p><h4>Case Study: “Separation of Concerns (SoC) in Nani Dashboard”</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hyzo5THTbcng8ebj1ILj8A.png" /><figcaption>Dashboard Nani application SoC.</figcaption></figure><p><strong>SoC for Nani Dashboard:</strong></p><p>In the development of a dashboard feature, employing Separation of Concerns (SoC) principles is paramount to ensuring a modular and maintainable architecture. Let’s examine a hypothetical case study to illustrate the benefits of SoC in the development of three distinct components within a dashboard feature: <strong>Weather, Trivia, and Plant.</strong></p><ul><li><strong>Weather App</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XN_cv4ESE-AGMOdf0sCK4g.png" /><figcaption>Weather app on nani project.</figcaption></figure><p>The Weather app focuses solely on fetching and displaying weather information relevant to the user’s location. It communicates with external APIs or services dedicated to weather data retrieval. By isolating weather-related concerns within this component, such as API integration and data presentation, it becomes easier to modify or replace weather-related functionality <strong>without affecting other parts</strong> of the dashboard.</p><ul><li><strong>Trivia App</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HXPv4MpXa25m__42Xa4Psg.png" /><figcaption>Trivia app on nani project.</figcaption></figure><p>The Trivia app is responsible for fetching and presenting trivia cards to engage users. It communicates with trivia databases or services to retrieve trivia informations. Through the application of SoC, the Trivia component <strong>remains independent of other</strong> dashboard features, allowing developers to update or expand trivia functionality without impacting the Weather or Plant components.</p><ul><li><strong>Plant App</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SppjXP6nOYccUy2Fn9UB3Q.png" /><figcaption>Plant app for nani project.</figcaption></figure><p>The Plant app provides recommendations for plants suitable for the user’s location and displays current plant prices. It interacts with plant databases or APIs to gather information on plant species and pricing data. By separating plant-related concerns into this component, such as data retrieval and presentation, developers can enhance or customize plant-related functionality <strong>without affecting the Weather or Trivia</strong> components.</p><h4>Summary:</h4><p>In the development of our dashboard feature encompassing weather, plant, and trivia functionalities, applying Separation of Concerns (SoC) principles yields numerous benefits tailored to each component’s specific requirements.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1006/1*5b1qZLhAntGf7V-ZMQCzWg.png" /><figcaption>Directory structure for plant, trivia, weather app.</figcaption></figure><p>In the Weather app, SoC allows for a focused approach to retrieving and presenting weather information. By isolating weather-related concerns within this component, such as data fetching from external APIs and rendering weather forecasts, we ensure <strong>modularity and ease of maintenance</strong>. This modular design enables swift updates to weather functionality <strong>without disrupting</strong> the functionalities of the plant recommendation or trivia sections.</p><pre># app/weather/models.py<br><br>from django.db import models<br><br># Empty because it uses an external API; the weather app simply transforms the API.</pre><p>In the Plant app, SoC facilitates the independent management of plant-related data retrieval and presentation. By separating concerns related to plant recommendations and pricing information, we ensure that modifications or enhancements to plant-related features can be implemented seamlessly. This modular architecture promotes scalability and flexibility, allowing for the integration of new plant-related functionalities in the future.</p><pre># app/plant/models.py<br><br>from django.db import models<br>from app.plant.constants import (<br>    SEASON_TYPE_CHOICES,<br>    JUNGHUHN_TYPE_CHOICES<br>)<br><br>class Plant(models.Model):<br>    name = models.CharField(max_length=255)<br>    description = models.CharField(max_length=255)<br>    harvest_duration = models.IntegerField()<br>    photo_url = models.URLField()<br>    season_type = models.CharField(max_length=255, choices=SEASON_TYPE_CHOICES)<br>    junghuhn_type = models.CharField(max_length=255, choices=JUNGHUHN_TYPE_CHOICES)<br><br>    def __str__(self):<br>        return self.name<br><br>class PlantPrice(models.Model):<br>    plant = models.OneToOneField(Plant, on_delete=models.CASCADE, related_name=&#39;plant_price&#39;)<br>    price_now = models.DecimalField(max_digits=20, decimal_places=2, null=True, blank=True) <br>    price_prediction = models.DecimalField(max_digits=20, decimal_places=2, null=True, blank=True)<br>    per_date = models.DateTimeField(null=True, blank=True)<br><br>    def __str__(self):<br>        return f&quot;Plant Price for {self.plant.name}&quot; <br><br>class PlantPeriod(models.Model):<br>    plant = models.OneToOneField(Plant, on_delete=models.CASCADE, related_name=&#39;plant_period&#39;)<br>    planting_soil_preparation = models.CharField(max_length=255, default=&quot;&quot;)<br>    planting_seeding = models.CharField(max_length=255, default=&quot;&quot;)<br>    planting_fertilization = models.CharField(max_length=255, default=&quot;&quot;)<br>    planting_sprinkling = models.CharField(max_length=255, default=&quot;&quot;)<br>    planting_pest_spraying = models.CharField(max_length=255, default=&quot;&quot;)<br><br>    def __str__(self):<br>        return f&quot;Plant Period for {self.plant.name}&quot;<br><br>class PlantDetail(models.Model):<br>    plant = models.ForeignKey(Plant, on_delete=models.CASCADE, related_name=&#39;plant_details&#39;)<br>    name = models.CharField(max_length=255, default=&quot;&quot;)<br>    title = models.CharField(max_length=255, default=&quot;&quot;)<br>    description = models.TextField(default=&quot;&quot;)<br>    content = models.TextField(default=&quot;&quot;)<br><br>    def __str__(self):<br>        return f&quot;{self.title} - {self.plant.name}&quot;</pre><p>In the Trivia app, SoC enables us to focus on delivering engaging trivia content to users without entangling it with other dashboard features. By compartmentalizing trivia-related concerns, such as fetching trivia questions from databases and displaying them in an interactive format, we enhance maintainability and code readability. This isolated approach allows for rapid iterations and updates to trivia functionality, enriching the user experience without impacting weather or plant functionalities.</p><pre># app/trivia/models.py<br><br>from django.db import models<br>from app.trivia.constants import TRIVIA_TYPE_CHOICES<br><br>class Trivia(models.Model):<br>    title = models.CharField(max_length=255)<br>    description = models.CharField(max_length=255)<br>    type = models.CharField(max_length=20, choices=TRIVIA_TYPE_CHOICES)<br>    photo_url = models.URLField()<br>    <br>    def __str__(self):<br>        return self.title</pre><p>By embracing SoC principles in our dashboard development, we foster a modular, scalable, and maintainable architecture tailored to the specific needs of each feature. This approach promotes agility and innovation, enabling us to deliver a comprehensive dashboard experience that seamlessly integrates weather forecasts, plant recommendations, and interactive trivia content for our users.</p><h3>Section 2: Keep It Simple, Stupid (KISS)</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TFtuYvyuxRvBp-4ekEQJUQ.png" /><figcaption>Keep it simple, stupid by eugeniusmario.</figcaption></figure><h4><strong>Definition:</strong></h4><blockquote>KISS, an acronym for “Keep it simple, stupid!”, is a design principle first noted by the U.S. Navy in 1960. First seen partly in American English by at least 1938, the KISS principle states that most systems work best if they are kept simple rather than made complicated; therefore, simplicity should be a key goal in design, and unnecessary complexity should be avoided. (Wikipedia)</blockquote><h4><strong>Benefits:</strong></h4><p>Keep It Simple, Stupid (KISS) is a principle that complements Separation of Concerns (SoC) and offers additional <strong>advantages in microservices migration</strong>:</p><ul><li><strong>Simplicity in Design</strong></li></ul><p>KISS advocates for simplicity in design, encouraging developers to favor <strong>straightforward solutions</strong> over complex ones. By adhering to this principle, microservices can be designed with clear, concise architectures, making them <strong>easier to understand and maintain</strong>.</p><ul><li><strong>Reduced Complexity</strong></li></ul><p>Simplifying the design reduces the overall complexity of the microservices ecosystem. With fewer moving parts and <strong>less intricate interactions between components</strong>, developers can <strong>minimize the risk of errors</strong> and <strong>improve overall system reliability</strong>.</p><ul><li><strong>Ease of Onboarding</strong></li></ul><p>KISS promotes straightforward and intuitive designs, which <strong>facilitates the onboarding process for new team members</strong>. Developers can quickly grasp the architecture and functionality of microservices, <strong>accelerating their productivity</strong> and integration into the development team.</p><ul><li><strong>Faster Development Cycles</strong></li></ul><p>By keeping designs simple and <strong>avoiding unnecessary complexities</strong>, developers can streamline the development process. This allows for <strong>faster iteration</strong> and deployment of new features, enhancing the agility and responsiveness of the development team.</p><ul><li><strong>Lower Maintenance Overhead</strong></li></ul><p>Simple designs require <strong>less maintenance overhead</strong> compared to complex architectures. With fewer dependencies and less intricate logic, developers can more <strong>easily troubleshoot issues</strong>, perform updates, and implement changes without introducing unintended side effects.</p><h4>Case Study: “Keep It Simple, Stupid (KISS) in Nani Project”</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/961/1*d_mhLWXD1h1zCJSX0LCf2w.png" /><figcaption>Root directory betelgeuse as backend server of Nani.</figcaption></figure><p>The display above shows the list of folders at the root level of the project. Each application is stored within the “app” folder, making it easier for developers during the migration from monolithic to microservices architecture. Simply put, every folder/file outside of the “app” directory belongs to the global scope and must be implemented across all microservices in the future. However, the contents within the “app” directory depend on the respective application.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/946/1*Ayqgt8DFFPf6caWWPHC6wg.png" /><figcaption>App folder on Nani project.</figcaption></figure><p>Each functionality is grouped into its respective folder according to the app, making it easier for developers to perform coding and migration to microservices later on.</p><pre>app/<br>│<br>├── [app_name]/<br>│   ├── __init__.py<br>│   ├── admin.py<br>│   ├── apps.py<br>│   └── constants.py<br>│   └── models.py<br>│   └── serializers.py<br>│   └── urls.py<br>│   └── views.py</pre><p>In each app, files are also organized to have similar patterns with other apps. Functionality is consolidated in just one folder. Moving the folder into a new project is akin to creating a microservice for that app.</p><pre># app/plant/admin.py<br><br>from django.contrib import admin<br>from app.plant.models import Plant, PlantPrice, PlantPeriod, PlantDetail<br><br>class PlantAdmin(admin.ModelAdmin):<br>    list_display = [&#39;id&#39;, &#39;name&#39;, &#39;season_type&#39;, &#39;junghuhn_type&#39;, &#39;harvest_duration&#39;, &#39;photo_url&#39;]<br>    search_fields = [&#39;name&#39;]<br>    list_filter = [&#39;season_type&#39;, &#39;junghuhn_type&#39;]<br>    readonly_fields = [&#39;id&#39;]<br><br>class PlantPriceAdmin(admin.ModelAdmin):<br>    list_display = [&#39;id&#39;, &#39;plant&#39;, &#39;price_now&#39;, &#39;price_prediction&#39;, &#39;per_date&#39;]<br>    list_filter = [&#39;per_date&#39;]<br>    readonly_fields = [&#39;id&#39;]<br><br>class PlantPeriodAdmin(admin.ModelAdmin):<br>    list_display = [&#39;id&#39;, &#39;plant&#39;, &#39;planting_soil_preparation&#39;, &#39;planting_seeding&#39;, &#39;planting_fertilization&#39;, &#39;planting_sprinkling&#39;, &#39;planting_pest_spraying&#39;]<br>    readonly_fields = [&#39;id&#39;]<br><br>class PlantDetailAdmin(admin.ModelAdmin):<br>    list_display = [&#39;id&#39;, &#39;plant&#39;, &#39;name&#39;, &#39;title&#39;, &#39;description&#39;, &#39;content&#39;]<br>    readonly_fields = [&#39;id&#39;]<br><br>admin.site.register(Plant, PlantAdmin)<br>admin.site.register(PlantPrice, PlantPriceAdmin)<br>admin.site.register(PlantPeriod, PlantPeriodAdmin)<br>admin.site.register(PlantDetail, PlantDetailAdmin)py</pre><p>This code adheres to the KISS (Keep It Simple, Stupid) principle by maintaining simplicity and clarity in its structure and implementation. Each admin class corresponds to a model and specifies the display fields, search fields, filters, and readonly fields, keeping the code concise and focused. By organizing functionalities into separate admin classes, it promotes maintainability and ease of understanding. This approach ensures that the codebase remains straightforward and comprehensible, facilitating future modifications or enhancements.</p><pre># app/plant/apps.py<br><br>from django.apps import AppConfig<br><br>class PlantConfig(AppConfig):<br>    default_auto_field = &quot;django.db.models.BigAutoField&quot;<br>    name = &quot;app.plant&quot;</pre><p>This code adheres to the KISS (Keep It Simple, Stupid) principle by providing a straightforward configuration for the `Plant` app. It simply defines the `PlantConfig` class, specifying the default auto field and the name of the app. By keeping the configuration concise and focused, it maintains simplicity and clarity, making it easy to understand and manage. This approach ensures that the configuration remains uncomplicated and does not introduce unnecessary complexity, aligning with the KISS principle.</p><pre># app/plant/constants.py<br><br>SEASON_TYPE_CHOICES = [<br>    (&#39;DRY&#39;, &#39;DRY&#39;),<br>    (&#39;RAINY&#39;, &#39;RAINY&#39;)<br>]<br><br>JUNGHUHN_TYPE_CHOICES = [<br>    (&#39;DINGIN&#39;, &#39;DINGIN&#39;),<br>    (&#39;SEJUK&#39;, &#39;SEJUK&#39;),<br>    (&#39;SEDANG&#39;, &#39;SEDANG&#39;),<br>    (&#39;PANAS&#39;, &#39;PANAS&#39;)<br>]</pre><p>This code adheres to the KISS (Keep It Simple, Stupid) principle by providing straightforward constant choices for `SEASON_TYPE_CHOICES` and `JUNGHUHN_TYPE_CHOICES`. Each choice is represented by a tuple with a value and a human-readable label, ensuring clarity and simplicity in usage. By avoiding unnecessary complexity or abstraction, it maintains a clear and concise representation of the available options, aligning well with the KISS principle.</p><pre># app/plant/models.py<br><br>from django.db import models<br>from app.plant.constants import (<br>    SEASON_TYPE_CHOICES,<br>    JUNGHUHN_TYPE_CHOICES<br>)<br><br>class Plant(models.Model):<br>    name = models.CharField(max_length=255)<br>    description = models.CharField(max_length=255)<br>    harvest_duration = models.IntegerField()<br>    photo_url = models.URLField()<br>    season_type = models.CharField(max_length=255, choices=SEASON_TYPE_CHOICES)<br>    junghuhn_type = models.CharField(max_length=255, choices=JUNGHUHN_TYPE_CHOICES)<br><br>    def __str__(self):<br>        return self.name<br><br>class PlantPrice(models.Model):<br>    plant = models.OneToOneField(Plant, on_delete=models.CASCADE, related_name=&#39;plant_price&#39;)<br>    price_now = models.DecimalField(max_digits=20, decimal_places=2, null=True, blank=True) <br>    price_prediction = models.DecimalField(max_digits=20, decimal_places=2, null=True, blank=True)<br>    per_date = models.DateTimeField(null=True, blank=True)<br><br>    def __str__(self):<br>        return f&quot;Plant Price for {self.plant.name}&quot; <br><br>class PlantPeriod(models.Model):<br>    plant = models.OneToOneField(Plant, on_delete=models.CASCADE, related_name=&#39;plant_period&#39;)<br>    planting_soil_preparation = models.CharField(max_length=255, default=&quot;&quot;)<br>    planting_seeding = models.CharField(max_length=255, default=&quot;&quot;)<br>    planting_fertilization = models.CharField(max_length=255, default=&quot;&quot;)<br>    planting_sprinkling = models.CharField(max_length=255, default=&quot;&quot;)<br>    planting_pest_spraying = models.CharField(max_length=255, default=&quot;&quot;)<br><br>    def __str__(self):<br>        return f&quot;Plant Period for {self.plant.name}&quot;<br><br>class PlantDetail(models.Model):<br>    plant = models.ForeignKey(Plant, on_delete=models.CASCADE, related_name=&#39;plant_details&#39;)<br>    name = models.CharField(max_length=255, default=&quot;&quot;)<br>    title = models.CharField(max_length=255, default=&quot;&quot;)<br>    description = models.TextField(default=&quot;&quot;)<br>    content = models.TextField(default=&quot;&quot;)<br><br>    def __str__(self):<br>        return f&quot;{self.title} - {self.plant.name}&quot;</pre><p>This code adheres to the KISS (Keep It Simple, Stupid) principle by providing clear and concise models for the `Plant` app. Each model represents a distinct entity with its relevant fields, ensuring simplicity and readability. By avoiding unnecessary complexity and keeping the structure straightforward, it facilitates ease of understanding and maintenance. Additionally, the integration of constant choices from `constants.py` enhances clarity and reusability. Overall, this codebase adheres well to the KISS principle by maintaining simplicity without sacrificing functionality.</p><pre># app/plant/serializers.py<br><br>from rest_framework import serializers<br>from app.plant.models import Plant, PlantPeriod, PlantDetail, PlantPrice<br><br>class PlantSerializer(serializers.ModelSerializer):<br>    class Meta:<br>        model = Plant<br>        fields = &#39;__all__&#39;<br><br>class PlantPeriodSerializer(serializers.ModelSerializer):<br>    class Meta:<br>        model = PlantPeriod<br>        fields = &#39;__all__&#39;<br>    <br>class PlantDetailSerializer(serializers.ModelSerializer):<br>    class Meta:<br>        model = PlantDetail<br>        fields = &#39;__all__&#39;<br><br>class PlantPriceSerializer(serializers.ModelSerializer):<br>    class Meta:<br>        model = PlantPrice<br>        fields = &#39;__all__&#39;</pre><p>This code adheres to the KISS (Keep It Simple, Stupid) principle by providing straightforward serializers for the `Plant` app models. Each serializer class maps directly to its corresponding model, utilizing the `ModelSerializer` provided by Django REST Framework. By specifying `fields = ‘__all__’`, it includes all fields from the respective models, simplifying the serialization process. This approach maintains simplicity and clarity, making it easy to understand and manage serializers for API interactions. Overall, the codebase follows a clear and concise pattern, aligning well with the KISS principle.</p><pre># app/plant/urls.py<br><br>from django.urls import path<br>from app.plant.views import (<br>    PlantDetailAPIView,<br>)<br><br>urlpatterns = [<br>    path(&#39;&lt;int:plant_id&gt;/&#39;, PlantDetailAPIView.as_view(), name=&#39;path_plant_detail_api_view&#39;),<br>]</pre><p>This code adheres to the KISS (Keep It Simple, Stupid) principle by providing a straightforward URL configuration for the `Plant` app. It defines a single URL pattern that routes requests with a plant ID to the `PlantDetailAPIView`, keeping the URL configuration concise and focused. By using intuitive naming conventions and avoiding unnecessary complexity, it promotes readability and maintainability. This approach ensures that the URL routing remains clear and easy to follow, aligning well with the KISS principle.</p><pre># app/plant/views.py<br><br>from rest_framework.views import APIView<br>from rest_framework_simplejwt.authentication import JWTAuthentication<br>from rest_framework.permissions import IsAuthenticated<br>from rest_framework import status<br>from config.response import SuccessResponse, FailedResponse<br>from app.plant.models import Plant, PlantDetail, PlantPrice<br>from rest_framework.response import Response<br>from app.plant.models import (<br>    Plant,<br>    PlantPeriod,<br>    PlantDetail,<br>    PlantPrice<br>)<br>from app.plant.serializers import (<br>    PlantSerializer, <br>    PlantPeriodSerializer, <br>    PlantDetailSerializer, <br>    PlantPriceSerializer,<br>)<br><br>class PlantDetailAPIView(APIView):<br>    authentication_classes = [JWTAuthentication]<br>    permission_classes = [IsAuthenticated]<br>    <br>    def get(self, request, plant_id):<br>        try:<br>            plant = Plant.objects.get(id=plant_id)<br>            plant_period = PlantPeriod.objects.get(plant_id=plant_id)<br>            plant_detail = PlantDetail.objects.filter(plant_id=plant_id)<br>            plant_price = PlantPrice.objects.get(plant_id=plant_id)<br><br>            plant_serializer = PlantSerializer(plant)<br>            plant_period_serializer = PlantPeriodSerializer(plant_period)<br>            plant_detail_serializer = PlantDetailSerializer(plant_detail, many=True)<br>            plant_price_serializer = PlantPriceSerializer(plant_price)<br><br>            return SuccessResponse(&#39;berhasil mendapatkan data tanaman&#39;, {<br>                &#39;plant&#39;: plant_serializer.data,<br>                &#39;plant_period&#39;: plant_period_serializer.data,<br>                &#39;plant_detail&#39;: plant_detail_serializer.data,<br>                &#39;plant_price&#39;: plant_price_serializer.data<br>            })<br>        except PlantDetail.DoesNotExist:<br>            return Response(status=status.HTTP_404_NOT_FOUND)</pre><p>This code partially adheres to the KISS (Keep It Simple, Stupid) principle by encapsulating the logic for retrieving plant-related data within the `PlantDetailAPIView`. It utilizes serializers to transform model instances into JSON representations and returns a successful response containing the data if found. However, it could further improve simplicity by avoiding redundant imports and optimizing queries to reduce complexity. Refactoring redundant code and optimizing database queries would enhance readability and maintainability, fully aligning with the KISS principle.</p><h4>Summary:</h4><p>The Keep It Simple, Stupid (KISS) principle <strong>emphasizes simplicity and clarity </strong>in software design and development. In the case study provided, the development of a Django-based application for managing plant-related data demonstrates various aspects of adhering to the KISS principle.</p><ul><li><strong>Code Organization</strong></li></ul><p>The project organizes its codebase into logical components, such as models, serializers, views, and URLs, each serving a distinct purpose. This modular organization promotes clarity and <strong>ease of maintenance</strong>, aligning with the KISS principle.</p><ul><li><strong>Model Definition</strong></li></ul><p>The models defined for plants, plant periods, plant details, and plant prices <strong>exhibit simplicity by encapsulating</strong> relevant fields and relationships. By avoiding unnecessary complexity, these models remain comprehensible and easy to manage.</p><ul><li><strong>Constants Management</strong></li></ul><p>Constants for season types and junghuhn types are defined in a separate file, enhancing <strong>readability and reusability</strong>. This approach follows the KISS principle by providing straightforward representations of constant choices.</p><ul><li><strong>Serializer Implementation</strong></li></ul><p>Serializer classes are created for each model, utilizing Django REST Framework’s `ModelSerializer` for simplicity. By specifying all fields and directly mapping them to models, these serializers adhere to the KISS principle by keeping serialization logic <strong>concise and focused</strong>.</p><ul><li><strong>View Logic</strong></li></ul><p>The `PlantDetailAPIView` encapsulates the logic for retrieving plant-related data, but there’s room for improvement. While it successfully retrieves and serializes data, it could benefit from refactoring to eliminate redundant imports and optimize database queries further.</p><ul><li><strong>URL Configuration</strong></li></ul><p>The URL configuration remains simple, with only one URL pattern defined for accessing plant details. This straightforward routing promotes <strong>clarity and maintainability</strong>, aligning well with the KISS principle.</p><p>Overall, while the project demonstrates adherence to the KISS principle in many aspects, there are opportunities for further simplification and optimization, particularly in the view logic. By continuously striving for simplicity and clarity in design and implementation, developers can ensure that their codebases remain <strong>manageable, scalable, and easy to understand</strong>.</p><h3>Section 3: Migrate Monolithic to Microservices App</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*duXtyp2ZnGjmeqOqZfWjwg.png" /><figcaption>Migrate monolithic to microservices by eugeniusmario.</figcaption></figure><h4><strong>Definition of Monolithic:</strong></h4><blockquote>In <a href="https://en.wikipedia.org/wiki/Application_software">application software</a>, software is called “monolithic” if it has a <strong>monolithic architecture</strong>, in which functionally distinguishable aspects (for example data input and output, data processing, error handling, and the user interface) are all interwoven, rather than containing architecturally separate components. (Wikipedia)</blockquote><h4>Definition of Microservices:</h4><blockquote>In <a href="https://en.wikipedia.org/wiki/Software_engineering">software engineering</a>, a <strong>microservice</strong> architecture is a variant of the <a href="https://en.wikipedia.org/wiki/Service-oriented_architecture">service-oriented architecture</a> structural style. It is an <a href="https://en.wikipedia.org/wiki/Architectural_pattern">architectural pattern</a> that arranges an application as a collection of <a href="https://en.wikipedia.org/wiki/Loose_coupling">loosely coupled</a>, <a href="https://en.wikipedia.org/wiki/Granularity">fine-grained</a> services, communicating through <a href="https://en.wikipedia.org/wiki/Lightweight_protocol">lightweight protocols</a>. One of its goals is that teams can develop and <a href="https://en.wikipedia.org/wiki/Software_deployment">deploy</a> their services independently of others. (Wikipedia)</blockquote><h4><strong>Benefits:</strong></h4><p>Here are some benefits that can be obtained from migrating from monolithic architecture to microservices:</p><ol><li><strong>Scalability: </strong>Microservices enable individual components of the application to be scaled independently, allowing better resource utilization and accommodating varying loads more efficiently.</li><li><strong>Agility:</strong> Microservices promote faster development cycles and deployment times as teams can work on smaller, more focused services, enabling quicker iterations and updates.</li><li><strong>Fault Isolation:</strong> In a microservices architecture, failures in one service are isolated and do not affect the entire application, enhancing resilience and minimizing downtime.</li><li><strong>Technology Heterogeneity:</strong> Microservices allow teams to choose the most appropriate tools and technologies for each service, enabling flexibility and innovation in technology stack selection.</li><li><strong>Resilience: </strong>Microservices can be designed to handle failures gracefully, ensuring that the application remains operational even in the face of partial failures or disruptions.</li><li><strong>Scalability:</strong> Microservices enable horizontal scaling of specific services, allowing resources to be allocated where they are most needed without affecting the entire application.</li><li><strong>Improved Development Speed:</strong> With smaller, more focused services, development teams can work in parallel on different parts of the application, leading to faster development cycles and quicker time-to-market.</li><li><strong>Ease of Maintenance: </strong>Microservices promote modularity and encapsulation, making it easier to understand, update, and maintain individual components of the application.</li><li><strong>Better Resource Utilization:</strong> Microservices allow for efficient resource allocation as services can be deployed and scaled independently based on their specific resource requirements.</li><li><strong>Enhanced Flexibility:</strong> Microservices architecture enables easier experimentation and innovation, allowing teams to introduce new features or technologies without disrupting the entire application.</li></ol><h4>Case Study: “Migrating Monolithic to Microservices for Nani App”</h4><p>Given a project structure as shown in the diagram below, where there are 3 apps within it, namely weather, plant, and trivia. Note that this folder is part of the same project, so deployment will also be on the same virtual machine server.</p><pre># Server Nani<br><br>app/<br>│<br>├── weather /<br>│   ├── __init__.py<br>│   ├── admin.py<br>│   ├── apps.py<br>│   └── constants.py<br>│   └── models.py<br>│   └── serializers.py<br>│   └── urls.py<br>│   └── views.py<br>│<br>├── plant /<br>│   ├── __init__.py<br>│   ├── admin.py<br>│   ├── apps.py<br>│   └── constants.py<br>│   └── models.py<br>│   └── serializers.py<br>│   └── urls.py<br>│   └── views.py<br>│<br>├── trivia /<br>│   ├── __init__.py<br>│   ├── admin.py<br>│   ├── apps.py<br>│   └── constants.py<br>│   └── models.py<br>│   └── serializers.py<br>│   └── urls.py<br>│   └── views.py</pre><p>The more applications there are, the larger the dependencies that need to be fulfilled. Therefore, we can separate each app by utilizing the principle of separation of concern into several separate servers. The result will be like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0_s5Tg2CqpFQEaigWpoSWg.png" /><figcaption>Separation of concerns by eugeniusmario.</figcaption></figure><p>The folder structure provided above represents the whole application containing multiple apps. We will refactor and move each folder into a new project so that each app can be deployed as a separate server with its own functionality.</p><ul><li><strong>Weather Server</strong></li></ul><p>The weather server will be created as a new repository, serving as a service that processes weather data from an external API. We will include all weather-related functionalities from the whole backend into this backend server. If you have implemented Separation of Concerns (SoC) and Keep It Simple, Stupid (KISS) principles from the beginning of the large project, you can effectively refactor and separate the server.</p><pre># Server Weather<br><br>├── weather /<br>│   ├── __init__.py<br>│   ├── admin.py<br>│   ├── apps.py<br>│   └── constants.py<br>│   └── models.py<br>│   └── serializers.py<br>│   └── urls.py<br>│   └── views.py</pre><p>For example, the weather server includes functionalities to retrieve daily weather data, hourly weather within a day, current weather, and forecasting.</p><ul><li><strong>Plant Server</strong></li></ul><p>The plant server will be created as a new repository, serving as a service that processes plant data from a database. All functionalities related to plants in the whole backend will be moved to this repository. If you have implemented SoC and KISS principles from the beginning of the large project, you can effectively refactor and separate the server.</p><pre># Server Plant<br><br>├── plant /<br>│   ├── __init__.py<br>│   ├── admin.py<br>│   ├── apps.py<br>│   └── constants.py<br>│   └── models.py<br>│   └── serializers.py<br>│   └── urls.py<br>│   └── views.py</pre><p>For example, the plant server includes functionalities to retrieve complete plant data, recommendations for plants, prediction of plant prices, retrieval of plant data based on ID, tracking plant data, and more.</p><ul><li><strong>Trivia Server</strong></li></ul><p>The trivia server will be created as a new repository, serving as a service that processes trivia data from a database. All functionalities related to trivia in the whole backend will be moved to this repository. If you have implemented SoC and KISS principles from the beginning of the large project, you can effectively refactor and separate the server.</p><pre># Server Trivia<br><br>├── trivia /<br>│   ├── __init__.py<br>│   ├── admin.py<br>│   ├── apps.py<br>│   └── constants.py<br>│   └── models.py<br>│   └── serializers.py<br>│   └── urls.py<br>│   └── views.py</pre><p>For example, the trivia server includes functionalities to retrieve all trivia data, maximum three trivia, or trivia by ID.</p><ul><li><strong>Proxy Server</strong></li></ul><p>The proxy server acts as an intermediary between the client and the three separate service apps: Weather Server, Plant Server, and Trivia Server. Its main function is to handle client requests and <strong>route them to the appropriate service</strong>. Here’s a detailed explanation of the benefits of using a proxy server for these three service apps:</p><ol><li><strong>Load Balancing</strong>: The proxy server can distribute incoming client requests evenly across the three service apps, ensuring that the load is balanced. This prevents any single service from becoming <strong>overwhelmed with requests</strong>, thereby optimizing performance and resource utilization.</li><li><strong>Caching:</strong> The proxy server can cache responses from the service apps. This means that if multiple clients request the same data, the proxy server can <strong>serve the cached response</strong> instead of forwarding the request to the service, reducing latency and improving overall responsiveness.</li><li><strong>Security:</strong> The proxy server can act as a <strong>security barrier, filtering and inspecting incoming requests</strong> before forwarding them to the service apps. It can implement security measures such as access control, authentication, and authorization to <strong>protect the service</strong> apps from unauthorized access and potential security threats.</li><li><strong>Scalability:</strong> By abstracting the clients from the individual service apps, the proxy server facilitates scalability. Additional instances of the service apps <strong>can be added or removed without affecting the clients</strong>, as long as the proxy server is updated to route requests accordingly. This makes it easier to scale the system horizontally to <strong>handle increased traffic or load.</strong></li><li><strong>Fault Tolerance and Failover:</strong> The proxy server <strong>can monitor the health and availability of the service apps.</strong> In the event that one of the service apps becomes unavailable or fails, the proxy server can automatically reroute requests to alternative healthy instances, ensuring continuous service availability and <strong>minimal disruption for clients.</strong></li></ol><pre>                      +---------------------+<br>                      |    Proxy Server     |<br>                      +---------------------+<br>                             |    |    |<br>                      +------+------+------+<br>                      |      |      |      |<br>           +----------+      |      |      +----------+<br>           |          |      |      |      |          |<br>           | Weather  |      |      |      | Trivia   |<br>           |  Server  |      |      |      |  Server  |<br>           |          |      |      |      |          |<br>           +----------+      |      |      +----------+<br>                             |      |<br>                       +-----+      +-----+<br>                       |                  |<br>                       |    Plant Server  |<br>                       |                  |<br>                       +------------------+</pre><p>In this setup, the Proxy Server acts as a <strong>central gateway for client requests</strong>, distributing them to the appropriate service apps based on the requested functionality (e.g., weather data, plant information, trivia). This architecture <strong>enhances scalability, reliability, security, and performance</strong> of the overall system.</p><h4><strong>Summary:</strong></h4><p>In the context of migrating from a monolithic architecture to microservices, the principles of Separation of Concerns (SoC) and Keep It Simple, Stupid (KISS) play crucial roles in ensuring a successful transition.</p><p>When migrating from monolithic to microservices architecture, embracing principles like <strong>Separation of Concerns (SoC)</strong> and <strong>Keep It Simple, Stupid (KISS) </strong>ensures that the transition is smooth and effective. These principles help in breaking down complex systems into manageable components, facilitating <strong>agility, scalability, and maintainability in the new microservices environment.</strong></p><h3>Section 4: Conclusion</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FOPopCfo0YDAFWvDQHuqxw.png" /><figcaption>Conclusion of SoC, KISS, Monolithic to Microservices by eugeniusmario.</figcaption></figure><p>The migration from a monolithic architecture to microservices is driven by the need for <strong>improved scalability, flexibility, and maintainability</strong> in modern software development. This shift involves breaking down large, monolithic applications into smaller, independently deployable services, each responsible for a specific business function. Two key principles guiding this migration are <strong>Separation of Concerns (SoC) </strong>and <strong>Keep It Simple, Stupid (KISS)</strong>.</p><h4><strong>Separation of Concerns (SoC)</strong></h4><ul><li>SoC advocates for dividing a software system into distinct modules, each handling a specific set of responsibilities. This principle is crucial in microservices architecture, where services are <strong>decoupled and focused</strong> on <strong>specific tasks or functionalities</strong>.</li><li>By applying SoC, developers can <strong>isolate different concerns</strong> within a system, making it easier to understand, maintain, and scale. In the context of microservices, each service encapsulates a single concern, <strong>enabling teams to work independently</strong> on different parts of the application <strong>without affecting others.</strong></li></ul><h4>Keep It Simple, Stupid (KISS)</h4><ul><li>KISS emphasizes<strong> simplicity and avoiding unnecessary complexity</strong> in software design and development. When migrating to microservices, adhering to this principle helps in designing services that are <strong>easy to deploy, manage, and troubleshoot.</strong></li><li>By keeping services simple and focused on their core functionality, developers can reduce dependencies, improve agility, and minimize the risk of system failures. This approach also facilitates <strong>faster development cycles and easier integration</strong> of new features or changes.</li></ul><p>In summary, the migration from monolithic to microservices architecture leverages principles like Separation of Concerns (SoC) and Keep It Simple, Stupid (KISS) to <strong>break down complex systems</strong> into smaller, manageable components. By adopting these principles, organizations can achieve <strong>greater agility, scalability, and maintainability</strong> in their software development processes.</p><h3>The End</h3><p>Thanks for diving into the world of migrating from monolithic to microservices architecture and understanding how Separation of Concerns (SoC) and Keep It Simple, Stupid (KISS) principles can make our <strong>development journey smoother.</strong></p><p>Remember, by keeping things simple and focusing on <strong>breaking down our system into smaller, manageable parts,</strong> we’re setting ourselves up for <strong>easier maintenance and continuous improvement.</strong> So, let’s embrace these principles, simplify our codebase, and make our transition to microservices a breeze!</p><p>If you’re interested in connecting further with me, please visit my LinkedIn profile <a href="https://www.linkedin.com/in/eugenius-mario-s/"><strong>Eugenius Mario’s LinkedIn</strong></a><strong>.</strong></p><p>Thank you and happy coding!</p><h3><strong>References:</strong></h3><ol><li><a href="https://en.wikipedia.org/wiki/Separation_of_concerns">https://en.wikipedia.org/wiki/Separation_of_concerns</a></li><li><a href="https://dev.to/tamerlang/separation-of-concerns-the-simple-way-4jp2">https://dev.to/tamerlang/separation-of-concerns-the-simple-way-4jp2</a></li><li><a href="https://www.oreilly.com/library/view/software-architects-handbook/9781788624060/8ff905c2-217a-47f0-85c2-789296d42e8d.xhtml#:~:text=Concerns%20are%20the%20different%20aspects,concerns%20as%20much%20as%20possible">https://www.oreilly.com/library/view/software-architects-handbook/9781788624060/8ff905c2-217a-47f0-85c2-789296d42e8d.xhtml#:~:text=Concerns%20are%20the%20different%20aspects,concerns%20as%20much%20as%20possible</a>.</li><li><a href="https://en.wikipedia.org/wiki/KISS_principle">https://en.wikipedia.org/wiki/KISS_principle</a></li><li><a href="https://www.interaction-design.org/literature/topics/keep-it-simple-stupid">https://www.interaction-design.org/literature/topics/keep-it-simple-stupid</a></li><li><a href="https://www.freecodecamp.org/news/keep-it-simple-stupid-how-to-use-the-kiss-principle-in-design/">https://www.freecodecamp.org/news/keep-it-simple-stupid-how-to-use-the-kiss-principle-in-design/</a></li><li><a href="https://en.wikipedia.org/wiki/Monolithic_system">https://en.wikipedia.org/wiki/Monolithic_system</a></li><li><a href="https://en.wikipedia.org/wiki/Application_software">https://en.wikipedia.org/wiki/Application_software</a></li><li><a href="https://www.atlassian.com/microservices/microservices-architecture/microservices-vs-monolith">https://www.atlassian.com/microservices/microservices-architecture/microservices-vs-monolith</a></li><li><a href="https://en.wikipedia.org/wiki/Microservices">https://en.wikipedia.org/wiki/Microservices</a></li><li><a href="https://aws.amazon.com/microservices/">https://aws.amazon.com/microservices/</a></li><li><a href="https://dcloud.co.id/blog/kenali-apa-itu-microservices-dan-kelebihan.html">https://dcloud.co.id/blog/kenali-apa-itu-microservices-dan-kelebihan.html</a></li><li><a href="https://en.wikipedia.org/wiki/Software_engineering">https://en.wikipedia.org/wiki/Software_engineering</a></li><li><a href="https://en.wikipedia.org/wiki/Service-oriented_architecture">https://en.wikipedia.org/wiki/Service-oriented_architecture</a></li><li><a href="https://en.wikipedia.org/wiki/Architectural_pattern">https://en.wikipedia.org/wiki/Architectural_pattern</a></li><li><a href="https://en.wikipedia.org/wiki/Loose_coupling">https://en.wikipedia.org/wiki/Loose_coupling</a></li><li><a href="https://en.wikipedia.org/wiki/Granularity">https://en.wikipedia.org/wiki/Granularity</a></li><li><a href="https://en.wikipedia.org/wiki/Lightweight_protocol">https://en.wikipedia.org/wiki/Lightweight_protocol</a></li><li><a href="https://en.wikipedia.org/wiki/Software_deployment">https://en.wikipedia.org/wiki/Software_deployment</a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=da16e730ebef" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Become a Tech Lead, Master of Review: A Deep Dive into GitHub Pull Requests (Bonus: Teaching Your…]]></title>
            <link>https://eugeniusmario.medium.com/become-a-tech-lead-master-of-review-a-deep-dive-into-github-pull-requests-bonus-teaching-your-23817210bbc2?source=rss-974c337fafb0------2</link>
            <guid isPermaLink="false">https://medium.com/p/23817210bbc2</guid>
            <category><![CDATA[github]]></category>
            <category><![CDATA[pull-request]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[commit]]></category>
            <category><![CDATA[tech-lead]]></category>
            <dc:creator><![CDATA[Eugenius Mario]]></dc:creator>
            <pubDate>Tue, 12 Mar 2024 18:34:37 GMT</pubDate>
            <atom:updated>2024-03-12T18:37:56.466Z</atom:updated>
            <content:encoded><![CDATA[<h3>Become a Tech Lead, Master of Review: A Deep Dive into GitHub Pull Requests (Bonus: Teaching Your Team to Use Better Commit Messages)</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iqn3YBNMDL4N_SihxS8ILQ.png" /><figcaption>Collection of GitHub tools used to maintain projects.</figcaption></figure><p>As developers, GitHub serves as a cornerstone in our workflow, facilitating version control and collaboration. While many of us are adept at using GitHub for basic versioning, there’s often more to explore in maximizing its potential.</p><p>In this article, I’ll delve into two critical aspects: pull requests and commits, and uncover the depth of functionality they offer. By understanding and harnessing these features effectively, you can elevate your programming skills and maintain organized project documentation.</p><p>Let’s dive in.</p><h3><strong>Section 1: A Deep Dive into GitHub Pull Requests</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*UXw0jUPoOehGnBPswek5Zw.png" /><figcaption>View of the pull request page on GitHub.</figcaption></figure><p>Assuming that we have a good grasp of branching, how to checkout branches, and create features within them, the next step in our development process usually involves integrating our work with others. This is where pull requests come into play. If you’re not familiar with GitHub branching, you can refer to the documentation here: <a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-branches">GitHub Branching Documentation</a>.</p><p>I will dissect each part of what we can do in a pull request, let’s get started:</p><ol><li><strong>Filters</strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*W_-RSknN951EAHXQB-zMJw.png" /><figcaption>Pull request page on GitHub with highlight on filters.</figcaption></figure><p>With issue and pull request search terms, you can:</p><ul><li>Filter issues and pull requests by author: state:open type:issue author:octocat</li><li>Filter issues and pull requests that involve, but don’t necessarily <a href="https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax#mentioning-people-and-teams">@mention</a>, certain people: state:open type:issue involves:octocat</li><li>Filter issues and pull requests by assignee: state:open type:issue assignee:octocat</li><li>Filter issues and pull requests by label: state:open type:issue label:&quot;bug&quot;</li><li>Filter out search terms by using - before the term: state:open type:issue -author:octocat</li></ul><p>Tip: You can filter issues and pull requests by label using logical OR or using logical AND.</p><ul><li>To filter issues using logical OR, use the comma syntax: label:&quot;bug&quot;,&quot;wip&quot;.</li><li>To filter issues using logical AND, use separate label filters: label:&quot;bug&quot; label:&quot;wip&quot;.</li></ul><p>For issues, you can also use search to:</p><ul><li>Filter for issues that are linked to a pull request by a closing reference: linked:pr</li><li>Filter issues by the reason they were closed: is:closed reason:completed or is:closed reason:&quot;not planned&quot;</li></ul><p>For pull requests, you can also use search to:</p><ul><li>Filter <a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests#draft-pull-requests">draft</a> pull requests: is:draft</li><li>Filter pull requests that haven’t been <a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/about-pull-request-reviews">reviewed</a> yet: state:open type:pr review:none</li><li>Filter pull requests that <a href="https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/managing-protected-branches/about-protected-branches#require-pull-request-reviews-before-merging">require a review</a> before they can be merged: state:open type:pr review:required</li><li>Filter pull requests that a reviewer has approved: state:open type:pr review:approved</li><li>Filter pull requests in which a reviewer has asked for changes: state:open type:pr review:changes_requested</li><li>Filter pull requests by <a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/about-pull-request-reviews">reviewer</a>: state:open type:pr reviewed-by:octocat</li><li>Filter pull requests by the specific user <a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/requesting-a-pull-request-review">requested for review</a>: state:open type:pr review-requested:octocat</li><li>Filter pull requests that someone has asked you directly to review: state:open type:pr user-review-requested:@me</li><li>Filter pull requests by the team requested for review: state:open type:pr team-review-requested:github/docs</li><li>Filter for pull requests that are linked to an issue that the pull request may close: linked:issue</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*D7uJJkFS0Pnw06hDBxFA7g.png" /><figcaption>Pull request page on GitHub with highlight on filters.</figcaption></figure><p>As an example, when filtering closed pull requests authored by myself “eugeniusms”, it is observed that there are 71 closed pull requests from that filter.</p><p><strong>2. Labels</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GXD6Zx7-xfB8JRunk2s31A.png" /><figcaption>Pull request page on GitHub with highlight on labels.</figcaption></figure><p>You have the ability to organize issues, pull requests, and discussions by generating, modifying, applying, and removing labels. On GitHub, you can effectively oversee your tasks by establishing labels to classify issues, pull requests, and discussions. These labels can be applied within the repository where they were initially created. Once a label is set up, you can utilize it across any issue, pull request, or discussion within that specific repository.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Sb6aL6bGjRxyRC3OtPVsKw.png" /><figcaption>Pull request page on GitHub with highlight on one of labels.</figcaption></figure><p>GitHub provides default labels in every new repository. You can use these default labels to help create a standard workflow in a repository.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*m99rrV0hkQybbftVjqFFyA.png" /><figcaption>Default labels generated from GitHub.</figcaption></figure><ul><li>bug : Indicates an unexpected problem or unintended behavior</li><li>documentation : Indicates a need for improvements or additions to documentation</li><li>duplicate : Indicates similar issues, pull requests, or discussions</li><li>enhancement : Indicates new feature requests</li><li>good first issue : Indicates a good issue for first-time contributors</li><li>help wanted : Indicates that a maintainer wants help on an issue or pull request</li><li>invalid : Indicates that an issue, pull request, or discussion is no longer relevant</li><li>question : Indicates that an issue, pull request, or discussion needs more information</li><li>wontfix : Indicates that work won&#39;t continue on an issue, pull request, or discussion</li></ul><p>Default labels are included in every new repository when the repository is created, but you can edit or delete the labels later.</p><p>Issues with the good first issue label are used to populate the repository&#39;s contribute page. For an example of a contribute page, see <a href="https://github.com/github/docs/contribute">github/docs/contribute</a>.</p><p><strong>3. Milestone</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*tNNckDIiD4qJ-B8fNIsJGA.png" /><figcaption>Pull request page on GitHub with highlight on milestones.</figcaption></figure><p>Milestones offer a valuable tool for monitoring the progress of sets of issues or pull requests within a repository. When a milestone is created, it can be linked to specific issues and pull requests, facilitating organized tracking of project objectives. By accessing the milestone page, users can access comprehensive details regarding the milestone’s status.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7Z5AbsJzIdhE2nJzt3JmpQ.png" /><figcaption>An example of active milestone.</figcaption></figure><p>This includes a user-provided description offering project insights, relevant team information, and anticipated completion dates. Additionally, users can review essential metrics such as the milestone’s due date, completion percentage, and the tally of associated open and closed issues and pull requests. The milestone page also presents a convenient list of these associated issues and pull requests, aiding in streamlined management.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vjwJrmkLMrcqQwHaIr7Qmg.gif" /><figcaption>Organizing milestone on GitHub.</figcaption></figure><p>Furthermore, the milestone page enables users to actively engage in project management tasks. Users have the capability to modify milestone details directly from this page and create new issues seamlessly integrated with the milestone. Additionally, the functionality allows for prioritizing tasks within milestones for enhanced project organization. By simply clicking and dragging issues or pull requests to rearrange their order, users can effectively prioritize and manage the tasks associated with each milestone.</p><p><strong>4. Sort</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sudduAuy-kV6lcl2MIz2NQ.png" /></figure><p>In a GitHub pull request, several elements contribute to the management and organization of the proposed changes:</p><p><strong>Author</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Gs7cIwRoOhhVyaP9SMLaPA.png" /><figcaption>Author dropdown on pull request filter.</figcaption></figure><p>The author is the individual who initiated the pull request, typically the contributor who created the branch containing the changes. The author’s name and profile picture are displayed alongside the pull request.</p><p><strong>Labels</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*buN8fcysDb3_SpF1NLywWw.png" /><figcaption>Label dropdown on pull request filter.</figcaption></figure><p>Labels are metadata tags that provide additional context or categorization to the pull request. They help classify and organize pull requests based on their nature, such as bug fixes, feature requests, or documentation updates. Labels enable team members to quickly identify and prioritize pull requests.</p><p><strong>Projects</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eHeC2X277O_VuJEC9wXWPw.png" /><figcaption>Projects dropdown on pull request filter.</figcaption></figure><p>Projects offer a way to organize and track work related to pull requests. They allow teams to create boards where pull requests can be grouped into columns representing different stages of development or priority levels. Projects provide visibility into the status of pull requests and help teams manage their workflow effectively.</p><p><strong>Milestones</strong></p><p>Milestones are used to track progress towards completing a specific set of tasks or goals. They enable teams to group related pull requests and issues together under a common objective or deadline. Milestones help teams coordinate efforts, plan releases, and monitor project milestones.</p><p><strong>Reviews</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fbI9j9nHJrNx6Ya9Ac5V5g.png" /><figcaption>Reviews dropdown on pull request filter.</figcaption></figure><p>Reviews are a critical aspect of the pull request process, where team members provide feedback, approve changes, or request further modifications. Reviews ensure code quality, adherence to coding standards, and alignment with project objectives. They foster collaboration and enable thorough examination of proposed changes before merging.</p><p><strong>Assignee</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_Z5d7JbPyBGMwScrGPigEg.png" /><figcaption>Asignee dropdown on pull request filter.</figcaption></figure><p>The assignee is the individual responsible for overseeing the pull request and ensuring its completion. Assignees may be tasked with reviewing the changes, addressing feedback, or coordinating with other team members. Assignees help distribute responsibilities and streamline the pull request workflow.</p><p><strong>Sort</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kkn0nIKgtKxWuLTaB08SRw.png" /><figcaption>Sort dropdown on pull request filter.</figcaption></figure><p>Sorting options allow users to arrange pull requests based on various criteria, such as creation date, last updated, or the number of comments. Sorting helps users prioritize and focus on relevant pull requests, making it easier to manage and review a large volume of changes effectively.</p><p><strong>4. New Pull Request</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IgmeZKlB_NrMbQ-iwgKUFw.png" /><figcaption>New pull request button highlight.</figcaption></figure><p>The next most important part is creating a pull request, which you do when you want to merge two branches into one stream on one of the branches.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*l8ZfA5NpgjLeMeqGA25_eA.png" /><figcaption>Example of comparing changes.</figcaption></figure><p>This is the view of comparing changes, which is a list of changes that have occurred on our branch compared to our target branch. All changes we make on our feature will be included in the branch together. In this context:</p><ul><li>Source branch: PBI-3-authentication</li><li>Target branch: staging</li></ul><p>It means that PBI-3-authentication will be merged into staging, remembering that staging will incorporate new changes originating from PBI-3-authentication, but PBI-3-authentication will not receive anything.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*49S6NOZb2er73JJSYLbqdQ.png" /><figcaption>Example of open pull request.</figcaption></figure><p>If you press the create/view pull request button, you will encounter a view like the one above, which summarizes everything within your pull request. Let’s dissect each one:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*J57ZvtiKzqlsUEjX2d3fAw.png" /><figcaption>Header of GitHub pull request.</figcaption></figure><p>Inside the red circle, there are several important pieces of information. “PBI 3 authentication” serves as the title of the pull request, followed by “#98” indicating the pull request number. The “Open” chip signifies that the pull request status is currently open (not merged or closed). “Into staging from PBI-3-authentication” denotes that the latest update is from PBI-3-authentication and is intended to update staging.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Bf9zrKkHQxmwTI-MKihxVg.png" /><figcaption>Subheader of GitHub pull request.</figcaption></figure><p>Then, in the subheader section of the pull request, there are tabs. Currently, we are on the “conversation” tab. We will discuss each menu within the tab one by one.</p><p><strong>Conversation</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RuR8WYORMGB2r5gAhggBHg.png" /><figcaption>Conversation menu on pull request.</figcaption></figure><p>This tab displays the conversation related to the pull request. It includes comments, discussions, and any interactions between collaborators regarding the changes proposed in the pull request. Users can discuss feedback, ask questions, or provide suggestions to facilitate collaboration and communication throughout the review process.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Tve9g9XoIdwzNVlntTKU2w.png" /><figcaption>Opener comment on pull request.</figcaption></figure><p>The highlighted section above is a message that can be conveyed to other team members, containing a description of a pull request. You can fill it by providing any new features from your request.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-igR2G5_CxQa6KHReNSkXg.png" /><figcaption>Commit section on conversation menu pull request.</figcaption></figure><p>This section is a list of commits you made in the source branch that are not yet in the target branch, meaning this is the difference between two branches being merged.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hhRjyHyisOkclxc2a-gyOg.png" /><figcaption>Right sidebar information of conversation menu pull request.</figcaption></figure><p>This part explains who reviewed and suggests correcting by commenting on your code creation. There are also assignees, indicating who is working on the feature to be merged, along with labels, projects, and milestones as explained earlier. Additionally, there are developments and notifications to receive updates on this pull request.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*h82ce3NY6sfbTzH---Q9uQ.png" /><figcaption>Add a comment in conversation menu pull request.</figcaption></figure><p>As its name suggests, the conversation menu allows team members to engage in discussions by commenting through this menu.</p><p><strong>Commits</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VN0BW2rhsv1SKfHrf8HV0Q.png" /><figcaption>Commits menu on pull request.</figcaption></figure><p>The “Commits” tab provides a list of all the individual commits that are part of the pull request. Each commit represents a specific change or set of changes made to the codebase. By examining the commits, reviewers can gain insight into the history of changes, understand the development process, and assess the quality of the code modifications included in the pull request.</p><p><strong>Checks</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hzHyLHvdQTd9oCLE6IFqwA.png" /><figcaption>Checks menu on pull request.</figcaption></figure><p>This tab displays the status of various automated checks and continuous integration (CI) processes performed on the pull request. These checks may include automated tests, code quality analyses, and other verification procedures configured by the project’s development team.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2hJM25kipyBjp2CFA6zvoQ.png" /><figcaption>SonarCloud check as example on check pull request.</figcaption></figure><p>Reviewers can use the information presented in this tab to determine whether the proposed changes meet the project’s quality standards and compliance requirements.</p><p><strong>Files Changed</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Yn3Fc3wBuH_oJPuo2_ST9A.png" /><figcaption>File changed menu on pull request.</figcaption></figure><p>The “Files changed” tab provides an overview of all the files that have been modified, added, or deleted as part of the pull request. Users can review the specific changes made to each file, including line-by-line differences, to understand the impact of the proposed changes on the codebase. This tab is particularly useful for conducting a detailed code review, identifying potential issues, and providing feedback on specific code modifications.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XvS-J2_lJiny49Y4_cKjIw.png" /><figcaption>Line changes on file changed menu pull request.</figcaption></figure><p>The text on the top right corner means that if it’s green, it represents the number of new lines added to the code. If the line is red, it indicates the number of lines that have been deleted from our code. We can see this in the middle per file, marked according to its color.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*UKpJVXRsxprfC5-wX7XzSA.png" /><figcaption>List of file changed files on pull request.</figcaption></figure><p>This is a list of all files in a readable directory and folder structure format, also indicating some signs: if it’s green, it means a new file; if it’s yellow, it means a modified file; if it’s red, it means a deleted file. You can also click directly on these files to view their changes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QzATKz_VXobCvdUwrZibbw.png" /><figcaption>Review changes, viewed, and coments.</figcaption></figure><p>“0/12 files viewed” means that in this pull request, you haven’t viewed any files yet. You can click the ‘viewed’ checkbox to mark that you’ve read the file. This will help you track which files you’ve reviewed and commented on for your colleagues to address.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TW10GdGomhtLnGnP5MBWaw.png" /><figcaption>Comment a file in pull request.</figcaption></figure><p>You can also click the comment icon to leave a comment on a file. For example, if you find a code smell in your friend’s code and you want to inform them, you can add your comment in that box.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Ii1R2riCCyWThYAlbT0YGw.png" /><figcaption>Review changes on file changed menu pull request.</figcaption></figure><p>Then you can proceed with a clear review comment. There are 3 options in this menu:</p><ul><li>Comment: Submit general feedback without explicit approval.</li><li>Approve: Submit feedback and approve merging these changes.</li><li>Request changes: Submit feedback that must be addressed before merging.</li></ul><p>You can customize which option suits your needs in conducting a review to ensure your friend understands what you expect from them.</p><h3><strong>Bonus Section: Teaching Your Team to Use Better Commit Messages</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*O3TJx-1wwSD-3fUxVMQvnQ.png" /><figcaption>Commit message meme on internet from workchronicles.</figcaption></figure><p>In the realm of collaborative software development, the importance of clear and descriptive commit messages cannot be overstated. A well-crafted commit message serves as a concise record of changes made to the codebase, aiding in understanding the evolution of the project over time.</p><p>However, ensuring that every team member adheres to this best practice can be a challenge. In this article, we’ll explore the significance of quality commit messages and provide practical guidance on how to instill this habit within your development team.</p><p>Additionally, we’ll offer bonus insights into advanced techniques for crafting informative commit messages that enhance project transparency and streamline collaboration.</p><p>Let’s dive in!</p><p><strong>1. Type of commit</strong></p><pre>feat:     The new feature being added to a particular application<br>fix:      A bug fix (this correlates with PATCH in SemVer)<br>style:    Feature and updates related to styling<br>refactor: Refactoring a specific section of the codebase<br>test:     Everything related to testing<br>docs:     Everything related to documentation<br>chore:    Regular code maintenance</pre><p><strong>2. Scope of commit (Optional)</strong></p><p>A scope is REQUIRED to be a noun that describes a specific part of the codebase impacted by the modifications (or just the name of the epic) enclosed in parentheses. For instance:</p><pre>feat(plant_recommendation)<br>test(dashboard_weather)</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TK_mIp-WDOej5T5-CRBnjQ.png" /><figcaption>Example of commit messages.</figcaption></figure><p><strong>3. Subject</strong></p><p>Provide a concise summary of the implemented modifications.</p><ul><li>Keep the subject line under 50 characters.</li><li>Ensure your commit message excludes any spaces or punctuation.</li><li>Avoid concluding the subject line with a period.</li><li>Utilize <strong>present tense</strong> or <strong>imperative mood</strong> within the subject line.</li></ul><pre>feat(dashboard_trivia): create dashboard trivia api<br>test(dashboard_trivia): create test for dashboard trivia api</pre><p><strong>4. Body (Optional)</strong></p><p>Utilize the body section to clarify the modifications made and the rationale behind them.</p><ul><li>Include a blank line between the subject and the body.</li><li>Ensure each line does not exceed 72 characters.</li><li>Do not presume that the reviewer comprehends the initial issue; provide necessary context.</li><li>Avoid assuming that your code is inherently understandable.</li></ul><pre>refactor!: drop support for Pip 3.7<br>BREAKING CHANGE: refactor to use Python features not available in Pip 3.7.</pre><p><strong>5. Footer (Optional)</strong></p><p>This section is used to reference any issues impacted by the code changes or to communicate with other developers or testers.</p><pre>fix(weather): correct minor typos in code<br>See the issue for details<br>on typos fixed.<br>Reviewed-by: @eugeniusms<br>Refs #76</pre><h3><strong>Bonus² Section: Guidelines for Effective Git Commits</strong></h3><ul><li><strong>Opt for Small</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*196QY0vMFKWRFmALreIBFQ.jpeg" /><figcaption>Two distinct bugs.</figcaption></figure><p>Focused commits to maintain a tidy source code and facilitate better management, each commit should encapsulate related changes. For instance, if addressing two distinct bugs, it’s advisable to create two separate commits. This approach aids other developers in comprehending the modifications and facilitates easy rollback in case of errors.</p><ul><li><strong>Commit Frequently</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eOidjPHGGZ10_j9cgFSgnA.jpeg" /><figcaption>Sharing code more regularly with peers.</figcaption></figure><p>Commit frequently, timely committing frequently and promptly ensures that commits remain small and relevant. Additionally, it encourages sharing code more regularly with peers, mitigating the likelihood of encountering merge conflicts.</p><ul><li><strong>Validate Your Code Before Committing</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2xGnBSvl1j5EBm13rJk21Q.jpeg" /><figcaption>Validate your code before commiting.</figcaption></figure><p>Avoid the impulse to commit code that is deemed “completed” without rigorous testing. Prioritize thorough testing to ensure completeness and minimize any potential side effects.</p><ul><li><strong>Establish a Consistent Workflow</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*EAb22a4HfCIfDi_Idj4Dsg.jpeg" /><figcaption>Establish a consistent workflow.</figcaption></figure><p>Git offers various workflows, including long-running branches, feature branches, merge or rebase strategies, and git-flow, among others. The selection of a workflow should align with project requirements, development practices, and deployment processes. Regardless of the chosen workflow, consensus on a unified approach is paramount for effective collaboration.</p><h3>The End</h3><p>Congratulations, you have delved deeper into the art of being a tech lead by enhancing your understanding of code review through pull requests on GitHub, as well as providing new insights into the importance of good GitHub commit naming for your team. I hope this article proves beneficial to you in developing your team!</p><p>If you’re interested in connecting further with me, please visit my LinkedIn profile <a href="https://www.linkedin.com/in/eugenius-mario-s/">Eugenius Mario’s LinkedIn</a>.</p><p>Thank you and happy coding!</p><p><strong>References:</strong></p><ol><li><a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-branches">https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-branches</a></li><li><a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/incorporating-changes-from-a-pull-request/merging-a-pull-request">https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/incorporating-changes-from-a-pull-request/merging-a-pull-request</a></li><li><a href="https://docs.github.com/en/issues/tracking-your-work-with-issues/filtering-and-searching-issues-and-pull-requests">https://docs.github.com/en/issues/tracking-your-work-with-issues/filtering-and-searching-issues-and-pull-requests</a></li><li><a href="https://docs.github.com/en/issues/using-labels-and-milestones-to-track-work/managing-labels">https://docs.github.com/en/issues/using-labels-and-milestones-to-track-work/managing-labels</a></li><li><a href="https://github.com/github/docs/contribute">https://github.com/github/docs/contribute</a></li><li><a href="https://docs.github.com/en/issues/using-labels-and-milestones-to-track-work/about-milestones">https://docs.github.com/en/issues/using-labels-and-milestones-to-track-work/about-milestones</a></li><li><a href="https://docs.github.com/en/issues/using-labels-and-milestones-to-track-work/creating-and-editing-milestones-for-issues-and-pull-requests">https://docs.github.com/en/issues/using-labels-and-milestones-to-track-work/creating-and-editing-milestones-for-issues-and-pull-requests</a></li><li><a href="https://github.blog/2016-07-05-reorder-issues-within-a-milestone/">https://github.blog/2016-07-05-reorder-issues-within-a-milestone/</a></li><li><a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/commenting-on-a-pull-request">https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/commenting-on-a-pull-request</a></li><li><a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/committing-changes-to-a-pull-request-branch-created-from-a-fork">https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/committing-changes-to-a-pull-request-branch-created-from-a-fork</a></li><li><a href="https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/about-status-checks">https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/about-status-checks</a></li><li><a href="https://docs.github.com/en/enterprise-cloud@latest/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/reviewing-proposed-changes-in-a-pull-request">https://docs.github.com/en/enterprise-cloud@latest/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/reviewing-proposed-changes-in-a-pull-request</a></li><li><a href="https://medium.com/@hritik.jaiswal/how-to-write-a-good-commit-message-9d2d533b9052">https://medium.com/@hritik.jaiswal/how-to-write-a-good-commit-message-9d2d533b9052</a></li><li><a href="https://www.conventionalcommits.org/en/v1.0.0/">https://www.conventionalcommits.org/en/v1.0.0/</a></li><li><a href="https://medium.com/swlh/writing-better-commit-messages-9b0b6ff60c67">https://medium.com/swlh/writing-better-commit-messages-9b0b6ff60c67</a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=23817210bbc2" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Automated Deployment Django on Google Compute Engine using GitHub Action and Docker]]></title>
            <link>https://eugeniusmario.medium.com/automated-deployment-django-on-google-compute-engine-using-github-action-and-docker-662f84755c57?source=rss-974c337fafb0------2</link>
            <guid isPermaLink="false">https://medium.com/p/662f84755c57</guid>
            <category><![CDATA[deployment]]></category>
            <category><![CDATA[google-cloud-platform]]></category>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[django]]></category>
            <category><![CDATA[software-engineering]]></category>
            <dc:creator><![CDATA[Eugenius Mario]]></dc:creator>
            <pubDate>Tue, 27 Feb 2024 14:58:47 GMT</pubDate>
            <atom:updated>2024-02-27T14:58:47.900Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mnA4Ub5UPbfUL1w9yB9jLA.png" /><figcaption>Collection of tech stacks used to deploy projects.</figcaption></figure><p>Deploying Django to Google Compute Engine can be a challenging task for those who have never done it before. Here, I will explain how to deploy a Django project using Docker, first storing it in Docker Hub, and then pulling it into a Google Compute Engine VM to run the program. This is roughly the deployment workflow we’ll be discussing.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oPZ1cPmfQpEmFeaBZPVU_A.png" /><figcaption>Deployment work flow from start to finish.</figcaption></figure><p><strong>Section 1: Setup Your Django Project</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*UwnNY0LAj0bcWP7UVQ_q-A.png" /><figcaption>Section 1: Setup Your Django Project.</figcaption></figure><p>I assume that you already have your Django project locally and are using GitHub as an online repository. If you don’t have a project yet, please check out the Django documentation here: <a href="https://docs.djangoproject.com/en/5.0/intro/tutorial01/">Django Tutorial</a>.</p><p>Make sure you activate your environment and save all dependencies into requirements.txt. This step is crucial because the workflow will build your Django project with the dependencies listed in requirements.txt. You can learn more about it here: <a href="https://www.w3schools.com/django/django_deploy_requirements.php">Deploy Django with Requirements.txt</a>. Here’s an example of requirements.txt file:</p><pre>asgiref==3.5.2<br>autopep8==2.0.0<br>certifi==2022.6.15<br>charset-normalizer==2.1.1<br>dj-database-url==1.0.0<br>Django==4.1<br>django-bootstrap3==22.1<br>django-cors-headers==3.13.0<br>gunicorn==20.1.0<br>idna==3.3<br>Pillow==9.2.0<br>psycopg2-binary==2.9.3<br>pycodestyle==2.9.1<br>python-decouple==3.8<br>pytz==2022.2.1<br>requests==2.28.1<br>six==1.16.0<br>sqlparse==0.4.2<br>tomli==2.0.1<br>typed-ast==1.5.4<br>tzdata==2022.2<br>urllib3==1.26.11<br>whitenoise==6.2.0<br>wrapt==1.14.1</pre><p>Your Django project folder structure should look like this:</p><pre>[project_name]/<br>│<br>├── [project_name]/<br>│   ├── __init__.py<br>│   ├── settings.py<br>│   ├── urls.py<br>│   └── wsgi.py<br>│<br>├── env/...<br>├── .gitignore<br>├── manage.py<br>└── requirements.txt</pre><p>You can use Gitignore to exclude unnecessary files, including the virtual environment (env). Here&#39;s an example of .gitignore file:</p><pre># Django<br>*.log<br>__pycache__<br>db.sqlite3<br><br># Environments <br>.env <br>env/ <br><br># Mac OS<br>.DS_Store</pre><p>When a Django project is created, there are many strings hardcoded in [project_name]/settings.py. First, we need to store these strings in an environment variable to enhance security and flexibility. I utilize a Python library called decouple to attach the environment to the Django code. You can install it using the following command: pip install decouple</p><p>Change the necessary hardcode parts into deploy as example:</p><pre>from decouple import config<br><br>ENVIRONMENT = config(&#39;ENVIRONMENT&#39;, default=&#39;local&#39;)<br>SECRET_KEY = config(&#39;SECRET_KEY&#39;)<br>if ENVIRONMENT == &#39;local&#39;:<br>    DATABASES = {<br>        &#39;default&#39;: {<br>            &#39;ENGINE&#39;: &#39;django.db.backends.sqlite3&#39;,<br>            &#39;NAME&#39;: BASE_DIR / &#39;db.sqlite3&#39;,<br>        }<br>    }<br>else:<br>    DATABASES = {<br>        &#39;default&#39;: {<br>            &#39;ENGINE&#39;: &#39;django.db.backends.postgresql&#39;,<br>            &#39;NAME&#39;: config(&#39;DATABASE_NAME&#39;),<br>            &#39;USER&#39;: config(&#39;DATABASE_USER&#39;),<br>            &#39;PASSWORD&#39;: config(&#39;DATABASE_PASSWORD&#39;),<br>            &#39;HOST&#39;: config(&#39;DATABASE_HOST&#39;),<br>            &#39;PORT&#39;: config(&#39;DATABASE_PORT&#39;),<br>        }<br>    }</pre><p>The code above indicates that if we run using ENVIRONMENT=local, we will use the default Django database locally. If the environment is set to something else (you can set it yourself, for example ENVIRONMENT=production), then your Supabase database will be used.</p><p><strong>Section 2: Setup Supabase for Database</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qe50rbjluHcLe9y1WcT2rQ.png" /><figcaption>Section 2: Setup Supabase for Database.</figcaption></figure><p>I am utilizing PostgreSQL on Supabase as the database storage. Please create your Supabase project on the page <a href="https://supabase.com/">https://supabase.com/</a> after logging in. When creating the project, remember and save the password as it will be used as the password for your project’s database.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zSC29HQr3goFrsN12aZOnw.png" /><figcaption>Database env settings example in supabase.</figcaption></figure><p>After creating the project, you will be directed to a database where you can open the settings page to adjust the <strong>DATABASE</strong> config in your Django settings.py with .env file according to the values in your Supabase project settings.</p><p>Create a new file called .env in the root of your project folder as in the following example:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/802/1*KQerrqAMbn8BQO1eNNPriw.png" /><figcaption>Local .env file.</figcaption></figure><p><strong>Section 3: Setup GitHub Repository</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OOUMVFDvuh1QbFURoPjRPQ.png" /><figcaption>Section 3: Setup GitHub Repository.</figcaption></figure><p>Because I’m using GitHub Action for deployment here, this tutorial will utilize GitHub as the repository to store the Django project. I assume you have initialized the repository and pushed your local project to the GitHub project.</p><p>Please enter the values from your .env file into GitHub repository secrets. You can learn more about it here: <a href="https://docs.github.com/en/actions/security-guides/using-secrets-in-github-actions">Using Secrets in GitHub Actions</a>. If your setup is correct, it will display a page like the following:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ko5TaICazFeg4xQQDr8XnA.png" /><figcaption>GitHub repository secrets.</figcaption></figure><p>The repository secrets will be written by the GitHub workflow into our code, which uses the configuration from the Python decouple library. Next, we will start setting up Docker.</p><p><strong>Section 4: Setup Docker</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dOPwS_VOagEt246a4TMzYg.png" /><figcaption>Section 4: Setup Docker.</figcaption></figure><p>First, we will create a Dockerfile. A Dockerfile is used to set up a self-contained environment that can be run on various operating systems using Docker. If you’re interested in learning more, you can click here: <a href="https://docs.docker.com/get-started/overview/">Docker Overview</a>.</p><p>Here is the Dockerfile we will use in this project. This Dockerfile will add our secrets obtained from GitHub secrets into our application, install dependencies from requirements.txt, collect static files for static views, migrate the database schema, and run the built code with Gunicorn, exposing port 8000 since Django utilizes port 8000 when running the server.</p><p>Create a new file Dockerfile in the root of your django project:</p><pre># Use the official Python image as the base image<br>FROM python:3.9-slim<br><br># Menggunakan variabel lingkungan sebagai build argument<br>ARG DATABASE_NAME<br>ARG DATABASE_USER<br>ARG DATABASE_PASSWORD<br>ARG DATABASE_HOST<br>ARG DATABASE_PORT<br>ARG SECRET_KEY<br>ARG ENVIRONMENT<br><br># Set nilai variabel lingkungan dalam lingkungan Docker<br>ENV DATABASE_NAME=$DATABASE_NAME<br>ENV DATABASE_USER=$DATABASE_USER<br>ENV DATABASE_PASSWORD=$DATABASE_PASSWORD<br>ENV DATABASE_HOST=$DATABASE_HOST<br>ENV DATABASE_PORT=$DATABASE_PORT<br>ENV SECRET_KEY=$SECRET_KEY<br>ENV ENVIRONMENT=$ENVIRONMENT<br><br># Set the working directory in the container<br>WORKDIR /docker-app<br><br># Copy the requirements file into the container at /docker-app<br>COPY requirements.txt /docker-app/<br><br># Install any dependencies specified in requirements.txt<br>RUN pip install --upgrade pip &amp;&amp; pip install -r requirements.txt<br><br># Copy the current directory contents into the container at /docker-app<br>COPY . /docker-app/<br><br># Expose port 8000 to the outside world<br>EXPOSE 8000<br><br># Collect static for better visualization<br>RUN python manage.py collectstatic<br><br># Run migrate DB<br>RUN python manage.py migrate<br><br># Jalankan Gunicorn<br>CMD [&quot;gunicorn&quot;, &quot;app.nani.wsgi&quot;, &quot;--bind&quot;, &quot;0.0.0.0:8000&quot;]</pre><p>Log in to <a href="https://hub.docker.com/">Docker Hub</a> and create a DockerHub repository with the name of your Django project to easy project maintenance.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GoV5V7MlpO1NtAOz-g1H5g.png" /><figcaption>Create new Dockerhub repository.</figcaption></figure><p>Next, create your Docker token on My Account menu. This is necessary so that GitHub Actions can access your Docker account to publish the image from your GitHub repository to Docker Hub.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AAUSE4KShlg250HLB0dbBg.png" /><figcaption>Create new access token for dockerhub.</figcaption></figure><p>Save several values obtained from your Docker Hub account into GitHub secrets, for example:</p><pre>DOCKERHUB_TOKEN=xxx<br>DOCKERHUB_USERNAME=eugeniusms<br>DOCKER_CONTAINER_NAME=project_name<br>DOCKER_IMAGE_NAME=project_name</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yDBmP8HizHZjiiIhzrIe7A.png" /><figcaption>New secrets added to GitHub repository secrets.</figcaption></figure><p><strong>Section 5: Setup Google Compute Engine Virtual Machine</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iCM3jQNr6cfo6iEryAox1w.png" /><figcaption>Section 5: Setup Google Compute Engine Virtual Machine.</figcaption></figure><p>In this section, Google Compute Engine serves as the VM where the Docker containers will be stored and actively run. I assume that you already have a Google account and are connected to the Google Cloud Console. Please create your project in the Google Cloud Console first. You can find instructions on how to do this in the following page: <a href="https://cloud.google.com/compute/docs">Google Compute Engine Documentation</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MiUYwzMAfoSXu2PRJz0jBg.png" /><figcaption>Google Console project dashboard view.</figcaption></figure><p>If you have already created a project, please create your VM by accessing the Google Compute Engine menu. A complete tutorial on this can be found here: <a href="https://cloud.google.com/compute/docs/instances/create-start-instance">Creating and Starting an Instance</a>. I will only explain a few example parts that can be used.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oLTZPe0iQ1xiPOySQzJefg.png" /><figcaption>Create new VM on Google Compute Engine part 1.</figcaption></figure><p>You can use it according to your preference. In this example, I’m using Ubuntu as the operating system for my VM with settings as shown in the image:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/766/1*jtuqJYkrhb2v0hKHCKhNvQ.png" /><figcaption>Setup boot disk for VM.</figcaption></figure><p>You can enable this firewall to prevent your site from being accessed, after that you can click create for create VM.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/659/1*TfeUR3Vk21vGY3xqHoMREA.png" /><figcaption>Firewall setting for VM.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_zq4DR0cNn2HiJkV3sHNaQ.png" /><figcaption>VM instances display after creating new VM.</figcaption></figure><p>You can see that there is information about the external IP. Save this IP address to be placed into GitHub secrets later. The external IP will change each time you restart the VM. To ensure that the IP address remains the same, you can <a href="https://cloud.google.com/compute/docs/ip-addresses/reserve-static-external-ip-address">Reserve External IP Address</a>.</p><p>Now, we can create a new SSH account to access the VM from outside. You can read about how to <a href="https://cloud.google.com/compute/docs/connect/create-ssh-keys">Create a New SSH Key</a>. Note your public key by navigating to the folder containing the key file and using the cat command on your key file. Then, place it into the metadata of your VM as follows:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pSY13iVWFjj7lI9DGtMWGA.png" /><figcaption>Metadata SSH public key for VM.</figcaption></figure><p>Next, you can press the “Save” button and SSH from your local machine into the VM using the following command:</p><pre>ssh -o StrictHostKeyChecking=no -i $HOME/.ssh/[private_key_file] [your_username]@[external_ip_vm]</pre><p>After you are able to enter your VM through the terminal, install Docker and grant SSH user access to the Docker setup inside the VM with the following commands (run the commands inside the SSH terminal of the VM):</p><pre>sudo apt update &amp;&amp; sudo apt upgrade -y<br>curl -fsSL https://get.docker.com | sudo sh -<br>sudo usermod -aG docker $USER</pre><p>To check if Docker is installed, you can run the command:</p><pre>docker -v</pre><p>Congratulations, you have completed the setup on your VM. Now, you can add new secrets to your GitHub repository secrets to access the VM and pull Docker images from Docker Hub into your VM. Here is the list of secrets that need to be added:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*o_dm8ne2yt3N-iCPkiuW9g.png" /><figcaption>List of new secrets added to GitHub repository secrets.</figcaption></figure><ul><li>GCE_INSTANCE_IP: the external IP address of your VM.</li><li>GCE_PROJECT_ID: your project ID.</li><li>GCE_SA_KEY: the service account key in JSON format. You can export it from your service account in the IAM and Admin menu. The tutorial can be found <a href="https://cloud.google.com/iam/docs/keys-create-delete">Create Service Account Key</a>.</li><li>GCE_SSH_PRIVATE_KEY: your SSH user&#39;s private key.</li><li>GCE_SSH_USERNAME: the username of your SSH user.</li></ul><p><strong>Section 6: GitHub Action Workflow</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9pbW6usIblQyUAIoqn8CyA.png" /><figcaption>Section 6: GitHub Action Workflow.</figcaption></figure><p>Next, what you need to do is to create a workflow. You can create a new directory in the root of your Django project called .github, inside which there is a directory named workflows. Then, create a file named deploy.yml. This way, your Django project will have a complete structure like this:</p><pre>[project_name]/<br>│<br>├── [project_name]/<br>│   ├── __init__.py<br>│   ├── settings.py<br>│   ├── urls.py<br>│   └── wsgi.py<br>│<br>├── env/...<br>├── .github/workflows/deploy.yml<br>├── .gitignore<br>├── Dockerfile<br>├── manage.py<br>└── requirements.txt</pre><p>In this workflow section we focus on edit the deploy.yml file, I will divide it into 3 parts: build &amp; test, publish, and deploy.</p><p>First, let’s initialize the `deploy.yml` file with this code. Feel free to customize if you want to deploy on other branches:</p><pre>name: Deploy Django to GCP with Docker - Production<br>on:<br> push:<br> branches:<br> - master<br>env:<br> DATABASE_NAME: ${{ secrets.DATABASE_NAME_PRODUCTION }}<br> DATABASE_USER: ${{ secrets.DATABASE_USER_PRODUCTION }}<br> DATABASE_PASSWORD: ${{ secrets.DATABASE_PASSWORD_PRODUCTION }}<br> DATABASE_HOST: ${{ secrets.DATABASE_HOST_PRODUCTION }}<br> DATABASE_PORT: ${{ secrets.DATABASE_PORT_PRODUCTION }}<br> SECRET_KEY: ${{ secrets.SECRET_KEY }}<br> ENVIRONMENT: ${{ secrets.ENVIRONMENT }}</pre><p><strong>Part 1: Build &amp; Test</strong></p><p>In the build &amp; test section, we will build our Django project and run all the tests. We do this to ensure that our Django project can be built and run in the environment and passes all tests. If there are any failed tests, we won’t proceed to the next step. Here is the code for the build and test:</p><pre>jobs:<br>  build:<br>    runs-on: ubuntu-latest<br>    steps:<br>      - name: Checkout repository<br>        uses: actions/checkout@v3<br><br>      - name: Set up Python<br>        uses: actions/setup-python@v3<br>        with:<br>          python-version: 3.9<br><br>      - name: Install dependencies<br>        run: |<br>          python -m pip install --upgrade pip<br>          pip install -r requirements.txt  <br><br>      - name: Run Django tests<br>        run: |<br>          python manage.py test --keepdb</pre><p><strong>Part 2: Publish</strong></p><p>In the publish section, we will build our Django project to be published to our Docker Hub using the Docker Hub access token that we placed in the secrets earlier. This section can only run if our project can be built and tested successfully.</p><pre>publish:<br>    needs: test<br>    runs-on: ubuntu-latest<br>    steps:<br>      - name: Checkout repository<br>        uses: actions/checkout@v3<br><br>      - name: Login to Docker Hub<br>        uses: docker/login-action@v1<br>        with:<br>          username: ${{ secrets.DOCKERHUB_USERNAME }}<br>          password: ${{ secrets.DOCKERHUB_TOKEN }}<br><br>      - name: Set up Docker<br>        uses: docker/setup-buildx-action@v2<br><br>      - name: Build Docker image<br>        run: |<br>          docker build \<br>            -t ${{ secrets.DOCKER_IMAGE_NAME }}:latest \<br>            --build-arg DATABASE_NAME=$DATABASE_NAME \<br>            --build-arg DATABASE_USER=$DATABASE_USER \<br>            --build-arg DATABASE_PASSWORD=$DATABASE_PASSWORD \<br>            --build-arg DATABASE_HOST=$DATABASE_HOST \<br>            --build-arg DATABASE_PORT=$DATABASE_PORT \<br>            --build-arg SECRET_KEY=$SECRET_KEY \<br>            --build-arg ENVIRONMENT=$ENVIRONMENT \<br>            . --no-cache<br><br>      - name: Tag Docker image<br>        run: docker tag ${{ secrets.DOCKER_IMAGE_NAME }}:latest ${{ secrets.DOCKERHUB_USERNAME }}/${{ secrets.DOCKER_IMAGE_NAME }}:latest<br><br>      - name: Push Docker image to Docker Hub<br>        run: docker push ${{ secrets.DOCKERHUB_USERNAME }}/${{ secrets.DOCKER_IMAGE_NAME }}:latest</pre><p><strong>Part 3: Deploy</strong></p><p>The last stage is the deploy stage. If our Django project has been successfully pushed to Docker Hub, in the next stage, we will pull that Docker Hub repository into our VM using the service account and SSH keys that were placed in GitHub secrets earlier.</p><p>At the end, after the Docker image has been successfully pulled, the VM will continuously run that Docker image and will keep restarting if it fails to run. This ensures that if the VM is shut down and then restarted, Docker will automatically run this image instead of needing to run the workflow again.</p><pre>deploy:<br>    needs: publish<br>    runs-on: ubuntu-latest<br>    steps:<br>      - name: Set up gcloud CLI<br>        uses: google-github-actions/setup-gcloud@v0.3.0<br>        with:<br>          project_id: ${{ secrets.GCE_PROJECT_ID }}<br>          service_account_key: ${{ secrets.GCE_SA_KEY }}<br>          export_default_credentials: true<br><br>      - name: Access gcloud CLI<br>        run: |<br>          gcloud auth configure-docker<br><br>      - name: SSH into GCP instance and deploy Django<br>        uses: appleboy/ssh-action@master<br>        with:<br>          host: ${{ secrets.GCE_INSTANCE_IP }}<br>          username: ${{ secrets.GCE_SSH_USERNAME }}<br>          key: ${{ secrets.GCE_SSH_PRIVATE_KEY }}<br>          script: |<br>            docker stop ${{ secrets.DOCKER_CONTAINER_NAME }} || true<br>            docker rm ${{ secrets.DOCKER_CONTAINER_NAME }} || true<br>            docker pull ${{ secrets.DOCKERHUB_USERNAME }}/${{ secrets.DOCKER_IMAGE_NAME }}:latest<br>            docker run -dt --restart unless-stopped -p 443:8000 -p 8000:8000 -p 80:8000 --name ${{ secrets.DOCKER_CONTAINER_NAME }} ${{ secrets.DOCKERHUB_USERNAME }}/${{ secrets.DOCKER_IMAGE_NAME }}:latest<br>            docker image prune -</pre><p>Here is the complete workflow code:</p><pre>name: Deploy Django to GCP with Docker - Production<br>on:<br> push:<br> branches:<br> - master<br>env:<br> DATABASE_NAME: ${{ secrets.DATABASE_NAME_PRODUCTION }}<br> DATABASE_USER: ${{ secrets.DATABASE_USER_PRODUCTION }}<br> DATABASE_PASSWORD: ${{ secrets.DATABASE_PASSWORD_PRODUCTION }}<br> DATABASE_HOST: ${{ secrets.DATABASE_HOST_PRODUCTION }}<br> DATABASE_PORT: ${{ secrets.DATABASE_PORT_PRODUCTION }}<br> SECRET_KEY: ${{ secrets.SECRET_KEY }}<br> ENVIRONMENT: ${{ secrets.ENVIRONMENT }}<br><br>jobs:<br>  build:<br>    runs-on: ubuntu-latest<br>    steps:<br>      - name: Checkout repository<br>        uses: actions/checkout@v3<br><br>      - name: Set up Python<br>        uses: actions/setup-python@v3<br>        with:<br>          python-version: 3.9<br><br>      - name: Install dependencies<br>        run: |<br>          python -m pip install --upgrade pip<br>          pip install -r requirements.txt  <br><br>      - name: Run Django tests<br>        run: |<br>          python manage.py test --keepdb<br>  <br>  publish:<br>    needs: test<br>    runs-on: ubuntu-latest<br>    steps:<br>      - name: Checkout repository<br>        uses: actions/checkout@v3<br><br>      - name: Login to Docker Hub<br>        uses: docker/login-action@v1<br>        with:<br>          username: ${{ secrets.DOCKERHUB_USERNAME }}<br>          password: ${{ secrets.DOCKERHUB_TOKEN }}<br><br>      - name: Set up Docker<br>        uses: docker/setup-buildx-action@v2<br><br>      - name: Build Docker image<br>        run: |<br>          docker build \<br>            -t ${{ secrets.DOCKER_IMAGE_NAME }}:latest \<br>            --build-arg DATABASE_NAME=$DATABASE_NAME \<br>            --build-arg DATABASE_USER=$DATABASE_USER \<br>            --build-arg DATABASE_PASSWORD=$DATABASE_PASSWORD \<br>            --build-arg DATABASE_HOST=$DATABASE_HOST \<br>            --build-arg DATABASE_PORT=$DATABASE_PORT \<br>            --build-arg SECRET_KEY=$SECRET_KEY \<br>            --build-arg ENVIRONMENT=$ENVIRONMENT \<br>            . --no-cache<br><br>      - name: Tag Docker image<br>        run: docker tag ${{ secrets.DOCKER_IMAGE_NAME }}:latest ${{ secrets.DOCKERHUB_USERNAME }}/${{ secrets.DOCKER_IMAGE_NAME }}:latest<br><br>      - name: Push Docker image to Docker Hub<br>        run: docker push ${{ secrets.DOCKERHUB_USERNAME }}/${{ secrets.DOCKER_IMAGE_NAME }}:latest<br>  <br>  deploy:<br>    needs: publish<br>    runs-on: ubuntu-latest<br>    steps:<br>      - name: Set up gcloud CLI<br>        uses: google-github-actions/setup-gcloud@v0.3.0<br>        with:<br>          project_id: ${{ secrets.GCE_PROJECT_ID }}<br>          service_account_key: ${{ secrets.GCE_SA_KEY }}<br>          export_default_credentials: true<br><br>      - name: Access gcloud CLI<br>        run: |<br>          gcloud auth configure-docker<br><br>      - name: SSH into GCP instance and deploy Django<br>        uses: appleboy/ssh-action@master<br>        with:<br>          host: ${{ secrets.GCE_INSTANCE_IP }}<br>          username: ${{ secrets.GCE_SSH_USERNAME }}<br>          key: ${{ secrets.GCE_SSH_PRIVATE_KEY }}<br>          script: |<br>            docker stop ${{ secrets.DOCKER_CONTAINER_NAME }} || true<br>            docker rm ${{ secrets.DOCKER_CONTAINER_NAME }} || true<br>            docker pull ${{ secrets.DOCKERHUB_USERNAME }}/${{ secrets.DOCKER_IMAGE_NAME }}:latest<br>            docker run -dt --restart unless-stopped -p 443:8000 -p 8000:8000 -p 80:8000 --name ${{ secrets.DOCKER_CONTAINER_NAME }} ${{ secrets.DOCKERHUB_USERNAME }}/${{ secrets.DOCKER_IMAGE_NAME }}:latest<br>            docker image prune -</pre><p>Congratulations, you have successfully deployed automatically using GitHub Actions from GitHub to Google Compute Engine VM via Docker and utilizing PostgreSQL database from Supabase.</p><p>If you’re interested in connecting further with me, please visit my LinkedIn profile <a href="https://www.linkedin.com/in/eugenius-mario-s/">Eugenius Mario’s LinkedIn</a>.</p><p>Thank you and happy coding!</p><p>References:</p><ol><li><a href="https://docs.djangoproject.com/en/5.0/intro/tutorial01/">https://docs.djangoproject.com/en/5.0/intro/tutorial01/</a></li><li><a href="https://www.w3schools.com/django/django_deploy_requirements.php">https://www.w3schools.com/django/django_deploy_requirements.php</a></li><li><a href="https://pypi.org/project/python-decouple/">https://pypi.org/project/python-decouple/</a></li><li><a href="https://supabase.com/">https://supabase.com/</a></li><li><a href="https://docs.github.com/en/actions/security-guides/using-secrets-in-github-actions">https://docs.github.com/en/actions/security-guides/using-secrets-in-github-actions</a></li><li><a href="https://docs.docker.com/get-started/overview/">https://docs.docker.com/get-started/overview/</a></li><li><a href="https://hub.docker.com/">https://hub.docker.com/</a></li><li><a href="https://cloud.google.com/compute/docs">https://cloud.google.com/compute/docs</a></li><li><a href="https://cloud.google.com/compute/docs/instances/create-start-instance">https://cloud.google.com/compute/docs/instances/create-start-instance</a></li><li><a href="https://cloud.google.com/compute/docs/ip-addresses/reserve-static-external-ip-address">https://cloud.google.com/compute/docs/ip-addresses/reserve-static-external-ip-address</a></li><li><a href="https://cloud.google.com/compute/docs/connect/create-ssh-keys">https://cloud.google.com/compute/docs/connect/create-ssh-keys</a></li><li><a href="https://cloud.google.com/iam/docs/keys-create-delete">https://cloud.google.com/iam/docs/keys-create-delete</a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=662f84755c57" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Super Productive People Secret, Reset The Meaning of Life with The ‘Dopamine Detox’ Method]]></title>
            <link>https://eugeniusmario.medium.com/super-productive-people-secret-reset-the-meaning-of-life-with-the-dopamine-detox-method-22077e7a299f?source=rss-974c337fafb0------2</link>
            <guid isPermaLink="false">https://medium.com/p/22077e7a299f</guid>
            <category><![CDATA[productivity]]></category>
            <category><![CDATA[lifestyle]]></category>
            <category><![CDATA[dopamine-detox]]></category>
            <category><![CDATA[psychology]]></category>
            <category><![CDATA[self-improvement]]></category>
            <dc:creator><![CDATA[Eugenius Mario]]></dc:creator>
            <pubDate>Mon, 11 Jul 2022 16:47:39 GMT</pubDate>
            <atom:updated>2022-07-11T16:47:39.590Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PWu9c87E9MQvXDnDUQycsg.jpeg" /></figure><p>Sometimes, we feel uncertain about daily and future life. In my case, at 18 y.o. I feel anxious about my choice to take a gap year phase before I get into college. I take a gap year to prepare myself for the next step in life, and it’s all about maturity.</p><p>Before taking a gap year, I was not academically competent at school because I was sluggish with learning. I play a gadget game every time I can because it is entertaining. So, without games makes me feel frustrating. I feel bored at a particular time. I do it for myself; I call that freedom power young people, LOL.</p><p>Everything almost didn’t change until I took a gap year and found one reading about ‘Dopamine Detox.’ This thing made me realize many truths of life. I learned something new that I didn’t learn in the past.</p><p>Dopamine Detox is a method that everyone can use to prevent lousy habits. This method tells you to postpone your happiness for a moment for a bigger purpose. In my case, my joy came from my achievements in the game. Finishing checkpoints can make me feel happy, and this pushes me to do it again.</p><p>The medical world knows that the dopamine hormone is a chemical compound in the brain that plays a role in conveying stimuli throughout the body. This hormone affects various human activities, from the ability to remember to move the limbs. Dopamine is also known as the emotion control hormone. When released in the right amount, this hormone will improve mood and make people feel happier. Conversely, a lack of the hormone dopamine will make you feel bad and can even increase the risk of depression.</p><p>So, when I finish the checkpoint of my game, the dopamine hormone increases in my brain, making me feel happy. Dopamine also increases when we do activities that are fun for us, like physical exercise, reading a book, watching a film, stalking a person that we like, looks people eating, feeling loved, getting appreciation, and others. Every dopamine hormone gives us a stimulus; we feel more enthusiastic about doing an activity.</p><p>Unfortunately, when happiness comes from something less productive, it can destroy us. In my case, I am playing gadget games too much. As a result, if I am doing something normal like learning mathematics to prepare for preparing exam, it feels boring because before I do this, I could finish every checkpoint in a minute. Still, when I learn math, I feel upset because I feel stuck whenever I try to solve a problem. Dopamine hormone can’t instantly fill me like when I finish a game. The bad news is that we can’t directly increase our dopamine by doing things that we find boring.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/752/1*FJu7yocy8TUDGOWQW2dskg.jpeg" /></figure><p>‘Dopamine Detox’ method tells us to reset the little things that always give us happiness. What I mean little things in there are less productive habits like playing gadget games, scrolling social media, clicking online shop promos, watching porn, and many others. Every time we give a thumb click to our smartphone, every time dopamine fills us, this can make us feel happy with small things not crucial to our life. Even though there is a purpose bigger in life that we can lead to getting there, like in my case, my exam preparation to get into a college can make my dream come true.</p><p>We must have our own big goals, maybe be a good programmer, businessman, the wealthiest person in the world, and others. All the above require extra struggle by learning maximally at all times. If learning feels boring, we must change our mindset to not be happy at small things and delay ourselves from small steps to self-reward. Say no to distracted small rewards like getting liked by followers, getting love mail from fans, and many things that can make the dopamine increase so fast and make us forget the important thing we should do. So, our minds can renew the meaning of life.</p><p>So, do you dare to do a dopamine detox by delaying happiness for a moment for a greater purpose?</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=22077e7a299f" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>