How does a feature go from planning, development, testing, code review, deployment, to rollback?
sobes.tech AI
Answer from AI
The process of introducing a feature and delivering it to production usually involves several stages:
-
Planning — discussing requirements, setting tasks, estimating the scope of work. It is important to understand the business goal and success criteria.
-
Development — writing code according to requirements. It is important to follow coding standards, write readable and maintainable code.
-
Testing — writing and running unit tests, integration tests, possibly e2e tests. Tests help ensure that the feature works correctly and does not break existing functionality.
-
Code Review — colleagues review the code for errors, readability, architecture, security. This improves quality and facilitates knowledge sharing.
-
Deployment — moving changes to staging, then to production. CI/CD is usually used to automate the process and minimize risks.
-
Monitoring and Rollback — after deployment, metrics and logs are monitored. If critical errors are found, a rollback to the previous stable version is performed.
An example of a simplified CI/CD pipeline for a Go project:
stages:
- build
- test
- review
- deploy
build:
script: go build ./...
test:
script: go test ./...
review:
script: echo "Code review step"
when: manual
deploy:
script: ./deploy.sh
only:
- master
This approach ensures stability and quality when delivering new features.