One or more implementations relate to the field of database technologies; and more specifically, to techniques for handling failure and other anomalous situations during a data transfer.
Database replication technologies are used for copying data from one database to another. For example, the databases can be in different physical locations to provide a backup in case of a database failure. Databases can also be distributed to provide faster access to their data. Typically, multiple components are involved in the copying process. For example, one component may detect when a change occurs to a source database. This component can generate a notification such as an event when a change is detected. Other components react to the notification by gathering the associated data and forwarding it to a target database. A record of the event can also be stored. However, various challenges are presented in handling failures and other anomalous situations during a data transfer.
The following figures use like reference numbers to refer to like elements. Although the following figures depict various example implementations, alternative implementations are within the spirit and scope of the appended claims. In the drawings:
The following description describes technologies for copying data from one database to another.
Various database replication products are available. In an example implementation, a database (DB) monitoring process monitors a source database and detects when there is a change to the database. When the change is detection, a transaction is initiated for copying the changed data to a target database. For example, an event can be triggered for the transaction, where the event is pushed to an upstream component such as an EventInterceptor process. In response, the EventInterceptor process extracts data of the event and forwards it to an EventReceptor process which is further upstream, in the direction of the target database. The EventReceptor process is responsible for writing the data to the target database.
However, various failure scenarios can occur. For example, the EventInterceptor process or the EventReceptor process can have an unplanned or planned shutdown. In another example, one of the processes is started before the other. These scenarios can result in challenges such as the EventInterceptor having to buffer data when the EventReceptor is unavailable, or the EventInterceptor and EventReceptor having to retain state information to keep track of the replication process. In another example, the EventReceptor process detects an error with previously-written data and thus needs to re-write the data of the event. This can result in resending an excessive amount of data.
The techniques disclosed herein address the above and other issues. In an example implementation, the EventInterceptor waits to receive a pairing request from the EventReceptor before the EventInterceptor begins processing events from a DB Event Mining System. When it is not yet paired, the EventInterceptor rejects events pushed to it from the DB Event Mining System and requests that the DB Event Mining System resend the event at a specified time. This process can be repeated until the EventInterceptor is paired with the EventReceptor. Once paired, the EventInterceptor processes the events and forwards the associated data to the EventReceptor for writing to the target database.
In another example implementation, after the two are paired, the EventInterceptor detects a failure in the EventReceptor such as by determining that an ongoing transaction has failed or by determining that no response has been received to a heartbeat check signal sent to the EventReceptor. At this time, the EventInterceptor sends a request to the DB Event Mining System to re-send the current database event and the EventInterceptor shuts itself down for a specified period of time before restarting. When it restarts, it waits for a pairing request from the EventReceptor which indicates the EventReceptor has recovered from its failure. When no pairing request is received, the EventInterceptor repeatedly rejects events pushed to it from the DB Event Mining System, as discussed previously. When a pairing request is received, the EventInterceptor starts to accept events pushed to it from the DB Event Mining System.
In another example implementation, the EventReceptor detects an error with previously-written data such as due to a post-scan comparison between the source and target data. In this case, the EventReceptor requests that the EventInterceptor replay the data from a given point in time, such as can be identified by a specified system change number (SCN) or other transaction identifier. The EventInterceptor responds by requesting that the DB Event Mining System start sending event data from the specified SCN. The resending can continue until a last transaction in a batch of transactions is sent, for example.
These and other advantages will be further apparent in view of the following discussion.
The term “Event” is also the name of a Java API. An “Event” object in the Java standard captures the necessary information required to adequately describe some activity that has occurred. Events can fire before a change has been committed to memory (pre-committed) or after the change has been committed (post-commit). Semantically, EventInterceptors listening to pre-committed events will have the opportunity to change the state of the request before it has been committed. Generally, the term “event” can refer to any similar software interface, process or other construct. The term “EventReceptor” is the name of a Java function which can be used to receive any data that the EventReceptor 140 needs as parameters. Generally, “EventReceptor,” “event receptor,” or the like can refer to any software interface, process or other construct which is capable of receiving data regarding an event and writing the data to the target database 150.
The source database 110 and target database 150 can be of various types. For example, relational databases store data in multiple, related tables. Within the tables, data is stored in rows and columns. A relational database management system (RDBMS) is a program used to create, update, and administer a relational database. Structured Query Language (SQL) is the most common language for reading, creating, updating and deleting data. Examples include Microsoft SQL Server, Oracle Database, MySQL, PostgreSQL and IBM Db2.
NoSQL is a category that includes any database that does not use SQL as its primary data access language. These types of databases are also sometimes referred to as non-relational databases. This allows storage of unstructured or semi-structured data. Examples include Apache Cassandra, MongoDB, CouchDB, and CouchBase.
A cloud database refers to any database which runs in the cloud, e.g., on the Internet instead of at a local computer. Cloud databases offer flexibility and scalability, along with high availability. Examples include Microsoft Azure SQL Database, Amazon Relational Database Service, and Oracle Autonomous Database.
Columnar databases store data in columns rather than rows. These types of databases are often used in data warehouses because they are suited for handling analytical queries. Examples include Google BigQuery, Cassandra, HBase, MariaDB, Azure SQL Data Warehouse
In wide column databases, data is stored in column families, rather than in rows and columns. These are suited for supporting real-time big data applications. Examples include BigTable, Apache Cassandra and Scylla.
Object-oriented databases are based on object-oriented programming, where the data and its attributes are tied together as an object. Object-oriented databases are managed by object-oriented database management systems (OODBMS). These databases work well with object-oriented programming languages, such as C++ and Java. Examples include Wakanda and ObjectStore.
Key-value databases, a type of NoSQL database, save data as a group of key-value pairs made up of two data items each. These are suited for handling high volumes of traffic, such as for session management of web applications, user sessions for massive multi-player online games, and online shopping carts. Examples include Amazon DynamoDB and Redis.
Hierarchical databases use a parent-child model to store data. These are suited to support high-performance and high availability applications. Examples include IBM Information Management System (IMS) and Windows Registry.
Document databases use JavaScript Object Notation (JSON)-like documents to model data instead of rows and columns. These are suited to store and manage document-oriented information and are useful for mobile apps that need fast iterations. Examples include MongoDB, Amazon DocumentDB and Apache CouchDB.
Graph databases are a type of NoSQL database that are based on graph theory. These are suited to analyze the relationships between heterogeneous data points, such as in fraud prevention or for mining data about customers from social media. Examples include Datastax Enterprise Graph and Neo4J.
A time series database is a database optimized for time-stamped, or time series, data. Examples of this type of data include network data, sensor data, and application performance monitoring data. Internet of Things sensors output a constant stream of time series data. Examples include Druid, eXtremeDB and InfluxDB.
The source database 110 may store data for one or more users, for example, who access the database via respective computing devices. When data is changed in the source database 110, e.g., by adding, changing or deleting data, an event may be triggered by the DB Event Mining System 120. The DB Event Mining System 120 may monitor the source database 110 to detect the changes. One possible example of the DB Event Mining System 120 is the Oracle GoldenGate software. This software product allows one to replicate, filter, and transform data from one database to another database across an enterprise. The databases can be of the same type or of different types. Other examples of the DB Event Mining System 120 include Informatica PowerCenter, SQL Server Integration Services (SSIS), Denodo Platform, Fivetran, Alteryx Designer, AWS Glue, Pentaho Data Integration (PDI) and Qlik Replicate. Generally, the DB Event Mining System 120 can be any software interface, process, system or other construct which is capable of generating an event when there is a change to a database and communicating the event to an event interceptor process.
The DB Event Mining System 120 creates trail files 121, e.g., backup files. This can be a series of files on a non-volatile storage medium such as a disk drive, which the DB Event Mining System 120 uses to store the captured changes of the source database 110 to support the continuous extraction and replication of database changes. Each change may be associated with an event, such that each event is persisted in the trail files 121. The trail files 121 can store an identifier of the event such as a SCN and the changed data of the source database 110. The DB Event Mining System 120 pushes events to the EventInterceptor 130. The EventInterceptor 130 intercepts live database transaction events, extracts meta-data and data associated with the event, applies transformation logic to the data and transmits it to the EventReceptor 140 using a remote procedure protocol (RPC), for example. The EventInterceptor 130 is a process or software component which is responsible for interacting with the DB Event Mining System 120 and the EventReceptor 140.
An RPC is an inter-process communication technique that is used for client-server based applications. It is also known as a subroutine call or a function call. A client process has a request message that the RPC translates and sends to a server process. This request may be a procedure or a function call to a remote server. When the server receives the request, it sends the required response back to the client. The client is blocked while the server is processing the call and only resumes execution after the server is finished. In the context of the system of
In particular, gRPC is an API framework that allows a program in one location on the Internet to pass data to a distinct function in another program at another location on the Internet for processing. While other API frameworks such as REST typically pass data from client to server and back again using text-based formats such as JSON or XML, under gRPC, data is passed between a client and a server-side target function in faster, binary format.
In one implementation, the EventReceptor 140 receives the data in the RPC, converts it into one or more SQL statements and writes the data to the target database 150 using the one or more SQL transactions. However, any technique for writing the data can be used. The target database 150 is therefore kept consistent with the source database 110. The EventReceptor 140 is a process or software component which is responsible for interacting with the target database 150 to write data.
In summary, the system 100 provides an intelligent replication workflow involving a chain of components which intercept database events, extract data and provides it to upstream components. The components of the system 100 can runs on one or more computing devices such as depicted in
This approach has a number of disadvantages. For example, first, the EventInterceptor 130 will require a buffer/cache to hold the data until the EventReceptor 140 comes back online. Second, this would result in a duplication of storage since the DB Event Mining System 120 is already storing the data in trail files 121. Third, a data consistency problem can occur when there is a failure in an ongoing or uncompleted transaction. For example, an RPC may be sent by the EventInterceptor 130 to the EventReceptor 140 which is not completed or acknowledged. These issues can be understood further in view of the following.
The writing of the event data to the trail files 121 can be secured by security credentials. One example is Oracle Wallet Manager. The arrow 304 depicts a notification of the event being sent from the DB Event Mining System 120 to the EventInterceptor 130. This can be a callback, for example. In response, the arrow 305 depicts a request from the EventInterceptor 130 to the DB Event Mining System 120 to extract data of the event. For example, this data can be the changed data of the source database 110. An arrow 306 indicates the EventInterceptor 130 transforms the data into an RPC packet. One example is to transform the data into one or more gRPC packets. The arrow 307 depicts sending the data in the RPC packets to the EventReceptor 140. The arrow 308 depicts the EventReceptor 140 converting the data into one or more SQL statements. The arrow 309 depicts the EventReceptor 140 writing the data to the target database 150. The arrow 310 depicts a return confirmation signal from the EventReceptor 140 to the EventInterceptor 130, and the arrow 311 depicts a return confirmation signal from the EventInterceptor 130 to the DB Event Mining System 120. The arrow 312 depicts the SCN being incremented.
Note that each transaction or event can have an identifier such as a SCN, as mentioned. An SCN is similar to a serial number and is an example of a checkpoint. Each time data is committed in a database, the SCN is incremented. The SCN thus marks a consistent point in time in a database. The SCN can be used to track what has been processed and what has not been processed. The SCN can be used to go backward in time to access previously-committed data.
The above discussion involves a sequence where there is no failure. However, the presence of a failure results in various challenges. The techniques described herein provide a dynamic and intelligent SCN-based pairing mechanism between the EventInterceptor 130 and EventReceptor 140 to address failure scenarios. As mentioned, the failure of the EventReceptor 140 while a transaction is ongoing or the need of the EventInterceptor 130 to cache data until the EventReceptor 140 is back online requires an unorthodox way of managing the lifecycle of these two components. Instead, the techniques described herein enable the EventReceptor 140 to influence when the EventInterceptor 130 starts pushing events to it, and empower the EventReceptor 140 to tell the EventInterceptor 130 to go back in time to send events from the point where it failed to process a transaction.
The techniques comprise three primary features: lazy data transmission (see
The advantages of the techniques include a dynamic pairing process and the ability to go back in time, to obtain data from old events/transactions. Another advantage is ensuring data consistency even in the case of a component failure. Another advantage is there is no need to implement buffering logic inside the EventInterceptor 130 in case its partner, the EventReceptor 140, is down. As a result, there is no need for extra storage at the EventInterceptor 130. Instead, the techniques leverage the trail files 121 already being generated by the DB Event Mining System 120. By avoiding data duplication, extra storage capacity is not needed. This is particularly relevant in systems which charge the user based on the amount of storage used, in a “pay as you consume” model.
A further advantage is increased security by avoiding the duplication of data at the EventInterceptor 130. Instead, security measures can be applied to the trail files 121. As a result, there are fewer avenues of attack and the data migration is more secure.
A further advantage is that the ability to replay a set of DB events from a given SCN enables the EventReceptor 140 to recover any scenario where it has erred in writing database events to the target database 150. It effectively strengthens the replication eco-system to recover from various failure situations.
A further advantage is that not using persistent data inside the EventInterceptor 130 or the EventReceptor 140 makes them stateless applications. This simplifies deployment, management and scaling.
If the EventInterceptor 130 is not yet paired, any database event generated by the user and detected by the DB Event Mining System 120 is ignored. Instead, the EventInterceptor 130 sends a denial or rejection message to the DB Event Mining System 120. This cycle can occur repeatedly. As the DB Event Mining System 120 keeps sending events to the EventInterceptor 130 and keeps getting rejections in turn, it essentially gets stuck and cannot make progress until the partner of the EventInterceptor 130, the EventReceptor 140, is ready. When the EventReceptor 140 is ready, it sends a pairing request to the EventInterceptor 130 and the two exchange information for pairing. Once the EventInterceptor 130 is paired, it starts accepting database events sent by the DB Event Mining System 120, extracting the associated data and sending it to the EventReceptor. This approach avoids the need for the EventInterceptor 130 to do caching or to concern itself with sending data to the EventReceptor when the EventReceptor is not ready.
In the flowchart, at step 400, the user performs a transaction with a source database 110. At step 401, the DB Event Mining System 120 detects an event associated with the transaction, writes data of the transaction to trail files 121 and notifies the EventInterceptor 130 of the event. A decision step 402 determines whether the EventInterceptor 130 is paired with the EventReceptor 140. If the answer is yes, step 403 is reached where the EventInterceptor 130 extracts data of the event and sends a remote procedure call (RPC) with the data to the EventReceptor 140. Subsequently, at step 404, the EventReceptor 140 writes the data to the target database 150.
If the answer to the decision step 402 is no, step 405 is reached where the EventInterceptor 130 rejects the event and requests a resend of the event at a specified time. This can be any time period such as second, minutes or hours. In this time period, the DB Event Mining System 120 and the EventInterceptor 130 are free to perform other tasks. For example, the EventInterceptor 130 can continue to listen for a potential pairing request from the EventReceptor 140 in case the EventReceptor 140 returns to an online status to pair with the EventInterceptor 130. As mentioned, there is no need for the EventInterceptor 130 to cache data and leverage the trail files 121. The DB Event Mining System 120 can continue to listen for database transactions and store the associated data in the trail files 121. In this approach, the synchronization of the event flow is directed by the EventReceptor 140 so the EventReceptor 140 can consume data whenever it wants.
At step 406, the DB Event Mining System 120 extracts the event from the trail files 121 at the specified time and notifies the EventInterceptor 130. The decision step 402 is then reached again to re-determine whether EventInterceptor 130 is paired with the EventReceptor 140. See
In this example, assume the EventInterceptor 130 is not yet paired with the EventReceptor 140 when the database transaction begins. In this case, the EventReceptor 140 is not available to write data to the target database 150. An arrow 423 depicts the user performing a database transaction. An arrow 424 depicts the DB Event Mining System 120 detecting an associated database event. An arrow 425 depicts the DB Event Mining System 120 writing the data to trail files 121. An arrow 426 depicts the DB Event Mining System 120 notifying the EventInterceptor 130 of the event. An arrow 427 depicts the EventInterceptor 130 determining that it is not paired. An arrow 428 depicts the EventInterceptor 130 rejecting the event and requesting a resend of the event at a specified time.
A dashed box region 435 depicts a sequence of processes which may occur repeatedly while the EventInterceptor 130 remains unpaired. For example, an arrow 429 indicates the DB Event Mining System 120 extracts an event and its data from the trail files 121 at the specified time. An arrow 430 depicts a notification of the event to the EventInterceptor 130. The arrow 431 depicts the EventInterceptor 130 determining that it is still not paired. The arrow 432 depicts the EventInterceptor 130 rejecting the event and requesting a resend of the event at a specified time. At the specified time, e.g., after a specified delay, step 429 is repeated. If the EventInterceptor 130 determines that it is paired with the EventReceptor 140, the sequence of
On the other hand, if the EventInterceptor 130 is down, the DB Event Mining System 120 can determine this when the EventInterceptor 130 does not respond to events pushed to it. Instead, the DB Event Mining System 120 keeps storing data in trail files 121 regarding new transactions at the source database 110. As the EventInterceptor 130 comes online following a failure or a self-initiated shutdown, it returns to the sequence of
In the flowchart, at step 500, the user performs a transaction with the source database 110. At step 501, the DB Event Mining System 120 detects the event, writes corresponding data to the trail files 121, and notifies the EventInterceptor 130. A decision step 502 determines whether the EventReceptor 140 failed. If the answer is no, step 503 indicates the EventInterceptor 130 extracts data of the event, and sends a remote procedure call (RPC) with the data to the EventReceptor 140. At step 504, the EventReceptor 140 writes the data to the target database 150. If the answer to the decision step 502 is yes, at step 505, the EventInterceptor 130 requests a resend of the event at a specified time and shuts itself down. See the sequence diagrams of
At the start of the process, the EventInterceptor 130 and EventReceptor 140 are already paired. In this first pairing, the EventInterceptor 130 responded to a first pairing request from the EventReceptor 140 to pair the EventInterceptor 130 with the EventReceptor 140. When the EventInterceptor 130 determines that the EventReceptor 140 has failed, the EventInterceptor 130 shuts down for a period of time, then restarts. When the EventInterceptor 130 is restarted, it listens for a second pairing request from the event receptor. When the EventInterceptor 130 is restarted and the second pairing request is not received from the EventReceptor 140, the
EventInterceptor 130 is to repeatedly receive and reject the event for the incomplete transaction from the DB Event Mining System 120. When the EventInterceptor 130 receives the second pairing request from the EventReceptor 140, the EventInterceptor 130 is to again pair itself with the EventReceptor 140.
An arrow 527 indicates that a timeout occurs, leading the EventInterceptor 130 to determine that the EventReceptor 140 process is down. For example, this can be a synchronous call time out. It is assumed that the EventInterceptor 130 and EventReceptor 140 were previously paired. An arrow 528 indicates the EventInterceptor 130 requests a resend of the event. An arrow 529 indicates the EventInterceptor 130 shuts itself down for a specified period of time followed by a self-restart. In another implementation, the EventInterceptor 130 is manually restarted by a user.
As requested by the EventInterceptor 130, the DB Event Mining System 120 will resend the event after the specified delay for further processing. Additionally, as the
EventInterceptor 130 is restarted, it can follow the process of
To avoid the need to resend the entire batch of data starting at SCN=1,001, the restart can begin instead at the selected errored event. The EventReceptor 140 will thus request that the EventInterceptor 130 restart from SCN=1,075 instead of SCN 1,001 to optimize performance. A process at the EventReceptor 140 can include: receiving data regarding each event of a plurality of events, e.g., a batch of 100 events, where each event of the plurality of events involves a transfer of data from a source database 110 to a target database 150, writing the data of each event of the plurality of events to the target database 150, after the writing, determining that an error exists with data of a selected event of the plurality of events, e.g., the event of SCN=1,075, and sending a request to resend data regarding a subset of the plurality of events starting with the selected event, where the request comprises an identifier, e.g., SCN, of the selected event. In this case, the EventReceptor 140 can ask the EventInterceptor 130 to replay starting from the specified SCN which represents a previous point in time. The EventReceptor 140 then receives data of the subset of the events identified by SCN=1,075 to 1,000. The EventInterceptor 130 forwards the request to the DB Event Mining System 120.
In the flowchart, at step 600, the EventReceptor 140 determines the need to receive data of an old event, e.g., an event which occurred earlier than the most recent event. For example, the EventReceptor 140 may find that it needs to re-write data from an event which was not written correctly to the target database 150. In another example, the EventReceptor 140 recognizes that a partial SQL write to the target database 150 was performed in a previous batch of transactions. In another example, the EventReceptor 140 needs to replay events since a time at which the target database 150 went down and does not want to start at the first transaction of the batch. The ability to rollback over a period of time leveraging the SCN provides a greater degree of control to the EventReceptor 140, to achieve consistency in writing data to the target database 150. It can also be used to verify data, comparing data in the target database 150 to what is received.
At step 601, the EventReceptor 140 sends a request to the EventInterceptor 130 to restart from a selected SCN. At step 602, the EventInterceptor 130 sends a corresponding request to the DB Event Mining System 120 to restart from the selected SCN. At step 603, the DB Event Mining System 120 retrieves data from trail files 121 at the selected SCN, provides the data to the EventInterceptor 130, and increments the SCN to the next transaction in the batch. A decision step 604 determines whether the SCN is the last SCN in the batch. If the answer is yes, the process ends at step 605. If the answer is no, step 606 increments SCN and step 603 follows. See the sequence diagram of
One or more parts of the above implementations may include software. Software is a general term whose meaning can range from part of the code and/or metadata of a single computer program to the entirety of multiple programs. A computer program (also referred to as a program) comprises code and optionally data. Code (sometimes referred to as computer program code or program code) comprises software instructions (also referred to as instructions). Instructions may be executed by hardware to perform operations. Executing software includes executing code, which includes executing instructions. The execution of a program to perform a task involves executing some or all of the instructions in that program.
An electronic device (also referred to as a device, computing device, computer, etc.) includes hardware and software. For example, an electronic device may include a set of one or more processors coupled to one or more machine-readable storage media (e.g., non-volatile memory such as magnetic disks, optical disks, read only memory (ROM), Flash memory, phase change memory, solid state drives (SSDs) to store code and optionally data. For instance, an electronic device may include non-volatile memory (with slower read/write times) and volatile memory (e.g., dynamic random-access memory (DRAM), static random-access memory (SRAM)). Non-volatile memory persists code/data even when the electronic device is turned off or when power is otherwise removed, and the electronic device copies that part of the code that is to be executed by the set of processors of that electronic device from the non-volatile memory into the volatile memory of that electronic device during operation because volatile memory typically has faster read/write times. As another example, an electronic device may include a non-volatile memory (e.g., phase change memory) that persists code/data when the electronic device has power removed, and that has sufficiently fast read/write times such that, rather than copying the part of the code to be executed into volatile memory, the code/data may be provided directly to the set of processors (e.g., loaded into a cache of the set of processors). In other words, this non-volatile memory operates as both long term storage and main memory, and thus the electronic device may have no or only a small amount of volatile memory for main memory.
In addition to storing code and/or data on machine-readable storage media, typical electronic devices can transmit and/or receive code and/or data over one or more machine-readable transmission media (also called a carrier) (e.g., electrical, optical, radio, acoustical or other forms of propagated signals—such as carrier waves, and/or infrared signals). For instance, typical electronic devices also include a set of one or more physical network interface(s) to establish network connections (to transmit and/or receive code and/or data using propagated signals) with other electronic devices. Thus, an electronic device may store and transmit (internally and/or with other electronic devices over a network) code and/or data with one or more machine-readable media (also referred to as computer-readable media).
Software instructions (also referred to as instructions) are capable of causing (also referred to as operable to cause and configurable to cause) a set of processors to perform operations when the instructions are executed by the set of processors. The phrase “capable of causing” (and synonyms mentioned above) includes various scenarios (or combinations thereof), such as instructions that are always executed versus instructions that may be executed. For example, instructions may be executed: 1) only in certain situations when the larger program is executed (e.g., a condition is fulfilled in the larger program; an event occurs such as a software or hardware interrupt, user input (e.g., a keystroke, a mouse-click, a voice command); a message is published, etc.); or 2) when the instructions are called by another program or part thereof (whether or not executed in the same or a different process, thread, lightweight thread, etc.). These scenarios may or may not require that a larger program, of which the instructions are a part, be currently configured to use those instructions (e.g., may or may not require that a user enables a feature, the feature or instructions be unlocked or enabled, the larger program is configured using data and the program's inherent functionality, etc.). As shown by these exemplary scenarios, “capable of causing” (and synonyms mentioned above) does not require “causing” but the mere capability to cause. While the term “instructions” may be used to refer to the instructions that when executed cause the performance of the operations described herein, the term may or may not also refer to other instructions that a program may include. Thus, instructions, code, program, and software are capable of causing operations when executed, whether the operations are always performed or sometimes performed (e.g., in the scenarios described previously). The phrase “the instructions when executed” refers to at least the instructions that when executed cause the performance of the operations described herein but may or may not refer to the execution of the other instructions.
Electronic devices are designed for and/or used for a variety of purposes, and different terms may reflect those purposes (e.g., user devices, network devices). Some user devices are designed to mainly be operated as servers (sometimes referred to as server devices), while others are designed to mainly be operated as clients (sometimes referred to as client devices, client computing devices, client computers, or end user devices; examples of which include desktops, workstations, laptops, personal digital assistants, smartphones, wearables, augmented reality (AR) devices, virtual reality (VR) devices, mixed reality (MR) devices, etc.). The software executed to operate a user device (typically a server device) as a server may be referred to as server software or server code), while the software executed to operate a user device (typically a client device) as a client may be referred to as client software or client code. A server provides one or more services (also referred to as serves) to one or more clients.
The term “user” refers to an entity (e.g., an individual person) that uses an electronic device. Software and/or services may use credentials to distinguish different accounts associated with the same and/or different users. Users can have one or more roles, such as administrator, programmer/developer, and end user roles. As an administrator, a user typically uses electronic devices to administer them for other users, and thus an administrator often works directly and/or indirectly with server devices and client devices.
In one possible approach, the processes of the database replication service act both as clients and servers. For example, the EventInterceptor 130 may act as a server to the DB Event Mining System 120, which acts as a client, and the EventReceptor 140 may act as a server to the EventInterceptor 130 process, which acts as a client.
During operation, an instance of the software 728 (illustrated as instance 706 and referred to as a software instance; and in the more specific case of an application, as an application instance) is executed. In electronic devices that use compute virtualization, the set of one or more processor(s) 722 typically execute software to instantiate a virtualization layer 708 and one or more software container(s) 704A-704R (e.g., with operating system-level virtualization, the virtualization layer 708 may represent a container engine (such as Docker Engine by Docker, Inc. or rkt in Container Linux by Red Hat, Inc.) running on top of (or integrated into) an operating system, and it allows for the creation of multiple software containers 704A-704R (representing separate user space instances and also called virtualization engines, virtual private servers, or jails) that may each be used to execute a set of one or more applications; with full virtualization, the virtualization layer 708 represents a hypervisor (sometimes referred to as a virtual machine monitor (VMM)) or a hypervisor executing on top of a host operating system, and the software containers 704A-704R each represent a tightly isolated form of a software container called a virtual machine that is run by the hypervisor and may include a guest operating system; with para-virtualization, an operating system and/or application running with a virtual machine may be aware of the presence of virtualization for optimization purposes). Again, in electronic devices where compute virtualization is used, during operation, an instance of the software 728 is executed within the software container 704A on the virtualization layer 708. In electronic devices where compute virtualization is not used, the instance 706 on top of a host operating system is executed on the “bare metal” electronic device 700. The instantiation of the instance 706, as well as the virtualization layer 708 and software containers 704A-704R if implemented, are collectively referred to as software instance(s) 702.
Alternative implementations of an electronic device may have numerous variations from that described above. For example, customized hardware and/or accelerators might also be used in an electronic device.
The system 740 is coupled to user devices 780A-780S over a network 782. The service(s) 742 may be on-demand services that are made available to one or more of the users 784A-784S working for one or more entities other than the entity which owns and/or operates the on-demand services (those users sometimes referred to as outside users) so that those entities need not be concerned with building and/or maintaining a system, but instead may make use of the service(s) 742 when needed (e.g., when needed by the users 784A-784S). The service(s) 742 may communicate with each other and/or with one or more of the user devices 780A-780S via one or more APIs (e.g., a REST API). In some implementations, the user devices 780A-780S are operated by users 784A-784S, and each may be operated as a client device and/or a server device. In some implementations, one or more of the user devices 780A-780S are separate ones of the electronic device 700 or include one or more features of the electronic device 700.
In some implementations, the system 740 is a multi-tenant system (also known as a multi-tenant architecture). The term multi-tenant system refers to a system in which various elements of hardware and/or software of the system may be shared by one or more tenants. A multi-tenant system may be operated by a first entity (sometimes referred to a multi-tenant system provider, operator, or vendor; or simply a provider, operator, or vendor) that provides one or more services to the tenants (in which case the tenants are customers of the operator and sometimes referred to as operator customers). A tenant includes a group of users who share a common access with specific privileges. The tenants may be different entities (e.g., different companies, different departments/divisions of a company, and/or other types of entities), and some or all of these entities may be vendors that sell or otherwise provide products and/or services to their customers (sometimes referred to as tenant customers). A multi-tenant system may allow each tenant to input tenant specific data for user management, tenant-specific functionality, configuration, customizations, non-functional properties, associated applications, etc. A tenant may have one or more roles relative to a system and/or service. For example, in the context of a customer relationship management (CRM) system or service, a tenant may be a vendor using the CRM system or service to manage information the tenant has regarding one or more customers of the vendor. As another example, in the context of Data as a Service (DAAS), one set of tenants may be vendors providing data and another set of tenants may be customers of different ones or all of the vendors' data. As another example, in the context of Platform as a Service (PAAS), one set of tenants may be third-party application developers providing applications/services and another set of tenants may be customers of different ones or all of the third-party application developers.
Multi-tenancy can be implemented in different ways. In some implementations, a multi-tenant architecture may include a single software instance (e.g., a single database instance) which is shared by multiple tenants; other implementations may include a single software instance (e.g., database instance) per tenant; yet other implementations may include a mixed model; e.g., a single software instance (e.g., an application instance) per tenant and another software instance (e.g., database instance) shared by multiple tenants.
In one implementation, the system 740 is a multi-tenant cloud computing architecture supporting multiple services, such as one or more of the following types of services: database replication service (see the system 100 in
For example, system 740 may include an application platform 744 that enables PAAS for creating, managing, and executing one or more applications developed by the provider of the application platform 744, users accessing the system 740 via one or more of user devices 780A-780S, or third-party application developers accessing the system 740 via one or more of user devices 780A-780S.
In some implementations, one or more of the service(s) 742 may use one or more multi-tenant databases 746, as well as system data storage 750 for system data 752 accessible to system 740. In certain implementations, the system 740 includes a set of one or more servers that are running on server electronic devices and that are configured to handle requests for any authorized user associated with any tenant (there is no server affinity for a user and/or tenant to a specific server). The user devices 780A-780S communicate with the server(s) of system 740 to request and update tenant-level data and system-level data hosted by system 740, and in response the system 740 (e.g., one or more servers in system 740) automatically may generate one or more Structured Query Language (SQL) statements (e.g., one or more SQL queries) that are designed to access the desired information from the multi-tenant database(s) 746 and/or system data storage 750.
In some implementations, the service(s) 742 are implemented using virtual applications dynamically created at run time responsive to queries from the user devices 780A-780S and in accordance with metadata, including: 1) metadata that describes constructs (e.g., forms, reports, workflows, user access privileges, business logic) that are common to multiple tenants; and/or 2) metadata that is tenant specific and describes tenant specific constructs (e.g., tables, reports, dashboards, interfaces, etc.) and is stored in a multi-tenant database. To that end, the program code 760 may be a runtime engine that materializes application data from the metadata; that is, there is a clear separation of the compiled runtime engine (also known as the system kernel), tenant data, and the metadata, which makes it possible to independently update the system kernel and tenant-specific applications and schemas, with virtually no risk of one affecting the others. Further, in one implementation, the application platform 744 includes an application setup mechanism that supports application developers' creation and management of applications, which may be saved as metadata by save routines. Invocations to such applications, including the database replication service, may be coded using Procedural Language/Structured Object Query Language (PL/SOQL) that provides a programming language style interface. Invocations to applications may be detected by one or more system processes, which manages retrieving application metadata for the tenant making the invocation and executing the metadata as an application in a software container (e.g., a virtual machine).
Network 782 may be any one or any combination of a LAN (local area network), WAN (wide area network), telephone network, wireless network, point-to-point network, star network, token ring network, hub network, or other appropriate configuration. The network may comply with one or more network protocols, including an Institute of Electrical and Electronics Engineers (IEEE) protocol, a 3rd Generation Partnership Project (3GPP) protocol, a 4th generation wireless protocol (4G) (e.g., the Long Term Evolution (LTE) standard, LTE Advanced, LTE Advanced Pro), a fifth generation wireless protocol (5G), and/or similar wired and/or wireless protocols, and may include one or more intermediary devices for routing data between the system 740 and the user devices 780A-780S.
Each user device 780A-780S (such as a desktop personal computer, workstation, laptop, Personal Digital Assistant (PDA), smartphone, smartwatch, wearable device, augmented reality (AR) device, virtual reality (VR) device, etc.) typically includes one or more user interface devices, such as a keyboard, a mouse, a trackball, a touch pad, a touch screen, a pen or the like, video or touch free user interfaces, for interacting with a graphical user interface (GUI) provided on a display (e.g., a monitor screen, a liquid crystal display (LCD), a head-up display, a head-mounted display, etc.) in conjunction with pages, forms, applications and other information provided by system 740. For example, the user interface device can be used to access data and applications hosted by system 740, and to perform searches on stored data, and otherwise allow one or more of users 784A-784S to interact with various GUI pages that may be presented to the one or more of users 784A-784S. User devices 780A-780S might communicate with system 740 using TCP/IP (Transfer Control Protocol and Internet Protocol) and, at a higher network level, use other networking protocols to communicate, such as Hypertext Transfer Protocol (HTTP), File Transfer Protocol (FTP), Andrew File System (AFS), Wireless Application Protocol (WAP), Network File System (NFS), an application program interface (API) based upon protocols such as Simple Object Access Protocol (SOAP), Representational State Transfer (REST), etc. In an example where HTTP is used, one or more user devices 780A-780S might include an HTTP client, commonly referred to as a “browser,” for sending and receiving HTTP messages to and from server(s) of system 740, thus allowing users 784A-784S of the user devices 780A-780S to access, process and view information, pages and applications available to it from system 740 over network 782.
In the above description, numerous specific details such as resource partitioning/sharing/duplication implementations, types and interrelationships of system components, and logic partitioning/integration choices are set forth in order to provide a more thorough understanding. The invention may be practiced without such specific details, however. In other instances, control structures, logic implementations, opcodes, means to specify operands, and full software instruction sequences have not been shown in detail since those of ordinary skill in the art, with the included descriptions, will be able to implement what is described without undue experimentation.
References in the specification to “one implementation,” “an implementation,” “an example implementation,” etc., indicate that the implementation described may include a particular feature, structure, or characteristic, but every implementation may not necessarily include the particular feature, structure, or characteristic. Moreover, such phrases are not necessarily referring to the same implementation. Further, when a particular feature, structure, and/or characteristic is described in connection with an implementation, one skilled in the art would know to affect such feature, structure, and/or characteristic in connection with other implementations whether or not explicitly described.
For example, the figure(s) illustrating flow diagrams sometimes refer to the figure(s) illustrating block diagrams, and vice versa. Whether or not explicitly described, the alternative implementations discussed with reference to the figure(s) illustrating block diagrams also apply to the implementations discussed with reference to the figure(s) illustrating flow diagrams, and vice versa. At the same time, the scope of this description includes implementations, other than those discussed with reference to the block diagrams, for performing the flow diagrams, and vice versa.
Bracketed text and blocks with dashed borders (e.g., large dashes, small dashes, dot-dash, and dots) may be used herein to illustrate optional operations and/or structures that add additional features to some implementations. However, such notation should not be taken to mean that these are the only options or optional operations, and/or that blocks with solid borders are not optional in certain implementations.
The detailed description and claims may use the term “coupled,” along with its derivatives. “Coupled” is used to indicate that two or more elements, which may or may not be in direct physical or electrical contact with each other, co-operate or interact with each other.
While the flow diagrams in the figures show a particular order of operations performed by certain implementations, such order is exemplary and not limiting (e.g., alternative implementations may perform the operations in a different order, combine certain operations, perform certain operations in parallel, overlap performance of certain operations such that they are partially in parallel, etc.).
While the above description includes several example implementations, the invention is not limited to the implementations described and can be practiced with modification and alteration within the spirit and scope of the appended claims. The description is thus illustrative instead of limiting.
Number | Name | Date | Kind |
---|---|---|---|
5577188 | Zhu | Nov 1996 | A |
5608872 | Schwartz et al. | Mar 1997 | A |
5649104 | Carleton et al. | Jul 1997 | A |
5715450 | Ambrose et al. | Feb 1998 | A |
5761419 | Schwartz et al. | Jun 1998 | A |
5819038 | Carleton et al. | Oct 1998 | A |
5821937 | Tonelli et al. | Oct 1998 | A |
5831610 | Tonelli et al. | Nov 1998 | A |
5873096 | Lim et al. | Feb 1999 | A |
5918159 | Fomukong et al. | Jun 1999 | A |
5963953 | Cram et al. | Oct 1999 | A |
5983227 | Nazem et al. | Nov 1999 | A |
6092083 | Brodersen et al. | Jul 2000 | A |
6161149 | Achacoso et al. | Dec 2000 | A |
6169534 | Raffel et al. | Jan 2001 | B1 |
6178425 | Brodersen et al. | Jan 2001 | B1 |
6189011 | Lim et al. | Feb 2001 | B1 |
6216133 | Masthoff | Apr 2001 | B1 |
6216135 | Brodersen et al. | Apr 2001 | B1 |
6233617 | Rothwein et al. | May 2001 | B1 |
6236978 | Tuzhilin | May 2001 | B1 |
6266669 | Brodersen et al. | Jul 2001 | B1 |
6288717 | Dunkle | Sep 2001 | B1 |
6295530 | Ritchie et al. | Sep 2001 | B1 |
6324568 | Diec et al. | Nov 2001 | B1 |
6324693 | Brodersen et al. | Nov 2001 | B1 |
6336137 | Lee et al. | Jan 2002 | B1 |
D454139 | Feldcamp et al. | Mar 2002 | S |
6367077 | Brodersen et al. | Apr 2002 | B1 |
6393605 | Loomans | May 2002 | B1 |
6405220 | Brodersen et al. | Jun 2002 | B1 |
6411949 | Schaffer | Jun 2002 | B1 |
6434550 | Warner et al. | Aug 2002 | B1 |
6446089 | Brodersen et al. | Sep 2002 | B1 |
6535909 | Rust | Mar 2003 | B1 |
6549908 | Loomans | Apr 2003 | B1 |
6553563 | Ambrose et al. | Apr 2003 | B2 |
6560461 | Fomukong et al. | May 2003 | B1 |
6574635 | Stauber et al. | Jun 2003 | B2 |
6577726 | Huang et al. | Jun 2003 | B1 |
6601087 | Zhu et al. | Jul 2003 | B1 |
6604117 | Lim et al. | Aug 2003 | B2 |
6604128 | Diec et al. | Aug 2003 | B2 |
6609150 | Lee et al. | Aug 2003 | B2 |
6621834 | Scherpbier et al. | Sep 2003 | B1 |
6654032 | Zhu et al. | Nov 2003 | B1 |
6665648 | Brodersen et al. | Dec 2003 | B2 |
6665655 | Warner et al. | Dec 2003 | B1 |
6684438 | Brodersen et al. | Feb 2004 | B2 |
6711565 | Subramaniam et al. | Mar 2004 | B1 |
6724399 | Katchour et al. | Apr 2004 | B1 |
6728702 | Subramaniam et al. | Apr 2004 | B1 |
6728960 | Loomans et al. | Apr 2004 | B1 |
6732095 | Warshavsky et al. | May 2004 | B1 |
6732100 | Brodersen et al. | May 2004 | B1 |
6732111 | Brodersen et al. | May 2004 | B2 |
6754681 | Brodersen et al. | Jun 2004 | B2 |
6763351 | Subramaniam et al. | Jul 2004 | B1 |
6763501 | Zhu et al. | Jul 2004 | B1 |
6768904 | Kim | Jul 2004 | B2 |
6772229 | Achacoso et al. | Aug 2004 | B1 |
6782383 | Subramaniam et al. | Aug 2004 | B2 |
6804330 | Jones et al. | Oct 2004 | B1 |
6826565 | Ritchie et al. | Nov 2004 | B2 |
6826582 | Chatterjee et al. | Nov 2004 | B1 |
6826745 | Coker | Nov 2004 | B2 |
6829655 | Huang et al. | Dec 2004 | B1 |
6842748 | Warner et al. | Jan 2005 | B1 |
6850895 | Brodersen et al. | Feb 2005 | B2 |
6850949 | Warner et al. | Feb 2005 | B2 |
6907566 | McElfresh et al. | Jun 2005 | B1 |
7062502 | Kesler | Jun 2006 | B1 |
7069231 | Cinarkaya | Jun 2006 | B1 |
7069497 | Desai | Jun 2006 | B1 |
7100111 | McElfresh et al. | Aug 2006 | B2 |
7181758 | Chan | Feb 2007 | B1 |
7269590 | Hull et al. | Sep 2007 | B2 |
7289976 | Kihneman et al. | Oct 2007 | B2 |
7340411 | Cook | Mar 2008 | B2 |
7356482 | Frankland et al. | Apr 2008 | B2 |
7373599 | McElfresh et al. | May 2008 | B2 |
7401094 | Kesler | Jul 2008 | B1 |
7406501 | Szeto et al. | Jul 2008 | B2 |
7412455 | Dillon | Aug 2008 | B2 |
7454509 | Boulter et al. | Nov 2008 | B2 |
7508789 | Chan | Mar 2009 | B2 |
7599935 | La Rotonda et al. | Oct 2009 | B2 |
7603331 | Tuzhilin et al. | Oct 2009 | B2 |
7603483 | Psounis et al. | Oct 2009 | B2 |
7620655 | Larsson et al. | Nov 2009 | B2 |
7644122 | Weyer et al. | Jan 2010 | B2 |
7668861 | Steven | Feb 2010 | B2 |
7698160 | Beaven et al. | Apr 2010 | B2 |
7730478 | Weissman | Jun 2010 | B2 |
7747648 | Kraft et al. | Jun 2010 | B1 |
7779039 | Weissman et al. | Aug 2010 | B2 |
7779475 | Jakobson et al. | Aug 2010 | B2 |
7827208 | Bosworth et al. | Nov 2010 | B2 |
7853881 | Aly Assal et al. | Dec 2010 | B1 |
7945653 | Zukerberg et al. | May 2011 | B2 |
8005896 | Cheah | Aug 2011 | B2 |
8014943 | Jakobson | Sep 2011 | B2 |
8015495 | Achacoso et al. | Sep 2011 | B2 |
8032297 | Jakobson | Oct 2011 | B2 |
8073850 | Hubbard et al. | Dec 2011 | B1 |
8082301 | Ahlgren et al. | Dec 2011 | B2 |
8095413 | Beaven | Jan 2012 | B1 |
8095531 | Weissman et al. | Jan 2012 | B2 |
8095594 | Beaven et al. | Jan 2012 | B2 |
8103611 | Tuzhilin et al. | Jan 2012 | B2 |
8150913 | Cheah | Apr 2012 | B2 |
8209308 | Rueben et al. | Jun 2012 | B2 |
8209333 | Hubbard et al. | Jun 2012 | B2 |
8275836 | Beaven et al. | Sep 2012 | B2 |
8457545 | Chan | Jun 2013 | B2 |
8484111 | Frankland et al. | Jul 2013 | B2 |
8490025 | Jakobson et al. | Jul 2013 | B2 |
8504945 | Jakobson et al. | Aug 2013 | B2 |
8510045 | Rueben et al. | Aug 2013 | B2 |
8510664 | Rueben et al. | Aug 2013 | B2 |
8566301 | Rueben et al. | Oct 2013 | B2 |
8646103 | Jakobson et al. | Feb 2014 | B2 |
10216820 | Holenstein | Feb 2019 | B1 |
11748212 | Holenstein | Sep 2023 | B1 |
20010044791 | Richter et al. | Nov 2001 | A1 |
20020072951 | Lee et al. | Jun 2002 | A1 |
20020082892 | Raffel et al. | Jun 2002 | A1 |
20020129352 | Brodersen et al. | Sep 2002 | A1 |
20020140731 | Subramaniam et al. | Oct 2002 | A1 |
20020143997 | Huang et al. | Oct 2002 | A1 |
20020162090 | Parnell et al. | Oct 2002 | A1 |
20020165742 | Robbins | Nov 2002 | A1 |
20030004971 | Gong | Jan 2003 | A1 |
20030018705 | Chen et al. | Jan 2003 | A1 |
20030018830 | Chen et al. | Jan 2003 | A1 |
20030066031 | Laane et al. | Apr 2003 | A1 |
20030066032 | Ramachandran et al. | Apr 2003 | A1 |
20030069936 | Warner et al. | Apr 2003 | A1 |
20030070000 | Coker et al. | Apr 2003 | A1 |
20030070004 | Mukundan et al. | Apr 2003 | A1 |
20030070005 | Mukundan et al. | Apr 2003 | A1 |
20030074418 | Coker et al. | Apr 2003 | A1 |
20030120675 | Stauber et al. | Jun 2003 | A1 |
20030151633 | George et al. | Aug 2003 | A1 |
20030159136 | Huang et al. | Aug 2003 | A1 |
20030187921 | Diec et al. | Oct 2003 | A1 |
20030189600 | Gune et al. | Oct 2003 | A1 |
20030204427 | Gune et al. | Oct 2003 | A1 |
20030206192 | Chen et al. | Nov 2003 | A1 |
20030225730 | Warner et al. | Dec 2003 | A1 |
20040001092 | Rothwein et al. | Jan 2004 | A1 |
20040010489 | Rio et al. | Jan 2004 | A1 |
20040015981 | Coker et al. | Jan 2004 | A1 |
20040027388 | Berg et al. | Feb 2004 | A1 |
20040128001 | Levin et al. | Jul 2004 | A1 |
20040186860 | Lee et al. | Sep 2004 | A1 |
20040193510 | Catahan et al. | Sep 2004 | A1 |
20040199489 | Barnes-Leon et al. | Oct 2004 | A1 |
20040199536 | Barnes-Leon et al. | Oct 2004 | A1 |
20040199543 | Braud et al. | Oct 2004 | A1 |
20040249854 | Barnes-Leon et al. | Dec 2004 | A1 |
20040260534 | Pak et al. | Dec 2004 | A1 |
20040260659 | Chan et al. | Dec 2004 | A1 |
20040268299 | Lei et al. | Dec 2004 | A1 |
20050050555 | Exley et al. | Mar 2005 | A1 |
20050091098 | Brodersen et al. | Apr 2005 | A1 |
20080249972 | Dillon | Oct 2008 | A1 |
20090059788 | Granovsky | Mar 2009 | A1 |
20090063415 | Chatfield et al. | Mar 2009 | A1 |
20090100342 | Jakobson | Apr 2009 | A1 |
20090177744 | Marlow et al. | Jul 2009 | A1 |
20110218958 | Warshavsky | Sep 2011 | A1 |
20110247051 | Bulumulla | Oct 2011 | A1 |
20120042218 | Cinarkaya | Feb 2012 | A1 |
20120233137 | Jakobson et al. | Sep 2012 | A1 |
20120290407 | Hubbard et al. | Nov 2012 | A1 |
20130212497 | Zelenko et al. | Aug 2013 | A1 |
20130218948 | Jakobson | Aug 2013 | A1 |
20130218949 | Jakobson | Aug 2013 | A1 |
20130218966 | Jakobson | Aug 2013 | A1 |
20130247216 | Cinarkaya | Sep 2013 | A1 |
20140359537 | Jackobson et al. | Dec 2014 | A1 |
20180176307 | Kancherla | Jun 2018 | A1 |
20210182162 | Kohli | Jun 2021 | A1 |
Number | Date | Country | |
---|---|---|---|
20230229670 A1 | Jul 2023 | US |