Comments (3)
If I then delete the first configuration object, component instances for two remaining configuration objects are activated:
list Available configurations: [0] Component._0 [1] Component._1 [2] Component._2 configuration> delete 0 Deleting Component._0 configuration> [stdout] === Deactivate null === [stdout] component.name=Component [stdout] component.id=1 [stdout] === Constructor === [stdout] === Activate 2 === [stdout] service.pid=Component._1 [stdout] service.factoryPid=Component [stdout] component.name=Component [stdout] number=2 [stdout] component.id=1 [stdout] === Constructor === [stdout] === Activate 3 === [stdout] service.pid=Component._2 [stdout] service.factoryPid=Component [stdout] component.name=Component [stdout] number=3 [stdout] component.id=1
But only one of them is shown by the SCR command:
enter scr scr> show -f Component ID State BID Name 1 ACTIVE 28 Component > No services provided. > No referenced services > Property component.id = 1 > Property component.name = Component > Property number = 2 > Property service.factoryPid = Component > Property service.pid = Component._1 > Immediate component, default enabled, config policy = require scr> enter configuration configuration> list Available configurations: [0] Component._1 [1] Component._2 configuration> delete 0 Deleting Component._1 configuration> [stdout] === Deactivate null === [stdout] component.name=Component [stdout] component.id=1
I don't think "Deactivate null" is right, all component properties should be passed to deactivate method, including number=2, so it should be Deactivate 2.
Here, the last configuration object is deleted, but a Component Instance with configuration-policy="require" is still activated despite having no configurations available.
list Available configurations: [0] Component._2 configuration> delete 0 Deleting Component._2 configuration> [stdout] === Deactivate null === [stdout] component.name=Component [stdout] component.id=1 [stdout] === Constructor === [stdout] === Activate null === [stdout] component.name=Component [stdout] component.id=1 enter scr scr> show -f Component ID State BID Name 1 ACTIVE 28 Component > No services provided. > No referenced services > Property component.id = 1 > Property component.name = Component > Immediate component, default enabled, config policy = require scr> enter configuration configuration> list No configurations available configuration>
from knopflerfish.org.
I've tested test this and can confirm the bug. This bug was introduced in 6.0.0, in the previous version things worked correctly.
from knopflerfish.org.
Bug fixed in component(SCR) bundle version 6.0.2.
from knopflerfish.org.
Related Issues (20)
- proguard does not support java 9
- asm and JDK9 HOT 1
- Release docs: index.html
- Release docs: index.html
- docs: programming.html
- Dynamic import dead lock HOT 1
- Building with JDK10 fails HOT 1
- Improve framework log message when unable to resolve
- Using target property filters may cause SCR to give incorrect errors for circular component chains
- Junit test doesn't detect if it fails to start a test bundle HOT 2
- SCR doesn't handle service that dynamically changes service ranking
- reference:file: bundles can not be loaded if org.knopflerfish.osgi.registerserviceurlhandler=false HOT 2
- Compiling KF with JDK 11 HOT 4
- Deadlock weaving hooks HOT 1
- Question about Knopflerfish R7 compatibility for SCR HOT 2
- SCR gets ConcurrentModificationException in service listener HOT 1
- API question: HttpService registerServlet and registerResources enumeration HOT 1
- Is this project dead? HOT 1
- Http Server: threads created in transactions increase activeCount and server will eventually stop processing requests
- Generate a maven repository index file
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from knopflerfish.org.