简体   繁体   中英

Loading and updating Gemfire cache from Oracle table

I am new to Pivotal Gemfire and configuring Gemfire to store Oracle table data for low-latency and high throughput application.

Via there are ways by which we can load the data in to Gemfire cache.

Does anyone know how can I update the data if any update happens in Oracle post Gemfire cache loading?

Any help, directions, references would be of great help.

Typically, you would want to design your application such that all updates are flowing from your application through GemFire and then to Oracle. You could use a GemFire CacheWriter to update the Oracle database synchronously and even wrap this in a (JTA) transaction so that the Oracle database is only updated if GemFire was successfully updated. See more details here . You can even perform the update asynchronously (write-behind) using AsyncEventQueues and Listeners, see here and more generally here .

It is possible that you have other non-GemFire based applications that access your Oracle database directly. In this case, you are going to have to rely on external means to detect the database updates and feed them into GemFire. There are many ways to do this, of course, such as from a scheduled service that periodically checks for database updates and pulls them into GemFire. A combination of the core Spring Frameworks' Task Scheduling infrastructure combined with Spring Data JPA (or even just Spring's JDBC Abstraction ) would greatly simplify this effort.

Or, if it were me, I would probably opt for Spring XD , and setup a " stream " having a Oracle Database (JDBC) " source " mixed with some transformations/filters/etc as necessary, and then a GemFire " sink ".

Hope this helps and good luck.

Cheers!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM