friendica / friendica-directory

Global directory for the Friendica project. The repository has moved to git.friendi.ca/friendica/friendica-directory
GNU Affero General Public License v3.0
20 stars 11 forks source link

Health Score calculation #75

Open Tealk opened 3 years ago

Tealk commented 3 years ago

Hello all

I was wondering how the calculation of the Health Score is done and I found some things in the code, now the question is why I am missing e.g. 10 points. There are apparently a few possibilities therefore my question: Would it be possible to make the whole thing more transparent so that you see why the points are missing and you can do something about it if necessary?

MrPetovan commented 3 years ago

I explained in natural language how the scoring works in a Friendica forum post I'd be hard-pressed to find again, but the gist is that scoring is dependent of over time effects to limit score drops in case of rare temporary outages.

The scoring was almost entirely lifted from the previous version of the directory that I didn't write, and adding a detailed breakdown would be a significant undertaking I'm not planning on taking on anytime soon.

You should check your score in a week or so to see if it changed or not. Most important criterions are: HTTPS, Friendica code version, server availability, request time. The latter is unfortunately depending on the location of the directory in France, but you shouldn't be unfairly penalized for this in Germany.

Tealk commented 3 years ago

Thanks again for the explanation, yes I have already discovered a few points in the code but I do not think that everyone understands php hence my intention for the issue

Maybe you could just put this in as a kind of information page, it doesn't have to be programmed.

MrPetovan commented 3 years ago

Fair enough, thank you for the suggestion!

Tealk commented 3 years ago

then you don't have to find lost posts again ;)

MrPetovan commented 3 years ago

Found it!

Here's the breakdown of the scoring:

  • Min health: -100.
  • Default max health: 100.
  • New server: 50.
  • Probe status: Success +10, Failure -30.
  • Request time score: <120ms +10, 120-250ms +5, 250-400ms 0, 400-800ms -5 (max health 60), >800ms -10 (max health 40).
  • SSL status: disabled -10, enabled +10.
  • Friendica version: stable 0, RC/dev max health 95, less than stable -10 above 0 health, 3 or less max health 30.

https://friendica.mrpetovan.com/display/735a2029-4660-7312-e23a-b8d188849800

Tealk commented 3 years ago

New Server(50) + Probe(10) + time(10) + ssl(10) = 80 isn't that 20 points missing? so if i assume the best case

MrPetovan commented 3 years ago

True, but your node on its new location was found before by the directory, so it's possible you got 10 additional points from my manual poll earlier.

Tealk commented 3 years ago

then thank you for the 10 points ;) I think that with repeated positive tests the score continues to rise?

MrPetovan commented 3 years ago

It will, until it reaches 100, the current maximum.

Tealk commented 3 years ago

oh too bad i thought i would get over 9000 🤣

thank you for the explanation