Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8591621
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T23:34:07+00:00 2026-06-11T23:34:07+00:00

We are considering Terracotta for our next project. I am intrigued by its potential

  • 0

We are considering Terracotta for our next project. I am intrigued by its potential to provide data persistence without the need for a separate DBMS. (See also On using Terracotta as a persistence solution)

One of the major pains of software evolution is to make the existing production data conform to the new data model. For an RDBMS you’d likely use a SQL change script at the moment of deployment. For Terracotta backed data, it is not immediately clear to me how to deal with non-trivial evolution.

There’s a couple of paragraphs on Class Evolution in the Terracotta documentation but it seems specific to DSO and stays rather superficial.

  1. What are possible ways to handle data model evolution for the persistent data stored in Terracotta? I’m particularly interested in the non-DSO scenario (i.e. through the Terracotta Toolkit API).
  2. Do Terracotta DSO and the Toolkit API differ in their reactions to evolved class definitions?
  3. To understand the limitations of class evolution it would help to know how Terracotta represents/communicates object data; is there a specification for that?
  4. Maybe there are schema evolution techniques from the OODBMS world that are applicable to Terracotta?

As a trivial example, let’s say I have a bunch of Car objects stored and I’ve changed the modelYear field of the Car class from a String to an int. According to the documentation this does not work out-of-the-box. I can imagine a solution where my old Car is loaded by a seperate classloader during application startup, and then converted to a new Car. Would that be a good approach and why (not)?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T23:34:08+00:00Added an answer on June 11, 2026 at 11:34 pm

    It depends on your use case scenario.

    If the cost of loading your cache is minimal (minutes) and you can afford down time…then I see no issue of simply rebuilding your cache for a new version.

    If you have high cost of populating your cache (hours/days) and you cannot afford any sizable downtime then you have to handle new and old version at the same time during transition period.
    For this:

    1. I would define a separate cache definition for any new version of
      the cached class and let old version to expire in the cache.
    2. Application code should have “old/new version” support as well.
    3. Have an instance that would still work with old version until data
      expires/obsolete (based on an old cache name)
    4. Have an instance that handled all new requests/flows with a new
      version (based on a new cache name)

    e.g. in ehcache.xml you would define 2 caches (based on your example):

    <cache name="com.xyz.Car" timeToLiveSeconds="600"/>
    <!--New version goes here-->
    <cache name="com.xyz.Car2" timeToLiveSeconds="600"/>
    

    In the long run, you should workout naming convention for your caches that includes version evolution.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Considering the following data frames : > tail(tot.final) names.id sequence names.reads width.reads names.counts st
Considering the code below: How is the str1 object created without using new String()
Considering that I use code like (with or without using (considering that using(??) may
Considering that everyone is always worried about User Data (And Rightly So), would it
considering that fairly static data should not be re-evaluated but cached instead, I wondered
Considering the basic data types like char, int, float, double etc..in any standard language
Considering class A, I would like to limit its creation to new. That is
Considering next simple example: The header: // a.hpp #ifndef A_HPP #define A_HPP #include <memory>
Considering next two classes : struct Base { virtual ~Base() { } virtual void
Considering a project where will work more than one developer and that will receive

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.