Introduce basic statistics visualization capabilities

Description

More and more Adopters use Opencast as a video management system in means of assets (video, recording) being managed in Opencast (vs. distributed into another video management system and being managed there).

What is currently totally missing in Opencast is the ability to retrieve statistics about the assets in its widest mean: How many assets do we have? How has this changed over time? What is the average duration of a video? How many hours of video do we have? How are the access restrictions used (private vs. public, etc.)? How many times have videos been watched?

Scope:

  • This ain't about server monitoring (there are other tools for that)

  • This ain't about web analytics / learning analytics (there are other tools for that)

  • This is about general information about the assets managed in Opencast

  • This is about the very introduction of some basic visualization capabilities...

  • ... a lot more effort will needed to address the "asset statistics" capabilities

As a starting point, we would like to introduce some basic statistics visualization capabilities in Opencast which includes the following extensions:

Backend:

  • Statistics Service

    • A service that manages statistics providers

  • Extensible Statistics Provider Interface

    • Various statistics data sources can provide implementations of the Statistics Provider which registers itself at the Statistics Service

    • The interface is extensible in means of allowing different kinds of data formats etc.

  • Implementation of InfluxDB Statistics Provider

    • InfluxDB is a time series database that is suitable for aggregating time series data of any kind

  • External API 1.3 with statistics support

Frontend:

  • Visualization of Statistics

    • New tab "Statistics" in Event Details and Series Details modal

    • New page "Statistics->Organization"

    • Implementation for InfluxDB time series visualization component using chartjs

Additionally (not part of Opencast code repository, see MH-13487):

  • Implementation of Apache log processor that continuously feeds view data into InfluxDB (-> asset usage)

The overall vision is that arbitrary sources of statistics data can implement the Statistics Provider Interface to make their data available to Opencast. Clients like the Admin UI or External API clients can ask for a list of available statistics (includes protocol, e.g. data format and parameters available) and visualize them. Opencast itself ("Admin UI") has visualization components for the various statistics data types and can visualize those on three object levels (events, series, organization).

Note that this is supposed to be the beginning - not the end

Current limitations:

  • While all views (Statistics->Organization, Event Details->Statistics and Series Details->Statistics) can visualize the data of multiple statistics provider, we haven't really optimized this case as we currently only have one real data sources. For example, it might make more sense to allow the user to select a statistics provider to be visualized rather than just showing all (think of performance, too). Also, we could visualize data of multiple statistics providers in a single chart. But let's see whether other statistics provider implementations appear and address the potential problem once it actually happens...

  • The new "statistics" page currently suffers "emptiness". We originally

  • We aimed at making the statistics APIs extensible across all layers. The current implementation is not 100% extensible, though, and likely will need to be adapted once somebody actually does introduce another type (not "timeseries" of statistics provider).

  • We decided to go for InfluxDB 1.x. There are first alpha releases of InfluxDB 2.x already available, so it might be interesting to support InfluxDB 2.x once considered stable enough for production use

Steps to reproduce

None

Status

Assignee

Unassigned

Reporter

Sven Stauber

Criticality

None

Tags (folksonomy)

None

Fix versions

Priority

Configure