Announcement

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

    Doubts Evaluating SmartClient

    Hi,

    I am evaluating SmartClient for business application development through the SmartClient 8.2 Full-Featured Evaluation. I have some doubts:

    Is it easy to connect SmartClient Datasources to database through IBM Wesphere DataSources?

    In a previous question you indicated that iBatis is a much weaker than the technology built-in SQLDataSource and its SQL Templating engine. Please, why iBatis is weaker? What's your opinion of hibernate vs the built-in SQLDataSource and its SQL Templating engine?

    We haven't been able to connect to our Oracle database using the Admin Console of the Evaluation version. We finnally did it modifying the server properties file by hand. Do you have documentation about how to use de Admin Console?

    Thanks,
    Anna

    #2
    IBM WebSphere DataSources appear to be accessible via just normal JNDI. See the AdminConsole docs.

    iBatis is much weaker than SQLDataSource because it has no support for generating default queries based on criteria, sort direction, paging parameters, includeFrom, etc, all of which are built into SQLDataSource. Instead you have to hand-create all queries.

    This is just the start of the many reasons why SQLDataSource is preferred over both iBatis and over our Hibernate and JPA DataSources. For a fuller explanation, see the QuickStart Guide.

    See also the QuickStart Guide so that you are aware of where all the documentation is.

    Comment


      #3
      Doubts Evaluating SmartClient

      I'm evaluating SmartClient 8.2 too.
      I use taglib <isomorphic> run in Tomcat and works fine, but the same app doesn't works at Websphere 7. It returns at exception:

      Error 500: javax.servlet.jsp.JspException: java.lang.NullPointerException at com.isomorphic.taglib.LoadTag.getIsomorphicURI(LoadTag.java:114) at com.isomorphic.taglib.LoadISCTag.doStartTag(LoadISCTag.java:54) at com.ibm._jsp._principal._jspx_meth_isomorphic_loadISC_0(_principal.java:251) at com.ibm._jsp._principal._jspService(_principal.java:103) at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:98) at javax.servlet.http.HttpServlet.service(HttpServlet.java:831) at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1443) at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:790) at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:443) at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:175) at com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(GenericServletWrapper.java:121) at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionServletWrapper.handleRequest(AbstractJSPExtensionServletWrapper.java:234) at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionProcessor.handleRequest(AbstractJSPExtensionProcessor.java:335) at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3610) at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:274) at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:926) at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1557) at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:173) at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:455) at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:384) at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:83) at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165) at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217) at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161) at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:202) at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:766) at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:896) at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1527)

      Thanks in advance,

      Comment


        #4
        This would generally indicate that you forgot to install the Init servlet. This servlet must be installed or the rest of the system will not function - see Deploying SmartClient for more information on installation steps.

        Comment


          #5
          I defined in my web.xml:
          <servlet>
          <servlet-name>Init</servlet-name>
          <servlet-class>com.isomorphic.base.Init</servlet-class>
          <load-on-startup>1</load-on-startup>
          </servlet>

          Is it right?
          Why does it work in Tomcat but it doesn't in Websphere?

          Comment


            #6
            That looks correct, but the way to tell is to look at your server-side log. At startup you should see several messages indicating that SmartClient is initializing. If you need more help, post your complete server log (from startup).

            Comment


              #7
              My was server log (SystemOut.log) shows:
              [19/10/12 12:42:44:880 CEST] 0000002f CompositionUn A WSVR0190I: Iniciando unidad de composición WebSphere:cuname=Historico20121219_war en BLA WebSphere:blaname=Historico20121219_war.
              [19/10/12 12:42:50:823 CEST] 0000002f ApplicationMg A WSVR0200I: Se inicia la aplicación: Historico20121219_war
              [19/10/12 12:42:50:823 CEST] 0000002f ApplicationMg A WSVR0204I: Aplicación: Historico20121219_war Nivel de build de aplicación: Desconocido
              [19/10/12 12:42:55:238 CEST] 0000002f webapp I com.ibm.ws.webcontainer.webapp.WebGroupImpl WebGroup SRVE0169I: Cargando módulo Web: Historico.
              [19/10/12 12:42:55:254 CEST] 0000002f WASSessionCor I SessionContextRegistry getSessionContext SESN0176I: Se creará un nuevo contexto de sesión para la clave de aplicación default_host/Historico
              [19/10/12 12:42:55:316 CEST] 0000002f SystemOut O ISC: Configuring log4j from: file:/E:/IBM/Websphere/profiles/AppSrv01/installedApps/SRVINTCONNode01Cell/Historico20121219_war.ear/Historico20121219.war/WEB-INF/classes/log4j.isc.config.xml
              [19/10/12 12:42:55:410 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,410 [ : 4] INFO ISCInit - Isomorphic SmartClient Framework - Initializing
              [19/10/12 12:42:55:425 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,425 [ : 4] INFO ConfigLoader - Attempting to load framework.properties from CLASSPATH
              [19/10/12 12:42:55:535 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,535 [ : 4] INFO ConfigLoader - Successfully loaded framework.properties from CLASSPATH at location: file:/E:/IBM/Websphere/profiles/AppSrv01/installedApps/SRVINTCONNode01Cell/References/configuration/framework.properties
              [19/10/12 12:42:55:550 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,550 [ : 4] INFO ConfigLoader - Attempting to load project.properties from CLASSPATH
              [19/10/12 12:42:55:550 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,550 [ : 4] INFO ConfigLoader - Unable to locate project.properties in CLASSPATH
              [19/10/12 12:42:55:581 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,581 [ : 4] INFO ConfigLoader - Successfully loaded isc_interfaces.properties from CLASSPATH at location: wsjar:file:/E:/Historico/librerias/isomorphic_core_rpc.jar!/isc_interfaces.properties
              [19/10/12 12:42:55:581 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,581 [ : 4] INFO ConfigLoader - Attempting to load server.properties from CLASSPATH
              [19/10/12 12:42:55:597 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,597 [ : 4] INFO ConfigLoader - Successfully loaded server.properties from CLASSPATH at location: file:/E:/IBM/Websphere/profiles/AppSrv01/installedApps/SRVINTCONNode01Cell/Historico20121219_war.ear/Historico20121219.war/WEB-INF/classes/server.properties
              [19/10/12 12:42:55:597 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,597 [ : 4] INFO Logger - Logging system started.
              [19/10/12 12:42:55:597 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,597 [ : 4] INFO ISCInit - Isomorphic SmartClient Framework (null null) - Initialization Complete
              [19/10/12 12:42:55:597 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,597 [ : 4] ERROR ISCInit - Can't find marker file for webRoot: E:/IBM/Websphere/profiles/AppSrv01/installedApps/SRVINTCONNode01Cell/Historico20121219_war.ear/Historico20121219.war/null for configured/autodetected webRoot - if you moved the 'isomorphic' directory, please set isomorphicPathRootRelative in server.properties to the new location and restart the servlet engine.
              [19/10/12 12:42:55:597 CEST] 0000002f SystemOut O === 2012-10-19 12:42:55,597 [ : 4] INFO ISCInit - WebRoot auto-detection failed - using container IO
              [19/10/12 12:42:55:597 CEST] 0000002f servlet I com.ibm.ws.webcontainer.servlet.ServletWrapper init SRVE0242I: [Historico20121219_war] [/Historico] [Init]: Inicialización satisfactoria.
              [19/10/12 12:42:55:628 CEST] 0000002f webcontainer I com.ibm.ws.wswebcontainer.VirtualHost addWebApplication SRVE0250I: El módulo Web Historico se ha enlazado con default_host[*:9080,*:80,*:9443,*:5060,*:5061,*:443].
              [19/10/12 12:42:55:644 CEST] 0000002f ApplicationMg A WSVR0221I: Aplicación iniciada: Historico20121219_war
              [19/10/12 12:42:55:644 CEST] 0000002f CompositionUn A WSVR0191I: La unidad de composición WebSphere:cuname=Historico20121219_war en BLA WebSphere:blaname=Historico20121219_war se ha iniciado.
              [19/10/12 12:43:03:506 CEST] 0000004e servlet I com.ibm.ws.webcontainer.servlet.ServletWrapper init SRVE0242I: [Historico20121219_war] [/Historico] [/jsp/principal.jsp]: Inicialización satisfactoria.
              [19/10/12 12:43:03:865 CEST] 0000003f servlet I com.ibm.ws.webcontainer.servlet.ServletWrapper init SRVE0242I: [Historico20121219_war] [/Historico] [/jsp/albaranes/albBusqueda.jsp]: Inicialización satisfactoria.
              [19/10/12 12:43:03:881 CEST] 0000003f SystemOut O === 2012-10-19 12:43:03,881 [ : 8] DEBUG LoadISCTag - isomorphicURI not specified in tag, defaulting to: null
              [19/10/12 12:43:03:881 CEST] 0000003f SystemOut O === 2012-10-19 12:43:03,881 [ : 8] ERROR LoadISCTag - caught exception sending fileLoader
              java.lang.NullPointerException
              at com.isomorphic.taglib.LoadTag.getIsomorphicURI(LoadTag.java:114)
              at com.isomorphic.taglib.LoadTag.init(LoadTag.java:188)
              at com.isomorphic.taglib.LoadISCTag.doStartTag(LoadISCTag.java:50)
              at com.ibm._jsp._albBusqueda._jspx_meth_isomorphic_loadISC_0(_albBusqueda.java:115)
              at com.ibm._jsp._albBusqueda._jspService(_albBusqueda.java:84)
              at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:98)
              at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
              at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1443)
              at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:790)
              at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:443)
              at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:175)
              at com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(GenericServletWrapper.java:121)
              at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionServletWrapper.handleRequest(AbstractJSPExtensionServletWrapper.java:234)
              at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionProcessor.handleRequest(AbstractJSPExtensionProcessor.java:335)
              at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3610)
              at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:274)
              at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:926)
              at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1557)
              at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:173)
              at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:455)
              at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:384)
              at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:83)
              at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
              at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
              at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
              at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138)
              at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:202)
              at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:766)
              at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:896)
              at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1527)
              [19/10/12 12:43:03:881 CEST] 0000003f SystemOut O === 2012-10-19 12:43:03,881 [ : 8] DEBUG LoadISCTag - isomorphicURI not specified in tag, defaulting to: null
              [19/10/12 12:43:03:881 CEST] 0000003f SystemOut O === 2012-10-19 12:43:03,881 [ : 8] ERROR LoadISCTag - Exception while attempting to process a loadISC tag.
              java.lang.NullPointerException


              Although, my tomcat works fine and shows:

              ISC: Configuring log4j from: file:/F:/desarrollo/HistoricoSmartClient/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/Historico/WEB-INF/classes/log4j.isc.config.xml
              === 2012-10-19 12:52:56,932 [main] INFO ISCInit - Isomorphic SmartClient Framework - Initializing
              === 2012-10-19 12:52:56,940 [main] INFO ConfigLoader - Attempting to load framework.properties from CLASSPATH
              === 2012-10-19 12:52:56,991 [main] INFO ConfigLoader - Successfully loaded framework.properties from CLASSPATH at location: jar:file:/F:/desarrollo/HistoricoSmartClient/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/Historico/WEB-INF/lib/isomorphic_core_rpc.jar!/framework.properties
              === 2012-10-19 12:52:56,992 [main] INFO ConfigLoader - Attempting to load project.properties from CLASSPATH
              === 2012-10-19 12:52:56,992 [main] INFO ConfigLoader - Unable to locate project.properties in CLASSPATH
              === 2012-10-19 12:52:56,995 [main] INFO ConfigLoader - Successfully loaded isc_interfaces.properties from CLASSPATH at location: jar:file:/F:/desarrollo/HistoricoSmartClient/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/Historico/WEB-INF/lib/isomorphic_core_rpc.jar!/isc_interfaces.properties
              === 2012-10-19 12:52:56,995 [main] INFO ConfigLoader - Attempting to load server.properties from CLASSPATH
              === 2012-10-19 12:52:57,000 [main] INFO ConfigLoader - Successfully loaded server.properties from CLASSPATH at location: file:/F:/desarrollo/HistoricoSmartClient/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/Historico/WEB-INF/classes/server.properties
              === 2012-10-19 12:52:57,007 [main] INFO Logger - Logging system started.
              === 2012-10-19 12:52:57,007 [main] INFO ISCInit - Isomorphic SmartClient Framework (8.2/SDK Development Only 2011-12-05) - Initialization Complete
              === 2012-10-19 12:52:57,008 [main] INFO ISCInit - Auto-detected webRoot - using: F:\desarrollo\HistoricoSmartClient\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\Historico

              Sorry, my server are configured with spanish language.

              Can you help me?

              Thanks in advace,

              Comment


                #8
                Beside not to ignore ERROR messages in the logs. In this case there is a log telling you that there is a problem and what to do about it - webroot auto detection is failing in your environment, so you must set it in server.properties.

                Comment


                  #9
                  I realized some proofs, the result is equal. I read (server.properties) some containers refuse to provide the webRoot path. I set webRoot: __USE_CONTAINER__ .
                  My Isomorphic dir is webroot.
                  Can I set anything?

                  Thanks,

                  Comment


                    #10
                    Set webroot to the actual filesystem path of webroot, and not to _USE_CONTAINER_ (which means to autodetect).

                    Comment


                      #11
                      Another question

                      I found my problem. My server JVM had a wrong settings.

                      Now, I have another question. Does SmartClient Sql Datasource work with Pl/sql whose return is an Oracle Object Type?

                      Thanks in advance,

                      Comment

                      Working...
                      X