fablabbcn / smartcitizen-api

The Smart Citizen Engine
https://developer.smartcitizen.me
GNU Affero General Public License v3.0
10 stars 4 forks source link

(Minuteman, removed). Do we need the readings info in /metrics endpoint? #100

Open viktorsmari opened 6 years ago

viktorsmari commented 6 years ago

Minuteman has not been updated since 2016 https://github.com/elcuervo/minuteman EDIT: it was updated in feb 2019

It gives us the good/bad readings at http://api.smartcitizen.me/metrics

Instead we can maybe query the database or Kairos for this info?

Files using minuteman static_controller sessions_controller raw_storer storer

Minuteman used do slow the CSV uploads down 4x times, so maybe we should stop using it in general.

viktorsmari commented 6 years ago

Minuteman has been removed in 312a5fe33102d204928addcc5b4106fb93c20f57, and now the /metrics is returning empty values.

readings: {
good: { },
bad: { },
total: null
}

Do we need a replacement?

A maintained version example is https://github.com/ankane/ahoy

pral2a commented 5 years ago

Let's consider having a readings property per device updates after each ingestion.

That will allow us to query and sort devices by the number of data points they have created!

We might need to design a migration that uses one of the sensors available per each device and queries Kairos to obtain the total number of readings posted.

oscgonfer commented 1 year ago

Hi,

Just saw this issue as I was needing readings data for a report. Answering to @viktorsmari question --> yes, we need info for the readings. Just to keep this in mind.

oscgonfer commented 1 year ago

Consider using Kairos for storing platform usage data