apinf / platform

Apinf - Open source API management platform with multi proxy and protocol support
https://apinf.com/
European Union Public License 1.1
74 stars 35 forks source link

REGRESSION - analytics view not loading for 7 days or 28 days #3747

Closed ilarimikkonen closed 5 years ago

ilarimikkonen commented 5 years ago

this is suspected to be due to regression caused by Meteor 1.8

1) login to platform (https://94-237-88-234.de-fra1.upcloud.host/ can be used), create an account if needed 2) ask admin access from me 3) go to https://94-237-88-234.de-fra1.upcloud.host/dashboard?proxy_id=zXsL5K9MHemjgbNJy&timeframe=7&sort=name

error: no data is shown for 7 days and 28 days. expected: data is shown for all selected time periods.

This is a good place to start digging: https://github.com/apinf/platform/blob/af8881beb8d13c4b55506009aa2cbc1aed3810cf/apinf_packages/analytics/server/methods.js

I suspect that this causes the regression: https://github.com/apinf/platform/commit/0973a6b1b0e32cfa5e73639dd7d6df643c0e4b0e#diff-30ce14aa9f6f1695d82b6c9d416cf38e

to develop locally, you need to clone the meteor project. to have meaningful long term data for testing, you need to have a proxy and elastic search to work with:

1) locally run the meteor project 2) setup a proxy: https://94-237-88-234.de-fra1.upcloud.host:3002 dQ0TXVfQLu3iiL7dpROFOZmePUnbudjjFkkIortB 3BVE4qRnveSbMSdWj3euM1fE2JXfS3IJNDTSMeKD http://94-237-88-234.de-fra1.upcloud.host:9200 3) add an API and generate some traffic 4) check the stats for 7 or 28 days.

ilarimikkonen commented 5 years ago

on the other hand; not sure what is causing this. the code in https://apinf.io/analytic/parkkihaukka?timeframe=7 is broken, and that runs on meteor 1.5 still. this works: https://vamos.apinf.io/dashboard?proxy_id=vf6xnqQMbmNnKgoHH&timeframe=7&sort=name and it runs meteor 1.5 also.

ilarimikkonen commented 5 years ago