Multiple JVM (and separate processes). Le 19 juin 2013 à 09:47, Chetan Mehrotra a écrit :
> Do you want to launch multiple jvm (seprate processes) of Felix or > within same process multiple Felix instances? > > Chetan Mehrotra > > > On Wed, Jun 19, 2013 at 1:12 PM, Benoît Thiébault <[email protected]> > wrote: >> Hi everyone, >> >> We have developed a simulation software based on OSGi and using Felix. >> >> The execution of the application is done in a script that executes the >> following command: >> java -jar -Dfelix.config.properties=file:./resources/felix/config.properties >> ./dependencies/thirdparty/felix-4.0.2/felix.jar >> >> We then have two folders containing all the OSGi bundles that are >> automatically installed and started by felix when it is launched. >> >> This works very well. >> >> Users have however requested to be able to launch several instances of our >> software (to run several simulations in parallel for instance). This however >> does not work and I think felix has difficulties dealing with the cache >> folder when multiple instances are running in parallel >> >> Our Felix config.properties file is in attachement. >> >> Does anyone know how to solve this problem? >> >> Kind regards, >> >> Ben >> >> # Licensed to the Apache Software Foundation (ASF) under one >> # or more contributor license agreements. See the NOTICE file >> # distributed with this work for additional information >> # regarding copyright ownership. The ASF licenses this file >> # to you under the Apache License, Version 2.0 (the >> # "License"); you may not use this file except in compliance >> # with the License. You may obtain a copy of the License at >> # >> # http://www.apache.org/licenses/LICENSE-2.0 >> # >> # Unless required by applicable law or agreed to in writing, >> # software distributed under the License is distributed on an >> # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY >> # KIND, either express or implied. See the License for the >> # specific language governing permissions and limitations >> # under the License. >> >> # >> # Framework config properties. >> # >> >> # To override the packages the framework exports by default from the >> # class path, set this variable. >> #org.osgi.framework.system.packages= >> >> # To append packages to the default set of exported system packages, >> # set this value. >> #org.osgi.framework.system.packages.extra= >> >> # The following property makes specified packages from the class path >> # available to all bundles. You should avoid using this property. >> org.osgi.framework.bootdelegation=sun.awt.*, sun.sun.*, com.sun.org.*, >> com.sun.*, sun.*, org.w3c.dom.traversal >> #sun.*, com.sun.* >> >> # Felix tries to guess when to implicitly boot delegate in certain >> # situations to ease integration without outside code. This feature >> # is enabled by default, uncomment the following line to disable it. >> #felix.bootdelegation.implicit=false >> >> # The following property explicitly specifies the location of the bundle >> # cache, which defaults to "felix-cache" in the current working directory. >> # If this value is not absolute, then the felix.cache.rootdir controls >> # how the absolute location is calculated. (See next property) >> #org.osgi.framework.storage=${felix.cache.rootdir}/felix-cache >> >> # The following property is used to convert a relative bundle cache >> # location into an absolute one by specifying the root to prepend to >> # the relative cache path. The default for this property is the >> # current working directory. >> felix.cache.rootdir=${user.dir} >> >> # The following property controls whether the bundle cache is flushed >> # the first time the framework is initialized. Possible values are >> # "none" and "onFirstInit"; the default is "none". >> org.osgi.framework.storage.clean=onFirstInit >> >> # The following property determines which actions are performed when >> # processing the auto-deploy directory. It is a comma-delimited list of >> # the following values: 'install', 'start', 'update', and 'uninstall'. >> # An undefined or blank value is equivalent to disabling auto-deploy >> # processing. >> felix.auto.deploy.action=install,start >> >> # The following property specifies the directory to use as the bundle >> # auto-deploy directory; the default is 'bundle' in the working directory. >> felix.auto.deploy.dir=./dependencies/main >> >> # The following property is a space-delimited list of bundle URLs >> # to install when the framework starts. The ending numerical component >> # is the target start level. Any number of these properties may be >> # specified for different start levels. >> #felix.auto.install.1= >> >> # The following property is a space-delimited list of bundle URLs >> # to install and start when the framework starts. The ending numerical >> # component is the target start level. Any number of these properties >> # may be specified for different start levels. >> #felix.auto.start.1= >> >> felix.log.level=1 >> >> # Sets the initial start level of the framework upon startup. >> #org.osgi.framework.startlevel.beginning=1 >> >> # Sets the start level of newly installed bundles. >> #felix.startlevel.bundle=1 >> >> # Felix installs a stream and content handler factories by default, >> # uncomment the following line to not install them. >> #felix.service.urlhandlers=false >> >> # The launcher registers a shutdown hook to cleanly stop the framework >> # by default, uncomment the following line to disable it. >> #felix.shutdown.hook=false >> >> # >> # Bundle config properties. >> # >> org.osgi.service.http.port=8080 >> obr.repository.url=http://felix.apache.org/obr/releases.xml >> >> # File install configuration >> felix.fileinstall.dir=./lib >> felix.fileinstall.log.level=1 >> felix.fileinstall.noInitialDelay=true >> felix.fileinstall.poll=10000 >> >> >> -- >> Dr Benoît Thiébault >> Project Manager >> >> Artenum Toulouse - Science & Groupware >> http://www.artenum.com >> >> Bâtiment Calfocenter >> 10, rue Marguerite-Long >> 31320 Castanet-Tolosan >> France >> Phone: +33 (0)5 82 95 19 00 >> >> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [email protected] >> For additional commands, e-mail: [email protected] >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > -- Dr Benoît Thiébault Project Manager Artenum Toulouse - Science & Groupware http://www.artenum.com Bâtiment Calfocenter 10, rue Marguerite-Long 31320 Castanet-Tolosan France Phone: +33 (0)5 82 95 19 00

