You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Karl Pauls (JIRA)" <ji...@apache.org> on 2007/07/02 10:46:04 UTC
[jira] Created: (FELIX-316) Configuration Admin should use the
bundle data storage area by default.
Configuration Admin should use the bundle data storage area by default.
-----------------------------------------------------------------------
Key: FELIX-316
URL: https://issues.apache.org/jira/browse/FELIX-316
Project: Felix
Issue Type: Improvement
Components: Configuration Admin
Reporter: Karl Pauls
At present, the Configuration Admin creates a "config" dir in the user dir. There is the possibility to specify a different location via a property but this doesn't allow to make it use it's bundle data storage area.
I'd really like to have that possibility -- preferably, as the default.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (FELIX-316) Configuration Admin should use the
bundle data storage area by default.
Posted by "Karl Pauls (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-316?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Karl Pauls closed FELIX-316.
----------------------------
Resolution: Fixed
That works for me. Thanks a lot Felix.
> Configuration Admin should use the bundle data storage area by default.
> -----------------------------------------------------------------------
>
> Key: FELIX-316
> URL: https://issues.apache.org/jira/browse/FELIX-316
> Project: Felix
> Issue Type: Improvement
> Components: Configuration Admin
> Reporter: Karl Pauls
> Assignee: Felix Meschberger
>
> At present, the Configuration Admin creates a "config" dir in the user dir. There is the possibility to specify a different location via a property but this doesn't allow to make it use it's bundle data storage area.
> I'd really like to have that possibility -- preferably, as the default.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (FELIX-316) Configuration Admin should use the
bundle data storage area by default.
Posted by "Karl Pauls (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-316?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510016 ]
Karl Pauls commented on FELIX-316:
----------------------------------
There seems to be a minor issue with the implementation namely, the FilePersisenceManager will create a somewhat deep directory structure in the bundle data area. The reason is that it first gets the config dir file from the context and then gets its absolute path. Subsequently, it checks whether the file returned from the context is absolute (which it is not - the path string called "location" is) and because it is not it will request a new file form the context using the previously extracted absolute path and use that one as config dir. This is an issue on certain platforms that have weak support for deep directory structures. It should be easy to fix.
> Configuration Admin should use the bundle data storage area by default.
> -----------------------------------------------------------------------
>
> Key: FELIX-316
> URL: https://issues.apache.org/jira/browse/FELIX-316
> Project: Felix
> Issue Type: Improvement
> Components: Configuration Admin
> Reporter: Karl Pauls
> Assignee: Felix Meschberger
>
> At present, the Configuration Admin creates a "config" dir in the user dir. There is the possibility to specify a different location via a property but this doesn't allow to make it use it's bundle data storage area.
> I'd really like to have that possibility -- preferably, as the default.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (FELIX-316) Configuration Admin should use the
bundle data storage area by default.
Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-316?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12509557 ]
Felix Meschberger commented on FELIX-316:
-----------------------------------------
Sounds reasonable. Just for clarification on my part:
Currently the configuration file location is slected as follows:
- check the "felix.cm.dir" bundle context property
- if the property is not set fallback to the "config" directory in the current working directory (user.dir Java property)
I suspect you envision something like:
- check the "felix.cm.dir" bundle context property
- if the property is not set use the "config" directory in the Configuration Admins bundle data area
- If the framework has not bundle data area, that is BundleContext.getDataFile(String) returns null for any path fall back to the "config" directory in the current working directory (user.dir Java property)
alternatively, we could use the felix.cm.dir as follows:
- if set and relative: use it inside the Bundle Data area (or current directory if there is Bundle Data area)
- if set and absolute, use the exact path
- if not set, use "config" in Bundle Data area (or current directory if there is Bundle Data area)
Actually, I tend to more like the second solution. What do you think ?
> Configuration Admin should use the bundle data storage area by default.
> -----------------------------------------------------------------------
>
> Key: FELIX-316
> URL: https://issues.apache.org/jira/browse/FELIX-316
> Project: Felix
> Issue Type: Improvement
> Components: Configuration Admin
> Reporter: Karl Pauls
> Assignee: Felix Meschberger
>
> At present, the Configuration Admin creates a "config" dir in the user dir. There is the possibility to specify a different location via a property but this doesn't allow to make it use it's bundle data storage area.
> I'd really like to have that possibility -- preferably, as the default.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (FELIX-316) Configuration Admin should use the
bundle data storage area by default.
Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-316?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Felix Meschberger reassigned FELIX-316:
---------------------------------------
Assignee: Felix Meschberger
> Configuration Admin should use the bundle data storage area by default.
> -----------------------------------------------------------------------
>
> Key: FELIX-316
> URL: https://issues.apache.org/jira/browse/FELIX-316
> Project: Felix
> Issue Type: Improvement
> Components: Configuration Admin
> Reporter: Karl Pauls
> Assignee: Felix Meschberger
>
> At present, the Configuration Admin creates a "config" dir in the user dir. There is the possibility to specify a different location via a property but this doesn't allow to make it use it's bundle data storage area.
> I'd really like to have that possibility -- preferably, as the default.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (FELIX-316) Configuration Admin should use the
bundle data storage area by default.
Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-316?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510072 ]
Felix Meschberger commented on FELIX-316:
-----------------------------------------
Fixed the use of the BundleContext.getDataFile result to ensure only the absolute path is used.
I also adapted the test case to have tests for both situations of the BundleContext.getDataFile: return absolute and relative Files.
Fixed in Rev. 553090.
> Configuration Admin should use the bundle data storage area by default.
> -----------------------------------------------------------------------
>
> Key: FELIX-316
> URL: https://issues.apache.org/jira/browse/FELIX-316
> Project: Felix
> Issue Type: Improvement
> Components: Configuration Admin
> Reporter: Karl Pauls
> Assignee: Felix Meschberger
>
> At present, the Configuration Admin creates a "config" dir in the user dir. There is the possibility to specify a different location via a property but this doesn't allow to make it use it's bundle data storage area.
> I'd really like to have that possibility -- preferably, as the default.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (FELIX-316) Configuration Admin should use the
bundle data storage area by default.
Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-316?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510100 ]
Felix Meschberger commented on FELIX-316:
-----------------------------------------
The latest bundle (20070704.072110-4) deployed to Apache Snapshots contains this fix.
> Configuration Admin should use the bundle data storage area by default.
> -----------------------------------------------------------------------
>
> Key: FELIX-316
> URL: https://issues.apache.org/jira/browse/FELIX-316
> Project: Felix
> Issue Type: Improvement
> Components: Configuration Admin
> Reporter: Karl Pauls
> Assignee: Felix Meschberger
>
> At present, the Configuration Admin creates a "config" dir in the user dir. There is the possibility to specify a different location via a property but this doesn't allow to make it use it's bundle data storage area.
> I'd really like to have that possibility -- preferably, as the default.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (FELIX-316) Configuration Admin should use the
bundle data storage area by default.
Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-316?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12509814 ]
Felix Meschberger commented on FELIX-316:
-----------------------------------------
I have implemented this extension and checked in as Rev. 552770.
Actually, I implemented the second solution, which essentially is an extension of the first solution. While the first solution does not use the bundle data area in case the felix.cm.dir property is set, the second solution still uses the data area and thus allows overwriting the default data area location with a felix.cm.dir property.
I am currently investigating another issue reported on the Felix User list, so I will delay deploying a snapshot until after this investigation.
> Configuration Admin should use the bundle data storage area by default.
> -----------------------------------------------------------------------
>
> Key: FELIX-316
> URL: https://issues.apache.org/jira/browse/FELIX-316
> Project: Felix
> Issue Type: Improvement
> Components: Configuration Admin
> Reporter: Karl Pauls
> Assignee: Felix Meschberger
>
> At present, the Configuration Admin creates a "config" dir in the user dir. There is the possibility to specify a different location via a property but this doesn't allow to make it use it's bundle data storage area.
> I'd really like to have that possibility -- preferably, as the default.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (FELIX-316) Configuration Admin should use the
bundle data storage area by default.
Posted by "Karl Pauls (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-316?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12509567 ]
Karl Pauls commented on FELIX-316:
----------------------------------
I think I prefer the first solution but I don't care to much as long as the bundle data area is used by default :-)
> Configuration Admin should use the bundle data storage area by default.
> -----------------------------------------------------------------------
>
> Key: FELIX-316
> URL: https://issues.apache.org/jira/browse/FELIX-316
> Project: Felix
> Issue Type: Improvement
> Components: Configuration Admin
> Reporter: Karl Pauls
> Assignee: Felix Meschberger
>
> At present, the Configuration Admin creates a "config" dir in the user dir. There is the possibility to specify a different location via a property but this doesn't allow to make it use it's bundle data storage area.
> I'd really like to have that possibility -- preferably, as the default.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (FELIX-316) Configuration Admin should use the
bundle data storage area by default.
Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-316?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510069 ]
Felix Meschberger commented on FELIX-316:
-----------------------------------------
Thanks for pointing this out. In fact in my test cases I had the mock BundleContext return an absolute File. Which is why it worked I will fix to ensure the result of BundleContext.getDataDir is in fact an absolute file.
> Configuration Admin should use the bundle data storage area by default.
> -----------------------------------------------------------------------
>
> Key: FELIX-316
> URL: https://issues.apache.org/jira/browse/FELIX-316
> Project: Felix
> Issue Type: Improvement
> Components: Configuration Admin
> Reporter: Karl Pauls
> Assignee: Felix Meschberger
>
> At present, the Configuration Admin creates a "config" dir in the user dir. There is the possibility to specify a different location via a property but this doesn't allow to make it use it's bundle data storage area.
> I'd really like to have that possibility -- preferably, as the default.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.