MSc Thesis Document


From the abstract:

Functional programming and Relational persistence: An exploration via Meta-programming and Domain Specific Languages

This research contributes to shorten the gap between functional programming languages and relational database management systems, by providing a supplemental database access library with code generation capabilities.

The methods used were readings, learning and experimental testing with the construction of programs in order to explore the problem.

The results of the research are specifications, programs and findings.

These programs were specified and built:

  • Amigos, an Oracle application;
  • PICA, a domain-specific language and tool for the analysis of Oracle applications; Tránsito Abierto, a persistence service library.

The experimental platform binds Amigos with PICA and PICA with Tránsito Abierto. PICA uses a Domain Specific Language (DSL) to express which objects are to be analyzed. In order to process the DSL an interpreter was implemented. Formal methods were used to build the DSL.

The Tránsito Abierto library (see lessens the semantic gap by improving the programmer’s efficiency with these services:

  • Haskell code generation from the description of a database query;
  • Generated code preservation;
  • And a programmable short-circuit breaker: A program may be stopped if the code generated at compile time is different from the one generated at run-time.

The organization of this document is discussed at the introduction. In the methodological framework the research tools and protocols are discussed. The use and development of PICA, Tránsito Abierto and Amigos is covered there. At the appendices, part of 23,000 lines of code from experimental programs is presented.

Six objectives were established for this research. Two were completely fufillled and the rest were partially accomplished.

This research shows, by using reflection and meta-programming techniques, the feasibility of decreasing the semantic gap between the typed functional programming paradigm and the relational database model, and provides specifications and implementations of programs that makes use of advanced technologies.

Click here to open thesis document in a new tab

Keywords: Functional Programming, Persistence, Relational Database Management Systems, Meta-programming, Domain Specific Languages, Haskell, Template-Haskell, Takusen, PICA, Tránsito Abierto.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s