[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
[platform-update-dev] Cascaded Configuration Areas
|
Hi Everyone,
I just posted the following (see the end of this email)
to the platform newsgroup but figured I may get a better response here.
But while I am at it - I came across another (related) anomoly in
the docs that I can't seem to get to work at all. The docs state
that you can declare configuration areas as read only by setting certain
properties to 'true'. For example, setting osgi.sharedConfiguration.area.readOnly=true
is supposed to make your shared configuration area read only. But
I can't get this to work, and I can't see any code that actually uses this
property or does anything with it. The launcher code (Java) actually
attempts to write a file to the configuration area to see if it is read
only. So apart from physically setting the area to be read only I
can't see a way to take advantage of the platform automatically calculating
a user configuration area for me. Am I missing something?
I'm asking because I may have answered my original
question below. I found this information in the docs:
Setting the private configuration area location
The default location for a private configuration area is:
<user-home-dir>/.eclipse/<product-id>_<product-version>/configuration
The user home dir is determined by the user.home
Java system property. The product id and version are obtained from the
product marker file .eclipseproduct
under the Eclipse install.
So it appears that the recommended way of specifying
a user configuration area is to encode the product ID and product version
into the path - which sort of answers my original question about multiple
products accessing the same configuration area. However, I don't
have access to this information in any dynamic way so it would be nice
to let the platform calculate it for me. BUT - it appears from my
failed attempts and grokking the source that this calculation *only* occurs
if the shared configuration area is physically unwriteable, and setting
those magical *.readOnly properties has no effect.
Thanks,
Mark.
<<original post>>
Hi There,
We are taking advantage of the cascaded configuration
areas with our product and I have a fundamental question. Let's say
I release v1.0 of our product, and the user installs a master copy into
C:\Program Files\<whatever>, and thus has a master "shared"
configuration area initialized under C:\Program Files\<whatever>\eclipse\configuration.
The user will then maintain a user configuration area in c:\Documents
and Settings\<user>\.eclipse\configuration. This all works
fine and user settings and plugins installed by the user go into their
user configuration area. Over the course of time the product is upgraded
from 1.0 to 1.2, 1.2, 1.3, etc. - all of which is done with a proper installer
on Windows, and the plugins in the shared configuration area are all properly
updated using the Eclipse update mechanism. The user configuration
area detects and responds to changes in the master, shared configuration
area and life is good.
Now what happens if I then release v2.0 of our product
and it is intended to coexist with v1.x of our product, but I don't change
the user configuration area to point to a new location? I assume
Eclipse is going to regenerate the appropriate files as required (in particular
platform.xml), but will this work seamlessly in both directions? Also,
what if I run both products at once? Will weird things happen? I
assume they will because the user-specific platform.xml has the following
in it right now:
<config date="1181147819593" shared_ur="file:configuration/org.eclipse.update/platform.xml"
transient="false" version="3.0">
</config>
If I run two products at the same time that are installed
in two different folders (and thus the master, "shared" configuration
area is different between the two products), but the user configuration
area is the same - c:\Documents and Settings\<user>\.eclipse\configuration
- I assume there will be contention on this file (in particular on the
datestamp)?
What is the recommended way of doing this? Any
advice is appreciated.
Thanks,
Mark.
AMI Semiconductor - "Silicon Solutions for the Real World"
NOTICE:
This electronic message contains information that may be confidential or privileged. The information is intended for the use of the individual or entity named above. If you are not the intended recipient, please be aware that any disclosure, copying, distribution or use of the contents of this information is prohibited. If you received this electronic message in error, please notify the sender and delete the copy you received.