Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    BatchUpload internal class cast exception ClassCastException LocaleMessage String

    Hello Isomorphic,

    I'm getting an error when using BatchUploader. Could you have a look at this seemingly internal class cast error (I'm using v10.1p_2016-02-09).

    This is the server log, important rows in bold:
    Code:
    === 2016-02-15 12:25:50,367 [ec-9] DEBUG RPCManager - Processing 1 requests.
    === 2016-02-15 12:25:50,367 [ec-9] DEBUG RPCManager - Request #1 (RPCRequest) data: {
        appID:"isc_builtin",
        className:"com.isomorphic.tools.BuiltinRPC",
        methodName:"setAttributes",
        arguments:[
            "session",
            [
                {
                    name:"dsName",
                    type:"hidden",
                    value:"V_LEADUPLOAD"
                },
                {
                    name:"delimiter",
                    type:"hidden",
                    value:";"
                },
                {
                    name:"quoteString",
                    type:"hidden",
                    value:"\""
                },
                {
                    name:"dataFormat",
                    type:"hidden",
                    value:"csv"
                }
            ],
            null
        ],
        is_ISC_RPC_DMI:true
    }
    === 2016-02-15 12:25:50,367 [ec-9] INFO  LMSIDACall - Performing 1 operation(s)
    === 2016-02-15 12:25:50,367 [ec-5] DEBUG RPCManager - Processing 1 requests.
    === 2016-02-15 12:25:50,368 [ec-5] DEBUG RPCManager - Request #1 (DSRequest) payload: {
        criteria:{
        },
        values:{
            file:"leadupload.xlsx",
            dsName:"V_LEADUPLOAD",
            delimiter:";",
            quoteString:"\"",
            dataFormat:"csv",
            _transaction:null
        },
        operationConfig:{
            dataSource:"batchUpload",
            repo:null,
            operationType:"update",
            textMatchStyle:"exact"
        },
        componentId:"isc_DynamicForm_0",
        appID:"builtinApplication",
        operation:"upload",
        oldValues:{
            dsName:"V_LEADUPLOAD",
            delimiter:";",
            quoteString:"\"",
            dataFormat:"csv",
            file:null
        }
    }
    === 2016-02-15 12:25:50,368 [ec-5] INFO  LMSIDACall - Performing 1 operation(s)
    === 2016-02-15 12:25:50,368 [ec-9] DEBUG RPCDMI - appConfig: isc.Application.create({
        rpcBindings:[
            {
                ID:"builtin",
                className:"com.isomorphic.rpc.BuiltinRPC",
                visibleMethods:[
                    {
                        name:"downloadWSDL"
                    },
                    {
                        name:"downloadClientContent"
                    },
                    {
                        name:"downloadClientExport"
                    },
                    {
                        name:"xmlToJS"
                    },
                    {
                        name:"uploadProgressCheck"
                    },
                    {
                        name:"saveFile"
                    },
                    {
                        name:"appendToFile"
                    },
                    {
                        name:"loadFile"
                    },
                    {
                        name:"deleteFile"
                    },
                    {
                        name:"loadSharedXML"
                    },
                    {
                        name:"saveSharedXML"
                    },
                    {
                        name:"getAvailableScriptEngines"
                    },
                    {
                        name:"devConsoleEvalServerScript"
                    },
                    {
                        name:"evalJava"
                    },
                    {
                        name:"getLogNames"
                    },
                    {
                        name:"getLogEntries"
                    },
                    {
                        name:"clearLogEntries"
                    },
                    {
                        name:"getLogThresholds"
                    },
                    {
                        name:"setLogThreshold"
                    },
                    {
                        name:"setTemporaryLogThreshold"
                    },
                    {
                        name:"revertTemporaryLogThresholds"
                    },
                    {
                        name:"getPdfObject"
                    },
                    {
                        name:"exportImage"
                    },
                    {
                        name:"areServerTimingsTracked"
                    },
                    {
                        name:"trackServerTimings"
                    },
                    {
                        name:"messagingSend"
                    },
                    {
                        name:"downloadZip"
                    }
                ]
            },
            {
                ID:"builtin_tools",
                className:"com.isomorphic.tools.BuiltinRPC",
                visibleMethods:[
                    {
                        name:"getDataSourceFromTable"
                    },
                    {
                        name:"getDataSourceJSONFromTable"
                    },
                    {
                        name:"getDataSourceFromHibernateMapping"
                    },
                    {
                        name:"getDataSourceJSONFromHibernateMapping"
                    },
                    {
                        name:"getTables"
                    },
                    {
                        name:"getFieldsFromTable"
                    },
                    {
                        name:"getBeanFields"
                    },
                    {
                        name:"getHibernateBeans"
                    },
                    {
                        name:"getDatabaseProductNameAndVersion"
                    },
                    {
                        name:"getDatabaseTableTypes"
                    },
                    {
                        name:"setAttributes"
                    },
                    {
                        name:"clearAttributes"
                    },
                    {
                        name:"getAttributes"
                    },
                    {
                        name:"getAttribute"
                    },
                    {
                        name:"getDataSourceConfigFromJavaClass"
                    },
                    {
                        args:"cName",
                        language:"groovy",
                        name:"getJavaSource",
                        script:"\n                    if (!com.isomorphic.auth.DevModeAuthFilter.devModeAuthorized(request)) throw new Exception(\"Not Authorized\");                    \n                    //import org.apache.bcel.Repository;\n\n                    try {\n                        return org.apache.bcel.Repository.lookupClass(cName).toString();\n                    } catch (Throwable e) {\n                        return \"Unable to reverse engineer class \"+cName+\": \"+e.getMessage();\n                    }\n                "
                    },
                    {
                        name:"loadDataSource"
                    },
                    {
                        name:"dsFromXML"
                    },
                    {
                        name:"dsConfigFromXML"
                    },
                    {
                        name:"getDefinedDataSources"
                    },
                    {
                        name:"importData"
                    },
                    {
                        name:"checkForTestData"
                    }
                ]
            },
            {
                ID:"builtin_adminconsole",
                className:"com.isomorphic.tools.AdminConsole",
                visibleMethods:[
                    {
                        name:"getDefinedDatabases"
                    },
                    {
                        name:"testDB"
                    },
                    {
                        name:"saveDBConfig"
                    },
                    {
                        name:"setDefaultDB"
                    },
                    {
                        name:"importDataSources"
                    },
                    {
                        name:"discoverJNDIDatabases"
                    }
                ]
            }
        ]
    })
    
    === 2016-02-15 12:25:50,370 [ec-9] DEBUG RPCDMI - rpc returned data
    === 2016-02-15 12:25:50,370 [ec-9] DEBUG RPCManager - Content type for RPC transaction: text/plain; charset=UTF-8
    === 2016-02-15 12:25:50,370 [ec-9] INFO  Compression - /lms/lms/sc/IDACall: 67 -> 73 bytes
    === 2016-02-15 12:25:50,372 [ec-5] DEBUG AppBase - [builtinApplication.null] No userTypes defined, allowing anyone access to all operations for this application
    === 2016-02-15 12:25:50,372 [ec-5] DEBUG AppBase - [builtinApplication.null] No public zero-argument method named '_null' found, performing generic datasource operation
    === 2016-02-15 12:25:50,372 [ec-5] INFO  SQLDataSource - [builtinApplication.null] Performing fetch operation with
        criteria: {TENANT_ID:4}    values: {TENANT_ID:4}
    === 2016-02-15 12:25:50,373 [ec-5] INFO  SQLDataSource - [builtinApplication.null] derived query: SELECT $defaultSelectClause FROM $defaultTableClause$defaultAnsiJoinClause WHERE $defaultWhereClause
    === 2016-02-15 12:25:50,374 [ec-5] INFO  SQLDataSource - [builtinApplication.null] 271: Executing SQL query on 'Oracle': SELECT T_SETTINGS_LEADIMPORT.ID, T_SETTINGS_LEADIMPORT.TENANT_ID, T_SETTINGS_LEADIMPORT.CREATED_BY, T_SETTINGS_LEADIMPORT.CREATED_AT, T_SETTINGS_LEADIMPORT.MODIFIED_BY, T_SETTINGS_LEADIMPORT.MODIFIED_AT, T_SETTINGS_LEADIMPORT.DSXMLFIELDNAME, T_SETTINGS_LEADIMPORT.CSVFIELDNAME, USER_CREATED_BY.FULLNAME_INITIALS_GIVENNAME AS CREATED_BY_NAME, USER_CREATED_BY.FULLNAME_LEGALENTITYNAME AS CREATED_BY_NAME_TOOLTIP, USER_MODIFIED_BY.FULLNAME_INITIALS_GIVENNAME AS MODIFIED_BY_NAME, USER_MODIFIED_BY.FULLNAME_LEGALENTITYNAME AS MODIFIED_BY_NAME_TOOLTIP FROM T_SETTINGS_LEADIMPORT JOIN MV_USER_DATA USER_CREATED_BY ON T_SETTINGS_LEADIMPORT.CREATED_BY = USER_CREATED_BY.ID JOIN MV_USER_DATA USER_MODIFIED_BY ON T_SETTINGS_LEADIMPORT.MODIFIED_BY = USER_MODIFIED_BY.ID WHERE (T_SETTINGS_LEADIMPORT.TENANT_ID=4)
    === 2016-02-15 12:25:50,375 [ec-5] DEBUG SQLConnectionManager - [builtinApplication.null] Borrowed connection '1220387926'
    === 2016-02-15 12:25:50,375 [ec-5] INFO  SQLDriver - [builtinApplication.null] Executing SQL query on 'Oracle' using connection '1220387926': SELECT T_SETTINGS_LEADIMPORT.ID, T_SETTINGS_LEADIMPORT.TENANT_ID, T_SETTINGS_LEADIMPORT.CREATED_BY, T_SETTINGS_LEADIMPORT.CREATED_AT, T_SETTINGS_LEADIMPORT.MODIFIED_BY, T_SETTINGS_LEADIMPORT.MODIFIED_AT, T_SETTINGS_LEADIMPORT.DSXMLFIELDNAME, T_SETTINGS_LEADIMPORT.CSVFIELDNAME, USER_CREATED_BY.FULLNAME_INITIALS_GIVENNAME AS CREATED_BY_NAME, USER_CREATED_BY.FULLNAME_LEGALENTITYNAME AS CREATED_BY_NAME_TOOLTIP, USER_MODIFIED_BY.FULLNAME_INITIALS_GIVENNAME AS MODIFIED_BY_NAME, USER_MODIFIED_BY.FULLNAME_LEGALENTITYNAME AS MODIFIED_BY_NAME_TOOLTIP FROM T_SETTINGS_LEADIMPORT JOIN MV_USER_DATA USER_CREATED_BY ON T_SETTINGS_LEADIMPORT.CREATED_BY = USER_CREATED_BY.ID JOIN MV_USER_DATA USER_MODIFIED_BY ON T_SETTINGS_LEADIMPORT.MODIFIED_BY = USER_MODIFIED_BY.ID WHERE (T_SETTINGS_LEADIMPORT.TENANT_ID=4)
    === 2016-02-15 12:25:50,376 [ec-5] INFO  DSResponse - DSResponse: List with 0 items
    === 2016-02-15 12:25:50,376 [ec-5] DEBUG SQLDriver - Freeing SQLDriver dbConnection 1220387926 for SQLDriver instance 95539480
    === 2016-02-15 12:25:50,376 [ec-5] DEBUG SQLConnectionManager - About to close connection with hashcode "1220387926"
    === 2016-02-15 12:25:50,415 [ec-5] DEBUG DataSourceDMI - Invocation threw exception
    [B]java.lang.ClassCastException: com.isomorphic.util.LocaleMessage cannot be cast to java.lang.String
        at com.isomorphic.tools.BatchUpload.internalBatchUpload(BatchUpload.java:118)
        at com.isomorphic.tools.BatchUpload.batchUpload(BatchUpload.java:88)[/B]
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at com.isomorphic.base.Reflection.adaptArgsAndInvoke(Reflection.java:964)
        at com.isomorphic.datasource.DataSourceDMI.execute(DataSourceDMI.java:416)
        at com.isomorphic.datasource.DataSourceDMI.execute(DataSourceDMI.java:64)
        at com.isomorphic.datasource.DSRequest.execute(DSRequest.java:2689)
        at com.isomorphic.servlet.IDACall.handleDSRequest(IDACall.java:228)
        at com.lmscompany.lms.server.LMSIDACall.handleDSRequest(LMSIDACall.java:87)
        at com.isomorphic.servlet.IDACall.processRPCTransaction(IDACall.java:187)
        at com.lmscompany.lms.server.LMSIDACall.processRequest(LMSIDACall.java:43)
        at com.isomorphic.servlet.IDACall._processRequest(IDACall.java:119)
        at com.isomorphic.servlet.IDACall.doPost(IDACall.java:79)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:648)
        at com.isomorphic.servlet.BaseServlet.service(BaseServlet.java:162)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:291)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at com.isomorphic.servlet.CompressionFilter._doFilter(CompressionFilter.java:260)
        at com.isomorphic.servlet.BaseFilter.doFilter(BaseFilter.java:88)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:212)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:106)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:614)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:141)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
        at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:616)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:521)
        at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1096)
        at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:674)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1500)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1456)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
        at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Unknown Source)
    [B]=== 2016-02-15 12:25:50,415 [ec-5] WARN  RequestContext - dsRequest.execute() failed:
    java.lang.ClassCastException: com.isomorphic.util.LocaleMessage cannot be cast to java.lang.String
        at com.isomorphic.tools.BatchUpload.internalBatchUpload(BatchUpload.java:118)
        at com.isomorphic.tools.BatchUpload.batchUpload(BatchUpload.java:88)[/B]
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at com.isomorphic.base.Reflection.adaptArgsAndInvoke(Reflection.java:964)
        at com.isomorphic.datasource.DataSourceDMI.execute(DataSourceDMI.java:416)
        at com.isomorphic.datasource.DataSourceDMI.execute(DataSourceDMI.java:64)
        at com.isomorphic.datasource.DSRequest.execute(DSRequest.java:2689)
        at com.isomorphic.servlet.IDACall.handleDSRequest(IDACall.java:228)
        at com.lmscompany.lms.server.LMSIDACall.handleDSRequest(LMSIDACall.java:87)
        at com.isomorphic.servlet.IDACall.processRPCTransaction(IDACall.java:187)
        at com.lmscompany.lms.server.LMSIDACall.processRequest(LMSIDACall.java:43)
        at com.isomorphic.servlet.IDACall._processRequest(IDACall.java:119)
        at com.isomorphic.servlet.IDACall.doPost(IDACall.java:79)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:648)
        at com.isomorphic.servlet.BaseServlet.service(BaseServlet.java:162)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:291)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at com.isomorphic.servlet.CompressionFilter._doFilter(CompressionFilter.java:260)
        at com.isomorphic.servlet.BaseFilter.doFilter(BaseFilter.java:88)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:212)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:106)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:614)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:141)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
        at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:616)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:521)
        at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1096)
        at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:674)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1500)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1456)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
        at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Unknown Source)
    === 2016-02-15 12:25:50,416 [ec-5] DEBUG RPCManager - Content type for RPC transaction: text/html; charset=UTF-8
    === 2016-02-15 12:25:50,416 [ec-5] DEBUG RPCManager - non-DMI response, dropExtraFields: false
    === 2016-02-15 12:25:50,416 [ec-5] INFO  Compression - /lms/lms/sc/IDACall: 712 -> 448 bytes
    [B][/B]


    If you say that it is no error on your side, I'll have to dig here what changed since the last working test, but I strongly assume that there is a framework bug - even if the online sample is working.

    This is an important one for me.

    Thank you & Best regards
    Blama

    #2
    Thanks for the notification. We have someone assigned to take a look. We'll follow up when we have more information for you

    Regards
    Isomorphic Software

    Comment


      #3
      This is fixed now and will be available in nightly builds since Feb 17 (tomorrow). Please let us know how it worked for you.

      Comment


        #4
        Hi Isomorphic,

        great, thank you. I'll test it and let you now.

        Best regards
        Blama

        Comment


          #5
          Hi Isomorphic,

          could you backport this one to 5.0p? I wanted to use 5.0p for a test, but this one is blocking me.

          Thank you & Best regards
          Blama

          Comment


            #6
            Hi Isomorphic,

            Originally posted by Isomorphic View Post
            This is fixed now and will be available in nightly builds since Feb 17 (tomorrow). Please let us know how it worked for you.
            sorry for not answering. Yes, your change did solve the problem for me.

            Thank you,
            Blama

            Comment


              #7
              This is fixed now in 5.0 as well. Available for download in nightly since Feb 23 (tomorrow).

              Comment


                #8
                Hi Isomorphic,

                great, thank you.

                Best regards
                Blama

                Comment

                Working...
                X