系统架构所需要的技术1

系统从整体分层来看B/S架构

如果真的要完成一个系统所需要哪些技术呢?它们在整个架构中又发挥了怎样的作用呢?怎样分工协作的呢?

web.xml是配置的文件也可以说是各个层的控制流配置集中的地方。看看web.xml里面的配置文件基本上就能知道整个系统运用了哪些技术的大概。web.xml配置.

   

系统架构所需要的技术1
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
    http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">

    <!--如果不定义webAppRootKey参数,那么webAppRootKey就是缺省的"webapp.root"。但最好设置,以免项目之间的名称冲突。
        定义以后,在Web Container启动时将把ROOT的绝对路径写到系统变量里。
        然后log4j的配置文件里就可以用${ bookstore.root }来表示Web目录的绝对路径,把log文件存放于webapp中。
        此参数用于后面的“Log4jConfigListener”-->
    <!--Spring ApplicationContext配置文件的路径。可使用通配符,多个路径用逗号分隔。
        此参数用于后面的“Spring-Context loader”-->
    <context-param>
        <param-name>contextConfigLocation</param-name>
        <param-value>
            classpath:context/applicationContext.xml
        </param-value>
    </context-param>

    <!--由Sprng载入的Log4j配置文件位置-->
    <context-param>
        <param-name>log4jConfigLocation</param-name>
        <param-value>classpath:log4j.properties</param-value>
    </context-param>

    <!--Spring默认刷新Log4j配置文件的间隔,单位为millisecond-->
    <context-param>
        <param-name>log4jRefreshInterval</param-name>
        <param-value>60000</param-value>
    </context-param>

    <!--默认i18n资源文件-->

    <context-param>
        <param-name>javax.servlet.jsp.jstl.fmt.localizationContext</param-name>
        <param-value>i18n/messages</param-value>
    </context-param>

    <!--ExtremeTable 表格标签的 Properties文件-->
    <context-param>
        <param-name>extremecomponentsPreferencesLocation</param-name>
        <param-value>classpath:conf/extremetable.properties</param-value>
    </context-param>

    <!-- 由于配置这个后apusic找不到指定的i18n/messages文件,反而出错 -->
    <!--
    <context-param>
        <param-name>extremecomponentsMessagesLocation</param-name>
        <param-value>i18n/messages</param-value>
    </context-param>
    -->
    <!-- listener定义 -->
    <context-param>
        <param-name>firstListener</param-name>
        <param-value>org.springframework.web.context.ContextLoaderListener;org.springframework.web.util.Log4jConfigListener;org.springframework.web.util.IntrospectorCleanupListener</param-value>
    </context-param>

    <!--HSQLDB Listener的参数,随WebApp启动停止的Listener
        {user.home}        System.getProperty("user.home")
        {webapp.root}      servletContext.getRealPath("/")
    -->
    <!-- 暂时屏蔽hsql,转移到mssql上,hanyou 2006/6/27
    <context-param>
        <param-name>hsql.dbPath</param-name>
        <param-value>{user.home}/firstframe/db</param-value>
    </context-param>

    <context-param>
        <param-name>hsql.dbName</param-name>
        <param-value>firstframe</param-value>
    </context-param>

    <context-param>
        <param-name>hsql.port</param-name>
        <param-value>9002</param-value>
    </context-param>
    -->

    <!--famous Character Encoding filter-->
    <filter>
        <filter-name>encodingFilter</filter-name>
        <filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
        <init-param>
            <param-name>encoding</param-name>
            <param-value>UTF-8</param-value>
        </init-param>
        <init-param>
            <param-name>forceEncoding</param-name>
            <param-value>true</param-value>
        </init-param>
    </filter>
<!-- 要尊重每个人的想法,以前总以为问题的人是SB.后来慢慢才明白,能提出正确的问题是多么的不容易! -->
    <filter-mapping>
        <filter-name>encodingFilter</filter-name>
        <url-pattern>*.do</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>encodingFilter</filter-name>
        <url-pattern>/rest/*</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>encodingFilter</filter-name>
        <url-pattern>*.action</url-pattern>
    </filter-mapping>
    <!-- 中文帐号登录的问题,以前没有加转码过滤器,所以就出问题了 -->
    <filter-mapping>
        <filter-name>encodingFilter</filter-name>
        <url-pattern>/j_acegi_security_check</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>encodingFilter</filter-name>
        <url-pattern>/ImportUpload</url-pattern>
    </filter-mapping>

    <!-- Acegi安全控制 Filter 配置用FilterToBeanProxy来代理每个filter request -->
    <filter>
        <filter-name>Acegi Filter Chain Proxy</filter-name>
        <filter-class>org.acegisecurity.util.FilterToBeanProxy</filter-class>
        <init-param>
            <param-name>targetClass</param-name>
            <param-value>org.acegisecurity.util.FilterChainProxy</param-value>
        </init-param>
    </filter>

    <!--Open Session in View Filter-->
    <filter>
        <filter-name>hibernateFilter</filter-name>
        <filter-class>org.springframework.orm.hibernate3.support.OpenSessionInViewFilter</filter-class>
    </filter>

    <!--SiteMesh filter-->
    <filter>
        <filter-name>sitemeshFilter</filter-name>
        <filter-class>com.opensymphony.module.sitemesh.filter.PageFilter</filter-class>
    </filter>

    <!--Log4J filter,将Session中的UserID属性放入Log4j MDC-->
    <filter>
        <filter-name>log4jMDCUserFilter</filter-name>
        <filter-class>cn.firstsoft.firstframe.web.support.Log4JUserFilter</filter-class>
    </filter>

    <!--ExtremeTable 导出Excel和Pdf的 Filter-->
    <filter>
        <filter-name>eXtremeExport</filter-name>
        <filter-class>org.extremecomponents.table.filter.ExportFilter</filter-class>
    </filter>

    <!--消息filter, 将Session中的messages属性放入request并从session移除
        参见BaseController中的saveMessages()方法使用,用于在Redirect时保留信息-->
    <filter>
        <filter-name>messageFilter</filter-name>
        <filter-class>org.springside.core.web.MessageFilter</filter-class>
    </filter>

    <!-- webwork 展示所需 filter : start -->
    <!-- 
    <filter>
        <filter-name>ActionContextCleanUp</filter-name>
        <filter-class>com.opensymphony.webwork.dispatcher.ActionContextCleanUp</filter-class>
    </filter>

    <filter>
        <filter-name>sitemeshForFreemarker</filter-name>
        <filter-class>com.opensymphony.webwork.sitemesh.FreeMarkerPageFilter</filter-class>
    </filter>

    <filter>
        <filter-name>webwork</filter-name>
        <filter-class>com.opensymphony.webwork.dispatcher.FilterDispatcher</filter-class>
    </filter>
    -->
    <!-- webwork 展示所需 filter : end -->

    <filter-mapping>
        <filter-name>Acegi Filter Chain Proxy</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>*.do</url-pattern>
    </filter-mapping>

    <!-- 针对后来定义的servlet,都加到此过滤器中 -->
    <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>/FilemanUpload</url-pattern>
    </filter-mapping>
    <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>/KnowledgePositionServlet</url-pattern>
    </filter-mapping>
    <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>/WebsignServlet</url-pattern>
    </filter-mapping>
    <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>/ImportUpload</url-pattern>
    </filter-mapping>
    <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>/PostilUpload</url-pattern>
    </filter-mapping>
     <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>/dwr/*</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>/j_acegi_security_check</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>*.jsp</url-pattern>
    </filter-mapping>

    <!--  加上此Mapping, 让xfire也用上open session in view -->
    <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>/service/*</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>/PositionServlet</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>sitemeshFilter</filter-name>
        <url-pattern>/modules/*</url-pattern>
        <dispatcher>REQUEST</dispatcher>
        <dispatcher>FORWARD</dispatcher>
    </filter-mapping>

    <filter-mapping>
        <filter-name>log4jMDCUserFilter</filter-name>
        <url-pattern>/modules/*</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>messageFilter</filter-name>
        <url-pattern>/*</url-pattern>
        <dispatcher>REQUEST</dispatcher>
        <dispatcher>FORWARD</dispatcher>
    </filter-mapping>

    <filter-mapping>
        <filter-name>eXtremeExport</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>

    <!-- session超时自动退出filter -->
    <filter>
        <filter-name>SessionFilter</filter-name>
        <filter-class>cn.firstsoft.firstframe.web.support.SessionFilter</filter-class>
    </filter>
    <filter-mapping>
    <filter-name>SessionFilter</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>
    
    <!-- 文件下载过滤器  -->
    <filter>
        <filter-name>FileDownloadFilter</filter-name>
        <filter-class>cn.firstsoft.firstframe.web.support.FileDownloadFilter</filter-class>
    </filter>
    <filter-mapping>
        <filter-name>FileDownloadFilter</filter-name>
        <url-pattern>/modules/download/*</url-pattern>
    </filter-mapping>

    <!-- webwork 展示所需 filter mapping : start -->
    <!--  暂时不用,屏蔽,hanyou 2006/6/27
    <filter-mapping>
        <filter-name>hibernateFilter</filter-name>
        <url-pattern>*.action</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>ActionContextCleanUp</filter-name>
        <url-pattern>*.action</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>sitemeshForFreemarker</filter-name>
        <url-pattern>*.action</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>sitemeshForFreemarker</filter-name>
        <url-pattern>*.jsp</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>webwork</filter-name>
        <url-pattern>*.action</url-pattern>
    </filter-mapping>

    <filter-mapping>
        <filter-name>webwork</filter-name>
        <url-pattern>/webwork/*</url-pattern>
    </filter-mapping>
    -->
    <!-- webwork 展示所需 filter mapping : end -->

    <!--控制HSQLDB随Web App 启动停止-->
    <!-- 启动内嵌的HSQL,用于演示,是否启动由firstframe.properties中plugins.hsql=true决定 -->
    <!--
    <listener>
        <listener-class>cn.firstsoft.firstframe.web.support.HsqlListener</listener-class>
    </listener>
    -->

    <!--Spring Context loader-->
    <!--
    <listener>
        <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
    </listener>
    -->
    <!--Spring log4j Config loader-->
    <!--
    <listener>
        <listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
    </listener>
    -->
    <!--
        发布HttpSessionApplicationEvents和HttpSessionDestroyedEvent事件给spring的applicationcontext
     -->
    <listener>
        <listener-class>org.acegisecurity.ui.session.HttpSessionEventPublisher</listener-class>
    </listener>
    <!--退出登录时session 失效的方式 -->
    <listener>
        <listener-class>org.springside.modules.security.service.acegi.logout.SessionListener</listener-class>
    </listener>
    <!-- 自动清理内存垃圾的监听器 -->
    <!--
    <listener>
        <listener-class>org.springframework.web.util.IntrospectorCleanupListener</listener-class>
    </listener>
    -->
    <!-- 用户在线监听器,不适合负载均衡处理,如果需要负载均衡则需要把保存的map变成oscache -->
    <listener>
        <listener-class>cn.firstsoft.firstframe.web.support.UserOnlineListener</listener-class>
    </listener>

    <listener>
        <listener-class>cn.firstsoft.firstframe.web.support.CommonListener</listener-class>
    </listener>

    <!--Spring Dispatch Servlet,Spring MVC的入口,按servlet-name, 载入bookstore-servlet.xml-->
    <servlet>
        <servlet-name>firstframe</servlet-name>
        <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>

    <servlet-mapping>
        <servlet-name>firstframe</servlet-name>
        <url-pattern>*.do</url-pattern>
    </servlet-mapping>

    <!--XFire WebServic的入口-->
    <servlet-mapping>
        <servlet-name>firstframe</servlet-name>
        <url-pattern>/service/*</url-pattern>
    </servlet-mapping>

    <!-- FCK 所见即所得编辑器文件上传 Servlet-->
    <servlet>
        <servlet-name>Connector</servlet-name>
        <servlet-class>com.fredck.FCKeditor.connector.ConnectorServlet</servlet-class>
        <init-param>
            <param-name>baseDir</param-name>
            <param-value>/uploadfiles/</param-value>
        </init-param>
        <init-param>
            <param-name>debug</param-name>
            <param-value>false</param-value>
        </init-param>
        <load-on-startup>2</load-on-startup>
    </servlet>

    <servlet>
        <servlet-name>SimpleUploader</servlet-name>
        <servlet-class>com.fredck.FCKeditor.uploader.SimpleUploaderServlet</servlet-class>
        <init-param>
            <param-name>baseDir</param-name>
            <param-value>/uploadfiles/</param-value>
        </init-param>
        <init-param>
            <param-name>debug</param-name>
            <param-value>false</param-value>
        </init-param>
        <init-param>
            <param-name>enabled</param-name>
            <param-value>true</param-value>
        </init-param>
        <init-param>
            <param-name>AllowedExtensionsFile</param-name>
            <param-value/>
        </init-param>
        <init-param>
            <param-name>DeniedExtensionsFile</param-name>
            <param-value>php|php3|php5|phtml|asp|aspx|ascx|jsp|cfm|cfc|pl|bat|exe|dll|reg|cgi|htm|html|js|mht</param-value>
        </init-param>
        <init-param>
            <param-name>AllowedExtensionsImage</param-name>
            <param-value>jpg|gif|jpeg|png|bmp</param-value>
        </init-param>
        <init-param>
            <param-name>DeniedExtensionsImage</param-name>
            <param-value/>
        </init-param>
        <init-param>
            <param-name>AllowedExtensionsFlash</param-name>
            <param-value>swf|fla</param-value>
        </init-param>
        <init-param>
            <param-name>DeniedExtensionsFlash</param-name>
            <param-value/>
        </init-param>
        <load-on-startup>1</load-on-startup>
    </servlet>

    <servlet-mapping>
        <servlet-name>Connector</servlet-name>
        <url-pattern>/components/fck/editor/filemanager/browser/default/connectors/jsp/connector</url-pattern>
    </servlet-mapping>

    <servlet-mapping>
        <servlet-name>SimpleUploader</servlet-name>
        <url-pattern>/components/fck/editor/filemanager/upload/simpleuploader</url-pattern>
    </servlet-mapping>
    <!-- end of FCK Editor‘s 文件上传Servlet-->
    
    <!---->
        <!-- Flex阅读器配置 -->
    
    <servlet>
        <servlet-name>FlexReaderAuthServlet</servlet-name>
        <servlet-class>
            cn.firstsoft.firstframe.plugins.readextend.FlexReaderAuth
        </servlet-class>
    </servlet>
    <servlet-mapping>  
        <servlet-name>FlexReaderAuthServlet</servlet-name>  
        <url-pattern>/servlet/FlexReader</url-pattern>  
    </servlet-mapping>
    
    
    <servlet>
        <servlet-name>ReaderStreamServlet</servlet-name>
        <servlet-class>
            cn.firstsoft.firstframe.plugins.readextend.SwfStream
        </servlet-class>
    </servlet>
    <servlet-mapping>  
        <servlet-name>ReaderStreamServlet</servlet-name>  
        <url-pattern>/servlet/ReaderStream</url-pattern>  
    </servlet-mapping>
    
     <servlet>
        <servlet-name>DownloadFileServlet</servlet-name>
        <servlet-class>
            cn.firstsoft.firstframe.plugins.readextend.FlieDownloadServlet
        </servlet-class>
    </servlet>
    <servlet-mapping>  
        <servlet-name>DownloadFileServlet</servlet-name>  
        <url-pattern>/servlet/downloadFileServlet</url-pattern>  
    </servlet-mapping>
    
    <servlet>
        <servlet-name>FlexReaderOperationLog</servlet-name>
        <servlet-class>
            cn.firstsoft.firstframe.plugins.readextend.FlexOperationLog
        </servlet-class>
    </servlet>
    <servlet-mapping>  
        <servlet-name>FlexReaderOperationLog</servlet-name>  
        <url-pattern>/servlet/flexReaderOperationLog</url-pattern>  
    </servlet-mapping>
    
    <!-- Flex阅读器配置 end -->
    
    <!-- WebService start -->
    <servlet>
        <servlet-name>CXFServlet</servlet-name>
        <servlet-class>
            org.apache.cxf.transport.servlet.CXFServlet
        </servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>CXFServlet</servlet-name>
        <url-pattern>/webservices/*</url-pattern>
    </servlet-mapping>
    <!-- WebService end -->
    

    <!-- DWR Ajax, 如果没安装plugins/DWR, Tomcat会报错,但不影响运行-->
    <servlet>
        <servlet-name>dwr-invoker</servlet-name>
        <servlet-class>org.directwebremoting.servlet.DwrServlet</servlet-class>
        <init-param>
            <description></description>
            <param-name>debug</param-name>
            <param-value>false</param-value>
        </init-param>
        <init-param>
            <param-name>classes</param-name>
            <param-value>java.lang.Object</param-value>
        </init-param>
        <load-on-startup>100</load-on-startup>
    </servlet>

    <servlet-mapping>
        <servlet-name>dwr-invoker</servlet-name>
        <url-pattern>/dwr/*</url-pattern>
    </servlet-mapping>

    <servlet>
        <servlet-name>Upload</servlet-name>
        <servlet-class>cn.firstsoft.firstframe.plugins.upload.web.Upload</servlet-class>
    </servlet>
        <servlet-mapping>
        <servlet-name>Upload</servlet-name>
        <url-pattern>/upload.do</url-pattern>
    </servlet-mapping>

    <!-- Webwork 展示用,FreeMarker支持taglib的用到servlet -->
    <!-- 暂时不支持webwork,屏蔽,hanyou 2006/6/27
    <servlet>
        <servlet-name>JspSupportServlet</servlet-name>
        <servlet-class>com.opensymphony.webwork.views.JspSupportServlet</servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>
    -->

    <!--  end of dwr -->
    <!-- 我只是利用他的init方法,来初始化这个webapplationcontxt -->
    <servlet>
        <servlet-name>initBeanFactroyServlet</servlet-name>
        <servlet-class>cn.firstsoft.firstframe.web.FirstFrameBeanFactory</servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>

    <!-- DsoFramer,WebOffice用来上传在线编辑的正文 -->
    <servlet>
        <servlet-name>PostilUpload</servlet-name>
        <servlet-class>cn.firstsoft.modules.workflow.web.PostilUpload</servlet-class>
        <load-on-startup>3</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>PostilUpload</servlet-name>
        <url-pattern>/PostilUpload</url-pattern>
    </servlet-mapping>

    <!-- 在线批量导入servlet -->
    <servlet>
        <servlet-name>ImportUpload</servlet-name>
        <servlet-class>cn.firstsoft.modules.knowledge.web.ImportUpload</servlet-class>
        <init-param>
            <param-name>source_charset</param-name>
            <!-- ISO-8859-1,GBK,UTF-8多试知道 -->
            <param-value></param-value>
        </init-param>
        <init-param>
            <param-name>target_charset</param-name>
            <!-- 一般转成GBK -->
            <param-value>GBK</param-value>
        </init-param>
        <load-on-startup>3</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>ImportUpload</servlet-name>
        <url-pattern>/ImportUpload</url-pattern>
    </servlet-mapping>

    <!-- iWebSignature集成的页面签章 -->
    <servlet>
        <servlet-name>WebsignServlet</servlet-name>
        <servlet-class>cn.firstsoft.modules.workflow.web.WebsignServlet</servlet-class>
        <load-on-startup>3</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>WebsignServlet</servlet-name>
        <url-pattern>/WebsignServlet</url-pattern>
    </servlet-mapping>

    <!-- iWebOffice集成金格全文批注 -->
    <servlet>
        <servlet-name>PositionServlet</servlet-name>
        <servlet-class>cn.firstsoft.modules.workflow.web.PositionServlet</servlet-class>
        <load-on-startup>3</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>PositionServlet</servlet-name>
        <url-pattern>/PositionServlet</url-pattern>
    </servlet-mapping>

    <servlet>
        <servlet-name>KnowledgePositionServlet</servlet-name>
        <servlet-class>cn.firstsoft.modules.knowledge.web.PositionServlet</servlet-class>
        <load-on-startup>3</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>KnowledgePositionServlet</servlet-name>
        <url-pattern>/KnowledgePositionServlet</url-pattern>
    </servlet-mapping>

    <!-- 带进度条上传 -->
    <servlet>
        <servlet-name>FilemanUpload</servlet-name>
        <servlet-class>cn.firstsoft.modules.fileman.web.FilemanUploadServlet</servlet-class>
        <load-on-startup>3</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>FilemanUpload</servlet-name>
        <url-pattern>/FilemanUpload</url-pattern>
    </servlet-mapping>

    <!-- 生成验证码 -->
    <servlet>
        <servlet-name>ImageRand</servlet-name>
        <servlet-class>cn.firstsoft.firstframe.util.ImageRand</servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>ImageRand</servlet-name>
        <url-pattern>/common/image.jpg</url-pattern>
    </servlet-mapping>
    <!-- end 用来上传在线编辑的正文 -->


    <servlet>
           <servlet-name>ImageServlet</servlet-name>
           <servlet-class>net.sf.jasperreports.j2ee.servlets.ImageServlet</servlet-class>
    </servlet>
    <!-- PT056407, R111009-0403, hao_yun, 将v6.2R1中的IM集成回迁至v6.1 -->
    <servlet>
        <servlet-name>CommSettingServlet</servlet-name>
        <servlet-class>cn.firstsoft.modules.admin.web.CommSettingServlet</servlet-class>
    </servlet>

    <servlet-mapping>
        <servlet-name>ImageServlet</servlet-name>
        <url-pattern>/servlets/image</url-pattern>
    </servlet-mapping>
    <!-- PT056407, R111009-0403, hao_yun, 将v6.2R1中的IM集成回迁至v6.1 -->
    <servlet-mapping>
        <servlet-name>CommSettingServlet</servlet-name>
        <url-pattern>/admin/comm.do</url-pattern>
    </servlet-mapping>

    <servlet>
        <servlet-name>Jersey Spring REST Service</servlet-name>
        <servlet-class>com.sun.jersey.spi.spring.container.servlet.SpringServlet</servlet-class>
        <load-on-startup>10</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>Jersey Spring REST Service</servlet-name>
        <url-pattern>/rest/*</url-pattern>
    </servlet-mapping>
    <!--  RMP:R111009-0419 DMP:PT056408 2011-11-16 zhenzhen_zhang 知识中心6.2回迁 -->
    <!-- flex在线阅读器 文档转换服务器通过restful访问 通知去下载转换好的swf格式文件  用到了上面的Jersey Spring REST Service 映射-->
    <servlet-mapping>
        <servlet-name>Jersey Spring REST Service</servlet-name>
        <url-pattern>/fileconvert/*</url-pattern>
    </servlet-mapping>
    <!-- flex在线阅读器 文档转换服务器通过restful访问 通知去下载转换好的swf格式文件  end-->
    
    <servlet>
        <servlet-name>UserPinyinInitServlet</servlet-name>
        <servlet-class>com.kingdee.ecp.rest.security.web.UserPinyinInitServlet</servlet-class>
        <load-on-startup>13</load-on-startup>
    </servlet>
    <!--   RMP:R111028-0341 DMP:PT057448 dexiang_lei 门户图表 -->
    <servlet>
        <servlet-name>ChartDefinitionInitServlet</servlet-name>
        <servlet-class>org.springside.modules.security.servlet.ChartDefinitionInitServlet</servlet-class>
        <load-on-startup>13</load-on-startup>
    </servlet>
    
  <servlet>
    <servlet-name>WebSignUpload</servlet-name>
    <servlet-class>cn.firstsoft.modules.workflow.web.WebSignUpload</servlet-class>
  </servlet>
  <servlet-mapping>
    <servlet-name>WebSignUpload</servlet-name>
    <url-pattern>/WebSignUpload</url-pattern>
  </servlet-mapping>


    <!-- -->
    <filter>
        <filter-name>REST SecurityFilter</filter-name>
        <filter-class>com.kingdee.ecp.rest.security.web.SecurityFilter</filter-class>
    </filter>
    <filter-mapping>
    <filter-name>REST SecurityFilter</filter-name>
        <url-pattern>/rest/*</url-pattern>
    </filter-mapping>
     
    <mime-mapping>
        <extension>mht</extension>
        <mime-type>text/x-mht</mime-type>
    </mime-mapping>
    <mime-mapping>
        <extension>rar</extension>
        <mime-type>application/octet-stream</mime-type>
    </mime-mapping>
    <mime-mapping>
        <extension>cab</extension>
        <mime-type>application/octet-stream</mime-type>
    </mime-mapping>
    <mime-mapping>
        <extension>cab</extension>
        <mime-type>application/zip</mime-type>
    </mime-mapping>

    <!--session 超时定义,增加了动态页面刷新,设置短一点好进行统计在线用户数量-->
    <session-config>
        <session-timeout>30</session-timeout>
    </session-config>

    <!--默认首页定义-->
    <welcome-file-list>
        <welcome-file>index.jsp</welcome-file>
        <welcome-file>index.html</welcome-file>
    </welcome-file-list>

    <!-- 下面定义的数据源为迁移到其他应用服务器上的需要,主要是BEA, WEBSPERE -->
    <!-- 在kingdee apusic下要屏蔽-->
    <resource-ref>
        <res-ref-name>jdbc/DefaultDS</res-ref-name>
        <res-type>javax.sql.DataSource</res-type>
        <res-auth>Container</res-auth>
        <res-sharing-scope>Shareable</res-sharing-scope>
    </resource-ref>
    

    <!--Error Page定义-->
    <error-page>
        <error-code>500</error-code>
        <location>/errors/error.jsp</location>
    </error-page>
    <error-page>
        <error-code>404</error-code>
        <location>/errors/404.jsp</location>
    </error-page>
    <error-page>
        <error-code>403</error-code>
        <location>/errors/403.jsp</location>
    </error-page>

</web-app>
系统架构所需要的技术1

web.xml文件里面可以呈现出很多的信息。这个问题的切入点找对了吗??这个系统运用了哪些框架呢,从管理框架来讲呢感觉有两层(spring MVC,Spring)为什么我又想到了

从管理框架层来讲呢,如果不管理会怎样呢?为什么会有spring 及spring 的MVC或者struts2呢? 

spring管理了Dao层,manager 层既然是管理框架有什么好处呢(事务,对象注入,jdbc连接管理,I18N国际化配置,Hibernate、EJB配置,缓存处理,如果更麻烦系统还是事件监听、过滤、拦截等) 这里面面所涉及的东西应该是一个相对完整的系统不可缺少的。而且每一项都包含着独立领域的难点等。

spring MVC 管理了前端jsp界面Controller 用这个又有什么好处呢(安全认证、权限管理、jsp界面控制(真的系统我开始以为jsp很简单其实不然)、标签管理、I18N国际化配置)

spring MVC 及sping 可以管理一个轻量级的系统

那么什么是事务呢

 

系统架构所需要的技术1
<beans>
    <bean id="baseTxService"
        class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean"
        abstract="true">
        <property name="transactionManager">
            <ref bean="transactionManager" />
        </property>

        <property name="proxyTargetClass">
            <value>true</value>
        </property>

        <property name="transactionAttributes">
            <props>
                <prop key="get*">PROPAGATION_REQUIRED,readOnly</prop>
                <prop key="find*">PROPAGATION_REQUIRED,readOnly</prop>
                <prop key="load*">PROPAGATION_REQUIRED,readOnly</prop>
                <prop key="save*">PROPAGATION_REQUIRED,-BusinessException</prop>
                <prop key="update*">PROPAGATION_REQUIRED,-BusinessException</prop>
                <prop key="remove*">PROPAGATION_REQUIRED,-BusinessException</prop>
                <prop key="builderCalendar">PROPAGATION_REQUIRED,readOnly</prop>
            </props>
        </property>
    </bean>
</beans>
系统架构所需要的技术1

这个是spring的事务配置。就是我在中间设立一个关卡,按照我的要求给你分配流的管道。AOP为什么说他是面象切面编程呢?它与spring的Ioc结合使用,更加体现了aop的强大功能所在.在讲它与spring结合使用之前先说几个难听,难懂的概念.它为什么不命名一些容易理解的概念了,因为aop很早就有人对它们命名了, 所以spring中讲的aop也不例外.在jboss,AspectJ...中都有aop这个概念.概念都一样的.看你怎样理解和运用了.我们简单的讲一下常用的几个概念.第一个: 切面(Aspect),这是中文的翻译,你可以把它翻译成方面,一部分...关于它的翻译太多,我们不关注这些,我们知道理解它是核心功能就OK了.切面简单的理解就是把那些不是核心业务应该处理的代码提取出来,进行封装成模块化.来处理那些附加的功能代码.(如日志,事务,安全验证)我们把这个模块的作用理解为一个切面,告诉我们它是一个功能模块.我们可以把它看成一个切面.说白了就是我们写一个类,在这个类中写一些处理在核心业务中起到同样效果的方法.这样大家应该明白了吧.专业的概念就是那么难理解.

 

 

 

 

 

 

 

 

 

---恢复内容结束---

系统架构所需要的技术1

上一篇:ARM学习笔记4——加载存储指令


下一篇:hdu 4324 Triangle LOVE(拓扑排序,基础)