adarsh datt

Greenhorn
+ Follow
since Aug 28, 2006
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by adarsh datt

I am working on a custom Interceptor that overrides the values in the v$session table . Is there a way to override the values of a v$session column. Currently I am overriding the reset method in the custom Interceptor

public class ConnPoolInterceptor extends JdbcInterceptor
{
...
....
public void reset(ConnectionPool arg0, PooledConnection arg1) {
poolConn = arg1;
if(poolConn != null)
{
PoolConfiguration config = poolConn.getPoolProperties();
config.setConnectionProperties("v$session.client_info=resetclient_info;v$session.osuser=resetosuser;v$session.program=resetprogram");
//config.setConnectionProperties("v$session.p3=2;v$session.p3text=resetP3TEXT;v$session.client_info=resetclient_info;v$session.osuser=resetosuser;v$session.program=resetprogram");
try
{
poolConn.reconnect();
config = poolConn.getPoolProperties();
}
catch(Exception ex) {
ex.printStackTrace();
}
}
}
}

Also, is there any forum apart from the tomcat site where JdbcInterceptors can be understood in depth? Any help is appreciated.
Following is when I tried to build the file using a windows system. There is a class not found exception for the class com.sun.tools.xjc.Driver. The classpath was set in maven.xml file. As the exception occurred we have also tried to set it in the classpath and have tried several other options like trying to set it the environment variable also. But the exception continues to occur. Please assist.


D:\CHF\development\applications\smart\build\GenSrc>maven

__ __
| \/ |__ _Apache__ ___
| |\/| / _` \ V / -_) ' \ ~ intelligent projects ~
|_| |_\__,_|\_/\___|_||_| v. 1.0.2

Starting the reactor...
Our processing order:
JAXBSource-Common
JAXBSource-DataTransfer
JAXBSource-MessageDataTypes
JAXBSource-MessageFramework
JAXBSource-Reports
+----------------------------------------
| Building SMART Application Suite JAXBSource-Common
| Memory: 2M/4M
+----------------------------------------
build:start:

smart-dist:
build:start:

smart-dist:
java repare-filesystem:

java:compile:
[echo] D:\CHF\development\applications\smart\build\GenSrc\Common
[exec] java.lang.ClassNotFoundException: com.sun.tools.xjc.Driver
[exec] at java.net.URLClassLoader$1.run(URLClassLoader.java:199)
[exec] at java.security.AccessController.doPrivileged(Native Method)
[exec] at java.net.URLClassLoader.findClass(URLClassLoader.java:187)
[exec] at java.lang.ClassLoader.loadClass(ClassLoader.java:289)
[exec] at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:274)

[exec] at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
[exec] at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)

[exec] at java.lang.Class.forName0(Native Method)
[exec] at java.lang.Class.forName(Class.java:141)
[exec] at org.apache.commons.launcher.ChildMain.run(ChildMain.java:224)

[exec] [ERROR] Result: 1
[echo] Compiling to D:\CHF\development\applications\smart\build\GenSrc\Commo
n/target/classes
[echo] No java source files to compile.
[echo] **** COMPILIATION OF Component SUCCESSFUL...
[echo] **** COMPILIATION OF Configuration SUCCESSFUL...
[echo] **** COMPILIATION OF processFlow SUCCESSFUL...

BUILD FAILED
File...... D:\CHF\development\applications\smart\build\GenSrc\maven.xml
Element... maven:reactor
Line...... 17
Column.... 263
16 years ago
Why do we have to write a setter method inside a controller class when we declare an object variable instead of directly creating an object?
Servlets are java programs. General notion is that the init() method creates a servlet but won't a constructor be called to create the servlet object in the first place?
17 years ago
I am getting the following exception
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'HelpController' defined in ServletContext resource [/WEB-INF/bean-servlet.xml]: Instantiation of bean failed; nested exception is java.lang.NoClassDefFoundError: org/springframework/dao/support/DaoSupport
java.lang.NoClassDefFoundError: org/springframework/dao/support/DaoSupport
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:502)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:476)
at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:181)
at weblogic.utils.classloaders.ChangeAwareClassLoader.findClass(ChangeAwareClassLoader.java:62)
at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
at java.lang.ClassLoader.loadClass(ClassLoader.java:255)
at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:223)
at weblogic.utils.classloaders.ChangeAwareClassLoader.loadClass(ChangeAwareClassLoader.java:41)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:315)
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:502)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:476)
at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:181)
at weblogic.utils.classloaders.ChangeAwareClassLoader.findClass(ChangeAwareClassLoader.java:62)
at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
at java.lang.ClassLoader.loadClass(ClassLoader.java:255)
at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:223)
at weblogic.utils.classloaders.ChangeAwareClassLoader.loadClass(ChangeAwareClassLoader.java:41)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:315)
at java.lang.Class.getDeclaredMethods0(Native Method)
at java.lang.Class.privateGetDeclaredMethods(Class.java:1627)
at java.lang.Class.getDeclaredMethods(Class.java:1114)
at java.beans.Introspector$1.run(Introspector.java:1103)
at java.security.AccessController.doPrivileged(Native Method)
at java.beans.Introspector.getPublicDeclaredMethods(Introspector.java:1101)
at java.beans.Introspector.getTargetMethodInfo(Introspector.java:966)
at java.beans.Introspector.getBeanInfo(Introspector.java:370)
at java.beans.Introspector.getBeanInfo(Introspector.java:144)
at org.springframework.beans.CachedIntrospectionResults.(CachedIntrospectionResults.java:140)
at org.springframework.beans.CachedIntrospectionResults.forClass(CachedIntrospectionResults.java:82)
at org.springframework.beans.BeanWrapperImpl.setIntrospectionClass(BeanWrapperImpl.java:310)
at org.springframework.beans.BeanWrapperImpl.setWrappedInstance(BeanWrapperImpl.java:268)
at org.springframework.beans.BeanWrapperImpl.setWrappedInstance(BeanWrapperImpl.java:250)
at org.springframework.beans.BeanWrapperImpl.(BeanWrapperImpl.java:203)
at org.springframework.beans.factory.support.AbstractBeanFactory.createBeanWrapper(AbstractBeanFactory.java:558)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:317)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:257)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:223)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:147)
at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:534)
at org.springframework.web.servlet.handler.AbstractUrlHandlerMapping.registerHandler(AbstractUrlHandlerMapping.java:180)
at org.springframework.web.servlet.handler.SimpleUrlHandlerMapping.initApplicationContext(SimpleUrlHandlerMapping.java:96)
at org.springframework.context.support.ApplicationObjectSupport.setApplicationContext(ApplicationObjectSupport.java:79)
at org.springframework.context.support.ApplicationContextAwareProcessor.postProcessBeforeInitialization(ApplicationContextAwareProcessor.java:80)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeInitialization(AbstractAutowireCapableBeanFactory.java:218)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:348)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:257)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:223)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:147)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:277)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:319)
at org.springframework.web.context.support.AbstractRefreshableWebApplicationContext.refresh(AbstractRefreshableWebApplicationContext.java:131)
at org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext(FrameworkServlet.java:305)
at org.springframework.web.servlet.FrameworkServlet.initWebApplicationContext(FrameworkServlet.java:250)
at org.springframework.web.servlet.FrameworkServlet.initServletBean(FrameworkServlet.java:219)
at org.springframework.web.servlet.HttpServletBean.init(HttpServletBean.java:111)
at javax.servlet.GenericServlet.init(GenericServlet.java:258)
at weblogic.servlet.internal.ServletStubImpl$ServletInitAction.run(ServletStubImpl.java:993)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:317)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:118)
at weblogic.servlet.internal.ServletStubImpl.createServlet(ServletStubImpl.java:869)
at weblogic.servlet.internal.ServletStubImpl.createInstances(ServletStubImpl.java:848)
at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:787)
at weblogic.servlet.internal.ServletStubImpl.getServlet(ServletStubImpl.java:518)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:362)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:305)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:6350)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:317)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:118)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3635)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2585)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:170)
Thanks for that.. now i am kinda familiar with jsp,servlet. I am still unsure of using beans(just get/set methods) in the spring framework
As of now, i am familiar with basic concepts of jsp,servlets. Will going through Head First Jsp&Servlets Book completely be of any help?
I am new to the Spring & Hibernate framework. What are the topics/basic concepts that one needs to understand in order to start working on Springs and the Hibernate Framework. Thanks in advance