mtakaki / cachet-url-monitor

URL monitor plugin for cachethq.io
MIT License
125 stars 49 forks source link

Added multi endpoint support #58

Closed ghost closed 4 years ago

ghost commented 5 years ago

It's a quick a dirty solution that just works, so merging this PR isn't expected. But it will satisfy the needs in #9 to some degree and they can merge this PR in their private repositories.

mtakaki commented 5 years ago

Thanks for submitting this, @k1-hedayati! I think it's a clever solution, but you're right. This is not very production ready. The reason why is that we get into some tricky cases. For example, if one URL is much slower than other ones, it could cause other checks to miss the beat. The ideal way is having each check run in a separate thread. So, one url don't affect other ones.

ghost commented 5 years ago

Yes making checks async is a different beast. In case you have 100 endpoints and each taking 1 second you won't have a good time with this monitoring but I believe this isn't the case for 90% of use cases so it would be safe to use this approach until there is enough budget to make monitoring asynchronous.

mtakaki commented 5 years ago

Very true! I do agree it's a pretty good intermittent solution and I do appreciate it :)

ogghi commented 5 years ago

Hi there, as I would like to get this running at some point: are there some (positive) news? :)

mtakaki commented 5 years ago

@ogghi sorry, I was on vacation without access to a computer. Also, I've been busy with other projects/work. I'll try at least solve the conflicts and merge this as soon as I can.

ogghi commented 5 years ago

@mtakaki thanks a lot! :slightly_smiling_face:

mtakaki commented 4 years ago

I don't think I can fix this broken tests, because the account is deleted... I'll favor merging #71 instead. Unfortunately, I'll have to close this PR.