How do i improve scalability in a java application




















A web-based app consists of three key elements — network connectivity the Internet , the application server, and a database server. This, in turn, leaves you with four areas where scalability can be applied:. Conditionally, you can organize the segments of a web application that are the most affected by the performance and scalability issues into the following groups:. Each of these three areas can pose a different set of challenges when it comes to increasing the performance and scalability of a web application.

Performance tuning assumes conducting a massive troubleshooting session to identify gaps in scalable website architecture and other issues causing the loss in performance. Typically, that may also include refactoring the web application source code, analyzing the current configuration settings, implementing new caching strategies and conducting a series of investigative procedures towards different tiers of the web app.

Performance tuning is the first step to understanding how to increase the performance and scalability of a web-based app. Unlike scaling, this procedure is less invasive and requires less time or budgets to be conducted successfully. Vertical scaling occurs when more resources are added to a single computer system.

For instance, one of your web app elements starts requiring more physical memory for processing all the incoming requests. But it is limited to the capacity of a single node.

If you can perform this action, you have scaled the application vertically. While vertical scaling may be faster and cheaper to implement, it may not be a viable long-term solution for a scalable web application or a scalable website.

Horizontal scaling occurs when more nodes VMs are added to work in parallel. This way your app can receive more resources not from a single node, but from multiple ones. If you want to implement horizontal scaling, however, several changes will have to be made:. A load balancer is a device that acts as a reverse proxy and helps administer application and network traffic across different servers.

A traffic manager typically uses DNS to route requests to specific service endpoints based on the coded rules for traffic management. Below are several types of rules you can use to effectively distribute traffic across different VMs:. You really should follow these rules if you want your app to scale flexibly over time.

To let the system grow smoothly, you must take care of the database. We have to keep in mind that scalability is not only about your code. You can save a lot of time just by selecting appropriate tools and providers. For example, Amazon EC2 provides auto-scaling features, Docker offers docker-compose scale , etc.

If we get a chance to move some code to the front-end, do it. Your backend will become less overloaded, as more and more things will be computed on the client-side. Even if our codebase is clean and perfectly maintainable, we need some tools to monitor it and identify the problems as soon as possible. Identifying the problems is one thing, but we have to take advantage of the tools we have and optimize our code and configuration to minimize the bottlenecks of your application.

Separate frontend and backend layers, detach background jobs from the main system, use design patterns wisely. Keep all the stuff up to date to avoid blocking moments due to outdated parts of your system e.

Performance Zone. Thanks for visiting DZone today,. Edit Profile. Sign Out View Profile. Complex Systems: Microservices and Humans. Building Tech at Presidential Scale. Soulful Socio-Technical Architecture. Consistency, Coupling, and Complexity at the Edge. Turning Microservices Inside-Out.

Evolutionary Architecture from an Organizational Perspective. Containers Are Contagious and Often Misused. Architecting Software for Leverage. HashiCorp Vault 1. Overriding Sealed Methods in C. Hibernate Releases Version 1. GraalVM View an example Enter your e-mail address.

Select your country Select a country I consent to InfoQ. Hello stranger! Get the most out of the InfoQ experience. Tell us what you think. Email me replies to any of my messages in this thread. Community comments.



0コメント

  • 1000 / 1000