×

Pattern for integrating primary and secondary data stores in a sharded data domain

  • US 10,025,710 B2
  • Filed: 04/30/2014
  • Issued: 07/17/2018
  • Est. Priority Date: 04/30/2014
  • Status: Active Grant
First Claim
Patent Images

1. A method comprising:

  • receiving, by a data access logic (DAL) framework comprising one or more processors, a request for a write operation of a record, the DAL framework managing cache persistence associated with a sharded database, a secondary data store, and an alternative key global indexes (AKGI) database, the secondary data store being configured to act as a read cache to offload read activity from the sharded database;

    initializing the secondary data store by (1) updating metadata of the record in the secondary data store, the metadata comprising a primary key (PK) associated with the record, and an alternative key (AK) hash value associated with the record, (2) not changing content data of the record when the record is not a new aggregate, and (3) storing a null payload in the content data of the record when the record is a new aggregate, wherein updating the metadata of the record in the secondary data store comprises;

    setting a transaction-specific time-to-live (TTL) for the record, the transaction-specific TTL being specified by an application that requested the write operation; and

    setting a check-and-set (CAS) value for the record;

    performing, based on the PK and the AK hash value, the write operation of the record in the AKGI database and the sharded database, respectively, in a single coordinated transaction in which a modification of the AKGI database is completed before modifying the sharded database; and

    updating the content data of the record in the secondary data store, in a finalization phase of the secondary data store, by (1) resetting the metadata, including the transaction-specific TTL, and (2) persisting aggregate data and AKGI data to the secondary data store in response to determining that;

    (i) the write operation is successfully completed and the record is committed to the sharded database and the AKGI database, and (ii) the CAS value has not been changed during the transaction-specific TTL.

View all claims
  • 2 Assignments
Timeline View
Assignment View
    ×
    ×