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

Hari Sankar Sivarama Subramaniyan commented on HIVE-10684:
----------------------------------------------------------

[~Ferd] Is it possible to do whatever you have done as part of 
target/generate_session_jars.sh mentioned in ql/pom.xml using maven 
components/plugins itself. This would be the most desirable way to avoid any 
portability issues. Also, I currently don't see the need to put the script in 
generate-sources id since the generate_session_jars.sh does not actually 
generate any scripts from any template but rather move it from one location to 
another.

The most effective way to work around portability issue would be to do 
something like what I have mentioned below, if at all possible.
For example, you can do something similar to  this in ql/pom.xml (I have not 
tested the below thing, but it should give you a start) :
{code}
<project>
  ...
  <build>
    <plugins>
      ...
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>RefreshedJarClassV1</artifactId>
        <configuration>
          <outputDirectory>${basedir}/target</outputDirectory>
        <includes>**/*RefreshedJarClassV1.class</includes>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>RefreshedJarClassV2</artifactId>
        <configuration>
          <outputDirectory>${basedir}/target</outputDirectory>
        <includes>**/*RefreshedJarClassV2.class</includes>
        </configuration>
      </plugin>
      ...
    </plugins>
  </build>
  ...
</project>
{code}

In the worst case, if maven plugins does not provide you the option to do what 
you need and you don't bother about having this change on any non-linux 
platforms, you need to add profile for all the platform dependent exec code in 
pom.xml, so that the end-user can prevent these scripts from running if needed 
(by providing a -D or -P option) . You can take a look at HIVE-10477 to see how 
this is done.

[~sushanth] what do you think about my feedback.

Thanks

> Fix the unit test failures for HIVE-7553 after HIVE-10674 removed the binary 
> jar files
> --------------------------------------------------------------------------------------
>
>                 Key: HIVE-10684
>                 URL: https://issues.apache.org/jira/browse/HIVE-10684
>             Project: Hive
>          Issue Type: Bug
>          Components: Tests
>            Reporter: Ferdinand Xu
>            Assignee: Ferdinand Xu
>         Attachments: HIVE-10684.patch
>
>




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to