`

SmartClient開發環境搭建

 
阅读更多


This overview serves as a how-to for installing SmartClient into your web application. Evaluators are urged to use the SmartClient SDK with the embedded tomcat servlet engine during evaluation rather than pursue installation into an existing web application up front, however, reading this document and the related materials is recommended to get an overview.

SmartClient has two pieces - the client components that run in the browser and the server components that run in a J2SE compatible container. You don't need to use a Java back-end to use SmartClient, but the SDK comes with some examples that assume the presence of the Java back-end and, for some examples, a SQL Database. If you will be using SmartClient with a Java back-end, see below for the list of J2SE application servers supported by the Java implementation of the SmartClient server.

The SDK contains two top-level directories: smartclientSDK and smartclientRuntime. The smartclientSDK directory contains the embedded servlet engine, embedded database, examples, and documentation. The smartclientRuntime directory contains just the client and server components of the SmartClient product - use the contents of this directory when deploying SmartClient into your application environment.

Client integration

To install the client-side portion of SmartClient, simply copy the isomorphic directory from the smartclientRuntime webroot to the webroot of your application. Having done this you can use SmartClient components on your pages regardless of the technologies used on your back-end and you can bind to server-side componentry backed by arbitrary technology - see the Data Integration section of the Client-Server Integration section for more information.

Server integration

SmartClient can be integrated with any backend without installing the SmartClient Java server. However, the SmartClient server accelerates Java integration and provides other useful facilities, including server-push and network performance enhancements. See the SmartClient Server summary for details.

To integrate the server portion of SmartClient, you need to follow the steps below for each application (WAR) that uses SmartClient. Note that, if installing into an environment that uses multiple WARs, installation of SmartClient JARs into a directory shared by multiple applications is not supported. Installation of a separate WAR with client-side SmartClient modules for maintaining cache coherence across applications using the same version of ISC is supported - contact Isomorphic support for more details on how to set that up.

Note: Some of the instructions below ask you to copy files into the WEB-INF/classes folder. If you're using an IDE such as Eclipse that attempts to manage the WEB-INF/classes folder, we recommend that you copy these files to the src/ directory of your project (next to the top-level folder for your java namespace) such that your IDE auto-deploys them to the WEB-INF/classes folder. We have seen cases of tools like Eclipse periodically deleting files that are checked into to WEB-INF/classes directly.

 

  • Copy all files from the WEB-INF/lib directory of the smartclientRuntime to your WEB-INF/lib. SmartClient leverages a number of third-party libraries - if there are conflicts with the versions you want to use, use the versions you want - SmartClient has minimal dependencies on these libraries. Contact Isomorphic with any specific questions about compatibility. See the "Java Module Dependencies" section below for a dependency tree that will help you select a minimal set of JARs to deploy.
  • Copy the WEB-INF/classes/log4j.isc.config.xml from the smartclientRuntime to your WEB-INF/classes directory. This file contains the SmartClient server log configuration.
  • Copy the WEB-INF/classes/server.properties from the smartclientRuntime to your WEB-INF/classes directory. This file contains settings for basic file locations such the location of webroot, the SmartClient SQL engine and DMI. The version under smartclientRuntime has a basic, secure configuration. See the version of server.properties under the smartclientSDK directory for sample SQL and other settings.
  • Copy the WEB-INF/iscTaglib.xml from the smartclientRuntime to your WEB-INF directory. This file enables the use of custom SmartClient tags in your JSPs.
  • Merge portions of the WEB-INF/web.xml into your application's web.xml. To use SmartClient JSP tags like <loadISC>, you'll need to merge the <jsp-config> section from web.xml. Also there are some mandatory and optional servlets and filters to merge - see below.
  • Power and Enterprise Editions only. Copy the shared/ds/batchUpload.ds.xml file to the same location in your target webapp directory. This file is a utility DataSource that is used to provide the initial upload functionality of the BatchUploader component - strictly speaking, you only need to perform this step if you intend to use that component.

See Core and Optional SmartClient servlets for details of additional changes you may need to make to your applications web.xml file. See Java Module Dependencies for details of the .JAR files that comprise the SmartClient Server, and their dependencies on various third-party libraries.

Troubleshooting

This section covers some common problems with possible solutions. You may also need to refer to the documentation for your specific application server, web server, or database. If you experience any problems installing and configuring SmartClient in your environment, please post on the SmartClient forums for assistance.

 

Problem Possible Causes Solution
Browser displays a generic "page cannot be displayed" or "unable to locate the server" message. Servlet engine not started. Start your application server.
Missing/incorrect port for servlet engine in URL. Check the startup messages, logs, or documentation for the servlet engine to determine what port it is using.
Host name is incorrect. Check whether other pages on the host can be accessed. Try the base URL http://[host name]:[port number] to see whether the servlet engine or webserver is functioning.
Browser displays a 404 or other page/file not found error. Incorrect URL. Check for errors in the URL, including capitalization.
Server error: taglib not defined Missing iscTaglib.xml or iscTaglib.xml not referenced in web.xml Copy WEB-INF/iscTaglib.xml from smartclientRuntime to your deployment WEB-INF directory and make sure that you have merged the <jsp-config> section from the smartclientRuntime web.xml
ClassNotFound or other Java Exceptions in the server log. Missing JAR files Verify every .jar from the smartclientRuntime WEB-INF/lib directory has been copied to your deployment WEB-INF/lib. Although you might later be able to remove some .jars, for initial installation testing, copy every .jar
"isc" is not defined JS error Incorrect URLs to SmartClient modules Use View Source to look at SCRIPT includes (e.g. for ISC_Core.js), try those URLs directly in the browser to verify the files are correctly deployed

 

Caching Considerations

When upgrading from one SmartClient release to the next, you want to make sure that the user picks up the new version on next access, but you also want to keep the ISC modules cacheable so they're not refetched on every access.

SmartClient deals with this problem by appending a version string as a query parameter to each module load directive. This is done by the <isomorphic:loadISC> and <isomorphic:loadModules> tags automatically. As long as you make sure that the file that contains these tags is non-cacheable, you will get the desired behavior.

 

分享到:
评论

相关推荐

    Smart Client系列课程(1):智能客户端开发概览(PPT QA)

    1. **开发环境搭建**:介绍如何设置开发环境,包括安装必要的SDK、IDE和其他开发工具。 2. **架构设计**:讲解如何设计适应Smart Client模式的软件架构,确保应用程序既能在本地高效运行,又能与远程服务器通信。 3....

    SmartClient_Quick_Start_Guide

    - **定义**: SmartClient 是由 Isomorphic Software 开发的一款基于 Java 的客户端应用开发平台。 - **功能**: 允许开发者创建高性能且高度交互性的 Web 应用程序。 - **特点**: - 高性能: 利用 AJAX 技术实现快速...

    部署智能客户端应用程序_PPT

    - **开发环境搭建**:选择合适的开发工具,如Visual Studio,安装必要的SDK和库。 - **设计与实现**:设计用户界面和业务逻辑,编写代码实现功能。 - **本地资源管理**:处理本地数据存储,如数据库或文件系统,确保...

    NET书籍介绍

    智能客户端(Smart Client)技术是.NET框架中的一个重要概念,它强调在离线和在线环境中提供丰富的用户体验。相关课程如“Smart Client系列课程(1):智能客户端开发概览”探讨了如何构建这些功能强大的应用程序。 ...

    SVN server/client

    一些开发环境(如Eclipse、IntelliJ IDEA)也集成了SVN插件。 2. **版本库克隆**:客户端通过URL连接到服务器,下载版本库的副本,即“检出”(Checkout)。这样,用户就可以在本地工作而不影响其他人。 3. **文件...

    Linux嵌入式系统的上层应用开发研究.pdf

    - **台式机开发阶段**:使用台式机上的X Window系统作为开发环境,此时X Server由台式机自带的X Window充当。 - **嵌入式平台开发阶段**:在实际部署到嵌入式平台之前,X Server由Microwindows等轻量级解决方案替代...

    微软电子商务应用解决方案模板.doc

    客户端服务使用Microsoft .NET作为一个端到端应用平台,提供了丰富的界面技术,包括浏览器及智能客户端(Smart Client),各种移动终端设备界面的支持。电子交易服务使用Commerce Serve提供了B2C和B2B交易服务平台,...

    Professional Visual Basic 2010 and .NET 4

    - **开发环境**: SharePoint 2010的开发环境搭建。 - **应用开发**: 如何在SharePoint平台上开发应用程序。 #### 五、库与专业主题(Libraries and Specialized Topics) - **Visual Studio Tools for Office** ...

    smart-brain-full:将在Heroku上部署的智能脑学习项目的组合仓库(CRA + Node)

    它预配置了开发环境,包括Webpack、Babel等,让你可以立即开始编写React组件而无需关心构建配置。CRA支持热模块替换,自动刷新,以及生产环境优化,如代码分割、tree-shaking和最小化,以确保应用性能和加载速度。 ...

    Htdemo-Chi-src

    1. **环境搭建**:确保你的开发环境中已经安装了所有必要的依赖,包括海康SDK的库文件和开发工具。 2. **代码阅读**:逐个分析源代码文件,理解每个函数和模块的作用,以及它们如何协同工作。 3. **编译调试**:...

    SQL Mobile 2005的Replication和RDA开发入门

    - 开发环境会自动检测SQL Mobile是否已经正确安装。 #### 三、RDA介绍 RDA是一种轻量级的数据同步解决方案,主要用于移动设备与服务器之间的数据交互。它不需要对SQL Server进行复杂的配置,支持通过HTTP协议进行...

    SVN安装包.zip

    常见的SVN客户端有TortoiseSVN、SmartSVN和CollabNet Subversion Client等。这些客户端提供了图形化的用户界面,使得版本控制操作直观易用。在安装客户端时,确保它与服务端版本兼容,同时设置好正确的服务器地址和...

    mqtt+springBoot+redis消息处理,

    Spring Boot提供了一种快速启动和配置Spring框架的方式,使得开发人员可以快速搭建稳定且功能完善的服务器。在本项目中,Spring Boot作为后端服务器,处理MQTT消息的接收、存储和转发,同时可能还包含了设备认证、...

    基于微信小程序的开题报告.docx

    【基于微信小程序的电商交易平台的设计与实现】 选题的来源及意义: 微信小程序电商交易平台的兴起源于电子商务行业...通过深入研究和开发,有望在竞争激烈的电商市场中脱颖而出,为商家和用户提供更优质的交易环境。

Global site tag (gtag.js) - Google Analytics