Menu:

Developing a content management system Part 1

Introduction

This site is currently implemented using MODX, and not very well on my end as I wanted something fast. It is also residing on a basic Linode running Debian Linux. I was always intending on creating a new site, but was most likely going to use an existing CMS, like Drupal.

I'm not a fan of PHP and have starting wanting to redevelop this site using Ada, Linode lets me rexecute binaries directly as it is a virtual system. I could use the Common Gateway Interface, but this is old technology and every invocation of an URL would mean that an application will have to be spawned from the web server, this is rather slow. Enhancements to CGI are Simple Common Gateway Interface (SCGI) and FastCGI; the former is simple to implement (hence the name), the other is actually quite difficult. I had previously implemented code to handle the SCGI protocol for Jesse Lang's Solid framework, so I'll use this.

I'll also require a Unicode library, so I'll utilise the League library in Vadim Godunko's Matreshka framework. This does have a FastCGI implementation, but I won't be using that.

Also required is template parsing, so that the document style can be replaced easily. There is a template parser library in the AWS project I can use for this.

Key concepts

The design of this CMS is fulfill the following requirements.

High level design

First we need to think about how this CMS is going to be structured at a high-level, the following diagram shows this using the client-server model.

High level structure of the CMS

The CMS runs as a daemon process in the background on the operating system, the HTTPD (the web server) will be configured to send certain requests over sockets to the CMS server, the CMS will then send a response which in turn gets passed back to the client that requested it.

You'll notice in the diagram that there is an External box. This basically means that there could be other servers that the CMS daemon needs to access.

System structure

The next diagram shows how the CMS fits in with the operating system. The CMS communicates with the web server via SCGI, it also interfaces to a database server and the filesystem. Very few OS specifics will be required:

  1. running the CMS as a daemon, and
  2. modules architecture.
System structure of the CMS and the OS

I have chosen PostgreSQL as the Database for storage of the various content within the CMS. I have heard very good things about the quality of this software from other Ada developers. There exists a number of bindings to libpq, I shall try the one in Matreshka as it also provides a common abstraction over other databases.

Abstractions

The following diagram shows the general abstractions that will be included in the CMS.

Abstractions required for the CMS

Documents

Documents are what the CMS is managing. Documents can be extended to create new types of documents, for example a site could have a blog document, an article document, a product document.

Each document has a number of fields that the user can complete when entering the content:

But the administrator can add new fields to the document type to give it more structure. For example, a site for a newspaper could add a photo field to a story document which could be shown at the top of the page and have it float to the right so the text flows around it.

As stated in the key concepts from the beginning of this article, each document has revision information. The database will essentially store a new version as new revision of the document, unless explicitly set by the user. It should be possible to roll back to a previous revision, thus deleting any subsequent revisions.

Fields

As mentioned in the previous section, Fields provide a mechanism for adding fields to the input forms on the documents. These fields can be anything and will provide extra features that an administrator wants to add to a site.

API's

API's are added to the system and can be used by other modules to build extra features or content. These API's can provide admin interfaces if one is required.

Users

These are the human's who use the site built with the CMS. Usernames and passwords, profile information can be built up separately.

Roles

Roles are given to specific users, such as Administrator, Editor, Writer, etc.

Permissions

Permissions define what a user's role can do within the CMS, e.g. deleting content.

Modules

Modules provide a mechanism to extend the CMS with new Documents, Fields or API's to enhance the CMS. An example could be an online shopping system.

Cache

The cache is where pages are stored after they've been taken from the database, parsed, tuck together with the other template fragments and sent back to the client.

N.B: I have just had a thought about this, say you have advertising on a page, this could end up getting stuck with the same ad on every page request.

Database

The database is where the content is stored.

Skip to Part 2 of this project.

If you have any comments or any ideas that I've missed out, please use the form below.

Showing comments 1 to 10 of 28 | Next | Last
Authentic Louis Vuitton Outlet
Comment
Yellow958
Reply #28 on : Wed August 27, 2014, 12:31:02
I changed this password instantly as i discovered vizgin must have been a con... I informed each of the individuals in the pal record over it. The item received delivered to me personally via an individual in the Google buddy checklist... these folks were fixed off of. Hopefully these people don't find scammed. The any shame individuals might do this.
Authentic Louis Vuitton Outlet http://www.mrrichardsbooks.com
louis vuitton outlet
Comment
Join()893
Reply #27 on : Wed August 27, 2014, 06:14:39
Have a look at Court records a web based social networking application regarding music artists and bands that makes all their files go to work your kids. Coming this could.
louis vuitton outlet http://www.mrrichardsbooks.com
Discount Louis Vuitton Outlet
Comment
Veri254
Reply #26 on : Wed August 27, 2014, 05:09:31
I placed that way up nowadays in my very own house check research laboratory while using intent associated with replicating this efforts at the office on Friday.
Discount Louis Vuitton Outlet http://www.milwaukeepetexpo.com
Authentic Louis Vuitton Outlet
Comment
TechView795
Reply #25 on : Wed August 27, 2014, 03:35:33
Jamendo. com is perfect if you want totally free tunes within the CC driver's licence. nevertheless are usually wonderful way too Probably simply because Spotify doesn't actually advise a person anything. Even though software is perfect if you want to examine something/someone available.
Authentic Louis Vuitton Outlet http://www.mrrichardsbooks.com
louis vuitton outlet
Comment
Join()982
Reply #24 on : Wed August 27, 2014, 01:46:08
I fixed this particular up currently in our house examination clinical with all the purpose associated with replicating our initiatives at work upon Wednesday.
louis vuitton outlet http://www.mrrichardsbooks.com
louis vuitton outlet
Comment
Unity970
Reply #23 on : Tue August 26, 2014, 14:41:22
My partner and i enjoy, bring about I discovered exactly what I got taking a look intended for. You have completed my very own several time lengthy search! Our god Bless you man. Have a very good morning. Bye To inform you your on line website appears a bit more odd within Safari in the pc applying Linux.
louis vuitton outlet http://www.mrrichardsbooks.com
Louis Vuitton Outlet 2014
Comment
Maaike918
Reply #22 on : Tue August 26, 2014, 14:30:49
The entire world really must analysis much more compared to you, you're a new respected publisher. Maintain writing. Appreciate your discussing your own personal expertise.
Louis Vuitton Outlet 2014 http://www.mrrichardsbooks.com
Cheap Louis Vuitton Outlet
Comment
URLs45
Reply #21 on : Mon August 25, 2014, 16:59:56
Jamendo. net is ideal if you need totally free new music beneath the CLOSED CIRCUIT driver's licence. nevertheless are fine too Possibly because Spotify won't actually recommend anyone something. Even though the plan is a great choice if you want to check something/someone available.
Cheap Louis Vuitton Outlet http://www.mrrichardsbooks.com
louis vuitton outlet online
Comment
Ordinance151
Reply #20 on : Mon August 25, 2014, 09:27:40
Hi Kathy, <br />Are a person certain typically the. htaccess data is present? Make an empty. htaccess record add the idea. When you can start to see the data file you upload after that this failed to can be found start with: )
louis vuitton outlet online http://www.mrrichardsbooks.com
louis vuitton outlet online
Comment
Phusion236
Reply #19 on : Fri August 22, 2014, 11:27:40
Grooveshark set it up an awful pathogen in which obligated me to be able to reformat this >12 month old notebook and today it will not perform a similar. It absolutely was a new fanatic issue although We have viewed other individuals the same about different boards.
louis vuitton outlet online http://www.mrrichardsbooks.com
buy cigarettes online cheap fast ship to america