Java Reference
In-Depth Information
of time the component container waits during component startup for mandatory ser-
vice dependencies. The grace period ends in success if all mandatory dependencies
can be satisfied or in failure if its timeout is exceeded. If the grace period was a suc-
cess, the component is enabled and its services are registered. If the grace period was
a failure, the container is destroyed and the component isn't created. You can see how
this affects the Blueprint component lifecycle in figure 12.2.
You can configure the grace period timeout value using directives on the Bundle-
SymbolicName manifest header in the Blueprint component bundle. For example:
Bundle-SymbolicName: com.acme.foo; blueprint.graceperiod:=true;
blueprint.timeout:=10000
Here, you set the grace period timeout to be 10 seconds. It's also possible to com-
pletely disable the grace period by using blueprint.graceperiod:=false . In this
case, the Blueprint container won't wait for any mandatory service references to be
Event
Wait
Process
Entry/Exit
Decision
Lazy
bundle?
No
Yes
Wait bundle
state = ACTIVE
Wait bundle state =
ACTIVE | STARTING
Preparing
Creating
Parsing
Failed
Track references
Grace period
Wait &&
not satisfied
Grace period
No wait ||
satisfied
Satisfied
Not
satisfied
Register services
Instantiate
Failure
Created
Destroy
Wait for bundle
or extender to stop
Wait for bundle
or extender to stop
Destroying
Destroy
Destroyed
Figure 12.2 The Blueprint component lifecycle
 
Search WWH ::




Custom Search