felix-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Roland <...@ids.de>
Subject Re: Why OSGI Configuration is bound to a admin bundle temporary?
Date Tue, 09 Jul 2013 14:18:04 GMT
hi,
I have a similar issue. I get the below debug output if I register the
service and the parameter "properties" of the callback-function 
ManagedService::updated() is null. If I call Configuration::update() no
event is fired.

No SynchronousConfigurationListeners to send {0} event to.



  public void start(BundleContext context) throws NullPointerException {
    bundlecontext = context;
    new Thread() {
      public void run() {

        ...

        MyClass ctrl = new MyClass();
        Dictionary<String, Object> properties = new Hashtable<String,
Object>();
        properties.put(Constants.SERVICE_PID, MyClass.class.getName());
        String[] classnames = {ManagedService.class.getName(),
MyClass.class.getName()};
        rs = bundlecontext.registerService(classnames, ctrl, properties);

        ...

        configuration =
configAdmin.createFactoryConfiguration(MyClass.class.getName(), null);
        configuration.update(properties); 
      }
    }.start();
  }

Does anyone have an idea or a suggestion?

Thanks in advance!
Roland



--
View this message in context: http://apache-felix.18485.x6.nabble.com/OSGI-Configuration-cannot-take-effect-immediately-tp4833849p5004254.html
Sent from the Apache Felix - Users mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Mime
View raw message