Table of Contents
开源项目以及Terracotta公司" >Terracotta开源项目以及Terracotta公司
核心平台DSO" >Terracotta核心平台DSO
Home Database Mysql Tutorial Terracotta 3.2.1简介 (一)

Terracotta 3.2.1简介 (一)

Jun 07, 2016 pm 03:30 PM
Introduction

Terracotta 开源 项目以及Terracotta公司 Terracotta是一款由美国Terracotta公司开发的著名开源Java集群平台。它在JVM与Java应用之间实现了一个专门处理集群功能的抽象层,以其特有的增量检测、智能 定向 传送、分布式协作、服务器镜像、分片等技术,允许用

Terracotta开源项目以及Terracotta公司

Terracotta是一款由美国Terracotta公司开发的著名开源Java集群平台。它在JVM与Java应用之间实现了一个专门处理集群功能的抽象层,以其特有的增量检测、智能定向传送、分布式协作、服务器镜像、分片等技术,允许用户在不改变现有系统代码的情况下实现单机Java应用向集群话应用的无缝迁移。使得用户可以专注于商业逻辑的开发,由Terracotta负责实现高性能、高可用性、高稳定性的企业级Java集群。

Terracotta公司目前在美国、欧洲、澳大利亚、印度等地有近百名员工,为Terracotta商业用户提供7x24技术支持、解决方案咨询等服务。同时在Terracotta开源产品之上提供适用于企业用户的高端产品。

Terracotta公司在2009年收购了著名的Java开源缓存项目Ehcache以及Java任务调度项目Quartz。经过对该项目的深度整合,Terracotta推出了易用性更高的分布式缓存、分布式任务调度以及分布式Web Session等快捷解决方案,进一步方便了开发人员开发分布式Java应用。

Terracotta核心平台DSO

Terracotta核心平台是一个基于JVM的集群解决方案,允许用户在不修改代码的情况下把单机Java应用程序运行在多JVM的集群中。

其主要功能特点如下:

  • 实现单机Java应用到集群环境的平滑移植
  • 允许Java程序像访问本地数据数据一样访问集群共享数据,并且实现对共享数据的集群范围内的访问同步
  • 提供给予网络的虚拟内存管理,允许Java程序访问超过其内存空间(heap)的数据
  • 数据保存在服务器端,因此客户端JVM宕机不会造成数据丢失
  • 增量数据传递,智能数据推送,最大限度减少对网络的负担,使得客户端JVM可以横向扩展
  • 主从服务器配置,支持多台从服务器,实现高可用服务器
  • 服务器分片,实现服务器数据存储及数据吞吐量横向扩展
  • 通过JMX开放服务器监控信息
  • 提供可视化监控和管理界面,大大方便对整合集群的共享数据、性能数据、软硬件指标等的实施监控、调试、优化

 

Terracotta 3.2.1简介 (一)

Terracotta DSO核心平台提供了一个稳健、高效、高可用、易用、易管理的Java集群平台。

Terracotta为了进一步帮助J2EE开发人员充分利用其核心平台提供的各项特性,针对Java开发人员常用的Java技术平台提供了一系列快捷模式(Express Mode)的解决方案,包括Ehcache分布式缓存、Hibernate分布式二级缓存、Web Session集群、

分布式Java任务调度Quartz等等。

Terracotta 3.2.1简介 (一)

使用快捷模式,可以避免客户端程序对JDK和应用服务器的依赖、避免配置tc-config.xml文件等等。用户直接拷贝相应的jar文件,对方案相关的配置文件进行简单修改(比如ehcache.xml, hibernate.cfg.xml文件等等),就可以实现集群化了。

后面将逐一介绍Terracotta快捷模式支持的解决方案。

分布式缓存-Terracotta EhcacheHibernate二级缓存

Ehcache是独立于Terracotta开发的开源Java缓存项目。由于其高效、易用等特点,已经被超过70%Java开发人员直接活间接使用。

Ehcache也是Hibernate项目缺省,也是功能支持最完备的耳机缓存解决方案。

Terracotta2009年收购了Ehcache项目,并且对其进行深度整合。

Terracotta 3.2.1简介 (一)

 

整合后的Ehcache保留了其原有的API,增加基于Terracotta集群的分布式缓存。用户可以通过对ehcache.xml的简单配置,实现对原有基于Ehcache构建的代码的集群化升级。

            maxElementsInMemory="10000"

            eternal="false"

            timeToLiveSeconds="120"

            />

 

           maxElementsInMemory="10000"

           eternal=”true”>

          

 

           maxElementsInMemory="10000"

           timeToLiveSeconds="3000">

          

 

整合后的分布式Ehcache有如下特点:

  • 简单、易用的分布式缓存
    • 沿用Ehcache单机版API
    • 直接支持Hibernate二级缓存实现
    • 服务器集群支持
    • 减少数据库30%-90%负载
  • 高效、可靠
    • 本地内存的访问速度
    • 动态缓存数据持久话
    • 客户端于服务器端均可横向线性扩展
    • 自动数据分片
    • 虚拟缓存内存管理,无限缓存空间
    • 多级缓存动态均衡
  • 企业用户支持
    • 支持工业标准JMX
    • 可视化管理工具
    • 动态监控、调试、优化

由于Ehcache本身就是Hibernate标准二级缓存实现,因此将单机版的Hibernate二级缓存扩展到分布式缓存于将Ehcache扩展成分布式缓存一样简单。其优势也可以自动继承。

Terracotta 3.2.1简介 (一)

 

20103月,Terracotta推出了Ehcache 2.0,其中包含了大量的新的功能:

  • Hibernate 3.3二级缓存SPI的支持
    • Hibernate3.3以前为了保证数据库于缓存数据的一致性,对二级缓存的访问有大量的锁操作,导致并发性能不高;
    • 3.3以后,Hibernate二级缓存部分代码进行了重构,提出了新的CacheRegionFactory的接口。大大提高对二级缓存的使用效率。Ehcache 2.0完全支持新的缓存接口;
  • Java分布式事务的全面支持
    • Ehcache可以通过配置,设定一个缓存为XAResource,自动加入分布式事务管理器启动的分布式事务;
    • 能够自动检测常用的分布式事务管理器;
    • 支持Spring、EJB等的分布式事务管理
  • 延迟写(Write Behind)和直通写(Write Through)
    • 提供Writer接口,负责将缓存数据写入数据库或者其他存储介质中;
    • Write Behind允许将数据保存在缓存中,再用后台线程把缓存数据异步保存到数据库或者其他存储介质中。由于缓存数据保存在Terracotta服务器上,不会由于客户端JVM宕机导致数据丢失。Write Behind是通过缓存提高数据写入速度的有效方式;
    • Write Through则是在将数据写入缓存后,马上调用Writer写入数据库中;
  • 批量导入缓存数据
    • 为了保证缓存数据一致性,每一次写操作都有同步处理,对于大量数据导入影响比较大;
    • 提供了coherent标记,来打开或者关闭同步处理。缺省为true,提供同步功能;进行大量数据导入的时候,可以暂时关闭该标记,或者10倍以上的数据导入速度;
    • setCoherent(), isCoherent(), waitForCoherent()
  • Cache级别的一致性、可用性、数据分片等支持
    • Coherent标记
    • syncrhonizedWrite
    • copyOnRead/copyOnWrite
    • 集群事件监听
    • UnlockedReadsView
  • NonStopCache
    • 在Terracotta服务器阵列出故障的时候仍然能够继续工作
    • 不会锁死本地应用
    • 超时设置
  • 管理功能
    • 新的基于Web的管理界面
    • 大部分Cache配置可以在配置界面中实时修改、即时生效

Terracotta 3.2.1简介 (一)

 

 待续。。。

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

Repo: How To Revive Teammates
1 months ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island Adventure: How To Get Giant Seeds
1 months ago By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Python ORM Performance Benchmark: Comparing Different ORM Frameworks Python ORM Performance Benchmark: Comparing Different ORM Frameworks Mar 18, 2024 am 09:10 AM

Object-relational mapping (ORM) frameworks play a vital role in python development, they simplify data access and management by building a bridge between object and relational databases. In order to evaluate the performance of different ORM frameworks, this article will benchmark against the following popular frameworks: sqlAlchemyPeeweeDjangoORMPonyORMTortoiseORM Test Method The benchmarking uses a SQLite database containing 1 million records. The test performed the following operations on the database: Insert: Insert 10,000 new records into the table Read: Read all records in the table Update: Update a single field for all records in the table Delete: Delete all records in the table Each operation

Application of Python ORM in big data projects Application of Python ORM in big data projects Mar 18, 2024 am 09:19 AM

Object-relational mapping (ORM) is a programming technology that allows developers to use object programming languages ​​to manipulate databases without writing SQL queries directly. ORM tools in python (such as SQLAlchemy, Peewee, and DjangoORM) simplify database interaction for big data projects. Advantages Code Simplicity: ORM eliminates the need to write lengthy SQL queries, which improves code simplicity and readability. Data abstraction: ORM provides an abstraction layer that isolates application code from database implementation details, improving flexibility. Performance optimization: ORMs often use caching and batch operations to optimize database queries, thereby improving performance. Portability: ORM allows developers to

Introduction to Yii Framework: Understand the core concepts of Yii Introduction to Yii Framework: Understand the core concepts of Yii Jun 21, 2023 am 09:39 AM

The Yii framework is a high-performance, highly scalable, and highly maintainable PHP development framework that is highly efficient and reliable when developing Web applications. The main advantage of the Yii framework is its unique features and development methods, while also integrating many practical tools and functions. The core concept of the Yii framework, the MVC pattern, Yii adopts the MVC (Model-View-Controller) pattern, which is a pattern that divides the application into three independent parts, namely the business logic processing model and the user interface presentation model.

Get an in-depth understanding of 7 commonly used Java design patterns Get an in-depth understanding of 7 commonly used Java design patterns Dec 23, 2023 pm 01:01 PM

Understanding Java Design Patterns: An introduction to 7 commonly used design patterns, specific code examples are required. Java design patterns are a universal solution to software design problems. It provides a set of widely accepted design ideas and codes of conduct. Design patterns help us better organize and plan the code structure, making the code more maintainable, readable and scalable. In this article, we will introduce 7 commonly used design patterns in Java and provide corresponding code examples. Singleton Patte

Implement efficient data persistence using Python ORM Implement efficient data persistence using Python ORM Mar 18, 2024 am 09:25 AM

Object-relational mapping (ORM) is a technology that allows building a bridge between object-oriented programming languages ​​and relational databases. Using pythonORM can significantly simplify data persistence operations, thereby improving application development efficiency and maintainability. Advantages Using PythonORM has the following advantages: Reduce boilerplate code: ORM automatically generates sql queries, thereby avoiding writing a lot of boilerplate code. Simplify database interaction: ORM provides a unified interface for interacting with the database, simplifying data operations. Improve security: ORM uses parameterized queries, which can prevent security vulnerabilities such as SQL injection. Promote data consistency: ORM ensures synchronization between objects and databases and maintains data consistency. Choose ORM to have

Add GUI charm to your projects with Python Tkinter Add GUI charm to your projects with Python Tkinter Mar 24, 2024 am 09:46 AM

Tkinter is a powerful library for creating graphical user interfaces (GUIs) in python. It is known for its simplicity, cross-platform compatibility, and seamless integration with the Python ecosystem. By using Tkinter, you can add a user-friendly interface to your project, improving user experience and simplifying interaction with your application. Creating a Tkinter GUI application To create a GUI application using Tkinter, perform the following steps: Import the Tkinter library: importtkinterastk Create the Tkinter main window: root=tk.Tk() Configure the main window: Set the window title, size, position, etc. Add GUI elements: Using Tki

Python Pandas data processing tool, a must-read for beginners! Python Pandas data processing tool, a must-read for beginners! Mar 20, 2024 pm 06:21 PM

Pandas is a powerful data processing library in python, specially designed for processing structured data (such as tables). It provides a rich set of features that make data exploration, cleaning, transformation, and modeling easy. For beginners in the field of data analysis and science, mastering Pandas is crucial. Data Structures Pandas uses two main data structures: Series: One-dimensional array, similar to NumPy arrays, but contains labels (indexes). DataFrame: A two-dimensional table containing labeled columns and decimals. Data Import and Export Import data: Use functions such as read_csv(), read_excel() and other functions to import data from CSV, Excel and other files. Export data: use to_

Python vs. Jython: Who is the king of cross-platform development? Python vs. Jython: Who is the king of cross-platform development? Mar 22, 2024 pm 12:21 PM

Both python and Jython are popular programming languages, but they are optimized for different use cases and have unique advantages and disadvantages when it comes to cross-platform development. Python Advantages: Extensive libraries and community support Easy to learn and use, suitable for beginners Highly portable, can run across multiple platforms Supports multiple programming paradigms, including object-oriented, functional and imperative programming Disadvantages: Lower performance, Not suitable for processing intensive computing tasks High memory consumption May require additional tools and configuration on some platforms Jython Advantages: Fully compatible with Python, can use all Python libraries and tools Run on the Java Virtual Machine (JVM), providing Seamless integration with the Java ecosystem performs better than Py

See all articles