In the previous blog, I have covered microservices ecosystem and building blocks. I also presented different tools and compared them against certain attributes for design and documentation. In this blog, I will be covering development and testing aspects.
Development (Specific to Java)
Development is an important and vital for any software and Microservices is no exception to this. You can develop Microservices using all popular backend programming languages like Java, .NET, Node.js and Python. Here my comparison is limited to Java technology.
Spring Boot is definitely asserting its leadership in overall adoption across Microservices development community. It does not support modularity, however for Microservices it is a problem as modularity is achieved at functional level (Bounded Context) in Microservices architecture.
Unit Testing (Specific to Java)
Unit testing plays an important role in ensuring good quality code and it is also known fact that effective unit testing also optimizes project costs by detecting problems in early stage of development.
Mockito is the most popular framework for unit testing. You will get good community support and this tool is being maintained relatively better, compared to another tools. If you need static method validation, you may need to use powerMockito.
Integration testing is the important phase in Microservices as each Microservice need to collaborate effectively with other Microservices to achieve common business objective by acting within its own bounded context. This phase gives product owner an understanding on whether product development is going in right direction or not in terms of achieving larger business goal.
Postman is a popular tool, but RestAssured is good, in terms of reporting and data driven testing. RestAssured may bind you to Java development, hence I would recommend Postman as a safe bet.
Load testing is slowly losing its prominence as computing cost is getting cheaper. Dynamic scaling up/down the number of service instances also become another deterrent for load testing. However, for some mission critical projects, we should not ignore load testing. This testing will ensure how much of load system can handle with a given set to resources. Sometimes load testing is being used to test dynamic scaling up/down configurations i.e. after reaching certain load spins up another instance.
I will go with Grinder as it has custom scripting as an additional capability compared to JMeter. Loadrunner has many in-built features which can help you running load testing with ease. But it is costly and for many businesses it is the bottleneck. In case you want to go with open source alternative Grinder and JMeter are in tight contest.
In this blog, we have covered tools and their comparison for Development and Unit Testing. I hope now you became familiar with some of tools that are available in the above mentioned phases Microservices development and knowledge to make a better decision on which tool to use for a given need.
In the next blog, I will be covering Containerization, Monitoring and Load Balancer.