SDLC

SDLC Notes

779

SDLC

Tech

The structure of this document goes like this: <ol>1. Introduction to SDLC <li>Definition of SDLC</li> <li>Importance of SDLC in software development</li> <li>Phases of SDLC</li> </ol> <ol>2. Phases of SDLC <li>Requirements Gathering</li> <li>System Design</li> <li>Implementation/Coding</li> <li>Testing</li> <li>Deployment</li> <li>Maintenance</li> </ol> <ol>3. Different Types of Testing <li>Unit Testing</li> <li>Integration Testing</li> <li>System Testing</li> <li>Acceptance Testing</li> </ol> <ol>4. Defect Life Cycle <li>Definition of a defect</li> <li>Stages in the defect life cycle</li> </ol> <ol>5. Comparison between SDLC and STLC <li>Definitions</li> <li>Phases</li> <li>Objectives</li> </ol> <b>1. Introduction to SDLC</b> SDLC stands for Software Development Life Cycle, which is a structured process for developing software applications. It involves a series of phases that lead to the creation, deployment, and maintenance of software. Different types of SDLC models: Waterfall Model: The Waterfall model is a linear and sequential approach to software development, where each phase must be completed before moving to the next. Phases: Requirements, Design, Implementation, Testing, Deployment, Maintenance. Characteristics: Emphasizes thorough planning and documentation upfront, suitable for projects with stable and well-understood requirements. Iterative Model: The Iterative model breaks down the development process into smaller iterations or cycles, each involving the repetition of the Waterfall model's phases. Phases: Requirements, Design, Implementation, Testing. Characteristics: Allows for feedback and adjustments between iterations, enabling incremental development and delivery of functionality. Incremental Model: The Incremental model divides the project into multiple increments or releases, with each increment delivering a portion of the functionality. Phases: Planning, Requirements, Design, Implementation, Testing, Deployment. Characteristics: Each increment builds upon the previous one, allowing for early delivery of key features and progressive elaboration of requirements. Spiral Model: The Spiral model combines the iterative and incremental approach with risk management, incorporating multiple cycles of development and risk analysis. Phases: Planning, Risk Analysis, Engineering (Requirements, Design, Implementation, Testing), Evaluation. Characteristics: Iteratively builds prototypes, identifies and mitigates risks at each cycle, suitable for projects with high levels of uncertainty or complexity. V-Model: The V-Model is an extension of the Waterfall model that emphasizes testing at each stage of the development process, with testing phases mirroring the corresponding development phases. Phases: Requirements, Design, Implementation, Testing (Unit Testing, Integration Testing, System Testing, Acceptance Testing). Characteristics: Enhances quality by validating requirements and designs early, minimizes defects through comprehensive testing. Agile Model: Agile methodologies, such as Scrum, Kanban, and Extreme Programming (XP), prioritize flexibility, collaboration, and responsiveness to change. Phases: Iterative cycles (Sprints), including Planning, Development, Testing, Review, and Retrospective. Characteristics: Emphasizes iterative and incremental development, customer collaboration, and rapid delivery of working software. DevOps Model: DevOps is not a traditional SDLC model but rather a cultural and organizational approach that emphasizes collaboration between development and operations teams to enable continuous integration, delivery, and deployment of software. Characteristics: Integrates development, operations, and quality assurance practices, promotes automation, continuous feedback, and rapid deployment. <b>2. Phases of SDLC</b> a. Requirements Gathering: Involves gathering and analyzing the requirements from stakeholders. Deliverables include requirements documents, user stories, and use cases. b. System Design: Involves creating a high-level design of the system architecture based on the gathered requirements. Deliverables include system architecture diagrams, database schemas, and interface designs. c. Implementation/Coding: Involves translating the design into code. Developers write code based on the design specifications. d. Testing: Involves testing the software for defects and ensuring it meets the specified requirements. Various types of testing are performed (unit testing, integration testing, system testing, acceptance testing). e. Deployment: Involves deploying the software to the production environment. This phase includes installation, configuration, and training. f. Maintenance: Involves maintaining and supporting the software post-deployment. This phase includes bug fixes, updates, and enhancements. <b>3. Different Types of Testing</b> a. Unit Testing: Testing individual units or components of the software in isolation. Typically performed by developers. Aim is to ensure that each unit works correctly as per the design specifications. Tools commonly used: JUnit, NUnit, Mockito. b. Integration Testing: Testing the integration or interaction between different units/modules of the software. Aim is to verify that the integrated units function together as expected. Helps identify interface defects and communication issues. Tools commonly used: Selenium, SoapUI, Postman. c. System Testing: Testing the entire system as a whole. Aim is to validate the system against the specified requirements. Tests functionalities, performance, security, and other non-functional aspects. Tools commonly used: Selenium, JMeter, LoadRunner. d. Acceptance Testing: Testing the software from the end-user's perspective. Aim is to ensure that the software meets the user's requirements and expectations. Includes User Acceptance Testing (UAT) performed by the end-users. Tools commonly used: Cucumber, Selenium, TestComplete. Continuous Integration/Continuous Deployment (CI/CD): Continuous Integration (CI): CI is a software development practice where team members integrate their work frequently, usually multiple times per day. Each integration is verified by an automated build (including test) to detect integration errors as quickly as possible. Key principles of CI include automating the build process, testing code in a clone of the production environment, and committing code changes frequently to version control repositories. CI helps identify and address integration issues early in the development cycle, leading to improved software quality and faster delivery of features. Tools commonly used for CI: Jenkins, Travis CI, CircleCI, GitLab CI. Continuous Deployment (CD): CD is an extension of CI where every code change that passes automated testing is automatically deployed to production. CD aims to automate the entire software release process, from code commit to deployment, with minimal human intervention. Key principles of CD include deploying small, incremental changes, monitoring the production environment closely, and rolling back changes automatically if issues arise. CD helps reduce the time between code commit and production deployment, enabling teams to release new features and updates more frequently and reliably. Tools commonly used for CD: Jenkins, GitLab CI/CD, AWS CodePipeline, Spinnaker. Benefits of CI/CD: Faster Time to Market: CI/CD streamlines the software delivery process, allowing teams to release new features and updates more frequently and reliably. Improved Quality: Automated testing and deployment help identify and address issues early in the development cycle, leading to higher-quality software. Increased Collaboration: CI/CD encourages collaboration between development, testing, and operations teams by automating and standardizing the software delivery process. Enhanced Reliability: By automating testing and deployment, CI/CD reduces the risk of human error and ensures consistent and reliable releases. Challenges of CI/CD: Complexity: Implementing CI/CD pipelines can be complex, especially in large, legacy systems with dependencies and legacy infrastructure. Cultural Shift: Adopting CI/CD requires a cultural shift towards continuous improvement, collaboration, and automation. Security Concerns: Automated testing and deployment processes need to be secure to prevent vulnerabilities and data breaches. Tooling and Infrastructure: Choosing the right CI/CD tools and infrastructure can be challenging and requires careful consideration of factors such as scalability, flexibility, and cost. Best Practices for CI/CD: Automate Everything: Automate build, test, and deployment processes as much as possible to ensure consistency and reliability. Test Early and Often: Implement automated testing at every stage of the CI/CD pipeline to catch issues early and ensure the quality of the software. Monitor and Measure: Monitor the CI/CD pipeline and production environment closely to identify bottlenecks, inefficiencies, and opportunities for improvement. Embrace DevOps Culture: Foster a culture of collaboration, transparency, and continuous improvement across development, testing, and operations teams. CI/CD is a critical aspect of modern software development and is integral to the SDLC. By adopting CI/CD practices, organizations can accelerate their software delivery process, improve the quality of their software, and respond more effectively to changing market demands. <b>4. Defect Life Cycle</b> Definition of a defect: A defect, also known as a bug or issue, is an abnormal behavior or deviation from the expected functionality of the software application. Stages in the defect life cycle: a. New: The defect is identified and reported for the first time. b. Assigned: The defect is assigned to a developer or a team responsible for fixing it. c. In Progress: The developer is actively working on fixing the defect. d. Fixed: The developer has implemented a fix for the defect. e. Ready for Retesting: The fixed code is ready to be tested to verify if the defect has been resolved. f. Retest: The defect is retested to ensure that the fix is successful and does not introduce new issues. g. Closed: The defect is verified to be fixed, and the issue is closed. h. Reopen: If the defect reappears or if the fix is not satisfactory, the issue may be reopened for further investigation and resolution. <b>5. Comparison between SDLC and STLC</b> SDLC (Software Development Life Cycle): Focuses on the entire software development process from initiation to deployment and maintenance. Encompasses phases such as requirements gathering, design, implementation, testing, deployment, and maintenance. Addresses both functional and non-functional aspects of software development. Involves activities related to project management, quality assurance, and stakeholder communication. STLC (Software Testing Life Cycle): Focuses specifically on the testing activities within the broader SDLC. Encompasses phases such as test planning, test design, test execution, and test closure. Primarily concerned with ensuring the quality and reliability of the software through thorough testing. Involves activities such as test case creation, test execution, defect reporting, and test result analysis. Key Differences: SDLC is concerned with the entire software development process, whereas STLC specifically focuses on testing activities. SDLC encompasses both development and testing activities, while STLC is primarily focused on testing. SDLC addresses various aspects of software development, including requirements, design, coding, testing, deployment, and maintenance, while STLC focuses exclusively on testing-related activities. SDLC involves stakeholders from various domains, including development, testing, project management, and business analysis, while STLC primarily involves testers and quality assurance professionals. Understanding the differences between SDLC and STLC is essential for ensuring effective coordination and collaboration between development and testing teams throughout the software development process.

- Shubham Anuraj, 08:59 PM, 23 Mar, 2024

Tech


Next Read: Hot and Cold