catalinii / minisatip

minisatip is an SATIP server for linux using local DVB-S2, DVB-C, DVB-T or ATSC cards
https://minisatip.org
330 stars 81 forks source link

[Q] Selectable strategy for tuner selection #1191

Open lars18th opened 2 months ago

lars18th commented 2 months ago

Hi,

I open this thread to discuss about an idea that I want to implement. First of all, this IS NOT the same as #908 or #1114. Therefore, don't confuse with them.

Considerations:

Use cases:

  1. Multiple remote tuners and the user wants to use all of them in a balanced mode. Then select LRU.
  2. Each tuner uses a different wire and you want to provide some noise resilience (because your environment is 24/7 and you need High Availability). Then select all to send the same request to all tuners at the same time. The first with valid signal will be used (or with strong signal).
  3. You have a local minisatip server using multiple SAT>IP servers in a shared environment (this case is when other clients can make requests to the SAT>IP servers and then you can receive 503 (No-More: frontends). In this case you can select all and several tuners will be requested at the same time. And when one is activated, the others are released.
  4. Normal usage which is the default usage we are all using now. 😉

Please share your views.

catalinii commented 2 months ago

The only concern I have is with 2:

the issue is that the current signal thread is separate and processes the adapters in order. Relying on testing signal can produce non deterministic amount of time for the adapters to be tuned.

then if you have multiple requests at the same time you may have to reject some requests.

If signal is a concern you can cache the (adapter, src, freq) -> signal And use that to make a routing decision

lars18th commented 2 months ago

Hi @catalinii ,

Yes, I've proposals for this condition as well. My idea is this:

I think this strategy could be easy to implement, and powerful for the user.

But in any case, my idea it's to first implement use cases 1 and 4. Then the use case 3. And only at the end the use case 2 that is the most complex.