[jira] [Commented] (OOZIE-2845) Replace reflection-based code which sets variable in HiveConf

2017-04-03 Thread Abhishek Bafna (JIRA)

[ 
https://issues.apache.org/jira/browse/OOZIE-2845?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15953654#comment-15953654
 ] 

Abhishek Bafna commented on OOZIE-2845:
---

+1. Committed to master. Thanks [~pbacsko] for the patch.

> Replace reflection-based code which sets variable in HiveConf
> -
>
> Key: OOZIE-2845
> URL: https://issues.apache.org/jira/browse/OOZIE-2845
> Project: Oozie
>  Issue Type: Improvement
>  Components: core
>Reporter: Peter Bacsko
>Assignee: Peter Bacsko
> Fix For: 5.0.0
>
> Attachments: OOZIE-2845-001.patch, OOZIE-2845-002.patch
>
>
> In different places, we use the following reflection-based code to reset a 
> variable inside {{HiveConf.java}}
> {code}
> public static void resetHiveConfStaticVariables() throws Exception {
> // HiveConf initializes location of hive-site.xml in static block.
> // So this is needed so that tests like TestHiveMain that create 
> hive-site.xml don't fail.
> Field declaredField = HiveConf.class.getDeclaredField("hiveSiteURL");
> declaredField.setAccessible(true);
> declaredField.set(null, 
> HiveConf.class.getClassLoader().getResource("hive-site.xml"));
> }
> {code}
> Note that HiveConf has supported setting {{hiveSiteURL}} for a long time. 
> Even version 0.13.0 has the static setter method:
> https://github.com/apache/hive/blob/branch-0.13/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java#L1493-L1495
> Therefore reflection-based solution should be modified.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (OOZIE-2845) Replace reflection-based code which sets variable in HiveConf

2017-04-03 Thread Peter Bacsko (JIRA)

[ 
https://issues.apache.org/jira/browse/OOZIE-2845?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15953450#comment-15953450
 ] 

Peter Bacsko commented on OOZIE-2845:
-

ping [~abhishekbafna]

> Replace reflection-based code which sets variable in HiveConf
> -
>
> Key: OOZIE-2845
> URL: https://issues.apache.org/jira/browse/OOZIE-2845
> Project: Oozie
>  Issue Type: Improvement
>  Components: core
>Reporter: Peter Bacsko
>Assignee: Peter Bacsko
> Attachments: OOZIE-2845-001.patch, OOZIE-2845-002.patch
>
>
> In different places, we use the following reflection-based code to reset a 
> variable inside {{HiveConf.java}}
> {code}
> public static void resetHiveConfStaticVariables() throws Exception {
> // HiveConf initializes location of hive-site.xml in static block.
> // So this is needed so that tests like TestHiveMain that create 
> hive-site.xml don't fail.
> Field declaredField = HiveConf.class.getDeclaredField("hiveSiteURL");
> declaredField.setAccessible(true);
> declaredField.set(null, 
> HiveConf.class.getClassLoader().getResource("hive-site.xml"));
> }
> {code}
> Note that HiveConf has supported setting {{hiveSiteURL}} for a long time. 
> Even version 0.13.0 has the static setter method:
> https://github.com/apache/hive/blob/branch-0.13/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java#L1493-L1495
> Therefore reflection-based solution should be modified.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (OOZIE-2845) Replace reflection-based code which sets variable in HiveConf

2017-03-31 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/OOZIE-2845?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15950726#comment-15950726
 ] 

Hadoop QA commented on OOZIE-2845:
--

Testing JIRA OOZIE-2845

Cleaning local git workspace



{color:green}+1 PATCH_APPLIES{color}
{color:green}+1 CLEAN{color}
{color:green}+1 RAW_PATCH_ANALYSIS{color}
.{color:green}+1{color} the patch does not introduce any @author tags
.{color:green}+1{color} the patch does not introduce any tabs
.{color:green}+1{color} the patch does not introduce any trailing spaces
.{color:green}+1{color} the patch does not introduce any line longer than 
132
.{color:green}+1{color} the patch does adds/modifies 1 testcase(s)
{color:green}+1 RAT{color}
.{color:green}+1{color} the patch does not seem to introduce new RAT 
warnings
{color:green}+1 JAVADOC{color}
.{color:green}+1{color} the patch does not seem to introduce new Javadoc 
warnings
{color:green}+1 COMPILE{color}
.{color:green}+1{color} HEAD compiles
.{color:green}+1{color} patch compiles
.{color:green}+1{color} the patch does not seem to introduce new javac 
warnings
{color:green}+1{color} There are no new bugs found in total.
. {color:green}+1{color} There are no new bugs found in [server].
. {color:green}+1{color} There are no new bugs found in [client].
. {color:green}+1{color} There are no new bugs found in [core].
. {color:green}+1{color} There are no new bugs found in [docs].
. {color:green}+1{color} There are no new bugs found in 
[hadooplibs/hadoop-utils-2].
. {color:green}+1{color} There are no new bugs found in [tools].
. {color:green}+1{color} There are no new bugs found in [examples].
. {color:green}+1{color} There are no new bugs found in [sharelib/streaming].
. {color:green}+1{color} There are no new bugs found in [sharelib/sqoop].
. {color:green}+1{color} There are no new bugs found in [sharelib/distcp].
. {color:green}+1{color} There are no new bugs found in [sharelib/oozie].
. {color:green}+1{color} There are no new bugs found in [sharelib/hcatalog].
. {color:green}+1{color} There are no new bugs found in [sharelib/hive].
. {color:green}+1{color} There are no new bugs found in [sharelib/hive2].
. {color:green}+1{color} There are no new bugs found in [sharelib/pig].
. {color:green}+1{color} There are no new bugs found in [sharelib/spark].
{color:green}+1 BACKWARDS_COMPATIBILITY{color}
.{color:green}+1{color} the patch does not change any JPA 
Entity/Colum/Basic/Lob/Transient annotations
.{color:green}+1{color} the patch does not modify JPA files
{color:green}+1 TESTS{color}
.Tests run: 1906
.Tests rerun: 15
.Tests failed at first run: org.apache.oozie.jms.TestJMSJobEventListener,
{color:green}+1 DISTRO{color}
.{color:green}+1{color} distro tarball builds with the patch 


{color:green}*+1 Overall result, good!, no -1s*{color}


The full output of the test-patch run is available at

. https://builds.apache.org/job/oozie-trunk-precommit-build/3757/

> Replace reflection-based code which sets variable in HiveConf
> -
>
> Key: OOZIE-2845
> URL: https://issues.apache.org/jira/browse/OOZIE-2845
> Project: Oozie
>  Issue Type: Improvement
>  Components: core
>Reporter: Peter Bacsko
>Assignee: Peter Bacsko
> Attachments: OOZIE-2845-001.patch, OOZIE-2845-002.patch
>
>
> In different places, we use the following reflection-based code to reset a 
> variable inside {{HiveConf.java}}
> {code}
> public static void resetHiveConfStaticVariables() throws Exception {
> // HiveConf initializes location of hive-site.xml in static block.
> // So this is needed so that tests like TestHiveMain that create 
> hive-site.xml don't fail.
> Field declaredField = HiveConf.class.getDeclaredField("hiveSiteURL");
> declaredField.setAccessible(true);
> declaredField.set(null, 
> HiveConf.class.getClassLoader().getResource("hive-site.xml"));
> }
> {code}
> Note that HiveConf has supported setting {{hiveSiteURL}} for a long time. 
> Even version 0.13.0 has the static setter method:
> https://github.com/apache/hive/blob/branch-0.13/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java#L1493-L1495
> Therefore reflection-based solution should be modified.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (OOZIE-2845) Replace reflection-based code which sets variable in HiveConf

2017-03-29 Thread Abhishek Bafna (JIRA)

[ 
https://issues.apache.org/jira/browse/OOZIE-2845?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15947154#comment-15947154
 ] 

Abhishek Bafna commented on OOZIE-2845:
---

[~pbacsko] I think 
{{HiveConf.setHiveSiteLocation(null);}}  
should be  
{{HiveConf.setHiveSiteLocation(HiveConf.class.getClassLoader().getResource("hive-site.xml"));}}

Because, we set the {{hiveSiteURL}} to the available {{hive-site.xml}} in the 
classpath.

Did we test this, on actual cluster? If not, we should I guess.

Thanks.

> Replace reflection-based code which sets variable in HiveConf
> -
>
> Key: OOZIE-2845
> URL: https://issues.apache.org/jira/browse/OOZIE-2845
> Project: Oozie
>  Issue Type: Improvement
>  Components: core
>Reporter: Peter Bacsko
>Assignee: Peter Bacsko
> Attachments: OOZIE-2845-001.patch
>
>
> In different places, we use the following reflection-based code to reset a 
> variable inside {{HiveConf.java}}
> {code}
> public static void resetHiveConfStaticVariables() throws Exception {
> // HiveConf initializes location of hive-site.xml in static block.
> // So this is needed so that tests like TestHiveMain that create 
> hive-site.xml don't fail.
> Field declaredField = HiveConf.class.getDeclaredField("hiveSiteURL");
> declaredField.setAccessible(true);
> declaredField.set(null, 
> HiveConf.class.getClassLoader().getResource("hive-site.xml"));
> }
> {code}
> Note that HiveConf has supported setting {{hiveSiteURL}} for a long time. 
> Even version 0.13.0 has the static setter method:
> https://github.com/apache/hive/blob/branch-0.13/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java#L1493-L1495
> Therefore reflection-based solution should be modified.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (OOZIE-2845) Replace reflection-based code which sets variable in HiveConf

2017-03-29 Thread Peter Bacsko (JIRA)

[ 
https://issues.apache.org/jira/browse/OOZIE-2845?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15947168#comment-15947168
 ] 

Peter Bacsko commented on OOZIE-2845:
-

Bah, that's right. I misread the original implementation. I though "null" 
refers to the value itself, but no, that's just the object instance.

I'll update the patch soon.

> Replace reflection-based code which sets variable in HiveConf
> -
>
> Key: OOZIE-2845
> URL: https://issues.apache.org/jira/browse/OOZIE-2845
> Project: Oozie
>  Issue Type: Improvement
>  Components: core
>Reporter: Peter Bacsko
>Assignee: Peter Bacsko
> Attachments: OOZIE-2845-001.patch
>
>
> In different places, we use the following reflection-based code to reset a 
> variable inside {{HiveConf.java}}
> {code}
> public static void resetHiveConfStaticVariables() throws Exception {
> // HiveConf initializes location of hive-site.xml in static block.
> // So this is needed so that tests like TestHiveMain that create 
> hive-site.xml don't fail.
> Field declaredField = HiveConf.class.getDeclaredField("hiveSiteURL");
> declaredField.setAccessible(true);
> declaredField.set(null, 
> HiveConf.class.getClassLoader().getResource("hive-site.xml"));
> }
> {code}
> Note that HiveConf has supported setting {{hiveSiteURL}} for a long time. 
> Even version 0.13.0 has the static setter method:
> https://github.com/apache/hive/blob/branch-0.13/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java#L1493-L1495
> Therefore reflection-based solution should be modified.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (OOZIE-2845) Replace reflection-based code which sets variable in HiveConf

2017-03-29 Thread Peter Bacsko (JIRA)

[ 
https://issues.apache.org/jira/browse/OOZIE-2845?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15946800#comment-15946800
 ] 

Peter Bacsko commented on OOZIE-2845:
-

[~abhishekbafna] [~gezapeti] please verify the patch.

> Replace reflection-based code which sets variable in HiveConf
> -
>
> Key: OOZIE-2845
> URL: https://issues.apache.org/jira/browse/OOZIE-2845
> Project: Oozie
>  Issue Type: Improvement
>  Components: core
>Reporter: Peter Bacsko
>Assignee: Peter Bacsko
> Attachments: OOZIE-2845-001.patch
>
>
> In different places, we use the following reflection-based code to reset a 
> variable inside {{HiveConf.java}}
> {code}
> public static void resetHiveConfStaticVariables() throws Exception {
> // HiveConf initializes location of hive-site.xml in static block.
> // So this is needed so that tests like TestHiveMain that create 
> hive-site.xml don't fail.
> Field declaredField = HiveConf.class.getDeclaredField("hiveSiteURL");
> declaredField.setAccessible(true);
> declaredField.set(null, 
> HiveConf.class.getClassLoader().getResource("hive-site.xml"));
> }
> {code}
> Note that HiveConf has supported setting {{hiveSiteURL}} for a long time. 
> Even version 0.13.0 has the static setter method:
> https://github.com/apache/hive/blob/branch-0.13/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java#L1493-L1495
> Therefore reflection-based solution should be modified.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (OOZIE-2845) Replace reflection-based code which sets variable in HiveConf

2017-03-29 Thread Peter Bacsko (JIRA)

[ 
https://issues.apache.org/jira/browse/OOZIE-2845?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15946797#comment-15946797
 ] 

Peter Bacsko commented on OOZIE-2845:
-

{{-1 TESTS - patch does not compile, cannot run testcases}}

Looking at the build, this is not the case, everything is passed, but there 
were problems during findbugs diff:

{code}
[TRACE] Downloading FindBugs diff JAR from 
https://repo1.maven.org/maven2/me/andrz/findbugs/findbugs-diff/0.1.0/findbugs-diff-0.1.0-all.jar
[TRACE] FindBugs diff JAR downloaded
grep: 
/home/jenkins/jenkins-slave/workspace/oozie-trunk-precommit-build/bin/findbugs-diff-0.1.0-all.jar.md5sum:
 No such file or directory
[TRACE] FindBugs diff JAR checked, is safe to use
[TRACE] Performing FindBugs diffs
bin/test-patch-11-findbugs-diff: line 253: : No such file or directory
bin/test-patch-11-findbugs-diff: line 255: [: -le: unary operator expected
Exception in thread "main" groovy.lang.GroovyRuntimeException: Ambiguous method 
overloading for method java.io.File#.
Cannot resolve which method to invoke for [null] due to overlapping prototypes 
between:
[class java.lang.String]
[class java.net.URI]
at 
groovy.lang.MetaClassImpl.chooseMostSpecificParams(MetaClassImpl.java:3202)
at 
groovy.lang.MetaClassImpl.chooseMethodInternal(MetaClassImpl.java:3154)
at groovy.lang.MetaClassImpl.chooseMethod(MetaClassImpl.java:3097)
at 
groovy.lang.MetaClassImpl.createConstructorSite(MetaClassImpl.java:3384)
at 
org.codehaus.groovy.runtime.callsite.CallSiteArray.createCallConstructorSite(CallSiteArray.java:88)
at 
org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallConstructor(CallSiteArray.java:57)
at 
org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:182)
at 
org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:190)
at 
me.andrz.findbugs.diff.FindBugsDiff.diffFromFilePaths(FindBugsDiff.groovy:33)
at me.andrz.findbugs.diff.FindBugsDiff$diffFromFilePaths.call(Unknown 
Source)
...
{code}

[~andras.piros] please take a look at this.

> Replace reflection-based code which sets variable in HiveConf
> -
>
> Key: OOZIE-2845
> URL: https://issues.apache.org/jira/browse/OOZIE-2845
> Project: Oozie
>  Issue Type: Improvement
>  Components: core
>Reporter: Peter Bacsko
>Assignee: Peter Bacsko
> Attachments: OOZIE-2845-001.patch
>
>
> In different places, we use the following reflection-based code to reset a 
> variable inside {{HiveConf.java}}
> {code}
> public static void resetHiveConfStaticVariables() throws Exception {
> // HiveConf initializes location of hive-site.xml in static block.
> // So this is needed so that tests like TestHiveMain that create 
> hive-site.xml don't fail.
> Field declaredField = HiveConf.class.getDeclaredField("hiveSiteURL");
> declaredField.setAccessible(true);
> declaredField.set(null, 
> HiveConf.class.getClassLoader().getResource("hive-site.xml"));
> }
> {code}
> Note that HiveConf has supported setting {{hiveSiteURL}} for a long time. 
> Even version 0.13.0 has the static setter method:
> https://github.com/apache/hive/blob/branch-0.13/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java#L1493-L1495
> Therefore reflection-based solution should be modified.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (OOZIE-2845) Replace reflection-based code which sets variable in HiveConf

2017-03-28 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/OOZIE-2845?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15946302#comment-15946302
 ] 

Hadoop QA commented on OOZIE-2845:
--

Testing JIRA OOZIE-2845

Cleaning local git workspace



{color:green}+1 PATCH_APPLIES{color}
{color:green}+1 CLEAN{color}
{color:green}+1 RAW_PATCH_ANALYSIS{color}
.{color:green}+1{color} the patch does not introduce any @author tags
.{color:green}+1{color} the patch does not introduce any tabs
.{color:green}+1{color} the patch does not introduce any trailing spaces
.{color:green}+1{color} the patch does not introduce any line longer than 
132
.{color:green}+1{color} the patch does adds/modifies 1 testcase(s)
{color:green}+1 RAT{color}
.{color:green}+1{color} the patch does not seem to introduce new RAT 
warnings
{color:green}+1 JAVADOC{color}
.{color:green}+1{color} the patch does not seem to introduce new Javadoc 
warnings
{color:green}+1 COMPILE{color}
.{color:green}+1{color} HEAD compiles
.{color:green}+1{color} patch compiles
.{color:green}+1{color} the patch does not seem to introduce new javac 
warnings
{color:red}-1{color} There are [333] new bugs found below threshold in total 
that must be fixed.
. {color:green}+1{color} There are no new bugs found in [client].
. {color:green}+1{color} There are no new bugs found in [sharelib/hive].
. {color:green}+1{color} There are no new bugs found in [sharelib/sqoop].
. {color:green}+1{color} There are no new bugs found in [sharelib/spark].
. {color:green}+1{color} There are no new bugs found in [sharelib/streaming].
. {color:green}+1{color} There are no new bugs found in [sharelib/hive2].
. {color:green}+1{color} There are no new bugs found in [sharelib/oozie].
. {color:green}+1{color} There are no new bugs found in [sharelib/hcatalog].
. {color:green}+1{color} There are no new bugs found in [sharelib/pig].
. {color:green}+1{color} There are no new bugs found in [sharelib/distcp].
. {color:green}+1{color} There are no new bugs found in [docs].
. {color:red}-1{color} There are [327] new bugs found below threshold in 
[server] that must be fixed, listing only the first [5] ones.
. You can find the FindBugs diff here (look for the red and orange ones): 
server/findbugs-new.html
. The top [5] most important FindBugs errors are:
. At BinaryBlob.java:[line 68]: org.apache.oozie.BinaryBlob.getBytes() may 
expose internal representation by returning BinaryBlob.bytes
. org.apache.oozie.BinaryBlob.getRawBlob() may expose internal representation 
by returning BinaryBlob.rawBlob: Another occurrence at BinaryBlob.java:[line 88]
. Another occurrence at BinaryBlob.java:[line 116]: At BinaryBlob.java:[line 99]
. At BinaryBlob.java:[line 43]: new org.apache.oozie.BinaryBlob(byte[], 
boolean) may expose internal representation by storing an externally mutable 
object into BinaryBlob.bytes
. At BinaryBlob.java:[line 47]: new org.apache.oozie.BinaryBlob(byte[], 
boolean) may expose internal representation by storing an externally mutable 
object into BinaryBlob.rawBlob
. {color:green}+1{color} There are no new bugs found in [core].
. {color:red}-1{color} There are [6] new bugs found below threshold in 
[hadooplibs/hadoop-utils-2] that must be fixed, listing only the first [5] ones.
. You can find the FindBugs diff here (look for the red and orange ones): 
hadooplibs/hadoop-utils-2/findbugs-new.html
. The top [5] most important FindBugs errors are:
. At DateList.java:[line 55]: Nullcheck of date at line 55 of value previously 
dereferenced in org.apache.oozie.example.DateList.main(String[])
. Private method org.apache.oozie.example.DateList.formatDateUTC(Calendar) is 
never called: Redundant null check at DateList.java:[line 62]
. org.apache.oozie.example.LocalOozieExample.execute(String[]) may fail to 
clean up java.io.InputStream: At DateList.java:[line 97]
. Path continues at LocalOozieExample.java:[line 76]: Obligation to clean up 
resource created at LocalOozieExample.java:[line 72] is not discharged
. Path continues at LocalOozieExample.java:[line 78]: Path continues at 
LocalOozieExample.java:[line 77]
{color:green}+1 BACKWARDS_COMPATIBILITY{color}
.{color:green}+1{color} the patch does not change any JPA 
Entity/Colum/Basic/Lob/Transient annotations
.{color:green}+1{color} the patch does not modify JPA files
{color:red}-1 TESTS{color} - patch does not compile, cannot run testcases
{color:green}+1 DISTRO{color}
.{color:green}+1{color} distro tarball builds with the patch 


{color:red}*-1 Overall result, please check the reported -1(s)*{color}


The full output of the test-patch run is available at

. https://builds.apache.org/job/oozie-trunk-precommit-build/3746/

> Replace reflection-based code which sets variable in HiveConf
> -
>
> Key: OOZIE-2845
> 

[jira] [Commented] (OOZIE-2845) Replace reflection-based code which sets variable in HiveConf

2017-03-28 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/OOZIE-2845?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15945621#comment-15945621
 ] 

Hadoop QA commented on OOZIE-2845:
--

Testing JIRA OOZIE-2845

Cleaning local git workspace



{color:green}+1 PATCH_APPLIES{color}
{color:green}+1 CLEAN{color}
{color:green}+1 RAW_PATCH_ANALYSIS{color}
.{color:green}+1{color} the patch does not introduce any @author tags
.{color:green}+1{color} the patch does not introduce any tabs
.{color:green}+1{color} the patch does not introduce any trailing spaces
.{color:green}+1{color} the patch does not introduce any line longer than 
132
.{color:green}+1{color} the patch does adds/modifies 1 testcase(s)
{color:green}+1 RAT{color}
.{color:green}+1{color} the patch does not seem to introduce new RAT 
warnings
{color:green}+1 JAVADOC{color}
.{color:green}+1{color} the patch does not seem to introduce new Javadoc 
warnings
{color:green}+1 COMPILE{color}
.{color:green}+1{color} HEAD compiles
.{color:green}+1{color} patch compiles
.{color:green}+1{color} the patch does not seem to introduce new javac 
warnings
{color:green}+1{color} There are no new bugs found in total.
. {color:green}+1{color} There are no new bugs found in [core].
. {color:green}+1{color} There are no new bugs found in [server].
. {color:green}+1{color} There are no new bugs found in [client].
. {color:green}+1{color} There are no new bugs found in [docs].
. {color:green}+1{color} There are no new bugs found in [examples].
. {color:green}+1{color} There are no new bugs found in [sharelib/hive].
. {color:green}+1{color} There are no new bugs found in [sharelib/pig].
. {color:green}+1{color} There are no new bugs found in [sharelib/distcp].
. {color:green}+1{color} There are no new bugs found in [sharelib/streaming].
. {color:green}+1{color} There are no new bugs found in [sharelib/spark].
. {color:green}+1{color} There are no new bugs found in [sharelib/hcatalog].
. {color:green}+1{color} There are no new bugs found in [sharelib/sqoop].
. {color:green}+1{color} There are no new bugs found in [sharelib/hive2].
. {color:green}+1{color} There are no new bugs found in [sharelib/oozie].
. {color:green}+1{color} There are no new bugs found in [tools].
. {color:green}+1{color} There are no new bugs found in 
[hadooplibs/hadoop-utils-2].
{color:green}+1 BACKWARDS_COMPATIBILITY{color}
.{color:green}+1{color} the patch does not change any JPA 
Entity/Colum/Basic/Lob/Transient annotations
.{color:green}+1{color} the patch does not modify JPA files
{color:red}-1 TESTS{color} - patch does not compile, cannot run testcases
{color:green}+1 DISTRO{color}
.{color:green}+1{color} distro tarball builds with the patch 


{color:red}*-1 Overall result, please check the reported -1(s)*{color}


The full output of the test-patch run is available at

. https://builds.apache.org/job/oozie-trunk-precommit-build/3742/

> Replace reflection-based code which sets variable in HiveConf
> -
>
> Key: OOZIE-2845
> URL: https://issues.apache.org/jira/browse/OOZIE-2845
> Project: Oozie
>  Issue Type: Improvement
>  Components: core
>Reporter: Peter Bacsko
>Assignee: Peter Bacsko
> Attachments: OOZIE-2845-001.patch
>
>
> In different places, we use the following reflection-based code to reset a 
> variable inside {{HiveConf.java}}
> {code}
> public static void resetHiveConfStaticVariables() throws Exception {
> // HiveConf initializes location of hive-site.xml in static block.
> // So this is needed so that tests like TestHiveMain that create 
> hive-site.xml don't fail.
> Field declaredField = HiveConf.class.getDeclaredField("hiveSiteURL");
> declaredField.setAccessible(true);
> declaredField.set(null, 
> HiveConf.class.getClassLoader().getResource("hive-site.xml"));
> }
> {code}
> Note that HiveConf has supported setting {{hiveSiteURL}} for a long time. 
> Even version 0.13.0 has the static setter method:
> https://github.com/apache/hive/blob/branch-0.13/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java#L1493-L1495
> Therefore reflection-based solution should be modified.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (OOZIE-2845) Replace reflection-based code which sets variable in HiveConf

2017-03-25 Thread Andras Piros (JIRA)

[ 
https://issues.apache.org/jira/browse/OOZIE-2845?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15941862#comment-15941862
 ] 

Andras Piros commented on OOZIE-2845:
-

+1 on the idea [~pbacsko]! We really should resort to reflection in case all 
other means are exhausted.

> Replace reflection-based code which sets variable in HiveConf
> -
>
> Key: OOZIE-2845
> URL: https://issues.apache.org/jira/browse/OOZIE-2845
> Project: Oozie
>  Issue Type: Improvement
>  Components: core
>Reporter: Peter Bacsko
>Assignee: Peter Bacsko
>
> In different places, we use the following reflection-based code to reset a 
> variable inside {{HiveConf.java}}
> {code}
> public static void resetHiveConfStaticVariables() throws Exception {
> // HiveConf initializes location of hive-site.xml in static block.
> // So this is needed so that tests like TestHiveMain that create 
> hive-site.xml don't fail.
> Field declaredField = HiveConf.class.getDeclaredField("hiveSiteURL");
> declaredField.setAccessible(true);
> declaredField.set(null, 
> HiveConf.class.getClassLoader().getResource("hive-site.xml"));
> }
> {code}
> Note that HiveConf has supported setting {{hiveSiteURL}} for a long time. 
> Even version 0.13.0 has the static setter method:
> https://github.com/apache/hive/blob/branch-0.13/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java#L1493-L1495
> Therefore reflection-based solution should be modified.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)