one of the things I'm setting up is a local Maven repository, and to
have an easy way of maintaining it. I'm testing out Artifactory
(http://www.jfrog.org/sites/artifactory/latest/), and I've come across
what seems to be a bug. In the Config instructions, it only mentions
artifactory.config.xml. There is no mention of any config files
outside the Artifactory install directory.
It seems that if you install Artifactory on a machine that already has
Maven installed on it, it will use the settings.xml for that Maven
installation. This however means that if there are any errors in that
local settings.xml - ie, invalid XML, etc - then Artifactory will not
run.
A few of the things I tried that didn't work:
- delete [ARTIFACTORY_HOME]/data directory
- renamed old Artifactory directory and reinstalled from zip file
- cleaned out C:/Temp
In the console output I noticed this error:
Caused by: org.codehaus.plexus.util.xml.pull.XmlPullParserException: in comment
after two dashes (--) next character must be > not - (position: START_TAG seen .
..</nonProxyHosts>\r\n---... @15:4)
at org.codehaus.plexus.util.xml.pull.MXParser.parseComment(MXParser.java
:2334)
at org.codehaus.plexus.util.xml.pull.MXParser.nextImpl(MXParser.java:117
4)
at org.codehaus.plexus.util.xml.pull.MXParser.next(MXParser.java:1090)
at org.apache.maven.settings.io.xpp3.SettingsXpp3Reader.parseSettings(Se
ttingsXpp3Reader.java:1325)
at org.apache.maven.settings.io.xpp3.SettingsXpp3Reader.read(SettingsXpp
3Reader.java:1637)
at org.apache.maven.settings.io.xpp3.SettingsXpp3Reader.read(SettingsXpp
3Reader.java:1648)
Which would indicate something wrong with an XML config file. I had
settings.xml open and I remembered I'd had this problem before with
XML files.
I removed the dashes in the XML comment, restarted Artifactory, and
w000t, it was working again.