<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<br>
<div class="moz-cite-prefix">On 5/2/14 5:45 PM, Cantor, Scott wrote:<br>
</div>
<blockquote
cite="mid:BA63CEAE152A7742B854C678D9491383CA2AF9E7@CIO-KRC-D1MBX01.osuad.osu.edu"
type="cite">
<blockquote type="cite">
<pre wrap="">Anyway, I don't know if this is useful, or solves any problems or makes things
cleaner, but worth looking at. One advantage I think is that you could then
just have generic boilerplate:
<context:property-placeholder />
declared once in each app context config XML, without referencing any
specific 'location', etc.
</pre>
</blockquote>
<pre wrap="">
I sent a note about this to Tom and Rod since it's more internal discussion at this point, but we actually may need to figure out how to do that,</pre>
</blockquote>
<br>
<br>
<br>
I think the above pretty much just works if you configure any
PropertySource(s) on the context, since in recent versions of Spring
the above context: schema element actually installs by default an
instance of PropertySourcesPlaceholderConfigurer (which is
PropertySource-aware), rather than the older
PropertyPlaceholderConfigurer (which isn't).<br>
<br>
<br>
<br>
<blockquote
cite="mid:BA63CEAE152A7742B854C678D9491383CA2AF9E7@CIO-KRC-D1MBX01.osuad.osu.edu"
type="cite">
<pre wrap=""> because right now we have some degree of disconnect between treating Windows paths as actual paths and treating them as <a class="moz-txt-link-freetext" href="file:/">file:/</a> URLs.</pre>
</blockquote>
<br>
<br>
I don't know if this helps for the Windows cases, but what I'm
actually doing in one of my components (CLI) is just setting some
base paths like app.home and app.configDir using the PropertySource,
and then in the XML wiring I just have:<br>
<br>
<tt><context:property-placeholder
location=<a class="moz-txt-link-rfc2396E" href="file:${app.configDir}/app.properties">"file:${app.configDir}/app.properties"</a>/></tt><br>
<br>
Just lets me abstract away the app.home and so forth, for example by
allowing it to be specified by a command-line argument.<br>
<br>
<br>
<br>
Fwiw, I also supply the same base properties (which includes an
app.logDir) to the code that bootstraps my Logback config, and set
those properties natively in the LoggerContext like so:<br>
<br>
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
<pre>loggerContext.putProperty(propName, properties.getProperty(propName))</pre>
<br>
which then lets me reference those in my logback.xml.<br>
<br>
<br>
<blockquote
cite="mid:BA63CEAE152A7742B854C678D9491383CA2AF9E7@CIO-KRC-D1MBX01.osuad.osu.edu"
type="cite">
<pre wrap="">
You can get away with some things when you use them as URLs that don't work when you try and do path weaving with the Path class.
I'm going to need to review what V2 is doing with IDP_HOME, if anything.
</pre>
</blockquote>
<br>
<br>
Yeah, I don't know what we did in V2 vis-a-via Windows, but I guess
it must be working somehow...<br>
<br>
<br>
<br>
<br>
<br>
<br>
</body>
</html>