Script Module or Service?
#1
I'm looking to have 3 new scripts added to the official repository, but before I do so I would like to make sure that they are setup correctly

t0mm0's common lib & urlresolver - http://forum.xbmc.org/showthread.php?tid=105707
metahandlers - http://forum.xbmc.org/showthread.php?tid=105707

All 3 are helper scripts for creating addons, currently they are all defined as script modules - xbmc.python.module

I don't see any way of being able to install/uninstall/configure/rollback these types of scripts, so I'm second guessing if they should instead be defined as services?

I'm not really familiar with services and what makes them a service rather than a module.. ability to run in the background?

Is it wrong if I change these to be a service?
Reply
#2
Eldorado Wrote:I'm looking to have 3 new scripts added to the official repository, but before I do so I would like to make sure that they are setup correctly

t0mm0's common lib & urlresolver - http://forum.xbmc.org/showthread.php?tid=105707
metahandlers - http://forum.xbmc.org/showthread.php?tid=105707

All 3 are helper scripts for creating addons, currently they are all defined as script modules - xbmc.python.module

I don't see any way of being able to install/uninstall/configure/rollback these types of scripts, so I'm second guessing if they should instead be defined as services?

I'm not really familiar with services and what makes them a service rather than a module.. ability to run in the background?

Is it wrong if I change these to be a service?

A script module is installed when the Addon Manager comes across an addon.xml that requires the module.

Code:
<requires>
    <import addon="xbmc.python" version="2.0"/>
    <import addon="script.module.pil" version="1.1.7"/>
  </requires>

The version is controlled by the addon.xml. There doesn't seem to be a rollback for script modules

Also the script using the modules can adjust the script module settings(if needed) using the setSetting() in xbmcaddon.

A Service addon is one that runs at the start of XBMC.
Reply

Logout Mark Read Team Forum Stats Members Help
Script Module or Service?0