Complete

The development of this feature is considered complete (of course, some features are never really complete, but we have to put a certain number of boundaries...)

The feature is expected to be bug free and is likely so. However, other features that you use may have side effects that makes such a feature "bogus" even though this feature itself is perfect and really others generate the bug.

See a complete list of features sorted by Snap! Websites Development Status

When using an SQL environment, it is very easy to create a new row of data with a unique number. You use a sequence identifier and your SQL system generates the numbers for you.

With Cassandra, there is no such thing as a unique number. There are facilities to count (add and subtract) but no unique number. This is actually very important to let the system go as fast as possible as it is expected to do. Because the only real way to create a unique number is to either make use of a single computer which generates those numbers (be it with an SQL database or another system) or to have all the ...

The core system offers an easy way to add tags to the header. This ease the handling of the header and allows us to ensure that the encoding appears first (before the title) which solves several issues with Internet Explorer (including a security issue in IE 6.x.)

Style Sheets

Having one place that handles the HTML header gives us a way to manage the style sheets in one place. This allows us to do two things to the style sheets:

  1. Add them inline when small enough (i.e. less than 1 kb)
  2. Compress them (remove all the possible new lines, spaces, etc.)

Also, all the style ...

Build System

Introduction

To handle the environment, as it grows, we want a build system that is capable of recompiling everything, build and publish the binaries, make source that compiles available to our users and run the available tests to detect that everything still works as expected.

Launchpad Builds

We actually went with building everything directly on Launchpad which is offered by Ubuntu (owned by Canonical.) This means if you are running Ubuntu, you do not need to worry about recompiling everything. Instead you can just install the necessary PPA and do:

sudo apt-get install snapserver ...

Each row in the content table is considered an object. All objects are composites meaning that different plugins handle different fields of the object. We do not have a function that load the whole object. Although it could be practical in some cases, we instead let each plugin handles their own data as required. For example, if the robots.txt plugin needs to know whether a page is indexable then it reads the corresponding link. In most other cases, however, that link is ignored because it is not important; i.e. boxes on the side also have that link, but robots.txt does not use it because ...

XML Sitemap feature

Sitemap

We want to generate an XML sitemap with all the pages that the system offers1.

Since the pages are not all clearly defined (i.e. a feature may generate hundred of pages) it is important to allow plug-ins to define their XML sitemap entries.

For example, the taxonomy feature allows you to categorize a page using tags (taxonomy pages titles). Pages that were categories can be listed by the taxonomy plug-in on generated pages. Such would not automatically ...

  • 1. Although some pages may be hidden by the users, and obviously any non public pages are never added to the XML sitemap.

C++ plugins [core]

Under Linux, we can use dlopen() to load a .so file. We will be using that function to load our plugins.

The function takes care of executing the C++ initialization as required (and corresponding destructions on dlclose() calls.)

This means we can create a plugin simply by creating a listener that will receive signals from the other plugins and Snap! core. The listener is created as a global variable which the dlopen() function automatically initializes (and if necessary, the dlclose() will turn it off.)

The dlopen() gives you a choice in loading everything in LAZY mode and making all the ...

In order to offer one server and many modules instead of one large server, one needs to redesign the signalling system to work dynamically.

Since we want to have two sides to our system: a CGI that directly communicates with Apache and the actual Snap! Server to which the CGI connects to to get the HTML or other result to be sent back to Apache.

This means the Snap! Server is started once and serves numerous times without having to rebuild all the event tables on each access (nor the connection to the Cassandra system. TBD... can we really just duplicate the Unix socket identifier?) ...

robots.txt feature

Robots.txt file

We want to support a robots.txt on a per domain basis.

This means if one website is visible from multiple domains, then we need to be able to have a different robots.txt for each domain, even though it's a single site.

The robots.txt should be easy to edit. That means not giving users access to the technical text file, but instead a flag in each file and folder that let them mark whether that file or folder can be indexed by robots.

The system always provides a default version of the robots.txt. All 3rd party plug-ins that have specific needs can also hide their ...

Note: The snapbackend process is fully functional. It generates sitemap.xml, sends emails, and verify whether an attachment is a virus... This feature is therefore complete although some plugin specific backends may not work or even not be implemented.

The system uses CRON to run batch processes. All batch processes run in the background, most certainly not on the main servers (i.e. the servers where users connect to use the website.)

For this reason, necessary batch work needs to be reported to backend servers.

Because some of the work can take a long time and a process may fail, we want ...

Content Concept

Note: In itself, this is marked as complete since it works already, although we will be making many additions, the basic concepts will remain the same.

The content is organized on a per page basis. It is formed of one to many elements. We use the Qt XSLT library with XML templates to finalize the output of a page with the dynamically generated data. (Details see Content Object in Cassandra (Content Tree)).

cTemplate basics1

The cTemplate library is used to transform inline tags with a corresponding value.

The ...

  • 1. cTemplate will not be used since XSLT is enough to do the job offered by cTemplate plus much more.

Snap! Websites
An Open Source CMS System in C++

Contact Us Directly