New entity based permission layer

The role and permission model is made more flexible allowing for
fine-grained permission checks compared to the current model.

This is also an opportunity to change the way data are stored in the
database.
\BlueLaTeX aims to be really modular on the server-side but this
modularity is not achieved if data is not as modular as code. The
entity-component system allows for adding and deleting responsibilities
to entities in a modular and dynamic way, hence seems to be a good way
to go for the future.

I am aware this commit introduces breaking changes but, that's the
moment to do it, \BlueLaTeX is not released yet so let's break things
now.

Concretely the new role and permission model introduces following
concepts:
 - Group of users,
 - Phase defining permission for each role,
 - Refined permissions for papers.

To prepare for the near future, the paper document in database is also
simplified to its essence. Branching related stuffs will come back later
when this feature is introduced into \BlueLaTeX.

Roles and permissions are components that are attached to the paper
entity without any need for modifying the entity document.

Having introduced this, we can now improve all other entities such as
paper data and user data.
Make users and papers entities with components

The core and compiler bundles bring their own data in a modular way.
Users and papers are just entities, with no other meaning than just
existing.

core bundle brings:
 - user basic data (first name, last name, email address, ...),
 - paper basic data (title, last modification),
 - paper roles (authors, reviewers, ...)

compile bundle brings:
 - paper LaTeX compiler settings
Update test scenarios

Make test scenarios take into account that data are now stored using an
entity-component system.
Merge pull request #84 from satabin/wip-entity-components

This merge introduces some compilation warnings which will be removed when updating to scala 2.11.
[imp #88] Add paper name to identify it

When a user creates a paper, he must give a name that is used in paper
list for further reference to it.

Using a name that is not the title extracted from the source is better
for several reasons:
 - Using a simple regular expression to extract the title from the
   source file is not a really robust method,
 - Source title may contain control sequences that are not really user
   friendly to display,
 - Several papers may have similar titles which will make it more
   difficult to distinguish between them.

For all these reasons we found it preferable to ask for a name that the
user can freely chose and edit.
Merge pull request #89 from satabin/wip-paper-name

[imp #88] Add paper name to identify it
Separate paper info and roles API

From now on:
 - `/papers/:paper_id/info` serves the core paper information such as
   paper name, paper creation date, paper kind, ...
 - `/papers/:paper_id/roles` serves the different roles for the paper
Merge pull request #91 from satabin/feature/cleaner-paper-api

Separate paper info and roles API
Correctly stop managed actors in dispatcher

After having sent the `Stop` message, send the `PoisonPill` message that
will actually kill the managed actors.
[imp #93] Make default file names user-friendly

Instead of using the paper identifier as default names for the files
automatically created with a new paper, it is better to use more
human-readable names such as `main.tex` and `references.bib`.
[imp #87] Suggest filename for downloaded content

There exists a special header named `Content-Disposition` that allows
for suggesting a filename to the web browser when it downloads a
resource.
It is a good idea to use it for files when the URL does not suggest any
user-friendly file name.
Update README

Too many information were given in this README, which is not the
official documentation of the project. Add link to the documentation for
details, and just present the project in this file.
Update configuration with some documentation
Package the launcher as standalone jar

This makes the classpath easier to write when launching with jsvc.
Merge pull request #95 from satabin/feature/new-default-names

[imp #93] Make default file names user-friendly
Merge pull request #96 from satabin/feature/set-filename-header

[imp #87] Suggest filename for downloaded content
[imp #42] Synchronization actor code clean-up

Lots of clean-up done in this commit:
 * The actor system now uses immutable parameters. This should allow more
advance and fancy akka-stuff, such as actors over network, etc. To do this, all
mutable parameters have been encapsulated in an immutable case class, and the
code now makes use of the 'context.become()' pattern. There is still use of
mutables variable in the code, but far less than before, and they should not
interfere with akka possibilities.
 * Separate code of dispatcher and actor. It is much easier to maintain this
way. By the way, correctly rename 'SynchroDispatcher' to 'SyncDispatcher'.
 * Rename unit test from 'SynchroDispatcher' to 'SyncActor', since it actually
tests the actor and not the dispatcher (+ it adds naming consistency).
 * Add of a package file to define type aliases for PaperId, PeerId, etc. In
fact, it may be a good move to actually define these in the blue-core package.

This commit is quite big and should have been done in multiple, smaller commits.
For that, I apologize. No kittens were harmed in the making of this patch.
Merge pull request #90 from chemicalstorm/wip-immutable-synchro

[imp #42] Synchronization actor code clean-up
Add much more log

The main current problem of \BlueLaTeX is that it suffers some
defficiencies in decent logging. We are working on it actively, and that
is another brick in the wall.
[Fix #39]Fix configuration load

Load the configuration file before starting the download of the
application.

Configurations are stored in window and then are copied in AngularJS
constants.

Change the default root path of API and of the web application.