Skip to content

Latest commit

 

History

History
140 lines (99 loc) · 5.1 KB

Web_Enabled_Data.md

File metadata and controls

140 lines (99 loc) · 5.1 KB

Data Management

For Scientific Research

stanza body copyPhoto: © Stanza. Used with permission.

Database-Driven Web Frameworks

history of web frameworks timeline 2013Image: Matt Raible

Frameworks: If they did not exist, you'd want to build your own.

Why did frameworks evolve?

  • Reduce repetitive programming tasks
  • Isolate error opportunities and reduce errors
  • Improve potential securability
  • Leverage collaborative development and contributed assets

A rough spectrum of frameworks

  • High-Level
  • Low/Language Level (IDEs)
  • General Purpose (CMS)
  • Learning Oriented (LMS)
  • Purpose-driven (Wordpress)
  • Document-oriented (DMS)
  • Code generators
  • WYSIWYG Editors (example: Dreamweaver)

Frameworks and the Web

  • Frameworks may have existed before the advent of the World Wide Web
  • Web-oriented tools^ evolved concurrently with the Web.
  • The Web really launched what people think of as frameworks
  • More recently, threats posed across the Internet and Web have made use of a framework almost compulsory.

^ PHP, 1995; Python 1989; Perl/CGI, 1997

Buzzword Side Note

People who talk about "framworks" also talk about "stacks".

Think about, for example, the LAMP^ stack.

The concept of a stack provides a clearer understanding of separation of functions.

^ Linux, Apache, MySQL(MariaDB), PHP (/Perl/Python)

Should be LMAPP!

Layer Function
Person You
PHP/Perl/Python App Delivery Scripting
Apache Web Server
MySQL/MariaDB Database
Linux Operating System

Factors in selecting a framework

  • General goodness-of-fit/orientation
  • Cost and learning curve
  • Strength of technology, stability, APIs?
  • Adoption, Community, and "Trajectory"
  • Security track record
  • Feasibility of underpinnings (language and constructs), esp. over long-term
  • Specific "must-have" functions/requirements
  • Your workflow (and more...)

"MVC"

  • Model-View-Controller design provides for separation of functions and better organization.

  • MVC frameworks typically rely on "OOP" (Object-Oriented Programming) constructs.

  • Frameworks often interact with data through Object-Relational Mapping (ORM) to relational databases.

A few popular MVC frameworks

Some important CakePHP characteristics

  • MVC
  • Object Oriented traits
  • DRY - Don't Repeat Yourself
    • inheritance, plugins, helpers, behaviors
  • CoC - Convention over Configuration

Examples:

  • Tables are plural (people)
  • Reference is singular (person)
  • Foreign keys always reference "reference_id"
  • Pre-ordained file structure

Implications for further use

  • Need multi-user access "by tommorrow"?
  • Need app security (role based access, encryption)?
  • Is this your job (app development can become "full-time")?
  • Can you cope with the fine print (code)?
  • Are you creating a legacy (that others can mantain)?