<?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 Chinthanasandeepa on Medium]]></title>
        <description><![CDATA[Stories by Chinthanasandeepa on Medium]]></description>
        <link>https://medium.com/@chinthanasandeepa123?source=rss-3f9bda54adb1------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*b3Ph8Wa4225O4OJu</url>
            <title>Stories by Chinthanasandeepa on Medium</title>
            <link>https://medium.com/@chinthanasandeepa123?source=rss-3f9bda54adb1------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 24 Nov 2026 18:04:41 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@chinthanasandeepa123/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[Securing Web Applications: OIDC Authentication and OWASP Top 10 Vulnerability Mitigation]]></title>
            <link>https://medium.com/@chinthanasandeepa123/securing-web-applications-oidc-authentication-and-owasp-top-10-vulnerability-mitigation-07d148824a7c?source=rss-3f9bda54adb1------2</link>
            <guid isPermaLink="false">https://medium.com/p/07d148824a7c</guid>
            <dc:creator><![CDATA[Chinthanasandeepa]]></dc:creator>
            <pubDate>Thu, 27 Aug 2026 08:24:08 GMT</pubDate>
            <atom:updated>2026-08-27T08:24:08.350Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IcXbjG03Uv4xqWa_H1yTtQ.jpeg" /></figure><h3>1. Executive Summary &amp; Application Overview</h3><p>In modern web application engineering, identity management and access control form the bedrock of cybersecurity. As part of <strong>Assessment 2: Secure Web Application Development</strong>, this project enhances the <strong>Project Hall (Student Project Showcase Platform)</strong> by integrating <strong>OpenID Connect (OIDC)</strong> federated authentication, robust <strong>Role-Based Access Control (RBAC)</strong>, and comprehensive mitigations for <strong>OWASP Top 10</strong> web security vulnerabilities.</p><p>The platform caters to three primary user roles:</p><ol><li><strong>Student</strong>: Can publish projects, upload thumbnails, edit/manage <strong>only</strong> their own projects, and maintain their student profile.</li><li><strong>Recruiter</strong>: Can browse public student project showcases, view student profiles, and like projects.</li><li><strong>Admin</strong>: Owns system administrative capabilities, managing user permissions, project visibility, and platform security.</li></ol><h3>2. Authentication Protocols &amp; Implementation Strategy (OIDC / SAML)</h3><h3>2.1 OIDC Architecture &amp; Token Signature (RS256)</h3><p>Authentication was implemented using <strong>OpenID Connect (OIDC)</strong> standards, backed by asymmetric cryptography:</p><ul><li><strong>Asymmetric Signing (RS256)</strong>: Access tokens and ID tokens are digitally signed using an RSA Private Key (2048-bit) and verified across microservices using an RSA Public Key.</li><li><strong>JWKS Endpoint (</strong><strong>/api/auth/jwks.json)</strong>: Exposes JSON Web Key Sets (JWKS) allowing frontend components and third-party services to dynamically fetch public keys for token validation without sharing private secrets.</li><li><strong>OpenID Discovery (</strong><strong>/.well-known/openid-configuration)</strong>: Provides standardized metadata endpoints detailing token endpoints, userinfo endpoints, and supported algorithms.</li><li><strong>Token Claims</strong>:</li><li>sub: Unique User ID.</li><li>username: IdP-authenticated username.</li><li>email: Authenticated email address.</li><li>role: Role claim (student, recruiter, or admin).</li><li>contact_number &amp; organization_name: Profile identity claims.</li></ul><h3>2.2 Dual Auth Strategy: Cloud IdP &amp; Local OIDC Provider</h3><ul><li><strong>Cloud Identity Provider (Google OAuth2 / OIDC)</strong>: Integrates seamlessly via Passport.js Google Strategy for enterprise single sign-on (SSO).</li><li><strong>Local Passwordless Magic OTP &amp; Password OIDC Server</strong>: Supports fallback passwordless OTP links (5-minute expiration) and PBKDF2 password hashing (SHA-512 with random 16-byte salt).</li></ul><h3>3. Fine-Grained Access Control &amp; RBAC</h3><p>Access control is strictly enforced on both API routes and data retrieval queries based on the verified JWT access token:</p><h3>3.1 Token Validation Middleware (authenticateToken)</h3><p>Every protected request extracts the access_token from HTTP-Only cookies or the Authorization: Bearer &lt;token&gt; header. The token&#39;s signature, expiration, issuer (JWT_ISSUER), and audience (JWT_AUDIENCE) are validated before attaching req.user.</p><h3>3.2 IDOR &amp; Ownership Validation (requireProjectOwnership)</h3><p>To prevent <strong>Insecure Direct Object References (IDOR)</strong>:</p><ul><li>Students creating or updating projects pass through requireProjectOwnership middleware, verifying that project.created_by === req.user.sub unless the user possesses the admin role.</li></ul><h3>4. OWASP Top 10 Security Mitigations</h3><h3>4.1 A01: Broken Access Control</h3><ul><li><strong>Mitigation</strong>: Implemented explicit backend role checks (requireRole) and IDOR ownership verification on every state-changing endpoint. Prevented horizontal privilege escalation.</li></ul><h3>4.2 A03: Injection (SQL Injection)</h3><ul><li><strong>Mitigation</strong>: Replaced raw string concatenation with <strong>Knex.js parameterized query builders</strong> and prepared statements across all database transactions. User inputs are bound as parameter arguments rather than inline SQL literals.</li></ul><h3>4.3 A07: Identification &amp; Authentication Failures</h3><ul><li><strong>Mitigation</strong>:</li><li>Password hashes use <strong>PBKDF2</strong> with 1,000 iterations and unique cryptographic salts.</li><li>Refresh tokens are stored in the database with strict revocation flags (revoked_at).</li><li>Session cookies enforce HttpOnly, SameSite=Lax, and 15-minute access token lifetimes.</li></ul><h3>4.4 A05: Security Misconfiguration &amp; XSS</h3><ul><li><strong>Mitigation</strong>:</li><li>Implemented global HTTP Security Headers: X-Frame-Options: DENY, X-Content-Type-Options: nosniff, X-XSS-Protection: 1; mode=block, Content-Security-Policy (CSP).</li><li>Added input sanitization middleware (sanitizeInput) escaping HTML entities (&lt;, &gt;, &quot;, &#39;, /) prior to processing request payloads.</li></ul><h3>5. Learning Outcomes &amp; Key Takeaways</h3><p>Through this assessment, I gained practical hands-on experience in:</p><ul><li>Designing and deploying <strong>OIDC-compliant authentication architectures</strong>.</li><li>Building <strong>defense-in-depth security mechanisms</strong> against OWASP Top 10 vulnerabilities.</li><li>Enforcing <strong>cryptographic integrity</strong> using RS256 JWT tokens and HTTP-Only security cookies.</li><li>Developing clean, responsive, and secure role-tailored user interfaces with React and Express.</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=07d148824a7c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Stop Writing Messy Automation Scripts: A Guide to SOLID Principles & Design Patterns]]></title>
            <link>https://medium.com/@chinthanasandeepa123/stop-writing-messy-automation-scripts-a-guide-to-solid-principles-design-patterns-42ccf2d1db59?source=rss-3f9bda54adb1------2</link>
            <guid isPermaLink="false">https://medium.com/p/42ccf2d1db59</guid>
            <dc:creator><![CDATA[Chinthanasandeepa]]></dc:creator>
            <pubDate>Mon, 06 Jul 2026 05:50:19 GMT</pubDate>
            <atom:updated>2026-07-06T05:50:19.876Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mTTQkYMmJZutrSWfHPSZcw.jpeg" /></figure><h3>The Problem with Monolithic Automation</h3><p>Developers often cram database connections, data transformations, and reporting logic into a single, monolithic automation script. While this procedural “spaghetti code” works initially, it introduces severe technical debt. As systems scale, these scripts become brittle and nearly impossible to maintain.</p><p>To architect enterprise-grade automation, we must treat our scripts with the same rigor as our core application code using <strong>SOLID principles</strong> and <strong>Design Patterns</strong>.</p><h3>1. Single Responsibility Principle (SRP)</h3><p><strong>The Concept:</strong> A class should have only one reason to change, focusing on a single business capability.</p><p><strong>The Fix:</strong> Instead of a massive script that queries databases and sends emails, decouple your architecture into purpose-built classes.</p><p>Java</p><pre>// Focuses strictly on external communication<br>public class AlertDispatcher {<br>    public void dispatch(String recipient, String payload) { /* SMTP/API logic */ }<br>}<br><br>// Focuses strictly on data extraction<br>public class MetricsExtractor {<br>    public Data retrieveMetrics() { /* Database logic */ return new Data(); }<br>}</pre><h3>2. Open/Closed Principle (OCP) via the Strategy Pattern</h3><p><strong>The Concept:</strong> Software entities should be open for extension but closed for modification.</p><p><strong>The Fix:</strong> Avoid complex if-else chains. Use the <strong>Strategy Pattern</strong> to encapsulate behaviors behind a common interface. For example, you can add new alert methods (Email, Slack, Webhooks) without ever altering the core automation logic.</p><p>Java</p><pre>public interface NotificationStrategy {<br>    void execute(String alertMessage);<br>}<br><br>public class EmailNotification implements NotificationStrategy {<br>    public void execute(String alertMessage) { /* Email logic */ }<br>}<br><br>// The core automation service remains completely untouched when adding new strategies!<br>public class IncidentAutomation {<br>    private final NotificationStrategy strategy;<br><br>    public IncidentAutomation(NotificationStrategy strategy) {<br>        this.strategy = strategy;<br>    }<br><br>    public void triggerIncident(String alertMessage) {<br>        strategy.execute(alertMessage);<br>    }<br>}</pre><h3>3. Dependency Inversion (DIP) via the Factory Pattern</h3><p><strong>The Concept:</strong> High-level modules should depend on abstractions, not low-level implementation details.</p><p><strong>The Fix:</strong> In UI automation, abstract the creation of components (like WebDrivers) using a <strong>Factory Pattern</strong>. Your main scripts should never hardcode specific browsers.</p><p>Java</p><pre>public interface WebDriver {<br>    void initialize();<br>}<br><br>public class ChromeDriver implements WebDriver {<br>    public void initialize() { System.out.println(&quot;Starting Chrome...&quot;); }<br>}<br><br>// High-level scripts call the Factory, keeping dependencies inverted<br>public class WebDriverFactory {<br>    public static WebDriver createDriver(String browser) {<br>        return switch (browser.toUpperCase()) {<br>            case &quot;CHROME&quot; -&gt; new ChromeDriver();<br>            case &quot;FIREFOX&quot; -&gt; new FirefoxDriver();<br>            default -&gt; throw new IllegalArgumentException(&quot;Unsupported&quot;);<br>        };<br>    }<br>}</pre><h3>The Business Value</h3><p>Treating automation as first-class software yields massive dividends:</p><ul><li><strong>Extensibility:</strong> Integrate new features or endpoints in minutes, not days.</li><li><strong>High-Fidelity Testing:</strong> Decoupled components allow for aggressive unit testing.</li><li><strong>Reduced Overhead:</strong> Clean, self-documenting code drastically reduces debugging time.</li></ul><p>Treat your automation codebase with architectural respect — it is the backbone of modern engineering.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=42ccf2d1db59" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[From Localhost to Production: A Complete Deployment Guide for Full-Stack Applications]]></title>
            <link>https://medium.com/@chinthanasandeepa123/from-localhost-to-production-a-complete-deployment-guide-for-full-stack-applications-b8e81c45c5ff?source=rss-3f9bda54adb1------2</link>
            <guid isPermaLink="false">https://medium.com/p/b8e81c45c5ff</guid>
            <dc:creator><![CDATA[Chinthanasandeepa]]></dc:creator>
            <pubDate>Wed, 03 Jun 2026 12:04:04 GMT</pubDate>
            <atom:updated>2026-06-03T12:04:04.244Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*28otfnHp6K-zU07qiY3uIg.png" /></figure><h3>Introduction</h3><p>Building a full-stack application on your local machine is an exciting achievement. Everything works perfectly on localhost, your APIs respond correctly, and your database stores data without issues. However, deploying that same application to production introduces a new set of challenges.</p><p>Many developers discover that an application running flawlessly in development can fail in production due to environment configuration issues, database connectivity problems, server misconfigurations, or deployment-related errors.</p><p>This guide walks through the complete deployment process for modern full-stack applications, covering hosting platforms, environment variables, production builds, databases, domains, SSL certificates, and common deployment issues.</p><h3>Understanding the Deployment Process</h3><p>Deployment is the process of making your application accessible to users over the internet.</p><p>A typical full-stack application consists of:</p><ul><li>Frontend (React, Angular, Vue, Next.js)</li><li>Backend (Node.js, Express, Spring Boot, Laravel, Django)</li><li>Database (MongoDB, MySQL, PostgreSQL)</li><li>Hosting Infrastructure</li><li>Domain and SSL Certificate</li></ul><p>Before deployment, all these components run locally on your machine. In production, they must work together across different servers and services.</p><h3>Preparing Your Application for Production</h3><p>Before deploying, ensure that your application is production-ready.</p><h3>Remove Hardcoded Values</h3><p>Avoid hardcoding:</p><ul><li>API URLs</li><li>Database credentials</li><li>Secret keys</li><li>JWT secrets</li><li>Third-party API keys</li></ul><p>Bad Example:</p><pre>const apiUrl = &quot;http://localhost:5000&quot;;</pre><p>Good Example:</p><pre>const apiUrl = process.env.REACT_APP_API_URL;</pre><p>This allows your application to use different configurations in different environments.</p><h3>Managing Environment Variables</h3><p>Environment variables store sensitive and environment-specific configuration values.</p><p>Example:</p><pre>PORT=5000<br>MONGODB_URI=your_database_connection_string<br>JWT_SECRET=your_secret_key</pre><p>Benefits:</p><ul><li>Improved security</li><li>Easier configuration management</li><li>Better scalability</li></ul><p>Never commit .env files to public repositories.</p><p>Always include:</p><pre>.env</pre><p>in your .gitignore file.</p><h3>Building the Frontend for Production</h3><p>Development builds are optimized for debugging, not performance.</p><p>For React applications:</p><pre>npm run build</pre><p>This command:</p><ul><li>Minifies JavaScript</li><li>Optimizes assets</li><li>Reduces file size</li><li>Improves performance</li></ul><p>The generated build folder contains the production-ready application.</p><h3>Choosing a Hosting Platform</h3><p>Several hosting platforms simplify deployment.</p><h3>Frontend Hosting</h3><p>Popular options include:</p><ul><li>Vercel</li><li>Netlify</li><li>GitHub Pages</li><li>Cloudflare Pages</li></ul><p>These platforms provide:</p><ul><li>Automated deployments</li><li>Free SSL certificates</li><li>Global CDN support</li><li>Custom domain integration</li></ul><h3>Backend Hosting</h3><p>Common choices include:</p><ul><li>Render</li><li>Railway</li><li>Fly.io</li><li>AWS</li><li>DigitalOcean</li></ul><p>Choose a platform based on:</p><ul><li>Scalability requirements</li><li>Budget</li><li>Performance needs</li><li>Team experience</li></ul><h3>Deploying the Database</h3><p>Never use a local database in production.</p><p>Cloud database providers include:</p><h3>MongoDB</h3><p>MongoDB Atlas provides:</p><ul><li>Cloud-hosted clusters</li><li>Automated backups</li><li>Security controls</li><li>Global deployment options</li></ul><h3>SQL Databases</h3><p>Options include:</p><ul><li>PostgreSQL</li><li>MySQL</li><li>PlanetScale</li><li>Supabase</li></ul><p>Always restrict database access using:</p><ul><li>Strong passwords</li><li>Network restrictions</li><li>Role-based permissions</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/347/0*WQJ3klHDfs7Kzl3n" /></figure><h3>Connecting Frontend and Backend</h3><p>One of the most common deployment issues occurs when the frontend cannot communicate with the backend.</p><p>Example Production API URL:</p><pre>https://api.myapp.com</pre><p>Update API requests to use production endpoints instead of localhost.</p><p>Incorrect:</p><pre>http://localhost:5000/api/users</pre><p>Correct:</p><pre>https://api.myapp.com/api/users</pre><h3>Configuring CORS</h3><p>Cross-Origin Resource Sharing (CORS) controls which domains can access your backend.</p><p>Example:</p><pre>app.use(<br>  cors({<br>    origin: &quot;https://myapp.com&quot;<br>  })<br>);</pre><p>Without proper CORS configuration, API requests may fail even when the server is running correctly.</p><h3>Setting Up a Custom Domain</h3><p>A custom domain improves professionalism and brand recognition.</p><p>Examples:</p><ul><li>myapp.com</li><li>api.myapp.com</li></ul><p>Steps:</p><ol><li>Purchase a domain.</li><li>Configure DNS records.</li><li>Point the domain to your hosting provider.</li><li>Verify ownership.</li></ol><p>Most hosting platforms provide detailed instructions for domain configuration.</p><h3>Enabling SSL Certificates</h3><p>SSL encrypts communication between users and your application.</p><p>Benefits:</p><ul><li>Secure data transmission</li><li>Improved trust</li><li>Better search engine rankings</li><li>Browser security compliance</li></ul><p>Always use HTTPS in production.</p><p>Most modern hosting providers automatically issue SSL certificates.</p><h3>Automating Deployments with CI/CD</h3><p>Continuous Integration and Continuous Deployment (CI/CD) automate the deployment process.</p><p>Workflow:</p><ol><li>Push code to GitHub.</li><li>Run automated tests.</li><li>Build the application.</li><li>Deploy automatically.</li></ol><p>Benefits:</p><ul><li>Faster releases</li><li>Reduced human errors</li><li>Consistent deployments</li><li>Improved reliability</li></ul><p>Popular CI/CD tools include GitHub Actions, GitLab CI/CD, and Jenkins.</p><h3>Common Deployment Problems</h3><h3>Environment Variables Not Loading</h3><p>Cause:</p><ul><li>Missing variables on the hosting platform.</li></ul><p>Solution:</p><ul><li>Verify all required variables are configured.</li></ul><h3>Database Connection Errors</h3><p>Cause:</p><ul><li>Incorrect connection string.</li><li>Database IP restrictions.</li></ul><p>Solution:</p><ul><li>Validate credentials and network settings.</li></ul><h3>Build Failures</h3><p>Cause:</p><ul><li>Dependency conflicts.</li><li>Version mismatches.</li></ul><p>Solution:</p><ul><li>Lock package versions and test builds locally.</li></ul><h3>CORS Errors</h3><p>Cause:</p><ul><li>Backend rejecting frontend requests.</li></ul><p>Solution:</p><ul><li>Configure allowed origins correctly.</li></ul><h3>Application Works Locally but Not in Production</h3><p>Cause:</p><ul><li>Hidden assumptions about the local environment.</li></ul><p>Solution:</p><ul><li>Test using production-like environments before deployment.</li></ul><h3>Monitoring and Maintenance</h3><p>Deployment is not the end of the journey.</p><p>Monitor:</p><ul><li>Server performance</li><li>Application logs</li><li>Error rate</li><li>Database health</li><li>Security vulnerabilities</li></ul><p>Popular monitoring tools:</p><ul><li>Grafana</li><li>Prometheus</li><li>Sentry</li><li>New Relic</li></ul><p>Regular monitoring helps identify issues before users are affected.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/310/0*uwjFdJYXLdhjS8n1" /></figure><h3>Conclusion</h3><p>Deploying a full-stack application involves much more than uploading code to a server. Success requires proper configuration, secure environment management, database deployment, domain setup, SSL configuration, and ongoing monitoring.</p><p>By following deployment best practices, developers can confidently move applications from localhost to production and provide users with reliable, secure, and scalable software experiences.</p><p>The transition from development to production may seem challenging at first, but mastering deployment is one of the most valuable skills in modern software engineering.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b8e81c45c5ff" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Microservices vs Monolith: What You Should Actually Choose in 2026]]></title>
            <link>https://medium.com/@chinthanasandeepa123/microservices-vs-monolith-what-you-should-actually-choose-in-2026-3cebc391ec84?source=rss-3f9bda54adb1------2</link>
            <guid isPermaLink="false">https://medium.com/p/3cebc391ec84</guid>
            <dc:creator><![CDATA[Chinthanasandeepa]]></dc:creator>
            <pubDate>Thu, 07 May 2026 18:52:24 GMT</pubDate>
            <atom:updated>2026-05-07T19:23:55.899Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/300/1*hxo6Jk3LMlotGxD1s7_U5A.jpeg" /></figure><p>In 2021, if you proposed a Monolith for a new project, you were viewed as a dinosaur. In 2026, if you propose Microservices for a seed-stage startup, you’re viewed as a liability.</p><p>The pendulum has finally swung back to center. We’ve moved past the “Netflix-envy” phase of software engineering and entered an era of <strong>Architectural Realism</strong>. We’ve realized that while microservices solve for <em>scale</em>, they introduce a level of operational tax that most teams simply cannot afford to pay.</p><p>If you are making an architectural decision today, here is the ground truth.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/293/0*I_dooM1s2ar3pDGU" /></figure><h3>1. The Great Consolidation of 2026</h3><p>The industry has experienced what many are calling “The Great Consolidation.” Major players — including some of the original microservices pioneers — have spent the last two years merging fragmented services back into larger, more manageable units.</p><p><strong>Why? Because complexity is a silent killer.</strong></p><ul><li><strong>The “Distributed Monolith” Trap:</strong> Most teams didn’t actually build microservices; they built a monolith connected by slow, unreliable network calls.</li><li><strong>Operational Tax:</strong> In 2026, cloud costs are higher than ever. Running 50 containers for a simple CRUD app isn’t just “over-engineering” — it’s a financial drain.</li><li><strong>Cognitive Load:</strong> Developers are tired of needing 15 tabs open just to trace a single request from the gateway to the database.</li></ul><h3>2. The 2026 Winner: The Modular Monolith</h3><p>If you want the “Senior Developer” choice for 90% of use cases, this is it. The Modular Monolith is the sweet spot between the “Big Ball of Mud” and the “Distributed Nightmare.”<strong><em>The Concept:</em></strong><em> You build a single deployment unit (one binary, one container), but you enforce strict domain boundaries within the code.</em></p><p><strong>Why it’s the superior choice today:</strong></p><ul><li><strong>Local Performance:</strong> No network latency between modules. Function calls are nanoseconds, not milliseconds.</li><li><strong>Simplified Refactoring:</strong> If you realize two modules should actually be one, it’s a simple IDE refactor, not a multi-week infrastructure project.</li><li><strong>Single-Step Deployment:</strong> Your CI/CD pipeline stays fast, predictable, and cheap.</li></ul><h3>3. When are Microservices Still the Right Choice?</h3><p>Despite the pushback, Microservices are not “dead.” They are simply specialized tools for specialized problems. You should only opt for a distributed architecture in 2026 if you hit one of the <strong>Three Hard Limits</strong>:</p><p><strong>LimitDescriptionThe Team Limit</strong>You have 10+ independent teams who are constantly stepping on each other’s toes in the same codebase.<strong>The Scaling Limit</strong>One specific part of your app (e.g., high-load image processing) needs 100x more resources than the rest of the system.<strong>The Language Limit</strong>You need to use vastly different tech stacks (e.g., a Python ML module alongside a Spring Boot core).</p><h3>4. The Decision Matrix</h3><p>To help you choose, ask yourself these three questions:</p><ol><li><strong>Do we have a dedicated Platform/DevOps team?</strong></li></ol><ul><li>No? <strong>Build a Monolith.</strong></li></ul><p><strong>2.Does our business logic fit in a single person’s head</strong></p><ul><li>Yes? <strong>Build a Monolith.</strong></li></ul><p><strong>3.Are we still finding “Product-Market Fit”?</strong></p><ul><li>Yes? <strong>Build a Monolith.</strong> Pivoting a microservices architecture is like trying to turn an aircraft carrier in a bathtub.</li></ul><h3>5. The “Extract-on-Demand” Strategy</h3><p>The smartest engineers in 2026 follow a simple rule: <strong>Start Monolithic, Design Modularly, Extract Incrementally.</strong></p><p>Write your code as if it <em>could</em> be a microservice tomorrow. Keep your data isolated by domain. Use internal events instead of tight coupling. When — and only when — a specific module becomes a bottleneck or a scaling nightmare, <em>then</em> you carve it out into its own service.</p><h3>Final Verdict</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/305/0*fQc4hKkO0egE21yJ" /></figure><p>In 2026, “Production-Ready” means <strong>sustainable</strong>.</p><p>Don’t let the ghost of 2018’s hype cycle dictate your architecture. Choose the Monolith until the pain of staying together is greater than the pain of being apart. Your infrastructure bill, your debugging sessions, and your sanity will thank you.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3cebc391ec84" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Stop Confusing REST API and RESTful API]]></title>
            <link>https://medium.com/@chinthanasandeepa123/stop-confusing-rest-api-and-restful-api-8027b4023bf4?source=rss-3f9bda54adb1------2</link>
            <guid isPermaLink="false">https://medium.com/p/8027b4023bf4</guid>
            <category><![CDATA[rest-api]]></category>
            <dc:creator><![CDATA[Chinthanasandeepa]]></dc:creator>
            <pubDate>Sun, 26 Apr 2026 12:21:49 GMT</pubDate>
            <atom:updated>2026-04-26T12:21:49.570Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cKEgKSGvmw7Dt1uFpSS1oQ.png" /></figure><h3>Introduction</h3><p>In modern software development, the terms REST API and RESTful API are often used interchangeably. While they are closely related, they do not mean exactly the same thing.</p><p><strong><em>Understanding the distinction is important — not only for technical interviews but also for designing clean, scalable, and maintainable systems.</em></strong></p><p>This article clarifies the difference with practical examples and clear explanations.</p><h3>What is REST?</h3><p>REST (Representational State Transfer) is an architectural style introduced by Roy Fielding. It defines a set of constraints for designing networked applications.</p><p>REST is not a protocol or a tool. Instead, it provides guidelines for how systems should communicate over HTTP.</p><h3>What is a REST API?</h3><p>A REST API is an API that follows the principles of REST to some extent. It typically:</p><ul><li>Uses HTTP methods such as GET, POST, PUT, and DELETE</li><li>Communicates over HTTP/HTTPS</li><li>Transfers data, commonly in JSON format</li></ul><p>However, not all REST APIs strictly adhere to every REST constraint. In practice, many APIs labeled as “REST” implement only a subset of these principles.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/362/0*7BuTKTxGFE2eNAMq" /></figure><h3>What is a RESTful API?</h3><p>A RESTful API is a REST API that fully complies with REST architectural constraints. It emphasizes:</p><ul><li>Resource-oriented design</li><li>Proper use of HTTP methods</li><li>Stateless communication</li><li>Consistent and predictable URL structures</li></ul><p>In other words, a RESTful API represents a more disciplined and standardized implementation of REST.</p><h3>Design Example</h3><h3>Non-RESTful API Design</h3><pre>GET /getUsers<br>POST /createUser<br>DELETE /deleteUser</pre><p><strong>Issues:</strong></p><ul><li>Uses verbs in endpoints</li><li>Lacks resource-based structure</li><li>Harder to scale and maintain</li></ul><h3>RESTful API Design</h3><pre>GET    /users<br>POST   /users<br>PUT    /users/1<br>DELETE /users/1</pre><p><strong>Advantages:</strong></p><ul><li>Clean and intuitive structure</li><li>Aligns with HTTP semantics</li><li>Easier for developers to understand and extend</li></ul><h3>Core REST Constraints</h3><p>A truly RESTful API adheres to the following constraints:</p><h4>1. Statelessness</h4><p>Each request from the client must contain all the information required to process it. The server does not store client context between requests.</p><h4>2. Resource Identification</h4><p>Resources are identified using URIs (e.g., /users, /products).</p><h4>3. Uniform Interface</h4><p>A consistent and standardized way of interacting with resources using HTTP methods.</p><h4>4. Client-Server Separation</h4><p>The client and server operate independently, enabling scalability and flexibility.</p><h3>Why the Difference Matters</h3><p>The distinction between REST API and RESTful API is not purely academic. It has practical implications:</p><ul><li><strong>Maintainability:</strong> Clean APIs are easier to manage and extend</li><li><strong>Scalability:</strong> Proper design supports growth</li><li><strong>Collaboration:</strong> Consistent APIs improve team productivity</li><li><strong>Interoperability:</strong> Standardized interfaces are easier to integrate</li></ul><h3>Common Misconceptions</h3><ul><li>“All REST APIs are RESTful” — Not necessarily</li><li>“Using JSON makes an API RESTful” — Incorrect</li><li>“HTTP alone defines REST” — Incomplete understanding</li></ul><h3>Industry Perspective</h3><p>Many organizations follow standard API guidelines to ensure quality and consistency. For example, Microsoft recommends:</p><ul><li>Using resource-based URLs (e.g., /users)</li><li>Applying correct HTTP methods</li><li>Keeping APIs consistent and easy to understand</li></ul><p>You can explore their guidelines here:<br><a href="https://github.com/microsoft/api-guidelines">https://github.com/microsoft/api-guidelines</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*hywvlJ-V1o8FFTd-.png" /></figure><h3>Conclusion</h3><p>A REST API refers broadly to APIs that use REST principles, while a RESTful API strictly adheres to those principles.</p><p>In practice, developers should aim to design RESTful APIs to ensure clarity, consistency, and scalability.</p><h3>Final Thought</h3><p>Good API design is not just about functionality — it is about structure, clarity, and long-term maintainability.</p><p>Understanding and applying RESTful principles is a key step toward becoming a professional software engineer.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8027b4023bf4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[A Complete Guide to Nodemon in Node.js Development]]></title>
            <link>https://medium.com/@chinthanasandeepa123/a-complete-guide-to-nodemon-in-node-js-development-88f428635c97?source=rss-3f9bda54adb1------2</link>
            <guid isPermaLink="false">https://medium.com/p/88f428635c97</guid>
            <dc:creator><![CDATA[Chinthanasandeepa]]></dc:creator>
            <pubDate>Sun, 29 Mar 2026 17:47:15 GMT</pubDate>
            <atom:updated>2026-03-29T17:47:15.894Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*43uEAPJU9qNbufC8.png" /></figure><h3><strong>What is Nodemon?</strong></h3><p>Nodemon is a command-line tool that automatically restarts your application when you make changes to your code. It watches your project files and refreshes the server whenever something is updated.</p><p>Instead of running your app using node, you can use nodemon. This saves time because you don’t need to restart the server manually.</p><p>Nodemon does not require any changes to your existing code. It works mainly with Node.js applications but can also run other scripts like Python.</p><h3><strong>Why Use Nodemon?</strong></h3><p>Nodemon is used to make development faster and easier by automatically restarting your application whenever you make changes to your code. Instead of stopping and starting the server manually, Nodemon handles it for you, saving time and effort.</p><p>It is very easy to use just replace node with nodemon when running your program. Overall, Nodemon helps developers focus more on coding and improves productivity by reducing repetitive tasks.</p><h3>Installing Nodemon</h3><p>You can install Nodemon globally or locally.</p><p>Global Installation (Recommended)</p><pre>npm install -g nodemon</pre><p>Local Installation</p><pre>npm install --save-dev nodemon</pre><h3>How to Use Nodemon</h3><p>Instead of running your app with:</p><pre>node app.js</pre><p>Use:</p><pre>nodemon app.js</pre><p>Now, whenever you save changes in your project files, Nodemon will automatically restart the server.</p><h3>Example</h3><h4>app.js</h4><pre>const express = require(&#39;express&#39;);<br>const app = express();</pre><pre>app.get(&#39;/&#39;, (req, res) =&gt; {<br>    res.send(&quot;Hello from Nodemon!&quot;);<br>});</pre><pre>app.listen(3000, () =&gt; {<br>    console.log(&quot;Server running on port 3000&quot;);<br>});</pre><p>Run the app:</p><pre>nodemon app.js</pre><p>In this example, we create a simple server using Express. When a user visits the home page (/), the server shows the message &quot;Hello from Nodemon!&quot;. The app runs on port 3000.</p><p>We run the app using nodemon app.js. Nodemon will watch the file for changes. If you edit the message and save the file, Nodemon will automatically restart the server.</p><p>After refreshing the browser, you will see the updated message without restarting the server manually.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/275/0*okHoIk1KIJvSZX9X" /></figure><h3>Advantages of Nodemon</h3><p>Nodemon offers several advantages that make development easier and more efficient. It saves time by automatically restarting the application whenever changes are made, reducing the need for manual restarts. This helps minimize repetitive tasks and improves the overall workflow. Nodemon is also easy to use, as developers only need to replace node with nodemon. Additionally, it is lightweight, supports configuration, and can work with different file types. These features make Nodemon a useful and reliable tool for developers.</p><h3>Conclusion</h3><p>Nodemon is a very useful tool for Node.js developers that makes development faster and easier. It automatically restarts the application whenever changes are made, saving time and reducing manual work. With its simple setup and easy usage, Nodemon helps developers focus more on coding and improving their applications. Overall, it is an essential tool for a smooth and efficient development workflow.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=88f428635c97" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Create a Simple operating system]]></title>
            <link>https://medium.com/@chinthanasandeepa123/create-a-simple-operating-system-2eead9a6b3d5?source=rss-3f9bda54adb1------2</link>
            <guid isPermaLink="false">https://medium.com/p/2eead9a6b3d5</guid>
            <dc:creator><![CDATA[Chinthanasandeepa]]></dc:creator>
            <pubDate>Tue, 24 Jun 2025 09:04:12 GMT</pubDate>
            <atom:updated>2025-06-24T09:17:17.595Z</atom:updated>
            <content:encoded><![CDATA[<p>Repository Link:<a href="https://github.com/Chinthana1234/Chin-Os.git">https://github.com/Chinthana1234/Chin-Os.git</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/660/0*Cmyu9_zrFcsW4Pl1.jpeg" /></figure><h3>Overview</h3><p>chinOS is a lightweight operating system built from scratch using x86 assembly. It demonstrates core OS concepts including bootloading, hardware detection, and a basic command-line interface .</p><h3>Key Components</h3><ol><li>512-byte Bootloader</li></ol><ul><li>Loads the kernel from disk using FAT12</li><li>Handles BIOS interrupts for disk operations</li><li>Transfers control to the kernel at 2000h:0000h</li></ul><p>2. Kernel Features</p><ul><li>CLI with commands: info, help, clear, mkdir, ls</li><li>Hardware detection: CPU, memory, drives, mouse</li><li>Pseudo-filesystem: Directory creation/listing (8 dir max)</li></ul><p>3.Build System</p><pre>sudo ./build-linux.sh &amp;&amp; sudo ./test-linux.sh</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/716/1*KCW4Kq6Zd_WJtKvDbIMGpQ.png" /></figure><h3>Technical Highlights</h3><ul><li>Memory Detection<br>Uses int 12h (conventional) and int 15h (extended)<br>Supports legacy BIOS and E801h methods</li><li>CPU Identification<br>Leverages CPUID for vendor string and features (FPU/MMX/SSE)</li><li>Compact Design<br>Kernel fits in ~8KB<br>Bootloader strictly adheres to 512-byte limit</li></ul><h3>Challenges Overcome</h3><ul><li>Disk I/O errors → Implemented floppy reset routine</li><li>Limited space → Optimized string handling</li><li>Hardware variety → Fallback detection methods</li></ul><h3>Quickstart</h3><ol><li>Assemble with NASM</li><li>Write to floppy image</li><li>Test in emulator:</li></ol><p><strong>qemu-system-i386 -fda chinOS.flp</strong></p><h3>References</h3><p><a href="https://medium.com/setublog/hands-on-to-operating-systems-a847e9dc75f7">https://medium.com/setublog/hands-on-to-operating-systems-a847e9dc75f7</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2eead9a6b3d5" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>