[ 
https://issues.apache.org/jira/browse/DRILL-5849?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16196063#comment-16196063
 ] 

ASF GitHub Bot commented on DRILL-5849:
---------------------------------------

Github user arina-ielchiieva commented on the issue:

    https://github.com/apache/drill/pull/977
  
    @vrozov 
    1. Change the the main pom.xml where I have added freemarker lib to the 
`dependencyManagement` section is the core change of this pull request. With 
this change dependency resolution is always done in favor of the freemarker 
version we expect.
    2. Changes in other two pom files are just clean up. Since as we now have 
freemarker lib in `dependencyManagement` there is no need to indicate version 
there.
    3. Regarding which modules do have transitive dependency on freemarker, 
right now there are two modules  - java-exec (jersey-mvc-freemarker lib) and 
fmpp (fmpp lib).


> Add freemarker lib to dependencyManagement to ensure proper version is used 
> when resolving dependency version conflicts
> -----------------------------------------------------------------------------------------------------------------------
>
>                 Key: DRILL-5849
>                 URL: https://issues.apache.org/jira/browse/DRILL-5849
>             Project: Apache Drill
>          Issue Type: Bug
>    Affects Versions: 1.12.0
>            Reporter: Arina Ielchiieva
>            Assignee: Arina Ielchiieva
>             Fix For: 1.12.0
>
>
> After DRILL-5766 we started using newer freemarker library in Drill. There 
> several libs in Drill that also use freemarker library and sometime older 
> version is pciked up. In this case we receive the following error:
> {noformat}
> 0: jdbc:drill:zk=local> Exception in thread "main" 
> java.lang.NoSuchFieldError: VERSION_2_3_26
>                 at 
> org.apache.drill.exec.server.rest.DrillRestServer.getFreemarkerConfiguration(DrillRestServer.java:140)
>                 at 
> org.apache.drill.exec.server.rest.DrillRestServer.<init>(DrillRestServer.java:83)
>                 at 
> org.apache.drill.exec.server.rest.WebServer.start(WebServer.java:174)
>                 at 
> org.apache.drill.exec.server.Drillbit.run(Drillbit.java:141)
>                 at 
> org.apache.drill.jdbc.impl.DrillConnectionImpl.<init>(DrillConnectionImpl.java:123)
>                 at 
> org.apache.drill.jdbc.impl.DrillJdbc41Factory.newDrillConnection(DrillJdbc41Factory.java:72)
>                 at 
> org.apache.drill.jdbc.impl.DrillFactory.newConnection(DrillFactory.java:69)
>                 at 
> org.apache.calcite.avatica.UnregisteredDriver.connect(UnregisteredDriver.java:143)
>                 at org.apache.drill.jdbc.Driver.connect(Driver.java:72)
>                 at 
> sqlline.DatabaseConnection.connect(DatabaseConnection.java:167)
>                 at 
> sqlline.DatabaseConnection.getConnection(DatabaseConnection.java:213)
>                 at sqlline.Commands.close(Commands.java:925)
>                 at sqlline.Commands.closeall(Commands.java:899)
>                 at sqlline.SqlLine.begin(SqlLine.java:649)
>                 at sqlline.SqlLine.start(SqlLine.java:375)
>                 at sqlline.SqlLine.main(SqlLine.java:268)
> {noformat}
> To fix this issue we should not rely on Maven nearest win strategy and define 
> allowed freemarker version under {{dependencyManagement}}.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to