1)테스트 환경
Resin Pro 3.0.23
Flex 3.0b,Cairngorm 2.2
Spring 2.0.6
iBATIS 2.3.0.677
Oracle 9i
Error 내용 :
[RPC Fault faultString="Cannot find class [org.apache.commons.dbcp.BasicDataSource] for bean with name 'dataSource' defined in ServletContext resource [/WEB-INF/applicationContext.xml]; nested exception is java.lang.ClassNotFoundException: org.apache.commons.dbcp.BasicDataSource" faultCode="Server.Processing" faultDetail="null"]
at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::faultHandler()
at mx.rpc::Responder/fault()
at mx.rpc::AsyncRequest/fault()
at ::NetConnectionMessageResponder/NetConnectionChannel.as$40:NetConnectionMessageResponder::statusHandler()
at mx.messaging::MessageResponder/status()
java.lang.ClassNotFoundException: org.apache.commons.dbcp.BasicDataSource
Cannot find class [org.apache.commons.dbcp.BasicDataSource] for bean with name 'dataSource' defined in ServletContext resource [/WEB-INF/applicationContext.xml]; nested exception is java.lang.ClassNotFoundException: org.apache.commons.dbcp.BasicDataSource
Error 해결 : commons-dbcp-1.2.2.jar 파일을 WEB-INF/lib 에 카피해서 해결
Error 내용 :
Error creating bean with name 'dataSource' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Instantiation of bean failed; nested exception is java.lang.NoClassDefFoundError: org/apache/commons/pool/impl/GenericObjectPool
[RPC Fault faultString="Error creating bean with name 'dataSource' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Instantiation of bean failed; nested exception is java.lang.NoClassDefFoundError: org/apache/commons/pool/impl/GenericObjectPool" faultCode="Server.Processing" faultDetail="null"]
at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::faultHandler()
at mx.rpc::Responder/fault()
at mx.rpc::AsyncRequest/fault()
at ::NetConnectionMessageResponder/NetConnectionChannel.as$40:NetConnectionMessageResponder::statusHandler()
at mx.messaging::MessageResponder/status()
Error 해결 : commons-pool-1.3.jar 파일을 WEB-INF/lib 에 카피해서 해결
Error 내용 :
Error creating bean with name 'categoryService' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyException: Invalid property 'categoryDao' of bean class [com.appfoundation.flexibatis.services.CategoryServiceImpl]: Bean property 'categoryDao' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
Error 해결 : 주의할 것!! CategoryServiceImpl *Service 인터페이스를 구현한 클래스 에는 반드시 Spring applicationContext.xml 에서 DAO Config 부분의 bean id와 같은 getter,setter가 있어야한다. 익숙하기 전까지는 자주 실수하는 부분이다.
Error 내용 :
org.springframework.jdbc.CannotGetJdbcConnectionException : Could not get JDBC Connection; nested exception is org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (ORA-01017: invalid username/password; logon denied
)
Error 해결 : application.properties 안의 아이디 비번이 틀린경우이다.
Error 내용 :
com.ibatis.sqlmap.client.SqlMapException : There is no statement named Category.getCategoryList in this SqlMap.
Error 해결 : SqlMapConfig.xml 파일에서 해당 sqlmap 파일을 명시하지 않았다
(아니면 이미 있는데,테스트시 코멘트 처리한걸 풀어주지 않고 테스트하는 경우가 있다.)
Error 내용 :
//com.ibatis.sqlmap.client.SqlMapException: There is already a statement named getContacts in this SqlMap.
가령 ContactDaoImpl 클래스를 코딩할때 아래처럼 Contact.getContacts 처럼 해줘야한다,다른 map 파일에서 똑같은 이름의 메소드가 있다면,아래 에러가 난다.
이 에러때문에 한참 헤맸었다.아래 포스팅에도 언급해놨지만, 이 부분때문에 반나절을 헤맨 기억이 나서 다시 중복으로 언급해둔다.
위와 관련해서 sqlmapconfig.xml 에 아래의 태그를 추가해준다.
<settings useStatementNamespaces="true"/>
public List getContacts() throws DataAccessException {
//return getSqlMapClientTemplate().queryForList("getContacts"); //이게 아니라 아래처럼이다.
return getSqlMapClientTemplate().queryForList("Contact.getContacts");
}
'Error creating bean with name '' defined in ServletContext resource'에 해당되는 글 1건
- 2007/08/15 iamyhs Flex(Cairngorm)+Spring+iBATIS+Oracle+Resin 연동시 대표적인 에러 몇가지들 (4)
TAG Cannot find class [org.apache.commons.dbcp.BasicDataSource] for bean with name,
com.ibatis.sqlmap.client.SqlMapException : There is no statement named .. in this SqlMap.,
Error creating bean with name '' defined in ServletContext resource,
Error creating bean with name 'dataSource' defined in ServletContext resource,
Flex,
iBATIS,
Oracle,
org.springframework.jdbc.CannotGetJdbcConnectionException,
Resin,
Spring

댓글을 달아 주세요
댓글 RSS 주소 : http://iamyhs.com/tc/rss/comment/113관리자만 볼 수 있는 댓글입니다.
그 당시 세팅할때 Resin 이라고 특별히 할건 없었습니다.
다른 WAS 처럼 flex.war 를 파일을 복사해준게 전부 였습니다.
BlazeDS 라고 해서 별다를건 없으리라 생각합니다.
resin +blazeds 로 구글링 해보십시요.
http://www.google.co.kr/search?complete=1&hl=ko&q=resin+%2Bblazeds&btnG=Google+%EA%B2%80%EC%83%89&lr=&aq=f
아하하...^^;
지금 오류관련해서 찾다보니...양과장님댁이네요
으흐흐흐..
대전의 하루는 길군요 ㅠㅠ
어서와라 떠라~
늘~ "나는 관대하다"