Jump to content

SDK documentation?


Go to solution Solved by softworkz,

Recommended Posts

Posted

For developing a Metadata provider, I would strongly advise doing so, to understand how the server calls in to your provider. With the Data Explorer plugin for Emby Server, you can not only see the information returned by all providers and how they're prioritized - you can also use it to trigger calls into your provider (repeatedly for the same item), which is also very useful.

  • Agree 1
Posted

@softworkzSo in general debugging of the plugin via Visual studio is impossible due to that my plugin uses Newtonsoft.Json which is not included in emby....

Posted

You must not use this. Like I said above.

Posted
On 12/12/2024 at 10:44 PM, softworkz said:

You must not use this. Like I said above.

Not only that it might not get admitted to the store, if it causes any trouble it would even get hard-blocked by the server.

At an early stage it is much easier to change this than when you're done already, so think about my warning.

Posted (edited)

Thanks for the tip @softworkz. I have already changed my plugin and got rid of all external dependencies.....

Edited by DimitarCC
  • Like 1
Posted

Perfect! Trust me, it's for good. And let me know when you have any issues with the IHttpClient or anything else.

Posted

One additional question.... What is the situation when there are official metadata provider but that is not in the store. If i make a fork and make it compatible/acceptable for the store will it be added or that is not allowed as well?

Posted

What do you mean by "official metadata provider"?

All our providers are in the store/catalog..

Posted
3 minutes ago, softworkz said:

Perfect! Trust me, it's for good. And let me know when you have any issues with the IHttpClient or anything else.

Well the only issue for now is with impossibility to define proxy for specific IHttpClient instance...

Posted
2 minutes ago, softworkz said:

What do you mean by "official metadata provider"?

All our providers are in the store/catalog..

I mean plugins provider from the owner of the specific site but not in Emby store...

Posted
3 minutes ago, DimitarCC said:

I mean plugins provider from the owner of the specific site but not in Emby store...

I think we'd need to look at an example, but from principle: when there's a site which provides certain metadata and the site owners are also providing an open-source metadata provider for other cases, that would be sound pretty much okay, but there can always be misunderstandings, so looking at a specific case is always the best way to get to a solid picture.

Posted (edited)

@softworkzWell lets take for example https://theporndb.net/

They provide official plugin here https://github.com/ThePornDatabase/Jellyfin.Plugin.ThePornDB.

The plugin in Emby/Jellyfin combined plugin but it requires a lot of external dependencies. It is not in Emby store and probably will not be due to that dependencies (if i understood you correct).

So i have a version that have zero external dependencies and besides fixes for Emby so to really work....

Well i know this one is for Adult site (hope this is not forbidden for the store), but that was my testing ground in development of Emby plugins. The site have official API so it is suitable for developing metadata provider imho.

Edited by DimitarCC
Posted
12 minutes ago, DimitarCC said:

So i have a version that have zero external dependencies and besides fixes for Emby so to really work....

Sounds all fine to me, when the site has an API that the provider is using, that's the typical case of allowed providers. 

Regarding adult data providers, I'm not on track -  @Lukeor  @ebr will be able to tell.

  • Thanks 1
Posted

For the proxy issue: it wouldn't be a problem to add appropriate properties, but the problem is that there's no isolation and lifetime control. The base is the HttpClientHandler where this is configured and the HttpClientHandler is reused everyhwhere for the creation of new HttpClient instances (for DI).

I think the only thing you can do is to use your own and separate instaces of HttpClient and HttpClientHandler. AFAIR, there are some drawbacks on Android or some other OS, where Emby Server uses a different implementation - I'm not sure though, whether that's still the case. Another question for  @Luke - he'll know for sure.

Posted

@softworkzWell indeed DI is the issue since it  handler is one and the same....So indeed the only option is custom HttpClient (hopefully the issues on different platforms are eliminated by now).

Or maybe you can give a possibility to manipulate the base HttpClientHandler....?

Posted
6 hours ago, DimitarCC said:

Or maybe you can give a possibility to manipulate the base HttpClientHandler....?

That would change the proxy settings for all server operations..

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...