• 1 reply
  • Latest Post - ‏2013-08-21T20:11:29Z by AlexMulholland
12 Posts

Pinned topic WLP 8.5.5 Including Shared Config

‏2013-07-31T18:27:27Z | 8.5.5 config include liberty shared wlp

I am trying to use the shared configuration for a server.xml file in WLP 8.5.5. I created a file 'commonWestyServer.xml' with all of the shared configuration for the server, and put it in the 'shared/config' directory. I then deleted that shared info from my 'server.xml', and replaced it with:

<server description="Westy's Test WLP 8.5.5 Server">
    <include location="commonWestyServer.xml" optional="false" />

However, it cannot find that file, either through the Eclipse tooling, or when I start up the server.

[ERROR   ] CWWKG0001E: The configuration parser detected an error while parsing the root of the
configuration and the referenced configuration documents. Error: Cannot read commonWestyServer.xml

I was under the impression from reading the doc that for any location that was not absolute, it would first look in the same directory as the file that includes it, then in the server's configuration directory (which in this case is the same as the previous, since we're talking about 'server.xml'), and then in 'shared/config'. But this does not appear to be the case. I even put the file in 'shared' and 'shared/resources', just in case, but that didn't help. When I put it in the same place as 'server.xml', then it finally worked.

Should it be finding this file where it is? Or did I misunderstand this following statement in the doc?

"Included files can be specified using full paths, paths with variables, or relative
paths. Relative paths are resolved by looking in a location relative to the parent
file, the server's configuration directory, or the shared configuration directory (in
that order)."

I have attached a screenshot of my Eclipse workspace and error messages.

  • AlexMulholland
    32 Posts

    Re: WLP 8.5.5 Including Shared Config


    Hi David,

    You're right this is an error in the documentation - sorry about that, I'll look at getting it corrected.  

    You need to specify:  <include location="${shared.config.dir}/included-file.xml" />

    Regards, Alex.