felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bengt Rodehav (JIRA)" <j...@apache.org>
Subject [jira] Created: (FELIX-2773) Automatic restart of iPOJO instance on configuration update
Date Tue, 11 Jan 2011 09:13:45 GMT
Automatic restart of iPOJO instance on configuration update

                 Key: FELIX-2773
                 URL: https://issues.apache.org/jira/browse/FELIX-2773
             Project: Felix
          Issue Type: Improvement
          Components: iPOJO
    Affects Versions: iPOJO-1.6.0
            Reporter: Bengt Rodehav
            Priority: Minor

I use iPOJO and configuration admin. When certain configuration properties change, I want
to "restart" my iPOJO instance. I e I want the instance to become invalid and then valid again.
Currently I do some initialisation on the method marked as @Validate and some cleanup in the
method marked as @Invalidate.

It's very tricky to get this to work. When I start my application it seems like both the @Validate
and the @Updated methods are called which causes problems. Ideally I would like to mark my
iPOJO properties as requiring the instance to "restart", e g

  @Property(name = "rootUrl", restart = "true")
  private String mRootUrl;

Whenever the "rootUrl" property of my instance is reconfigured, the iPOJO instance would be
invalidated and then validated again (if it is valid of course).

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message