skip to main content
article
Free Access

Optimism and consistency in partitioned distributed database systems

Published:01 September 1984Publication History
Skip Abstract Section

Abstract

A protocol for transaction processing during partition failures is presented which guarantees mutual consistency between copies of data-items after repair is completed. The protocol is “optimistic” in that transactions are processed without restrictions during failure; conflicts are then detected at repair time using a precedence graph, and are resolved by backing out transactions according to some backout strategy. The resulting database state then corresponds to a serial execution of some subset of transactions run during the failure. Results from simulation and probabilistic modeling show that the optimistic protocol is a reasonable alternative in many cases. Conditions under which the protocol performs well are noted, and suggestions are made as to how performance can be improved. In particular, a backout strategy is presented which takes into account individual transaction costs and attempts to minimize total backout cost. Although the problem of choosing transactions to minimize total backout cost is, in general, NP-complete, the backout strategy is efficient and produces very good results.

References

  1. 1 AHO, A.V., HOPCROFT, J.E., AND ULLMAN, J.D. The Design and Analysis of Computer Algorithms. Addison-Wesley, Reading, Mass., 1974. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. 2 ALSBERG, P.A., AND DAY, J.D. A principle for resilient sharing of distributed resources. In Proceedings 2nd International Conference on Software Engineering {Oct. 13-15, 1976), 562-570. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. 3 BERNSTEIN, P.A., ROTHNIE, J.B., GOODMAN, N., AND PAPADIMITRIOU, C.A. The concurrency control mechanism of SDD-I: A system for distributed databases (the fully redundant case). IEEE Trans. So{tw. Eng. 4, 3 (May 1978), 154-167.Google ScholarGoogle Scholar
  4. 4 BERNSTEIN, P.A., SHIPMAN, D.W., AND WONG, W.S. Formal aspects of serializability in database concurrency control. IEEE Trans. Softw. Eng. 5, 3 (May 1979), 203-216.Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. 5 DAVIDSON, S.B., GARCIA-MOLINA, H., AND SKEEN, D. Consistency in the face of partition failures: A survey. Tech. Rep. TR#84-4, Dept. of Computer and Information Sciences, Univ. of Pennsylvania, Feb. 1984.Google ScholarGoogle Scholar
  6. 6 DAVIDSON, S.B. An optimistic protocol for partitioned distributed database systems. Ph.D. dissertation, Dept. of Electrical Engineering and Computer Science, Princeton Univ. Princeton, N.J., Oct. 1982. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. 7 ESWARAN, K.P., GARY, J.N., LOR{E, R.A., AND TRAIGER, I.L. The notions of consistency and predicate locks in a database system. Commun. ACM I9, 11 (Nov. 1976), 624-633. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. 8 GAREY, M.R., AND JOHNSON, D.S. Computers and Intractability: A Guide to the Theory of NP- Completeness. W.H. Freeman and Co., San Francisco, 1979. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. 9 GARCIA-MOLINA, H. Elections in a distributed computing system. IEEE Trans. Comput. C-31, 1 (Jan. 1982), 48-59.Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. 10 GARCIA-MOLINA, H. Using semantic knowledge for transaction processing in a distributed database. ACM Trans. Database Syst. 8, 2 {June 1983), 186-213. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. 11 GIFFORD, D.K. Weighted voting for replicated data. In Proceedings 7th Symposium on Operating System Principles (Pacific Grove, Calif., Dec. 10-12, 1979), ACM, New York, 150-162. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. 12 HAMMER, M.M., AND SHIPMAN, D.W. The reliability mechanisms of SDD-I: A system for distributed databases. ACM Trans. Database Syst. 5, 4 (Dec. 1980), 431-466. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. 13 HOPCROFT, J.E., AND KARP, R.M. An n25 algorithm for maximum matching in bipartite graphs. J. SIAM Comput 2 (1973), 225-231.Google ScholarGoogle ScholarCross RefCross Ref
  14. 14 JOHNSON, D.B. Finding all the elementary circuits of a directed graph. SIAM J. Comput. 4 (1975), 77-84.Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. 15 KARP, R.M. Reducibility among combinatorial problems. In Complexity of Computer Computations, R.E. Miller and J.W. Thatcher, Eds., Plenum Press, New York, 85-103.Google ScholarGoogle Scholar
  16. 16 LAWLER, E.L. Combinatorial Optimization: Networks and Matroids. Holt, Rinehart and Winston, New York, 1976.Google ScholarGoogle Scholar
  17. 17 LIPSKI, W. On semantic issues connected with incomplete information databases. A CM Trans. Database Syst. 4, 3 (Sept. 1979), 262-296. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. 18 LYHCH, N.A. Multilevel atomicity--a new correctness criterion for distributed databases. ACM Trans. Database Syst. 8, 4 (Dec. 1983), 484-502. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. 19 MINOtJRA, T., AND WEIDERHOLD, G. Resilient extended true-copy token scheme for a distributed database system. IEEE Trans. Softw. Eng. SE8, 3 (May 1982), 173-189.Google ScholarGoogle Scholar
  20. 20 PAPADIMITRIOU, C.H. The serializability of concurrent database updates. J. ACM 26, 4 (Oct. 1979), 631-653. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. 21 PAPADIMITRIOU, C.H., AND STEIGLITZ, K. Combinatorhl Optimization: Algorithms and Complexity. Prentice Hall, Englewood Cliffs, N.J., 1982. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. 22 PARKER, D.S., POPEK, G.J., RUDISIN, G., STOUGHTON, A., WALKER, B., WALTON, E., CHOW, J., EDWARDS, D., KISER, S., AND KLINE, C. Detection of mutual inconsistency in distributed systems. In Proceedings 5th Berkeley Workshop on Distributed Data Management and Computer Networks (Feb. 1981), 172-183.Google ScholarGoogle Scholar
  23. 23 PARKER, D.S., AND RAMOS, R.A. A distributed file system architecture supporting high availability. In Proceedings 6th Berkeley Workshop on Distributed Data Management and Computer Networks (1982), 161-183.Google ScholarGoogle Scholar
  24. 24 REINGOLD, E.M., NEIVERGELT, J., AND DEO, N. CombinatorialAlgorithms: Theory and Practice. Prentice-Hall, Englewood Cliffs, N.J., 1977, 348-352. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. 25 ROTHNIE, J.B., AND GOODMAN, N. A survey of research and development in distributed database management. In Proceedings 3rd International Conference on Very Large Databases (Tokyo, Oct. 1977), 48-61.Google ScholarGoogle Scholar
  26. 26 STEARNS, R.E., LEWIS, P.M., II, AND ROSENKRANTZ, D.J. Concurrency control for database systems. In Foundations of Computer Science (1976), 19-32.Google ScholarGoogle Scholar
  27. 27 THOMAS, R.H. A solution to the concurrency control problem for multiple copy databases. In IEEE Compcon {Spring 1978), 56-62.Google ScholarGoogle Scholar
  28. 28 TRAIGER, I.L., GRAY, J.N., GALTIERI, C.A., AND LINDSAY, B.G. Transactions and consistency in distributed database systems. IBM Res. Rep. RJ2555 33155, June 5, 1979.Google ScholarGoogle Scholar
  29. 29 WRIGHT, D.D. Merging partitioned databases. Ph.D. dissertation, TR83-575, Dept. of Computer Science, Cornell Univ., Ithaca, N.Y., Sept. 1983. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Optimism and consistency in partitioned distributed database systems

            Recommendations

            Reviews

            Jason Gait

            This paper describes a protocol for recovering from partitions in fully replicated distributed database systems. The protocol is optimistic in allowing transactions to proceed to their commit point during the partition, and only guarantees globally consistent data after the partition is recovered. The author proposes a method for automating conflict detection and transaction backout, based on precedence graphs whose cycles correspond to conflicts. When a partition is rejoined, a coordinating site is designated in each half of the partition, and all processing of transactions is temporarily blocked. Each coordinator constructs a totally ordered transaction history for its half of the partition, and the tansaction histories are merged to form the precedence graph. The edges in the precedence graph represent the required ordering of transactions, with ripple edges representing the effect of backing out transactions and interference edges representing conflicts between transactions in different partition halves. A backout strategy is employed to select some set of transactions to be backed out until the precedence graph is acyclic. The partitions can then be merged to form a mutually consistent global transaction history. Backout strategies attempt to minimize the cost of backed out transactions, but the problem of selecting a minimal cost set of transactions to backout is NP-complete. The paper presents simulation results for several heuristic backout strategies. The most successful backout strategy detects and breaks two-cycles before looking for longer cycles. The simulations indicate there is on the average just one long cycle remaining after removal of the two-cycles. The problem of breaking the two-cycles for th case of two partition groups is polynomial in the total number of nodes, and if no long cycles remain after breaking the two-cycles, then minimizing backout cost is also a polynomial problem.

            Access critical reviews of Computing literature here

            Become a reviewer for Computing Reviews.

            Comments

            Login options

            Check if you have access through your login credentials or your institution to get full access on this article.

            Sign in

            Full Access

            • Published in

              cover image ACM Transactions on Database Systems
              ACM Transactions on Database Systems  Volume 9, Issue 3
              Sept. 1984
              172 pages
              ISSN:0362-5915
              EISSN:1557-4644
              DOI:10.1145/1270
              Issue’s Table of Contents

              Copyright © 1984 ACM

              Publisher

              Association for Computing Machinery

              New York, NY, United States

              Publication History

              • Published: 1 September 1984
              Published in tods Volume 9, Issue 3

              Permissions

              Request permissions about this article.

              Request Permissions

              Check for updates

              Qualifiers

              • article

            PDF Format

            View or Download as a PDF file.

            PDF

            eReader

            View online with eReader.

            eReader