Posts

Showing posts with the label cloud

Testing Queues and Batch Jobs

Image
Testing could be considered a solved problem. Everybody knows the importance of testing. Unit testing and integration testing are not rocket science. However, it is still not uncommon to see a lack of testing, poor coverage, and flaky tests in the industry. Internal service implementation can be tested using fakes and mocks. Testing classes is a simple task if you have a good design. Refactoring a legacy system to have a better design makes it easier to test and could be more entangled, but it is still possible and desired. However, sometimes you have a good design, which is still hard to test. Some architectures can be more complex to test naturally. If we consider standard RPC services, it's pretty vanilla to test them. However, things get more messy when we consider integration tests or end-to-end testing, mainly because of dependencies and state. From the test point of view, RPC services are simple. You have a request, very likely a rest call, and you have some assumptions; you...

Linux Terminal Goods VI

Image
  It's time for another Linux Terminal Goods post. This is post #6 of the series of posts about cool, productive Linux terminal tools for Engineers and DevOps Engineers. If you did not read the previous posts(there is lots of cool and useful stuff there) I recommend you take a look now: I , II , III , IV , V .  So without further due let's get started and checkout 5 new cool commands/programs for you! 

Infrastructure testing for Terraform with Clarity

Image
DevOps Engineering is a reality. DevOps principles like Immutable Infrastructure, Infrastructure as Code, GitOps and Observability are the default building principles for any cloud computing serious initiative. However, Infrastructure, provisioning, automation it's not trivial, tools like Ansible and Terraform make the engineer's life easier, productivity and fun. As time goes by we have more and more infrastructure code, how we make sure we keep software rolling faster with stability and quality?  The answer is testing.  Infrastructure testing is a very tricky, mocking terraform it's not easy. There are some interesting solutions like LocalStack ,  TestContainers , and molecule for Ansible . These tools are great but they are more towards Integration or E2E testing with are expensive, involve several other components and often super slow to run. A simple approach more towards unit testing could be achieved using Clarity .

Amazon Builder Library: Review Notes

Image
During AWS RE:Invent 2019 amazon release Amazon Builder's library . Which are world-class Distributed Systems, Engineering, Cloud-Architecture, DevOps class and lessons learned through experience on how to build reliable and scalable systems. The library is really great, some articles are a bit extensive like 30min read but they are really well crafted and provide great insight on amazon best practices. Today I want to share my review notes on the Library. I highly recommend you read the library. Amazon content has links with their products and also links to further readings in the sense of theory & tools. It took me a weekend to go through all the articles(13 so far) and this time was well invested I had lots of fun and learn a lot.

Amazon Aurora: Papers Review

Image
Amazon Aurora is a very interesting piece of engineering. I want to share my review notes on 2 papers related to amazon aurora. I was wondering for a long time, 2 years if I should start publishing my reviews or not. I do structure learning and study for a long time for more than 15+ years, however, I often take notes on the papers and videos I see in my Evernote. After 2 years of thinking I decided to share my papers review notes. I believe this decision will improve my learnings because I will write even more about the things I study and read and often do in my day-by-day work. I don't work at Amazon however I like amazon a lot, they are a reference for me in regards of SOA(Service Oriented Architecture), DevOps, Cloud, and NoSQL/NewSQL databases now, which aurora they proved to me that cloud-native database it's a real thing and its not BS marketing.

Reflections on Serverless:From SOA to Serverless part 3

Image
This is the 3rd part and last one on the series: Reflections on Serverless from SOA to Serverless. On the previous parts 1 and 2 I was explaining how software architecture evolved in several movements and how much we need to change our mindset in the sense of Culture, Movements, and Experiments. Our tools are changing pretty quickly and multi/poly cloud will be soon a reality for most companies. Even if so few companies have this problem in sense of availability and active-active global biz, most of the companies can benefit from multi-poly cloud in sense of getting lock in free from cloud vendors, cost reduction for better and multi offerings, better solutions for specific problems and much much more.

Reflections on Serverless:From SOA to Serverless part 1

Image
New technology is great. It's very important to open space for new ideas, better solutions, cheaper, faster and exciting new things. However, even with technology, there are principles and lessons learned with previous technologies we need to carry on otherwise we will keep making the same mistakes and we might not take full advantage of new tech. Why? Because often new tech requires a new way of things and often times also require to keep some things from the previous movements. Companies want to do Serverless now a day, often because cloud vendors are pushing that hard and because of the short term cost benefit. However, in the long run, Serverless solutions might be way more expensive than in-house solutions using OSS. There is no silver bullet, you need to understand what you are doing in order to take full benefit from new approaches, techs, and ideas rather than just moving everything from on-trend to another.  I want to share some thoughts from several architecture...

Kubernetes Everywhere with k3s

Image
Kubernetes is becoming the truly cloud-native specification for the cloud. However not all software runs on the cloud, there are other uses cases like embedded software(IoT and microcontrollers) besides IoT there is another kind of computation that is growing more a more nowadays called Edge, thanks to the low latency and facility capabilities. Would be great run the same infrastructure for the edge/IoT as we do for the cloud? Well, rancher folks addressed that with k3s . A super lightweight kubernetes distribution where they replace things and remove features instead of adding, This is great not only for the IoT/Edge uses cases but also for folks who study the cluster in the academia and for the developers in 2 fronts. First on the CI/CD front, so we can spin up a lightweight cluster to run all kinds of tests, this also has a perfect fit with GitOPS model.

Istio & Kubernetes: Developer Productivity and freedom to deliver your OKRs

Image
Innovation is a must have for companies today and work with the product mindset. Given the digital transformation, we live in, having a product mindset is more than delivering software but it is empowering teams and working with OKR-based management models that focus on Business Objectives rather than what teams have to do. Development teams are motivated by challenges and they should have the freedom to make choices. But these choices can often have a very high cost for the business and low return. Cloud usage is certainly a great disruptive force for all digital businesses.  There are many ways to architect Cloud-Native solutions (get the most out of cloud) often for a short-term view many companies are opting for Managed Services solution. These solutions, which are often database solutions, but not limited to the database, give a lot of speed for software development but bring two major problems in the long run.

Running Istio on EKS

Image
Besides all network overhead, Istio offers very interesting trade-off for sacrificing latency and network overhead for developer productivity and stack independence. In previous posts, I blogged a lot about kubernetes , Istio, Aws, Kops , Eksctl and EKS. Today I will show how to run Istio in AWS using EKS. Keep in mind EKS don't support Alpha* Specs right now(v1,v2 or v3) so some demos from the istio best selection of slideware won't work. But is possible to have istio installed and booking app running.

Running k8s on EKS

Image
EKS is the new AWS managed Service for Kubernetes launched at last Re-Invent 2018.  EKS is not available in all regions right now. EKS an option for those who don't want to use KOPS .  For this blog post, I will show how to easily set up a kubernetes cluster in AWS using EKS.  EKS has some benefits, first of all, is a managed service that you are not locked in since the API is kubernetes based so you can easily migrate to other kubernetes installation or even other kubernetes installation in other cloud vendor or on-premises.

Running Istio on AWS with Kops

Image
In previous posts, I show how to run Istio in Minikube and with Docker-Compose/Consul in local env, today I will show how to run on AWS using KOPS. This installation is Linux based(Ubuntu), I'm running all commands from my local-desktop, if you don't use Linux(shame on you) you can create a virtual-machine on AWS with ubuntu and run this commands there, also is possible to run Vagrant with Linux and them run this commands on Vagrant box as well. Istio runs smoothly in AWS with Kops. You don't need much, pretty much 3 machines(1 master node, 2 minions).  Keep in mind this is not a production-grade setup, for production, you should be running with 3 masters at least for High Availability.

Running Kubernetes on AWS with KOPS

Image
Kops is the best way to have Kubernetes running in AWS. Kops allow us to install kubernetes in EC2. Kops is written in Go . Kops helps us to create, update, maintain and destroy kubernetes clusters on aws. Kops also supports GCP(Google Could Platform). Kops has some interesting ability to generate terraform files if that's your you thing :-).  For this blog post, we will be using AWS ELB as DNS so we won't be using public DNS records which are done by setting carefully the name of the cluster - which need to end with .k8s.local. Right now is way faster to spin up a kubernetes cluster with Kops rather than EKS .

Getting Started with Istio and Minikube

Image
Istio is the new standard for microservices in Kubernetes . Around 2014 Netflix defined before everybody else how to do proper microservices using they brand new stack called NetflixOSS . Introducing game-changing concepts for the Cloud Native microservice components such as Mid-tier load balancing, fault tolerance, circuit breaking, retry/timeouts, service registry and discoverability and much more. NetflixOSS was super important and still is in the cloud-native microservices world. Today the great majority of companies who do Java development use

Lessons Learned with DevOps Engineering Experiences

Image
Lessons Learned with DevOps Engineering Experiences Almost 20 years ago an Agile movement was born. After 20 years there are still lots of confusion and misunderstanding on principles, practices, and mindsets. DevOps barely have 10 years but does not have a method like a scrum, Kanban or XP. However, DevOps rely on Lean / Agile there is no strict definition, method or formal guidance how to do proper DevOps.   Like everything in life, this is good and bad at same time. DevOps is a movement about experiences that made some for some companies and people in order to have or practice better ways to develop and operate the software. Currently, DevOps is a mess. DevOps is a mess is Brazil but is also a Mess in the USA. For lots of people, DevOps means Ops doing code. For other companies DevOps means Cloud Ops Team doing ops. There are DevOps folks from Development background like me and there are much more. There is so much confusion on the market that you really need...

Dynomite Eureka Registry with Prana

Image
Dynomite it's a great solution for clustering with NoSQL Databases like Redis . Eureka is a nice Registry & Discoverability Solution. We can get best of both worlds using Prana . Prana is a sidecar that enables non-JVM applications to register in Eureka. Sometimes we could easily use multiple discoverability solutions like DNS, ETCD, Eureka etc... However not all discoverability provide the same benefits some tools are better suited for some jobs them other. I like ETCD and make sense onKubernetes world but if you are doing Java Microservices eureka makes more sense. The triad(Eureka, Prana, Dynomite) is great, This is great because then you can do discoverability on your database nodes, this is not great for several reasons like: Use the same tool for Registry / Discoverability Enable all sorts of dynamic programming which is great for DevOps Engineering Avoid AWS Throttling issues Make dyno clients more dynamic and this is a better solution them DNS like route5...

Cloud-Native Microservices: The Next Shift

Image
All companies want to innovate currently today not everyone can actually. There are several bottlenecks for innovation. The technology it's often part of the problem and part of the solution. Software architect there is a crucial role in enabling solutions that not only scale and are available but also that make the difference. Many companies have monoliths or have several monolith systems and they are having trouble to keep up with the market pace of innovation. The cloud seems to be the right place to go. However, if we don't think how to do it we could be trapped in a problem bigger than we think. Currently, Microservices become a de-facto standard of architecture for several problems however in order to get more benefit from micro services we need do some mindset shifts. I'm not talking about basic shifts such as Independence and Isolation .

Having some fun with AWS Route53

Image
Amazon Web Services Route53 is a high available and scalable DNS solution. It can be used to route request inside and outside amazon web services as well. Route53 allow you to configure DNS health checker to route traffic to a healthy endpoint. Route53 has plenty of features, for me best ones are: Traffic Flow: Route end user to best endpoints. Latency Based Routing: Routes users to region with lowest latency. GEO DNS: Route users based on they IP location. Private DNS for Amazon VPC:  Manages custom domains internaly. DNS Failover: Avoid outages routing users to different locations. For this post i will show how to install and do some basic operations with  CLI53 a command line interface for Amazon Route53.  For this post we will use CentOS / Amazon Linux Distribution.

Failure is Hard

Image
Couple of days ago there was another massive outage on Amazon Web Services. This time was around AWS DynamoDB and that create lots of noise on the the web. Was not the first time a outage happened and wont be the last time for sure. There are some summary report from aws you can check. So is this the end of cloud computing? Should we stop using cloud as single provider? All this questions start emerge from the web . I dont think thats the case - for sure there are some lessons learned from this last incident. The reality is distributed computing is hard and will always be.

NetflixOSS: Installing and Running ICE

Image
NetflixOSS ICE is AWS COST monitoring solution. Similar to cloud watch but IMHO is better. There are some issues with ICE first of all is kinda of buggy at least right now - something you got some NPE and is hard to figure out what you did wrong. Second - its kinda of slow to run first time it take some time because it does lots of processing to figure out the costs.  You need have your billing configure right on AWS and also you need a S3 bucket to store the billing data so ICE and read and show the charts for you. We will install ICE on Amazon Linux OS(CentOS based).