Hostname: page-component-586b7cd67f-rcrh6 Total loading time: 0 Render date: 2024-11-27T15:49:14.106Z Has data issue: false hasContentIssue false

Capability-based localization of distributed and heterogeneous queries

Published online by Cambridge University Press:  12 December 2017

JOÃO COSTA SECO
Affiliation:
NOVA LINCS – Universidade Nova de Lisboa, Lisboa, Portugal e-mail: [email protected]
PAULO FERREIRA
Affiliation:
OutSystems, Lisboa, Portugal (e-mails: [email protected], [email protected])
HUGO LOURENÇO
Affiliation:
OutSystems, Lisboa, Portugal (e-mails: [email protected], [email protected])
Rights & Permissions [Opens in a new window]

Abstract

Core share and HTML view are not available for this content. However, as you have access to this content, a full PDF is available via the ‘Save PDF’ action button.

One key aspect of data-centric applications is the manipulation of data stored in persistent repositories, which is moving fast from querying a centralized relational database to the ad-hoc combination of constellations of data sources. The extension of general purpose languages with query operations is increasingly popular, as a tool to improve reasoning and optimizing capabilities of interpreters and compilers. However, not much is being done to integrate and orchestrate different and separate sources of data. We present a data manipulation language that abstracts the nature and location of data-sources. We define its semantics and a type directed query localization mechanism to be used in development tools for heterogeneous environments to efficiently compile them into native queries. We introduce a localization procedure based on rewriting of query expressions that is confluent, terminating and provides the maximum mapping between site capabilities and the structure of the query. We provide formal type safety results that support the sound distribution of query fragments over remote sites. Our approach is also suitable for an interactive query construction environment by rich user interfaces that provide immediate feedback on data manipulation operations. This approach is currently the base for the data layer of a development platform for mobile and web applications.

Type
Research Article
Copyright
Copyright © Cambridge University Press 2017 

References

Benzaken, V., Castagna, G. & Frisch, A. (2003) CDuce: An XML-centric general-purpose language. In Proceedings of the 8th ACM SIGPLAN International Conference on Functional Programming (ICFP '03). New York, NY, USA: ACM, pp. 51–63.CrossRefGoogle Scholar
Buneman, P., Libkin, L., Suciu, D., Tannen, V., & Wong, L. (1994) Comprehension syntax. ACM SIGMOD Rec. 23 (1), 8796.CrossRefGoogle Scholar
Buneman, P., Naqvi, S., Tannen, V., & Wong, L. (1995) Principles of programming with complex objects and collection types. Theor. Comput. Sci. 149 (1), 348.CrossRefGoogle Scholar
Cardelli, L. (1989) Typeful programming. In IFIP State of the Art Reports (Formal Description of Programming Concepts), Neuhold, Erich J. & Paul, M. (eds). New York, NY, USA: Springer-Verlag, pp. 431507.Google Scholar
Cardelli, L., Ghelli, G., & Gordon, A. D. (2002) Types for the ambient calculus. Inform. Comput. 177 (2), 160194.CrossRefGoogle Scholar
Cheney, J., Lindley, S. & Wadler, P. (2013) A practical theory of language-integrated query. In Proceedings of the 18th ACM SIGPLAN International Conference on Functional Programming (ICFP '13), New York, NY, USA: ACM, pp. 403–416.CrossRefGoogle Scholar
Cheney, J., Lindley, S., & Wadler, P. (2014) Query shredding: Efficient relational evaluation of queries over nested multisets. In Proceedings of the 2014 ACM SIGMOD International Conference on Management of Data (SIGMOD '14). New York, NY, USA: ACM, pp. 1027–1038.CrossRefGoogle Scholar
Chlipala, A. (2015) Ur/Web: A simple model for programming the web. In Proceedings of the 42nd Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL '15). New York, NY, USA: ACM, pp. 153–165.CrossRefGoogle Scholar
Clark, J. & DeRose, S. J. (1999) Path Language (XPath) Version 1.0. Available at: www.w3.org/TR/xpath/ Google Scholar
Colby, L. S. (1989) A recursive algebra and query optimization for nested relations. In Proceedings of the 1989 ACM SIGMOD International Conference on Management of Data (SIGMOD '89). New York, NY, USA: ACM, pp. 273–283.CrossRefGoogle Scholar
Cooper, E. (2009) The Script-Writer's dream: How to write great SQL in your own language, and be sure it will succeed. In Proceedings of the 12th International Symposium on Database Programming Languages (DBPL '09). Berlin, Heidelberg: Springer-Verlag, pp. 36–51.Google Scholar
Cooper, E., Lindley, S., Wadler, P., & Yallop, J. (2007) Links: Web programming without tiers. In Proceedings of the 5th International Conference on Formal Methods for Components and Objects (FMCO '06). Berlin, Heidelberg: Springer-Verlag, pp. 266–296.CrossRefGoogle Scholar
Davies, R., & Pfenning, F. (2001) A modal analysis of staged computation. J. ACM 48 (3), 555604.CrossRefGoogle Scholar
Fu, Y., Ong, K. W., & Papakonstantinou, Y. (2013) Declarative ajax web applications through SQL++ on a unified application state. In Proceedings of the International Symposium on Database Programming Languages.Google Scholar
Grade, N., Ferrão, L., & Seco, J. C. (2013) Optimizing data queries over heterogeneous sources. In Proceedings of the 5th Simpósio de Informática, INForum.Google Scholar
Halevy, A., Rajaraman, A. & Ordille, J. (2006) Data integration: The teenage years. In Proceedings of the 32nd International Conference on Very Large Data Bases (VLDB '06). VLDB Endowment, pp. 9–16.Google Scholar
Lindley, S. & Cheney, J. (2012) Row-based effect types for database integration. In Proceedings of the 8th ACM SIGPLAN Workshop on Types in Language Design and Implementation (TLDI '12). New York, NY, USA: ACM, pp. 91–102.CrossRefGoogle Scholar
Murphy, T. VII, Crary, K. & Harper, R. (2008) Type-safe distributed programming with ML5. In Trustworthy Global Computing: Third Symposium, TGC 2007, Sophia-Antipolis, France, November 5-6, 2007, Revised Selected Papers, Barthe, G. & Fournet, C. (eds). Berlin, Heidelberg: Springer, pp. 108123.CrossRefGoogle Scholar
Newman, M. H. A. (1942) On theories with a combinatorial definition of “equivalence”. Ann. Math. 43 (2), 223243.CrossRefGoogle Scholar
OutSystems. (2016) Using aggregates – Fetch and display data from the database. Technical documentation. Available at: www.outsystems.com/search/Fetch+and+Display+Data+from+the+Database Google Scholar
Papakonstantinou, Y., Gupta, A. & Haas, L. (1998) Capabilities-based query rewriting in mediator systems. Distrib.Parallel Databases 6 (1), 73110.CrossRefGoogle Scholar
Peyton Jones, S. & Wadler, P. (2007) Comprehensive comprehensions. In Proceedings of the ACM SIGPLAN Workshop on Haskell Workshop (Haskell '07). ACM, pp. 61–72.CrossRefGoogle Scholar
Robie, J. et al. (2014) XQuery 3.0: An XML query language. Available at: www.w3.org/TR/xquery-30/ Google Scholar
Seco, J. C., Lourenço, H., & Ferreira, P. (2015) A common data manipulation language for nested data in heterogeneous environments. In Proceedings of the 15th Symposium on Database Programming Languages (DBPL '15), pp. 11–20.CrossRefGoogle Scholar
Seco, J. C., Ferreira, P. & Lourenço, H. (2017) Capability-based Localization of Distributed and Heterogeneous Queries – Extended version with proofs. Technical Report, NOVA University of Lisbon. Available at: http://ctp.di.fct.unl.pt/~jcs/papers/jfp-big-data-tech-report.pdf CrossRefGoogle Scholar
Serrano, M., Gallesio, E. & Loitsch, F. (2006) Hop: A language for programming the web 2.0. In Companion to the 21th Annual Conference on Object-Oriented Programming, Systems, Languages, and Applications, pp. 975–985.Google Scholar
Silberschatz, A., Korth, H. & Sudarshan, S. (2006) Database Systems Concepts, 5 ed. New York, NY, USA: McGraw-Hill.Google Scholar
Taylor, R. (2010) Query Optimization for Distributed Database Systems. Master Thesis, University of Oxford, University of Oxford.Google Scholar
Vassalos, V. & Papakonstantinou, Y. (2000) Expressive capabilities description languages and query rewriting algorithms. J. Log. Program. 43 (1), 75122.CrossRefGoogle Scholar
Wong, L. (2000) Kleisli, a functional query system. J. Funct. Program. 10 (1), 1956.CrossRefGoogle Scholar
Submit a response

Discussions

No Discussions have been published for this article.