System and methods for implementing a consistent and persistent hybrid cloud cache
Systems, apparatuses, and methods provide an architecture and associated logic to enable implementing a consistent and persistent hybrid cloud cache. The logic comprises use of the “Cloud Push” and “Metadata Reconciliation” processes combined with use of a data object described herein to enable the accurate tracking and synchronization of operations and metadata regarding operations between a local persistent cache and a cloud data store. This enables both Explicit and Implicit transactions to be monitored and reconciled to provide a complete and up to date record of all operations.
1 . A method for managing a hybrid cloud cache, comprising:
obtaining a first list of objects in a folder, wherein the first list is generated from a copy of the folder stored locally;
obtaining a second list of objects in the folder, wherein the second list is generated from a copy of the folder stored in a cloud storage element;
obtaining a data object representing operations performed on the folder as a result of execution of explicit transactions occurring locally;
comparing the second list of objects in the folder to the first list of objects in the folder; based on the comparison, identifying a conflict between information in the first list and information in the second list;
determining if the identified conflict is an identifier change conflict;
if the identified conflict is an identifier change conflict, then moving the objects involved in the conflict into a hidden namespace of the hybrid cloud cache;
executing any explicit transactions in the cloud storage that have been executed locally but not in the cloud storage; and
based on the outcome of executing the explicit transactions that have been executed locally but not in the cloud storage, determining if the identifier change conflict is a direct identifier change conflict or an indirect identifier change conflict, wherein if the identifier change conflict is a direct change conflict, then changing an object's identifier in the data object to an identifier returned by execution of an explicit transaction in the cloud storage, and if the identifier change conflict is an indirect change conflict, then deleting the object and recreating the object with a different identifier.
2 . The method of claim 1 , further comprising:
determining if the identified conflict is a type mismatch conflict; and
if the identified conflict is a type mismatch conflict, then adding a randomly generated suffix to the object's name.
3 . The method of claim 2 , further comprising using the data object representing operations performed on the folder as a result of executing explicit transactions occurring locally to override both an identifier change conflict and a type mismatch conflict, and thereby to present a consistent view of a namespace.
4 . The method of claim 1 , wherein the first list and the second list comprise metadata for each of a plurality of objects in the folder.
5 . The method of claim 4 , where the metadata comprises one or more of an identifier, name, timestamp, size, or checksum.
6 . The method of claim 1 , wherein if an object has the same name in the first list and in the second list, but has a different type in the lists, then the identified conflict is a type mismatch conflict.
7 . The method of claim 1 , wherein if an object has the same name in the first list and in the second list, but has a different identifier in the lists, then the identified conflict is an identifier change conflict.
8 . The method of claim 1 , wherein if execution of an explicit transaction in the cloud storage returns a type mismatch, then the identified conflict is a type mismatch conflict.
9 . The method of claim 1 , wherein if execution of an explicit transaction in the cloud storage returns an identifier for the object that is different than the identifier recorded in the explicit transaction, then the identified conflict is an identifier change conflict.
10 . The method of claim 1 , wherein identifying a conflict between information in the first list and information in the second list further comprises executing a metadata reconciliation process or a cloud push process, wherein the metadata reconciliation process operates to provide a temporary resolution of a conflict and the cloud push process operates to provide a final resolution of the conflict.
11 . The method of claim 1 , wherein identifying a conflict between information in the first list and information in the second list further comprises executing a metadata reconciliation process or a cloud push process, wherein the metadata reconciliation process operates to provide a temporary resolution of a conflict and the cloud push process operates to provide a final resolution of the conflict.
12 . The method of claim 1 , wherein deleting the object and recreating the object with a different identifier further comprises: locking resources corresponding to an in-core representation of the folder; ignoring objects added to the data object for the folder by transactions performed locally that have been pushed to the cloud; creating a corresponding folder in a namespace of deleted folders locally with the initial identifier of the folder; moving the metadata of the folder to the corresponding folder; changing the identifier of the folder to a new identifier; scheduling the folder for a metadata reconciliation process; and releasing the locks placed on the resources.
13 . The method of claim 1 , wherein the second list is obtained by refreshing a node in a namespace of an object stored locally, and wherein refreshing the node causes a fetch of the second list from the cloud storage element.
14 . A system for managing a hybrid cloud cache, comprising:
one or more electronic processors configured to execute a set of computer executable instructions; and
the set of computer-executable instructions, wherein when executed, the instructions cause the one or more electronic processors to
obtain a first list of objects in a folder, wherein the first list is generated from a copy of the folder stored locally;
obtain a second list of objects in the folder, wherein the second list is generated from a copy of the folder stored in a cloud storage element;
obtain a data object representing operations performed on the folder as a result of execution of explicit transactions occurring locally;
compare the second list of objects in the folder to the first list of objects in the folder;
based on the comparison, identify a conflict between information in the first list and information in the second list;
determine if the identified conflict is an identifier change conflict;
if the identified conflict is an identifier change conflict, then move the objects involved in the conflict into a hidden namespace of the hybrid cloud cache;
execute any explicit transactions in the cloud storage that have been executed locally but not in the cloud storage; and
based on the outcome of executing the explicit transactions that have been executed locally but not in the cloud storage, determine if the identifier change conflict is a direct identifier change conflict or an indirect identifier change conflict, wherein if the identifier change conflict is a direct change conflict, then changing an object's identifier in the data object to an identifier returned by execution of an explicit transaction in the cloud storage, and if the identifier change conflict is an indirect change conflict, then deleting the object and recreating the object with a different identifier.
15 . The system of claim 14 , wherein the instructions further cause the one or more electronic processors to:
determine if the identified conflict is a type mismatch conflict;
if the identified conflict is a type mismatch conflict, then add a randomly generated suffix to the object's name; and
use the data object representing operations performed on the folder as a result of executing explicit transactions occurring locally to override both an identifier change conflict and a type mismatch conflict, and thereby to present a consistent view of a namespace.
16 . A set of computer-executable instructions that when executed by one or more programmed electronic processors, cause the processors to manage a hybrid cloud cache by:
obtaining a first list of objects in a folder, wherein the first list is generated from a copy of the folder stored locally;
obtaining a second list of objects in the folder, wherein the second list is generated from a copy of the folder stored in a cloud storage element;
obtaining a data object representing operations performed on the folder as a result of execution of explicit transactions occurring locally;
comparing the second list of objects in the folder to the first list of objects in the folder;
based on the comparison, identifying a conflict between information in the first list and information in the second list;
determining if the identified conflict is an identifier change conflict; and
if the identified conflict is an identifier change conflict, then moving the objects involved in the conflict into a hidden namespace of the hybrid cloud cache;
execute any explicit transactions in the cloud storage that have been executed locally but not in the cloud storage; and
based on the outcome of executing the explicit transactions that have been executed locally but not in the cloud storage, determine if the identifier change conflict is a direct identifier change conflict or an indirect identifier change conflict, wherein if the identifier change conflict is a direct change conflict, then changing an object's identifier in the data object to an identifier returned by execution of an explicit transaction in the cloud storage, and if the identifier change conflict is an indirect change conflict, then deleting the object and recreating the object with a different identifier.
17 . The one or more non-transitory computer-readable media of claim 16 , further comprising instructions that cause the processors to:
determine if the identified conflict is a type mismatch conflict;
if the identified conflict is a type mismatch conflict, then add a randomly generated suffix to the object's name; and
use the data object representing operations performed on the folder as a result of executing explicit transactions occurring locally to override both an identifier change conflict and a type mismatch conflict, and thereby to present a consistent view of a namespace.