spark-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sean R. Owen (Jira)" <j...@apache.org>
Subject [jira] [Commented] (SPARK-22000) org.codehaus.commons.compiler.CompileException: toString method is not declared
Date Mon, 28 Oct 2019 15:39:00 GMT

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

Sean R. Owen commented on SPARK-22000:
--------------------------------------

As indicated, it's fixed in 3.0, not 2.4.x. The change is substantial so is hard to back-port,
but I'd review a change that includes the three linked PRs above in 2.4, if it can be made
to work.

> org.codehaus.commons.compiler.CompileException: toString method is not declared
> -------------------------------------------------------------------------------
>
>                 Key: SPARK-22000
>                 URL: https://issues.apache.org/jira/browse/SPARK-22000
>             Project: Spark
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 2.2.0
>            Reporter: taiho choi
>            Assignee: Jungtaek Lim
>            Priority: Major
>             Fix For: 3.0.0
>
>         Attachments: testcase.zip
>
>
> the error message say that toString is not declared on "value13" which is "long" type
in generated code.
> i think value13 should be Long type.
> ==error message
> Caused by: org.codehaus.commons.compiler.CompileException: File 'generated.java', Line
70, Column 32: failed to compile: org.codehaus.commons.compiler.CompileException: File 'generated.java',
Line 70, Column 32: A method named "toString" is not declared in any enclosing class nor any
supertype, nor through a static import
> /* 033 */   private void apply1_2(InternalRow i) {
> /* 034 */
> /* 035 */
> /* 036 */     boolean isNull11 = i.isNullAt(1);
> /* 037 */     UTF8String value11 = isNull11 ? null : (i.getUTF8String(1));
> /* 038 */     boolean isNull10 = true;
> /* 039 */     java.lang.String value10 = null;
> /* 040 */     if (!isNull11) {
> /* 041 */
> /* 042 */       isNull10 = false;
> /* 043 */       if (!isNull10) {
> /* 044 */
> /* 045 */         Object funcResult4 = null;
> /* 046 */         funcResult4 = value11.toString();
> /* 047 */
> /* 048 */         if (funcResult4 != null) {
> /* 049 */           value10 = (java.lang.String) funcResult4;
> /* 050 */         } else {
> /* 051 */           isNull10 = true;
> /* 052 */         }
> /* 053 */
> /* 054 */
> /* 055 */       }
> /* 056 */     }
> /* 057 */     javaBean.setApp(value10);
> /* 058 */
> /* 059 */
> /* 060 */     boolean isNull13 = i.isNullAt(12);
> /* 061 */     long value13 = isNull13 ? -1L : (i.getLong(12));
> /* 062 */     boolean isNull12 = true;
> /* 063 */     java.lang.String value12 = null;
> /* 064 */     if (!isNull13) {
> /* 065 */
> /* 066 */       isNull12 = false;
> /* 067 */       if (!isNull12) {
> /* 068 */
> /* 069 */         Object funcResult5 = null;
> /* 070 */         funcResult5 = value13.toString();
> /* 071 */
> /* 072 */         if (funcResult5 != null) {
> /* 073 */           value12 = (java.lang.String) funcResult5;
> /* 074 */         } else {
> /* 075 */           isNull12 = true;
> /* 076 */         }
> /* 077 */
> /* 078 */
> /* 079 */       }
> /* 080 */     }
> /* 081 */     javaBean.setReasonCode(value12);
> /* 082 */
> /* 083 */   }



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org


Mime
View raw message