home
products
contribute
download
documentation
forum
Home
Forums
New posts
Search forums
What's new
New posts
All posts
Latest activity
Members
Registered members
Current visitors
Donate
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Search titles only
By:
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
MediaPortal 2
Plugin Development
Registering a new Aspect from a Plugin failing
Contact us
RSS
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="MJGraf" data-source="post: 935295" data-attributes="member: 17886"><p>Hi Leonard,</p><p>well, that's a good point - just had a look into the code:</p><p></p><p>At startup, the ApplicationLauncher calls</p><p></p><p>PluginManager.Startup - this is where IPluginStateTracker.Activated is called for all plugins set to autoactivate --> NRE</p><p>ApplicationCore.StartCoreServices</p><p>BackupExtensions.StartupBackendServices - this is where the MediaLibrary is instantiated --> too late...</p><p>ApplicationCore.RegisterDefaultMediaItemAspectTypes</p><p></p><p>And behind the last line is a comment that says: to be done after backed services are running</p><p></p><p>That looks like a conceptual bug to me, but in the end this is really a question for @<a href="https://forum.team-mediaportal.com/members/morpheus_xx.48495/" target="_blank">morpheus_xx</a> or @<a href="https://forum.team-mediaportal.com/members/albert.67886/" target="_blank">Albert</a>. I don't know whether PluginManager.Startup should be called after the backend services are running? To me that would make sense because as a plugin author I would assume that the backend services are running when my plugin reaches the active state, but I don't know whether there's another dependency I'm not aware of...</p><p></p><p>Good luck and keep up your great work!</p><p>Michael</p></blockquote><p></p>
[QUOTE="MJGraf, post: 935295, member: 17886"] Hi Leonard, well, that's a good point - just had a look into the code: At startup, the ApplicationLauncher calls PluginManager.Startup - this is where IPluginStateTracker.Activated is called for all plugins set to autoactivate --> NRE ApplicationCore.StartCoreServices BackupExtensions.StartupBackendServices - this is where the MediaLibrary is instantiated --> too late... ApplicationCore.RegisterDefaultMediaItemAspectTypes And behind the last line is a comment that says: to be done after backed services are running That looks like a conceptual bug to me, but in the end this is really a question for @[URL='https://forum.team-mediaportal.com/members/morpheus_xx.48495/']morpheus_xx[/URL] or @[URL='https://forum.team-mediaportal.com/members/albert.67886/']Albert[/URL]. I don't know whether PluginManager.Startup should be called after the backend services are running? To me that would make sense because as a plugin author I would assume that the backend services are running when my plugin reaches the active state, but I don't know whether there's another dependency I'm not aware of... Good luck and keep up your great work! Michael [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
MediaPortal 2
Plugin Development
Registering a new Aspect from a Plugin failing
Contact us
RSS
Top
Bottom