Software systems make remote calls to software running in different processes, usually on different machines across a network. One of the big differences between in-memory calls and remote calls is that remote calls can fail, or hang without a response until some timeout limit is reached. What's worse, if you have many callers on an unresponsive supplier, you can run out of critical resources leading to cascading failures across multiple systems.
The circuit breaker pattern is the solution to this problem. The basic idea behind the circuit breaker is very simple. You wrap a protected function call in a circuit breaker object, which monitors for failures. Once the failures reach a certain threshold, the circuit breaker trips, and all further calls to the circuit breaker return with an error or with some alternative service or default message, without the protected call being made at all. This will make sure system is responsive and threads are not waiting for an unresponsive call.
Reference:
https://dzone.com/articles/circuit-breaker-pattern
https://www.ibm.com/cloud/garage/practices/manage/practice_circuit_breaker_pattern/
https://developers.redhat.com/blog/2017/05/16/it-takes-more-than-a-circuit-breaker-to-create-a-resilient-application/
Netflix Chaos Monkey
Chaos Monkey randomly deactivates instances and services within our architecture. If we are not constantly testing our ability to deal well with flaws, we will probably not succeed when we really need it - in the case of an unexpected outage.
Reference:
https://www.infoq.com/br/news/2012/08/netflix-chaos-monkey
https://medium.com/netflix-techblog/chap-chaos-automation-platform-53e6d528371f
Reference:
https://www.infoq.com/br/news/2012/08/netflix-chaos-monkey
https://medium.com/netflix-techblog/chap-chaos-automation-platform-53e6d528371f
CheatSheet Kubernetes
kubectl get events -n <namespace>
kubectl get cs
kubectl get pods -n <namespace> -o wide
kubectl get pv,pvc -n <namespace>
kubectl describe pvc <pvc> -n <namespace>
kubectl delete pod <pod> -n <namespace>
kubectl set image deployment httpd httpd=httpd:2.4 -n web
Nomenclature:
sc - Storage Class
pv - Persistent Volume
pvc - Persistent Volume Claim
kubectl get cs
kubectl get pods -n <namespace> -o wide
kubectl get pv,pvc -n <namespace>
kubectl describe pvc <pvc> -n <namespace>
kubectl delete pod <pod> -n <namespace>
kubectl set image deployment httpd httpd=httpd:2.4 -n web
Nomenclature:
sc - Storage Class
pv - Persistent Volume
pvc - Persistent Volume Claim
CheatSheet Git
git config --global user.name "Your Name"
git config --global user.email "youremail@domain.com"
git config --list
git clone https://github.com/user/repository
git add <file>
git add *
git commit -m "comment"
git push origin master
git config --global user.email "youremail@domain.com"
git config --list
git clone https://github.com/user/repository
git add <file>
git add *
git commit -m "comment"
git push origin master
Assinar:
Postagens (Atom)