Hi,

I asume that's an issue for the Felix project now that the console
moved there, but as my example uses Sling, here it is...

I've been having trouble creating a factory component, I was getting
confused while testing, and I think I found why. My example uses the
RequestDataLogger service, which is a factory with no initial
instance, similar to the component that I was creating in my project.

When starting the Sling launchpad webapp after doing "mvn clean", the
dropdown on the http://localhost:8888/system/console/configMgr page
contains two instances of the "Customizable Request Data Logger"
service.

$ curl -s http://localhost:8888/system/console/configMgr | grep
RequestLoggerService

<option 
value='factoryPid=org.apache.sling.engine.impl.log.RequestLoggerService'>...

<option value='pid=org.apache.sling.engine.impl.log.RequestLoggerService'>...

The first one is correct (IIUC), with a factoryPid that makes the
"create config" button appear when selecting this option.

The second one looks to me like a useless empty config - after
creating an actual instance of this component with the "create config"
button, I get:

<option 
value='factoryPid=org.apache.sling.engine.impl.log.RequestLoggerService'>...

<option value='pid=org.apache.sling.engine.impl.log.RequestLoggerService'>...

<option 
value='pid=org.apache.sling.engine.impl.log.RequestLoggerService.85d3d22e-8992-4a56-be96-63efd501a468'>...

Again, the second option seems superfluous - and in firefox, one
cannot then select the first option anymore to create new configs,
unless the page is reloaded first.

Am I doing something wrong?
-Bertrand

Reply via email to