Global view

There are 3 components in ECM:

  1. A module for retrieving and analyzing data from EVE API servers
  2. A module for persistence in database
  3. A module for formatting and presentation of these data

Fetching & Analysis

Rather than develop our own module that makes queries, retrieves and decodes the response, we reused an existing component developed by a player: eveapi.

eveapi fetches XML streams from CCP servers and converts them to objects that we can handle. Those objects are handed to ECM analysis system. It will perform multiple operations on the raw data before sending them to the persistence system:

  • Filtering extraneous data.
  • Pre calculate some indicators such as the level of accreditation of each member (in order not to have to do it on demand).
  • Determination of changes in the data analyzed compared to those already in the database.
  • Instantiating objects representing the analyzed data. These objects will be interpreted by the persistence system.

Here is a diagram depicting the detailed operation of the module of "Data fetching and analysis":

Persistance

Already embedded in Django.

Data presentation

To reduce the load on the server, a part of the presentation workload will be performed by the client (web browser). The performance gain is especially noticeable when displaying tables and trees containing a large amount of information.

Once the client has received enough data, it will be able to interact with the server through AJAX requests. The server will then send the data in JSON format to reduce network traffic, the client will perform the presentation job by manipulating the HTML page being displayed.

Server side

According to the URL invoked by the client, the server will return either a complete HTML page that will be generated through a "template engine" or raw data in JSON format that will be encoded from the objects from the persistence system.

Client side

When the user requests certain pages, the server will send both HTML and JavaScript code. This JavaScript code will allow to manage tables and trees "gradually" through asynchronous requests, a module will generate specific HTTP requests that will be treated differently by the server. Instead of returning HTML pages, it will only send raw data. Then, a JSON interpreter will transform this raw data into HTML formatted code and transmit this code to the rendering engine of the web browser.

This method will allow the display of tables and trees containing a large number of elements while limiting the workload of the server.

global-architecture.jpg (182 KB) tash, Apr 07, 2012 07:15 pm

fetching-analysis.jpg (152 KB) tash, Apr 07, 2012 07:15 pm

persistence.jpg (99.7 KB) tash, Apr 07, 2012 07:15 pm

presentation-server-side.jpg (192 KB) tash, Apr 07, 2012 07:15 pm

presentation-client-side.jpg (183 KB) tash, Apr 07, 2012 07:15 pm