Unformatted text preview:

Client-server caching and object storesClient-server database designOverviewClient-server systemsNetworks of workstationsNaive client-server data accessClient-server cachingCaching principlesCaching in distributed file systemsDisadvantages of cachingClient-server caching revisitedDividing the workWhy cache data?Database client cachingThe downsideCaching in EXODUSAlternatives for cachingWhat to do on writeback?What to do on writeback?A taxonomy of strategiesOptimistic 2PLCallback lockingExperimentsHOTCOLD workload, slow networkFEED workload, slow networkHICON workload, fast networkSummaryQuickStore: a high-performance mapped object storeObject-oriented versus object-relational DBsThe programming interfaceDesign alternativesQuickStore structureFine points of pointer swizzlingPage faultsQuickStore page faultsThe mapping procedureThe ESM buffer managerOptimisationsHardware versus software swizzlingComparison: the OO7 benchmarkCold times, small databaseHot times, small databaseCold times, medium databaseQuickStore and E comparedClient-server caching and object storesBenjamin [email protected] cachingClient-server database designLow-level considerationsHow can database systems exploit powerful client machines?What implementation techniques are required?High-level considerationsWhat interface is provided to applications?How can we efficiently implement it?3Client-server cachingOverviewClient-server systemsAdvantages of caching Object-oriented databasesWisconsin's Exodus storage managerCache consistency and transactionsImplementation of programming interface: QuickStore4Client-server cachingClient-server systemsSimplify the client machinesShare services: filesystem, database, ...Run on powerful, dedicated hostsUser machines are "clients" of serversenables data sharingcentralised maintenancegreater securitye.g. Sun’s Network File System5Client-server cachingNetworks of workstationsc. 1990: more powerful clientsMove some processing to clientsfaster response timebetter utilisation of client machinesless load on servergreater scalabilityautonomy in the face of server failure6Client-server cachingNaive client-server data access..."read blue object""read blue object"7Client-server cachingClient-server caching..."read blue object""read blue object"8Client-server cachingCaching principlesAnalogous to hardware cachingServer stores the canonical copy of dataClient caches the results of each readSubsequent accesses served from cacheWhat if the data changes? Alternatives:"cheap to detect incorrect data", e.g. DNS"validate before use""notify on change"9Client-server cachingCaching in distributed file systemsCMU's Andrew File Systemclients cache all files on local disks50 client machines for each serverUC Berkeley's Sprite OSfile cache completes with virtual memoryCoda follow-up to AFS, UCLA's Ficusclient can completely disconnect from serverprediction algorithms to determine what to cache10Client-server cachingDisadvantages of cachingIncreases client workload, complexityWe may cache the wrong data!potentially wasted network trafficuses valuable space in the cacheData consistency problemstale cached datasimultaneous writebackClient-server caching revisitedMichael J. Franklin and Michael J. Carey12Client-server cachingDividing the workQuery shippingclients send queries to the serverData shippingclients request data from servertransactions run locallypotential for caching13Client-server cachingWhy cache data?A client may read a data object repeatedlyread and write an objectexecute multiple transactions on an objectCache an object and execute transactions locallyWrite back final value on commit14Client-server cachingDatabase client cachingclient serverbegin transactionread Awrite Aend transactioncache Astore Abegin transactionread A...read B15Client-server cachingThe downsideIntroduces a consistency problemIncreases work at client Slower under some conditionsPotentially higher abort rates ......16Client-server cachingCaching in EXODUSSmall objects are grouped in fixed-size disk pagesCaching and locking at the page levelClient has buffer manager, lock managerFranklin+Livny investigate the best strategy for caching with transactions17Client-server cachingAlternatives for cachingIntra-transaction versus inter-transaction cachingCaching locks as well as dataLocal versus global lockingOptimistic versus centralised lockingInvalidation versus propagation of updates18Client-server cachingWhat to do on writeback?begin transaction...fetch blue object19Client-server cachingWhat to do on writeback? commit transaction?propagate or invalidate?20Client-server cachingA taxonomy of strategiesPrimary-copy server 2PLCaching 2PLno lock caching, validate data before useOptimistic 2PL variantsO2PL-Dynamic, O2PL-New DynamicCallback locking21Client-server cachingOptimistic 2PLDuring transaction acquire local locksAt commit, validate with serverPropagation variant requires 2PCDynamic variant's propagation heuristicpage is resident at receiving siteaccessed since last propagation of pagepreviously invalidated this page incorrectly22Client-server cachingCallback lockingGlobal locks required during transactionOn lock conflict, server callback to revoke other locksNo validation required on commitCB-Read: cache only read locksCB-All: cache write locks as well, lock downgrade on conflict23Client-server cachingExperimentsVary data access patternsVary bottlenecks in the system24Client-server cachingHOTCOLD workload, slow network25Client-server cachingFEED workload,slow network26Client-server cachingHICON workload,fast network27Client-server cachingSummaryCB-Read, O2PL-ND come out bestCB-Read implemented in EXODUSlower abort rate than O2PL-NDscales better with data contentionNatural consequences of the optimistic approach?QuickStore: a high-performance mapped object storeSeth J. White and David J. DeWitt29Client-server cachingObject-oriented versus object-relational DBsDistributed application supportPersistent store for program dataAccess through programming language (C++), not SQLTransactions over objects30Client-server cachingThe programming interfaceApplication manipulates object identifiers


View Full Document

CORNELL CS 632 - Study Notes

Download Study Notes
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Study Notes and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Study Notes 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?