Databases Reference
In-Depth Information
One of the uses for smart branching is to implement a form of caching in which the consumer caches parts of
its data locally or fetches it from a cloud database whenever necessary. You can also use this pattern to implement a
disconnected mode to your application, in case Internet connectivity becomes unavailable.
Transparent Branching
Whereas smart branching depends on the consumer (or one of its components) to determine whether data is local
or in the cloud, transparent branching (see Figure 2-6 ) removes this concern from the consumer. The consuming
application no longer depends on routing logic and becomes oblivious to the ultimate location of the data.
Figure 2-6. Transparent branching pattern
This pattern is best implemented by applications that are difficult to modify or for which the cost of
implementation is prohibitive. It can effectively be implemented in the form of extended stored procedures that have
the knowledge to fetch data from a cloud data source. In essence, this pattern implements a DAL at the database layer.
Sharding
So far, you've seen patterns that implement a single connection at a time. In a shard (see Figure 2-7 ), multiple
databases can be accessed simultaneously in a read and/or write fashion and can be located in a mixed environment
(local and cloud). However, keep in mind that the total availability of your shard depends partially on the availability
of your local databases.
 
Search WWH ::




Custom Search