ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Clinton Begin" <clinton.be...@gmail.com>
Subject Re: Strange problem reloading SQLMaps
Date Fri, 14 Jul 2006 16:49:53 GMT
I hate giving answers like this...so my apologies in advance.

Don't do that!  :-)

Really, it should work and I have no idea what the problem could be.
I really have to wonder what you're trying to achieve by doing that
though.  Sounds pretty scary.

Cheers,
Clinton




On 7/13/06, Kevin Schraith <kevins@dbo2.com> wrote:
> Hello,
>
> We're using iBATIS SQLMap with the DAO wrapping functionality, and we have
> run into a new problem with one of our sqlMap XML files not reloading
> correctly.  After copying a new set of XML files to our Weblogic 9.1 server,
> we hit a JSP file that triggers the following code:
>
> Reader reader = Resources.getResourceAsReader( s_configurationFile );
> s_daoManager = DaoManagerBuilder.buildDaoManager( reader );
>
> This works right now apparently with all of our sqlMap XML files save one,
> ScheduledEventMap.xml.  We did not seem to have this problem before when
> using Weblogic 6.1/JDK 1.3, but have upgraded recently to Weblogic 9.1/JDK
> 1.5, and it is possible there is some connection.
>
> The file is definitely being read - the above code will fail if we don't
> have the ScheduledEventMap.xml file in the classpath of the app server.  But
> if it is there, there updated SQL is not being used.
>
> Any suggestions as what could be happening?  I'll include the dao.xml and
> SqlMapConfig.xml contents at the end of this post.
>
> Thanks,
>   Kevin
>
> ---------
> dao.xml:
> ---------
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE daoConfig PUBLIC "-//iBATIS.com//DTD DAO Configuration 2.0//EN"
>     "http://www.ibatis.com/dtd/dao-2.dtd">
> <daoConfig>
>
>   <context>
>
>     <transactionManager type="SQLMAP">
>       <property name="SqlMapConfigResource"
>                         value="com/dbo2/pipeline/model/SqlMapConfig.xml"/>
>     </transactionManager>
>
>     <dao interface="com.dbo2.pipeline.model.admin.AdminDao"
> implementation="com.dbo2.pipeline.model.admin.AdminSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.admin.ApplicationUserDao"
> implementation="com.dbo2.pipeline.model.admin.ApplicationUserSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.admin.ServerAdminDao"
> implementation="com.dbo2.pipeline.model.admin.ServerAdminSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.admin.TraceDao"
> implementation="com.dbo2.pipeline.model.admin.TraceSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.admin.event.ScheduledEventDao"
> implementation="com.dbo2.pipeline.model.admin.event.ScheduledEventSqlMapDao"
> />
>     <dao interface="com.dbo2.pipeline.model.analysis.AnalysisDao"
> implementation="com.dbo2.pipeline.model.analysis.AnalysisSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.analysis.salesplan.SalesPlanDao"
> implementation="com.dbo2.pipeline.model.analysis.salesplan.SalesPlanSqlMapDa
> o"/>
>     <dao interface="com.dbo2.pipeline.model.attachment.AttachmentDao"
> implementation="com.dbo2.pipeline.model.attachment.AttachmentSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.company.CompanyDao"
> implementation="com.dbo2.pipeline.model.company.CompanySqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.contact.ContactDao"
> implementation="com.dbo2.pipeline.model.contact.ContactSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.equipment.EquipmentDao"
> implementation="com.dbo2.pipeline.model.equipment.EquipmentSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.marketing.MarketingDao"
> implementation="com.dbo2.pipeline.model.marketing.MarketingSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.general.ActivityDao"
> implementation="com.dbo2.pipeline.model.general.ActivitySqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.general.HomeDao"
> implementation="com.dbo2.pipeline.model.general.HomeSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.project.ProjectDao"
> implementation="com.dbo2.pipeline.model.project.ProjectSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.reference.ReferenceDao"
> implementation="com.dbo2.pipeline.model.reference.ReferenceSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.safety.SafetyDao"
> implementation="com.dbo2.pipeline.model.safety.SafetySqlMapDao"/>
>     <dao
> interface="com.dbo2.pipeline.model.safety.inspections.InspectionDao"
> implementation="com.dbo2.pipeline.model.safety.inspections.InspectionSqlMapD
> ao"/>
>     <dao
> interface="com.dbo2.pipeline.model.safety.reports.BenchmarkRatingsReportDao"
> implementation="com.dbo2.pipeline.model.safety.reports.BenchmarkRatingsRepor
> tSqlMapDao"/>
>     <dao
> interface="com.dbo2.pipeline.model.safety.reports.OpenIssueReportDao"
> implementation="com.dbo2.pipeline.model.safety.reports.OpenIssueReportSqlMap
> Dao"/>
>     <dao
> interface="com.dbo2.pipeline.model.safety.reports.SafetyIssuesReportDao"
> implementation="com.dbo2.pipeline.model.safety.reports.SafetyIssuesReportSql
> MapDao"/>
>     <dao
> interface="com.dbo2.pipeline.model.safety.reports.SafetyComparisonReportDao"
> implementation="com.dbo2.pipeline.model.safety.reports.SafetyComparisonRepor
> tSqlMapDao"/>
>     <dao
> interface="com.dbo2.pipeline.model.safety.reports.SafetyMasterReportDao"
> implementation="com.dbo2.pipeline.model.safety.reports.SafetyMasterReportSql
> MapDao"/>
>     <dao
> interface="com.dbo2.pipeline.model.safety.reports.SafetyUtilizationReportDao
> "
> implementation="com.dbo2.pipeline.model.safety.reports.SafetyUtilizationRepo
> rtSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.survey.SurveyDao"
> implementation="com.dbo2.pipeline.model.survey.SurveySqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.zoneadmin.ZoneAdminDao"
> implementation="com.dbo2.pipeline.model.zoneadmin.ZoneAdminSqlMapDao"/>
>     <dao interface="com.dbo2.pipeline.model.metrics.AnalysisMetricDao"
> implementation="com.dbo2.pipeline.model.metrics.AnalysisMetricSqlMapDao"/>
>
>   </context>
>
> </daoConfig>
>
>
> ------------------
> SqlMapConfig.xml:
> ------------------
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE sqlMapConfig PUBLIC "-//iBATIS.com//DTD SQL Map Config 2.0//EN"
>     "http://www.ibatis.com/dtd/sql-map-config-2.dtd">
> <sqlMapConfig>
>
>   <settings cacheModelsEnabled="false"
>             enhancementEnabled="true"
>             lazyLoadingEnabled="false"
>             errorTracingEnabled="true"
>             useStatementNamespaces="false"/>
>
>   <transactionManager type="JDBC">
>     <dataSource type="JNDI">
>       <property name="DataSource" value="crmPool"/>
>     </dataSource>
>   </transactionManager>
>   <sqlMap resource="com/dbo2/pipeline/model/admin/AdminMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/admin/ApplicationUserMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/admin/CrossZoneMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/admin/EmailLogMap.xml"/>
>   <sqlMap
> resource="com/dbo2/pipeline/model/admin/ManageDeletedItemsMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/admin/ServerAdminMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/admin/TraceMap.xml"/>
>   <sqlMap
> resource="com/dbo2/pipeline/model/admin/event/ScheduledEventMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/attachment/AttachmentMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/analysis/AnalysisMap.xml"/>
>   <sqlMap
> resource="com/dbo2/pipeline/model/analysis/salesplan/SalesPlanMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/company/CompanyMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/contact/ContactMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/equipment/EquipmentMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/marketing/MarketingMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/general/ActivityMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/general/HomeMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/project/ProjectMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/reference/ReferenceMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/safety/SafetyMap.xml"/>
>   <sqlMap
> resource="com/dbo2/pipeline/model/safety/inspections/InspectionMap.xml"/>
>   <sqlMap
> resource="com/dbo2/pipeline/model/safety/reports/BenchmarkRatingsReportMap.x
> ml"/>
>   <sqlMap
> resource="com/dbo2/pipeline/model/safety/reports/OpenIssueReportMap.xml"/>
>   <sqlMap
> resource="com/dbo2/pipeline/model/safety/reports/SafetyComparisonReportMap.x
> ml"/>
>   <sqlMap
> resource="com/dbo2/pipeline/model/safety/reports/SafetyIssuesReportMap.xml"/
> >
>   <sqlMap
> resource="com/dbo2/pipeline/model/safety/reports/SafetyMasterReportMap.xml"/
> >
>   <sqlMap
> resource="com/dbo2/pipeline/model/safety/reports/SafetyUtilizationReportMap.
> xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/survey/SurveyMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/zoneadmin/ZoneAdminMap.xml"/>
>   <sqlMap resource="com/dbo2/pipeline/model/metrics/AnalysisMetricMap.xml"/>
>
> </sqlMapConfig>
>
>
> --
> No virus found in this outgoing message.
> Checked by AVG Free Edition.
> Version: 7.1.394 / Virus Database: 268.10.0/388 - Release Date: 7/13/2006
>
>
>

Mime
View raw message