开发者

Does it make sense to combine Terracotta with Java EE Application Server Cluster?

开发者 https://www.devze.com 2023-02-18 23:30 出处:网络
Terracotta is used for scaling JVM applications. Here is the short description of Wikipedia: Terracotta is an open source

Terracotta is used for scaling JVM applications. Here is the short description of Wikipedia:

Terracotta is an open source JVM-level clustering software for Java. It delivers clustering as a runtime infrastructure service, which simplifies the task of clustering a Java application, by clustering the JVM underneath the application, instead of clustering the application itself.

I see why you should use Terracotta if you want to scale a Java SE application.

My Question: Does it make any sense to use Terracotta if you also use a Ja开发者_运维知识库va EE Application Server such as WebSphere AS, which already supports clustering of applications? When should you use both in combination and why?


Suresh, Terracota does provide significant boost in performance when used in Java EE application servers.

The Terracotta Server can be thought of as a shared L2 for all machines to leverage. Access to the L2 costs more than access to the L1—in the case of Terracotta, this is due to the fact that the L2 is across a network connection from all JVMs—but the L2 is cheaper than other I/O such as database or messaging that would otherwise be invoked.

In contrast Zing Platform (Azul-Systems) scales by removing the heap size limitations, allows each instance to scale to hundreds of GBs of heap memory and tens of cores seamlessly and elastically. Conventional JVMs can't scale beyond 2-3 GB.

Application server clustering does not provide caching. Clustering is used for load-balancing and fail-over and simplify few administration tasks. Clustering improves horizontal scalability, Caching improves vertical scalability. Having both is a killer combination :)


Distributed caching is one of the most useful use-cases with Terracotta, but it is not just that. Terracotta provides clustering (in the true sense of the word) for the Java runtime, as an infrastructure level service. This means that applications deployed on different Java heaps over the network feel as though they are running in the same JVM, accessing the same heap. You can think of Terracotta as a technology that transforms J2SE into J2CE (Java 2 clustered edition).

0

精彩评论

暂无评论...
验证码 换一张
取 消