本帖最后由 qq13185187 于 2009-09-26 03:37:21 编辑

解决方案 »

  1.   


      <?xml version="1.0" encoding="UTF-8" ?> 
    - <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">
      <display-name>springTest</display-name> 
    - <welcome-file-list>
      <welcome-file>index.jsp</welcome-file> 
      </welcome-file-list>
    - <!--  Spring 初始化配置开始 
      --> 
    - <!--  确定多个配置文件 
      --> 
    - <context-param>
      <param-name>contextConfigLocation</param-name> 
      <param-value>/WEB-INF/applicationContext.xml</param-value> 
      </context-param>
    - <!--  采用Listener完成Spring容器的初始化 
      --> 
    - <listener>
      <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> 
      </listener>
    - <!--  Spring 初始化配置结束 
      --> 
    - <!--  Struts2 初始化配置开始 
      --> 
    - <!--  定义Struts2的FilterDispatcher的Filter 
      --> 
    - <filter>
    - <!--  定义核心Filter的名字 
      --> 
      <filter-name>struts2</filter-name> 
    - <!--  定义核心Filter的实现类 
      --> 
      <filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class> 
      </filter>
    - <!--  Struts2 初始化配置结束 
      --> 
    - <!--  为上传文件增加ActionContextCleanUp这个filter,如果不增加,会发生第一次上传取不到文件的情况  
      --> 
    - <filter>
      <filter-name>struts-cleanup</filter-name> 
      <filter-class>org.apache.struts2.dispatcher.ActionContextCleanUp</filter-class> 
      </filter>
    - <filter-mapping>
      <filter-name>struts-cleanup</filter-name> 
      <url-pattern>/*</url-pattern> 
      </filter-mapping>
    - <!-- ActionContextCleanUp定义结束  
      --> 
    - <!--  FilterDispatcher用来初始化Struts2 并且处理所用的web请求 
      --> 
    - <filter-mapping>
      <filter-name>struts2</filter-name> 
      <url-pattern>/*</url-pattern> 
      </filter-mapping>
    - <session-config>
      <session-timeout>20</session-timeout> 
    - <!--  (分)设置session 时间 
      --> 
      </session-config>
    - <error-page>
      <error-code>404</error-code> 
      <location>/error/fileNotFound.jsp</location> 
      </error-page>
      </web-app>
    希望对楼主有用~呵呵
      

  2.   

    现在已经配置好了,但是,第一次访问数据库的时候,没问题。
    第二次的时候就报错:Attempt to refer to a unregistered pool by its alias 'mycitywebdb'
    好郁闷。
    这是proxool.xml的配置<?xml version="1.0" encoding="UTF-8"?>
    <proxool-config>
    <proxool>
    <alias>mycitywebdb</alias>
    <driver-url>
    jdbc:microsoft:sqlserver://localhost:1433;datebase=mycityweb;
    </driver-url>
    <driver-class>com.microsoft.jdbc.sqlserver.SQLServerDriver</driver-class>
    <driver-properties>
    <property name="user" value="mycityweb" />
    <property name="password" value="yinshihua" />
    </driver-properties>
    <house-keeping-sleep-time>90000</house-keeping-sleep-time>
    <maximum-new-connections>20</maximum-new-connections>
    <prototype-count>5</prototype-count>
    <maximum-connection-count>1000</maximum-connection-count>
    <minimum-connection-count>10</minimum-connection-count>
    </proxool>
    </proxool-config>这是application.xml的配置<bean id="sessionFactory"
    class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">

    <property name="hibernateProperties">
    <props>
    <prop key="hibernate.dialect">org.hibernate.dialect.SQLServerDialect</prop>
        <prop key="hibernate.connection.provider_class">org.hibernate.connection.ProxoolConnectionProvider</prop>
                <prop key="hibernate.query.factory_class">org.hibernate.hql.ast.ASTQueryTranslatorFactory</prop>
        <prop key="hibernate.proxool.xml">proxool.xml</prop>
        <prop key="hibernate.proxool.pool_alias">mycitywebdb</prop>
    <prop key="hibernate.connection.autocommit">true</prop>
        <prop key="hbm2ddl.auto">create</prop>
        <prop key="hibernate.cache.use_second_level_cache">true</prop>
    <prop key="hibernate.show_sql">true</prop>
    <prop key="hibernate.connection.release_mode">auto</prop>
    <prop key="hibernate.jdbc.fetch_size">50</prop>
                <prop key="hibernate.jdbc.batch_size">20</prop>
    </props>
    </property>

    <property name="mappingResources">
    <list>

                            </list>
                    </property>
    有人知道的麻烦告诉我一下..
    谢谢.
      

  3.   

    我这边能通的思路是这样的1.在web.xml文件中只配置spring和struts2,根本没有配置proxool2
      

  4.   

    配置文件2<?xml version="1.0" encoding="UTF-8"?>
    <something-else-entirely>
      <proxool>
        <alias>mxj</alias>
        <driver-url>jdbc:mysql://cmsDB/FUNDCMS?autoReconnect=true</driver-url>
        <driver-class>com.mysql.jdbc.Driver</driver-class>
        <driver-properties>
          <property name="user" value="root"/>  <!-- 数据库帐号 -->
          <property name="password" value=""/>  <!-- 数据库密码 -->
          <property name="useUnicode" value="true"/>  <!-- 使用unicode字符编码集 -->
          <property name="characterEncoding" value="GBk"/>  <!-- 字符编码为utf-8 -->
          <property name="zeroDateTimeBehavior" value="convertToNull"/>  <!-- 用于测试数据库连接的sql语句 -->
        </driver-properties>
        <!-- proxool自动侦察各个连接状态的时间间隔(毫秒),侦察到空闲的连接就马上回收,超时的销毁 -->
        <house-keeping-sleep-time>90000</house-keeping-sleep-time>    <!-- 指因未有空闲连接可以分配而在队列中等候的最大请求数,超过这个请求数的用户连接就不会被接受 -->
        <maximum-new-connections>20</maximum-new-connections>    <!-- 最少保持的空闲连接数 -->
        <prototype-count>5</prototype-count>    <!-- 允许最大连接数,超过了这个连接,再有请求时,就排在队列中等候 -->
        <maximum-connection-count>100</maximum-connection-count>    <!-- 最小连接数 -->
        <minimum-connection-count>10</minimum-connection-count>
        <house-keeping-test-sql>select CURRENT_DATE</house-keeping-test-sql>  <!--  -->
      </proxool>
    </something-else-entirely>
      

  5.   

    我这边能通的思路是这样的 1.在web.xml文件中只配置spring和struts2,根本没有配置proxool 2接下来就是三种方案配置proxool了A单独的proxool配置文件配置文件1<?xml version='1.0' encoding='UTF-8'?>
    <!DOCTYPE hibernate-configuration PUBLIC
              "-//Hibernate/Hibernate Configuration DTD 3.0//EN"
              "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd"><hibernate-configuration>    <session-factory>
        
    <!-- local connection properties -->
    <property name="hibernate.connection.url">jdbc:mysql://cmsDB/FUNDCMS?autoReconnect=true</property>
    <property name="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property>
    <property name="hibernate.connection.username">root</property>
    <property name="hibernate.connection.password"></property>
    <property name="hibernate.dialect">org.hibernate.dialect.MySQLDialect</property>
    <property name="hibernate.show_sql">false</property>
    <property name="hibernate.format_sql">true</property>
    <property name="hibernate.use_outer_join">true</property>

    <property name="hibernate.jdbc.fetch_size">50</property>
    <property name="hibernate.jdbc.use_streams_for_binary">true</property>
    <property name="hibernate.query.substitutions">true 1, false 0, yes 'Y', no 'N'</property>

    <property name="hibernate.connection.provider_class">org.hibernate.connection.ProxoolConnectionProvider</property>
      
        <property name="proxool.pool_alias">mxj</property> <!-- 指定别名 -->
          <property name="proxool.xml">conf/pp.xml</property> <!-- 外部proxool的配置文件,和Hibernate在同一目录下 -->
      
    <property name="hibernate.hbm2ddl.auto">create</property>
    <property name="hibernate.hbm2ddl.auto">update</property>

    <property name="hibernate.cache.use_second_level_cache">false</property>
    <property name="hibernate.cache.use_query_cache">false</property>
    <property name="hibernate.cache.provider_class">org.hibernate.cache.EhCacheProvider</property>
    <!-- 
    <property name="hibernate.cache.provider_class">org.hibernate.cache.OSCacheProvider</property>
    -->
    <property name="hibernate.cache.region_prefix">cache_</property>

    <mapping resource="com/uu/deprecated/entity/Function.hbm.xml" />
    <mapping resource="com/uu/deprecated/entity/Role.hbm.xml" />
    <mapping resource="com/uu/deprecated/entity/User.hbm.xml" />
    <mapping resource="com/uu/deprecated/entity/DataCache.hbm.xml" />
    <!-- 
    <mapping resource="com/uu/base/entity/City.hbm.xml" />
    <mapping resource="com/uu/base/entity/Province.hbm.xml" />
    <mapping resource="com/uu/base/entity/Country.hbm.xml" />
      -->
     
    <mapping resource="com/uu/cms/entity/Channel.hbm.xml" />
    <mapping resource="com/uu/cms/entity/Article.hbm.xml" />
    <mapping resource="com/uu/cms/entity/Publish.hbm.xml" />
    <mapping resource="com/uu/cms/entity/Modal.hbm.xml" />
    <mapping resource="com/uu/cms/entity/ModalType.hbm.xml" />
    <mapping resource="com/uu/cms/entity/CmsAgent.hbm.xml" />
    <mapping resource="com/uu/cms/entity/Spider.hbm.xml" />
    <mapping resource="com/uu/cms/entity/SpiderLinks.hbm.xml" />
    <mapping resource="com/uu/cms/entity/SpiderFilter.hbm.xml" />
    <mapping resource="com/uu/cms/entity/PictureSite.hbm.xml" />
    <mapping resource="com/uu/cms/entity/PictureNews.hbm.xml" />
    <mapping resource="com/uu/cms/entity/HotNewsSite.hbm.xml" />
    <mapping resource="com/uu/cms/entity/HotNews.hbm.xml" />
    <mapping resource="com/uu/cms/entity/HtmlEditor.hbm.xml" />
    <mapping resource="com/uu/cms/entity/Contribute.hbm.xml" />
    <mapping resource="com/uu/cms/entity/Transfer.hbm.xml" />
    <mapping resource="com/uu/cms/entity/CmsKeywords.hbm.xml" />
    <mapping resource="com/uu/cms/entity/CmsAttachment.hbm.xml" />
    <mapping resource="com/uu/cms/entity/IssueArticle.hbm.xml" />
    <mapping resource="com/uu/cms/entity/nameQuery.hbm.xml" />
    <mapping resource="com/uu/cms/entity/FlowRecord.hbm.xml" />
    <mapping resource="com/uu/cms/entity/FlowRecordStatis.hbm.xml" />
    <mapping resource="com/uu/cms/entity/UserChannelRelation.hbm.xml" />

    <!-- 
    <mapping resource="com/uu/bank/entity/Deposit.hbm.xml" />
    <mapping resource="com/uu/bank/entity/Loan.hbm.xml" />
    <mapping resource="com/uu/bank/entity/Other.hbm.xml" />
    <mapping resource="com/uu/bank/entity/Rmb.hbm.xml" />
    <mapping resource="com/uu/bank/entity/Foreign.hbm.xml" />
    <mapping resource="com/uu/bank/entity/CreditCard.hbm.xml" />
    <mapping resource="com/uu/bank/entity/EleBank.hbm.xml" />
    <mapping resource="com/uu/ins/entity/Insure.hbm.xml" />
    <mapping resource="com/uu/fund/entity/Fund.hbm.xml" />
    <mapping resource="com/uu/fund/entity/Information.hbm.xml" />
    <mapping resource="com/uu/fund/entity/Manager.hbm.xml" />
    <mapping resource="com/uu/fund/entity/Administrant.hbm.xml" />
    <mapping resource="com/uu/fund/entity/Trustee.hbm.xml" />
    <mapping resource="com/uu/fund/entity/NetValue.hbm.xml" />
    <mapping resource="com/uu/fund/entity/HoldList.hbm.xml" />
    <mapping resource="com/uu/fund/entity/Document.hbm.xml" />
     
    <class-cache class="com.uu.bank.entity.Deposit" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.bank.entity.Loan" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.bank.entity.Other" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.bank.entity.Rmb" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.bank.entity.Foreign" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.bank.entity.CreditCard" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.bank.entity.EleBank" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.ins.entity.Insure" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.fund.entity.Fund" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.fund.entity.Information" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.fund.entity.Manager" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.fund.entity.Administrant" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.fund.entity.Trustee" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.fund.entity.NetValue" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.fund.entity.HoldList" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.fund.entity.Document" region="NormalRegion" usage="read-write" />
      --> <class-cache class="com.uu.deprecated.entity.Function" region="NormalRegion" usage="nonstrict-read-write" />
    <class-cache class="com.uu.deprecated.entity.Role" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.deprecated.entity.User" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.deprecated.entity.DataCache" region="NormalRegion" usage="read-write" />
    <!-- 
    <class-cache class="com.uu.base.entity.City" region="NormalRegion" usage="nonstrict-read-write" />
    <class-cache class="com.uu.base.entity.Province" region="NormalRegion" usage="nonstrict-read-write" />
    <class-cache class="com.uu.base.entity.Country" region="NormalRegion" usage="nonstrict-read-write" />
     -->
     
    <class-cache class="com.uu.cms.entity.Channel" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.Article" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.Publish" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.Modal" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.ModalType" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.CmsAgent" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.Spider" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.SpiderLinks" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.SpiderFilter" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.PictureSite" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.PictureNews" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.HotNewsSite" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.HotNews" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.HtmlEditor" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.Contribute" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.Transfer" region="NormalRegion" usage="read-write" />
    <class-cache class="com.uu.cms.entity.IssueArticle" region="NormalRegion" usage="read-only"/>
        
        </session-factory></hibernate-configuration>
      

  6.   

    第二种方案把proxool放在spring的配置文件中<?xml version="1.0" encoding="GBK"?><beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:context="http://www.springframework.org/schema/context"
    xmlns:aop="http://www.springframework.org/schema/aop"
    xmlns:tx="http://www.springframework.org/schema/tx"
    xsi:schemaLocation="http://www.springframework.org/schema/beans
    http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
    http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
    http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.5.xsd
    http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.5.xsd">
    <!-- 
    <bean id="myDataSource" class="org.springframework.jndi.JndiObjectFactoryBean">
    <property name="jndiName" value="java:comp/env/proxool/fundmaster"/>
    </bean>
     -->
    <bean id="myDataSource" class="org.logicalcobwebs.proxool.ProxoolDataSource" destroy-method="close">
    <property name="driver"><value>${database.driverClass}</value></property>
    <property name="driverUrl"><value>${database.jdbcUrl}</value></property>
    <property name="user"><value>${database.user}</value></property>
    <property name="password"><value>${database.password}</value></property>
    <property name="alias" value="proxoolPool" />
    <!--property name="houseKeepingSleepTime" value="30000" /-->
    <property name="prototypeCount" value="5" />
    <property name="maximumConnectionCount" value="10" />
    <property name="minimumConnectionCount" value="5" />
    <property name="trace" value="true" />
    <property name="verbose" value="true" />
    </bean>
    <bean id="sessionFactory" class="org.springframework.orm.hibernate3.annotation.AnnotationSessionFactoryBean">
    <property name="dataSource" ref="myDataSource" />
    <property name="schemaUpdate" value="true" />
    <property name="hibernateProperties">
    <props>
    <prop key="hibernate.cglib.use_reflection_optimizer">true</prop>
    <prop key="hibernate.query.substitutions">true 1,false 0,yes 'Y',no 'N'</prop>
    <prop key="hibernate.dialect">${hibernate.dialect}</prop>
    <prop key="hibernate.show_sql">false</prop>
    <prop key="hibernate.format_sql">true</prop>
    <prop key="hibernate.use_outer_join">true</prop>
    <prop key="hibernate.jdbc.fetch_size">50</prop>
    <prop key="hibernate.jdbc.use_streams_for_binary">true</prop>
    <prop key="hibernate.cache.use_second_level_cache">false</prop>
    <prop key="hibernate.cache.region_prefix">cache</prop>
    <prop key="hibernate.cache.use_query_cache">true</prop>
    <prop key="hibernate.cache.provider_class">org.hibernate.cache.EhCacheProvider</prop>
    </props>
    </property>

    <property name="annotatedClasses">
    <list>
    <!-- member -->
    <value>com.uusoft.core.member.entity.BASFriend</value>
    <value>com.uusoft.core.member.entity.BASMessage</value>
    <value>com.uusoft.core.member.entity.BASUser</value>
    <value>com.uusoft.core.member.entity.BASUserEducation</value>
    <value>com.uusoft.core.member.entity.BASUserInvest</value>
    <value>com.uusoft.core.member.entity.BASUserLife</value>
    <value>com.uusoft.core.member.entity.BASUserWork</value>
    <value>com.uusoft.core.member.entity.BASUserEmail</value>
    <value>com.uusoft.core.member.entity.BASUserSchool</value>
    <value>com.uusoft.core.member.entity.BASSpeciality</value>
    <value>com.uusoft.core.member.entity.BASIndustry</value>
    <value>com.uusoft.core.member.entity.UserVisit</value>
    <value>com.uusoft.core.member.entity.BASUserSetting</value>
    <value>com.uusoft.core.member.entity.BASUserState</value>
    <value>com.uusoft.core.member.entity.BASFriendGroup</value>
    <value>com.uusoft.core.member.entity.BASUserVCard</value>
    <value>com.uusoft.core.member.entity.BASUserInfoManager</value>
    <value>com.uusoft.core.member.entity.BASPrivacySetting</value>
    <value>com.uusoft.core.member.entity.BASCategorySetting</value>
    <!-- admin -->
    <value>com.uusoft.core.admin.entity.BASAdmin</value>
    <value>com.uusoft.core.admin.entity.BASDept</value>
    <value>com.uusoft.core.admin.entity.BASFunction</value>
    <value>com.uusoft.core.admin.entity.BASRole</value>
    <value>com.uusoft.core.admin.entity.BASNetValueGather</value>
    <!-- baseInfo -->
    <value>com.uusoft.core.baseinfo.entity.BASCity</value>
    <value>com.uusoft.core.baseinfo.entity.BASDict</value>
    <value>com.uusoft.core.baseinfo.entity.BASUniversity</value>
    <value>com.uusoft.core.baseinfo.entity.BASSeniorSchool</value>
    <value>com.uusoft.core.baseinfo.entity.BASTemp</value>
    </list>
    </property>
    <property name="lobHandler" ref="oracleLobHandler" />
    </bean> <bean id="defaultLobHandler" class="org.springframework.jdbc.support.lob.DefaultLobHandler" lazy-init="true" />  <bean id="nativeJdbcExtractor" class="org.springframework.jdbc.support.nativejdbc.C3P0NativeJdbcExtractor" lazy-init="true" /> <bean id="oracleLobHandler" class="org.springframework.jdbc.support.lob.OracleLobHandler" lazy-init="true">
    <property name="nativeJdbcExtractor" ref="nativeJdbcExtractor" />
    </bean> <bean id="transactionManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager">
    <property name="sessionFactory" ref="sessionFactory" />
    </bean></beans>
      

  7.   

    第三种方案就是用jndi的方式来解决了,它的好处是所有的工程共用一个context源
      

  8.   

    回复han_zhan_sheng
    嗯,是我配错了,不过现在已经配好了。第一次访问成功的时候控制台输出:
    48485 [http-8080-1] INFO impl.SessionFactoryImpl  - closing
    48485 [http-8080-1] INFO proxool.mycityweb  - Shutting down 'mycityweb' pool immediately [http-8080-1]
    48500 [http-8080-1] INFO impl.SessionFactoryImpl  - closing
    48500 [http-8080-1] INFO impl.SessionFactoryImpl  - closing
    48500 [http-8080-1] INFO impl.SessionFactoryImpl  - closing
    48500 [http-8080-1] INFO impl.SessionFactoryImpl  - closing
    48500 [http-8080-1] INFO impl.SessionFactoryImpl  - closing
    48500 [http-8080-1] INFO impl.SessionFactoryImpl  - closing
    48500 [http-8080-1] INFO impl.SessionFactoryImpl  - closing
    48500 [http-8080-1] INFO impl.SessionFactoryImpl  - closing
    提示已经关闭了'mycityweb'连接池。
    第二次访问的时候就找不到‘mycityweb’连接池了。
    请问你知道这是什么回事吗?
      

  9.   

      web.xml  配置文件中加上 OpenSessionInViewFilter 这个过滤器就好了
      

  10.   

    异常信息:52469 [http-8080-1] ERROR city.CityDAO  - find all failed
    org.springframework.jdbc.UncategorizedSQLException: Hibernate operation: Cannot open connection; uncategorized SQLException for SQL [???]; SQL state [null]; error code [0]; org.logicalcobwebs.proxool.ProxoolException: Attempt to refer to a unregistered pool by its alias 'mycityweb'; nested exception is java.sql.SQLException: org.logicalcobwebs.proxool.ProxoolException: Attempt to refer to a unregistered pool by its alias 'mycityweb'
    Caused by: 
    java.sql.SQLException: org.logicalcobwebs.proxool.ProxoolException: Attempt to refer to a unregistered pool by its alias 'mycityweb'
      

  11.   

    web.xml  配置文件中加上 OpenSessionInViewFilter 这个过滤器就好了
      

  12.   

    你的别名是mycityweb,我看你上面的配置是mycitywebdb啊
      

  13.   

    你换个思路!
    proxool单独使用的时候是要在web.xml中配置的,但是在ssh中我们可以把proxool交给Hibernate来管理,而hibernate被spring管理,spring的配置文件在服务器启动的时候就已经加载了,所以不用再web.xml在配置proxool的相关信息了!
      

  14.   

    为什么一定要pool呢?
    jndi不行吗?