05-architecture.tex
5.38 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
\section{Architecture}
\label{sec:architecture}
%TODO: Kanashiro e Siqueira
The two main requirements provided by the Brazilian Federal Government
for the new platform were:
%
1) \textit{Integrate existing FOSS systems}, with minimal differences
from their original versions. This way, the platform can benefit from
improvements done by the upstream communities that provide those
systems, and the maintenance effort that is specific for the SPB Portal
should be reduced;
%
and
2) \textit{Provide a consistent user interface} across the different
systems, as well as centralized authentication.
The first requirement was accomplished by dedicating specialized teams
for each system that was being integrated. The teams would learn how to
develop their assigned systems, and contribute the necessary features
directly to the original communities, so that the version we used was
not significantly different from the original. Of course, at times
project deadlines forced us to use our own version before tho features
were fully reviewed and integrated upstream to the original projects,
but we managed to contribute the vast majority of the changes back.
For the second requirement, we integrated a web integration platform
called Colab\footnote{\url{https://github.com/colab/colab}}. Colab
serves as a frontend for other web applications as a reverse proxy,
manages authentication, and can apply changes to the HTML provided by
the integrated applications in order to provide visual consistency.
Colab had support for an initial set of applications (Trac, GNU Mailman,
Apache Lucene) hard-coded; our team evolved Colab so that it can now
receive plugins to add support for new applications with minimal changes
to its existing core. We added support for the other applications used
in the SPB platform: Noosfero, GitLab, and Mezuro.
Noosfero\footnote{\url{http://noosfero.org/}} is a software for building
social and collaboration networks. Besides the classical social
networking features, it also provides publication features such as blogs
and a general-purpose CMS (Content Management System). Most of the user
interactions with SPB is through Noosfero: user registration, project
home pages and documentation, and contact forms.
GitLab\footnote{\url{http://gitlab.com/}} is a web-based Git repository
manager with wiki pages and issue tracking features.
Mezuro\footnote{\url{http://mezuro.org/}} is a platform to collect source code
metric to monitor the internal quality of softwares written in C, C++,
Java, Python, Ruby, and PHP. GNU Mailman is used for mailing lists.
\begin{figure}[hbt]
\centering
\includegraphics[width=\linewidth]{figures/arch.png}
\caption{SPB architecture overview.}
\label{fig:architecture}
\end{figure}
The conceptual architecture of the platform is presented in Figure
\ref{fig:architecture}. Colab initially handles all user interaction,
directing requests to one of the integrated applications. It
post-processes responses from the applications to apply a consistent
visual appearance, manages authentication, and provides a unified search
functionality: instead of using the redundant restricted search
functionality of each application, a search in the SPB portal might
return content from any of the applications, be it web pages, mailing
list posts, or source code.
%TODO: deixar coeso daqui para baixo
\begin{figure*}[hbt]
\centering
\includegraphics[width=\linewidth]{figures/arch2.png}
\caption{Instanciation view of the SPB architecture.}
\label{fig:architecture2}
\end{figure*}
In real, the SPB platform was deployed in 7 virtual machines with different functions,
as we can see in Figure \ref{fig:architecture2}.
The \textit{reverseproxy} handles the HTTP requests and redirects them to the
\textit{integration}, the \textit{email} sends and receives e-mails on behalf
of the platform and the \textit{monitor} keeps the entire environment tracked.
These three \textit{VMs} mentioned - \textit{reverseproxy}, \textit{email} and
\textit{monitor} - are accessible via Internet and the other ones are only
available in the local network created between them.
\textit{Integration} works as a second layer of proxy beneath
\textit{reverseproxy}, any request to the platform will be handled by it. The
Colab service provides interface, authentication and search engine integration
among all the services. When a request is received to a specific service,
Colab authenticates the user in the target tool, sends the request and makes a
visual transformation in the HTML page which is the content of the response.
Another user-oriented feature is the integrated search engine, when the user
want to find something in the platform Colab will perform the search in the
whole databases. Colab itself provides a web interface for GNU Mailman and we
have two others integrated tools in \textit{integration}: Gitlab and Prezento.
Gitlab provides web interface for Git repositories and issues tracker, and
Prezento is a front-end for source code static analysis.
The source code static analysis is performed by \textit{mezuro}. It runs some
static analysis tools on source code stored in repository and provide this data
to Prezento. A social network and CMS (Content Manager System) is provided by
Noosfero in \textit{social}, and the databases of all tools with a cache
service are in \textit{database}.
* Visão geral da implantação pode ser em um nível maior de abstração, mas deixar claro o esforço para automatizar (DevOps -> Chake)