OHDSI Home | Forums | Wiki | Github

WebAPI installation issue

mvn command worked fine. the issue I found was that POM.xml file was missing from Maven home, which fixed the error that I had on my above post and came across a new error.
Screenshot for the error has been attached

I validated the POM.xml and didn’t find any special characters so far. Please help.

TIA

Sorry, I do not understand this: you should not need to copy any Pom.XML files anywhere. You should have the root of the WebAPI directory which has the pom.xml, and then you specify the path to settings.xml via your mvn command. I’m not sure what the ‘maven home’ has to do with this.

Also, from the error, it is indicating which files it is unable to parse (the one under /jackson, for example), you should check the file in that location. I’m guessing that it downloaded an HTTP error response and not the pom.xml file for that library.

Ok, please let me know if I am doing something wrong here.
settings.xml lies under /root/WebAPI/settings.xml
maven lies at : /opt/apache-maven-3.6.0/conf
I am using the following command -
[root@ambuj~]# cd /opt/apache-maven-3.6.0/conf
[root@ambuj conf]#mvn clean package -s /root/WebAPI/settings.xml -P webapi-postgresql

I fixed the files and there is another error which I am not sure of.
[ERROR] the goal you specified requires a project to execute but there is no POM in this directory
Kindly suggest if I am doing it the correct way. Also with the error I can see there are too many discrepancies within the jackson’s folder’s pom files.

Try running maven from the WebAPI directory (i.e. the directory in which you clone the WebAPI git repo and in which the project POM should be located, as per @Chris_Knoll above). E.g.

[root@ambuj~]#cd /root/WebAPI
[root@ambuj conf]#mvn clean package -s settings.xml -P webapi-postgresql

Thank yo so much for correcting me. But I landed up on a different error overall.
[ERROR] Some problems were encountered while processing the POMs:
[FATAL] Non-parseable POM /root/.m2/repository/com/fasterxml/jackson/jackson-bom/2.8.7/jackson-bom-2.8.7.pom: entity reference name can not contain character ’ (position: START_TAG seen …is = true;\n }\n\n\tvar recipientsList = “”;\n\n\tfor (var i=0; i &lt … @184:22) @ /root/.m2/repository/com/fasterxml/jackson/jackson-bom/2.8.7/jackson-bom-2.8.7.pom, line 184, column 22 [FATAL] Non-parseable POM /root/.m2/repository/org/apache/logging/log4j/log4j-bom/2.7/log4j-bom-2.7.pom: start tag unexpected character ; (position: TEXT seen …\n\tvar recipientsList = “”;\n\n\tfor (var i=0; i [Help 1] [ERROR]
[ERROR] The project org.ohdsi:WebAPI:1.0.0-SNAPSHOT (/root/WebAPI/pom.xml) has 2 errors [ERROR] Non-parseable POM /root/.m2/repository/com/fasterxml/jackson/jackson-bom/2.8.7/jackson-bom-2.8.7.pom: entity reference name can not contain character ’ (position: START_TAG seen …is = true;\n }\n\n\tvar recipientsList = “”;\n\n\tfor (var i=0; i &lt … @184:22) @ /root/.m2/repository/com/fasterxml/jackson/jackson-bom/2.8.7/jackson-bom-2.8.7.pom, line 184, column 22 -> [Help 2] [ERROR] Non-parseable POM /root/.m2/repository/org/apache/logging/log4j/log4j-bom/2.7/log4j-bom-2.7.pom: start tag unexpected character ; (position: TEXT seen …\n\tvar recipientsList = “”;\n\n\tfor (var i=0; i [Help 2]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException [ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/ModelParseException

function recipientsArr2StrInTable(recipientsArr, ellipsisLimit, useLinebreakes)
if (ellipsisLimit == undefined)
{
ellipsisLimit = 0;
}

if (useLinebreakes == undefined)
{
useEllipsis = true;
}

var recipientsList = "";

for (var i=0; i<recipientsArr.length; i++)
{
recipientsList += HTMLEncode(recipientsArr[i].address);
if (i < recipientsArr.length-1)
{
    recipientsList += ", ";
    if (useLinebreakes)
    {
        recipientsList += "<br>";
    }
}
}

if (ellipsisLimit > 0)
{
//recipientsList = Ext.util.Format.ellipsis(recipientsList, 
ellipsisLimit);
recipientsList = recipientsList;`enter code here`
}

return recipientsList;
} //

======================================================================================

And the line 184 where it is locating the error, I am unable to understand what is the issue with that line. I also re-downloaded the xml files by calling mvn clean.

Please let me know if you have any solution to this one.

This is the core of the problem, and somehow maven downloaded a corrupt POM.xml and has problems parsing it. What I would do is complete delete /root/.m2/repository/com/fasterxml (and all child directories) and maven will attempt to re-download those dependencies again. The text file you included in your message looks like some kind of javascript, which may have been rendered if you are going through some kind of HTTP proxy and it was prompting you for some kind of input before proceeding? So check your internet connection to ensure you can access the remote maven repositories without errors.

I tried the step to delete the files under /root/.m2 and maven did restarted download when I invoked the query. And again I landed up on the same error which I posted on my previous post.
However, one thing I observed are couple of WARNING messages I receive during download. I am pasting it here so you can shed some light on it if it is due to network firewall or something else.

Happy Friday


Hi, @ambuj, I just did a ‘clean’ build on my side (by deleting everything under my .m2/repository, and ran my mvn build, and it successfully downloaded and compiled the war.

My maven version is 3.5.4, could you paste a screenshot of what you get when you do a mvn -v? Perhaps this is a maven verision issue.

This is what i get:

hi, @Chris_Knoll,
Hope you had a great weekend.
I tried to clean up the /.m2/repository folder and redid the installation of files from repository and got the same errors as mentioned in WebAPI installation issue - #13 by Chris_Knoll. here is the screenshot for mvn -v.

And, I also see errors when the fresh files gets downloaded, so I am assuming that my network firewall is blocking something…Let me know your thoughts on this, whether its maven version issue or its a firewall situation.

TIA

I think it’s a firewall situation. Is there any way you can get a clean connection (not proxied) to the internet and try again?

yes, I will try to do that and let you know if I come across any issues with it.

@Chris_Knoll, well,nothing changed after removing the firewalls from the network.
Then I tried to open following url’s manually and got the errors:
http://repo.odysseusinc.com/artifactory/community-libs-release-local/com/fasterxml/jackson/jackson-bom/2.8.7/jackson-bom-2.8.7.pom
{
“errors” L [ {
“status” : 404,
“message” : “File not found.”
} ]
}

above error comes with this url too:
http://repo.odysseusinc.com/artifactory/community-libs-release-local/org/apache/logging/log4j/log4j-bom/2.7/log4j-bom-2.7.pom

So, I am confused at why the url have such error.
Please help.

Hi, I noticed the same responses on my side when going to those URLs. However, running the maven command does not result in the same error that you have. However, I’m running on a 3.5 version of maven. and you are 3.6. Is there a way you could install the 3.5.3 version of maven?

Otherwise, i’m sorry, I do not know what is going on in your environment, but i can not reproduce it.

Yes, i can get maven 3.5. I will try that and update you.
By any chance can you upload your pom.xml file here, i can refer the url’s mentioned to download.

I use the pom.xml directly out of the git repository, so I never modify it.

ok. I will try to degrade Maven from 3.6 to 3.5.3 and try it out. Were you also using CentOS?
Also, I am using Java 8, so shall I use Java 7 on it.

I tried changing the names in url in POM.xml from http://repo.odysseusinc.com/artifactory/community-libs-snapshot-local to http://repo.odysseusinc.com/artifactory/libs-release
and http://repo.odysseusinc.com/artifactory/community-libs-release-local to http://repo.odysseusinc.com/artifactory/libs-release
After that all the files gets downloaded without any issues.
When it started building .war file it started throwing WARNING messages and ended up with BUILD FAILURE.
I am uploading the errors for that.
Can you please confirm why change in the url made the downloading a success and later a failure in build due to connection time out error. Is this is an issue with the url ? because I do not have any firewall restrictions so far.
Sorry for eating your head on this but this is really concerning, I cannot decide whether its url issue or maven issue.

TIA

With the final error of ‘connection timed out’ it indicates failure to connect to the server. Network issues are annoying, but when I’m faced with this, I try to execute again and see if the network issue was temporary.

Also, I’m not sure the impact of changing the values in the pom.xml file. @pavgra or @gregk : can you please chime in on this, we seem to be having frequent issues with the Odysseus artifactory, and I have no visibility as to what might be wrong there.

@Chris_Knoll as suggested, I rolled back Maven 3.6.0 and installed 3.5.3 with fresh WebAPI retrieval from git.
however, the error is still there without any changes made to the urls.
Screenshot attached for your reference. looks like I am completely lost here now :frowning:

As soon as it started throwing error, I barred it to save time. Please help.

So here is what I did so far:
O.S Cent OS 7
Maven 3.5.3
Java 8
Scenario1 - No changes made to urls in POM.XML
When I tried to create the .war file, I got the errors for checksum validation for jackson-bom and log-bom files.
I tried to open those respective urls in browser
http://repo.odysseusinc.com/artifactory/community-libs-release-local/com/fasterxml/jackson/jackson-bom/2.8.7/jackson-bom-2.8.7.pom
http://repo.odysseusinc.com/artifactory/community-libs-release-local/org/apache/logging/log4j/log4j-bom/2.7/log4j-bom-2.7.pom
With both of them I get
{
“errors” : [ {
“status” : 404,
“message” : “File not found.”
} ]
}
Now, I manually tried to go through the path and I cannot find fasterxml mentioned within the url


So, is this an issue for which I am receiving errors?

Scenario2: Changes made in POM.XML
Following url’s has been changed
http://repo.odysseusinc.com/artifactory/community-libs-snapshot-local
to
https://repo.odysseusinc.com/artifactory/libs-snapshot-local

and
http://repo.odysseusinc.com/artifactory/community-libs-release-local
to
http://repo.odysseusinc.com/artifactory/libs-release

With this all the required files gets downloaded without any issues, but when the war file build comes in picture it shows the connection times out for sqlrender.

I am not getting which way to go through as I am getting errors with everything I am doing to make it work. @pavgra @gregk @anthonysena @Chris_Knoll

t