Kodi Community Forum

Full Version: Request Get Stream twice
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
Hi all,

I don't know if this issue comes from Kodi or Addon. I'm using Kodi Leila
When I select any Channel to watch, Kodi send 2 requests Get, the first one always is closed by Kodi at few milliseconds and send second one, this last keep the connection and I can watch channel

Could you check why do that and fix?

Thanks
the first request is there to check the mime type of the file
(2020-11-04, 18:46)wsnipex Wrote: [ -> ]the first request is there to check the mime type of the file

If this have to be this way is a mess, the normal way to get that is through the respond header http
That is how I set the Server Stream header respond for dvb video ts mpg;

"HTTP/1.1 200 OK\r\n" +
"contentFeatures.dlna.org: DLNA.ORG_PN=MPEG_TS_SD_EU_ISO;DLNA.ORG_FLAGS=01100000000000000000000000000000\r\n" +
"TransferMode.dlna.org: Streaming\r\n" +
"Content-Type: video/mp2t\r\n\r\n";

Which or how should be the proper header respond http to avoid Addon request twice?

Thanks
if the server responds with mime type on a HEAD request, kodi will use this. 2 GETs only happen if the server refuses HEADs.
If you play this through an addons, you can also tell kodi which mime type is expected, so it _should_ only do 1 request.
(2020-11-04, 23:07)wsnipex Wrote: [ -> ]if the server responds with mime type on a HEAD request, kodi will use this. 2 GETs only happen if the server refuses HEADs.
If you play this through an addons, you can also tell kodi which mime type is expected, so it _should_ only do 1 request.

Hi,
Kodi doesn't do Head request for header resquest I wrote down above. Directly Kodi does 2 requests Get

It doesn't make sense. How can solve that?

Thanks
This happens with NextPVR too, I though it was three opens.  curl reads the head and tail trying to get a duration and find out if the string is seekable.  I am not sure it doesn't this is the content-length is not received.

Best bet is to turn on debug logging and component logging for libcurl and post your Kodi log to see what is really going on rather than talking theory.

Martin
For iptvsimple it will always do 2 requests unless you provide the mimetype as a KODIPROP or the mime type can be easily inferred from the file extension in the URL.
(2020-11-05, 21:58)phunkyfish Wrote: [ -> ]For iptvsimple it will always do 2 requests unless you provide the mimetype as a KODIPROP or the mime type can be easily inferred from the file extension in the URL.

Thanks phunkyfish, I just added the #KODIPROP:mimetype=video/mp2t in my m3u channel list and now only request one Get

Thanks all for help
Regards
Hi again,

I realized the imagen cover show from EPG view are required by addon requesting 2 Heads and then 1 Get. How can avoid it requests 2 Heads? I only prefer one Head and then 1 Get

Thanks
Sorry, I have no idea. I don’t even know what you mean by “imagen cover show”
(2020-11-10, 23:59)phunkyfish Wrote: [ -> ]Sorry, I have no idea. I don’t even know what you mean by “imagen cover show”

Hi,
I mean the icon of programme in XML

<programme channel="539" start="20200511121500 +0200" stop="20200511140000 +0200">
<title lang="es">Estando contigo</title>
<desc>País(Año): (2016)
</desc>
<category>Programas / Corazon/Sociedad</category>
Code:
<icon src="http://192.168.1.129:21583/Land-5043/50436133.jpg"/>

Regards
Sorry, I don’t know.
(2020-11-13, 00:49)phunkyfish Wrote: [ -> ]Sorry, I don’t know.

Ok, no problem
Thanks
out of interest: why is the HEAD request such a big issue for you?
(2020-11-14, 14:55)wsnipex Wrote: [ -> ]out of interest: why is the HEAD request such a big issue for you?

Because it doesn't make sense to do 2 Head requests, It takes time and resourse of my server and I'm perfectionist 😜
Anyway I could live with this 😄
Pages: 1 2 3