Prem Shankar

Greenhorn
+ Follow
since Jul 28, 2003
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Prem Shankar

Thanks for your reply. I have tried ip,hostname,localhost,127.0.0.1 also.. but still the same exception.. I got the following stack when invoking the remote without spring config.


SEVERE: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
java.lang.RuntimeException: java.rmi.ConnectException: Failure during invoke; nested exception is:
java.io.EOFException
at com.tollbrothers.archonline.ui.bean.StaticDataLoader.postProcessBeanFactory(StaticDataLoader.java:30)
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:554)
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:545)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:363)
at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:255)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:199)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3843)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4342)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:627)
at org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:553)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:488)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1149)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at org.apache.catalina.core.StandardService.start(StandardService.java:516)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Caused by: java.rmi.ConnectException: Failure during invoke; nested exception is:
java.io.EOFException
at org.jboss.invocation.pooled.interfaces.PooledInvokerProxy.invoke(PooledInvokerProxy.java:676)
at org.jboss.invocation.InvokerInterceptor.invokeInvoker(InvokerInterceptor.java:365)
at org.jboss.invocation.MarshallingInvokerInterceptor.invoke(MarshallingInvokerInterceptor.java:63)
at org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:61)
at org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:70)
at org.jboss.proxy.ejb.HomeInterceptor.invoke(HomeInterceptor.java:184)
at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:100)
at $Proxy3.create(Unknown Source)
at com.tollbrothers.archonline.ui.bean.LookupData.connectionLocal(LookupData.java:589)
at com.tollbrothers.archonline.ui.bean.LookupData.populateStaticData(LookupData.java:126)
at com.tollbrothers.archonline.ui.bean.LookupData.populateData(LookupData.java:73)
at com.tollbrothers.archonline.ui.bean.StaticDataLoader.postProcessBeanFactory(StaticDataLoader.java:25)
... 30 more
16 years ago

Hi,

Our application is using tomcat-6.0.18 as a front end server and for backend we are using JBoss 4.0.1Sp1.
I have deployed an ejb in the jboss server and trying to access it from front end. Both the servers are running in the same local machine.
I get the following error whenever home.create(); is called from tomcat. However when the ejb remote methods are called using a simple client(public static void main) it works fine. Also instead of localhost:1099 if I am pointing to a different Jboss server it works fine.

Following is the code snippet:This code is called during startup of the server.
public void connection() throws Exception {
System.out.println("Testing EJB Connection");
Context ctx = getInitialContext();
Object objref = ctx.lookup("CRUD");
Class clazz = getHomeClass("CRUD", objref);
CRUDHome home = (CRUDHome) PortableRemoteObject.narrow(objref, clazz);
CRUDRemote crudService = home.create();
List communityStatus = crudService.search(new CommunityStatusDTO());
System.out.println("Tested EJB Connection--"+communityStatus.size());

}

private Context getInitialContext() throws Exception {
//TODO: remove hard coding.
Properties p = new Properties();
p.put("java.naming.factory.initial",
"org.jnp.interfaces.NamingContextFactory");

p.put("java.naming.provider.url", "jnp://localhost:1099");
p.put("java.naming.factory.url.pkgs",
"org.jboss.naming:org.jnp.interfaces");

return new InitialContext(p);
}

The same code snippet when invoked using a client is getting fired without any exeption.

Following is the stack trace of exception when called within Tomcat:

SEVERE: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
java.lang.RuntimeException: java.rmi.ConnectException: Failure during invoke; nested exception is:
java.io.EOFException
at com.tollbrothers.archonline.ui.bean.StaticDataLoader.postProcessBeanFactory(StaticDataLoader.java:30)
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:554)
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:545)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:363)
at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:255)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:199)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3843)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4342)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:627)
at org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:553)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:488)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1149)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at org.apache.catalina.core.StandardService.start(StandardService.java:516)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Caused by: java.rmi.ConnectException: Failure during invoke; nested exception is:
java.io.EOFException
at org.jboss.invocation.pooled.interfaces.PooledInvokerProxy.invoke(PooledInvokerProxy.java:676)
at org.jboss.invocation.InvokerInterceptor.invokeInvoker(InvokerInterceptor.java:365)
at org.jboss.invocation.MarshallingInvokerInterceptor.invoke(MarshallingInvokerInterceptor.java:63)
at org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:61)
at org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:70)
at org.jboss.proxy.ejb.HomeInterceptor.invoke(HomeInterceptor.java:184)
at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:100)
at $Proxy3.create(Unknown Source)
at com.tollbrothers.archonline.ui.bean.LookupData.connection(LookupData.java:519)
at com.tollbrothers.archonline.ui.bean.LookupData.populateStaticData(LookupData.java:89)
at com.tollbrothers.archonline.ui.bean.LookupData.populateData(LookupData.java:73)
at com.tollbrothers.archonline.ui.bean.StaticDataLoader.postProcessBeanFactory(StaticDataLoader.java:25)
... 30 more
Caused by: java.io.EOFException
at java.io.ObjectInputStream$BlockDataInputStream.peekByte(ObjectInputStream.java:2554)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1297)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
at org.jboss.invocation.pooled.interfaces.PooledInvokerProxy.invoke(PooledInvokerProxy.java:654)


Any help would be appreciated. Thanks in advance




Regards,
PremShankar N.
16 years ago

Hi,

Our application is using tomcat-6.0.18 as a front end server and for backend we are using JBoss 4.0.1Sp1.
I have deployed an ejb in the jboss server and trying to access it from front end. Both the servers are running in the same local machine.
I get the following error whenever home.create(); is called from tomcat. However when the ejb remote methods are called using a simple client(public static void main) it works fine. Also instead of localhost:1099 if I am pointing to a different server it works fine.

Following is the code snippet:This code is called during startup of the server.
public void connection() throws Exception {
System.out.println("Testing EJB Connection");
Context ctx = getInitialContext();
Object objref = ctx.lookup("CRUD");
Class clazz = getHomeClass("CRUD", objref);
CRUDHome home = (CRUDHome) PortableRemoteObject.narrow(objref, clazz);
CRUDRemote crudService = home.create();
List communityStatus = crudService.search(new CommunityStatusDTO());
System.out.println("Tested EJB Connection--"+communityStatus.size());

}

private Context getInitialContext() throws Exception {
//TODO: remove hard coding.
Properties p = new Properties();
p.put("java.naming.factory.initial",
"org.jnp.interfaces.NamingContextFactory");

p.put("java.naming.provider.url", "jnp://localhost:1099");
p.put("java.naming.factory.url.pkgs",
"org.jboss.naming:org.jnp.interfaces");

return new InitialContext(p);
}

The same code snippet when invoked using a client is getting fired without any exeption.

Following is the stack trace of exception when called within Tomcat:

SEVERE: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
java.lang.RuntimeException: java.rmi.ConnectException: Failure during invoke; nested exception is:
java.io.EOFException
at com.tollbrothers.archonline.ui.bean.StaticDataLoader.postProcessBeanFactory(StaticDataLoader.java:30)
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:554)
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:545)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:363)
at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:255)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:199)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3843)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4342)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:627)
at org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:553)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:488)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1149)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at org.apache.catalina.core.StandardService.start(StandardService.java:516)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Caused by: java.rmi.ConnectException: Failure during invoke; nested exception is:
java.io.EOFException
at org.jboss.invocation.pooled.interfaces.PooledInvokerProxy.invoke(PooledInvokerProxy.java:676)
at org.jboss.invocation.InvokerInterceptor.invokeInvoker(InvokerInterceptor.java:365)
at org.jboss.invocation.MarshallingInvokerInterceptor.invoke(MarshallingInvokerInterceptor.java:63)
at org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:61)
at org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:70)
at org.jboss.proxy.ejb.HomeInterceptor.invoke(HomeInterceptor.java:184)
at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:100)
at $Proxy3.create(Unknown Source)
at com.tollbrothers.archonline.ui.bean.LookupData.connection(LookupData.java:519)
at com.tollbrothers.archonline.ui.bean.LookupData.populateStaticData(LookupData.java:89)
at com.tollbrothers.archonline.ui.bean.LookupData.populateData(LookupData.java:73)
at com.tollbrothers.archonline.ui.bean.StaticDataLoader.postProcessBeanFactory(StaticDataLoader.java:25)
... 30 more
Caused by: java.io.EOFException
at java.io.ObjectInputStream$BlockDataInputStream.peekByte(ObjectInputStream.java:2554)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1297)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
at org.jboss.invocation.pooled.interfaces.PooledInvokerProxy.invoke(PooledInvokerProxy.java:654)


Any help would be appreciated. Thanks in advance




Regards,
PremShankar N.
16 years ago
Geetha,
try using case statements in your updates
Example:
UPDATE <tablename>
SET result = CASE
WHEN close1>avg THEN 'good'
ELSE 'bad'
END;
Senthil,
We cannot pass tables as bind variable using prepared statement..
Instead form the query string dynamically.
eg: query="select * from "+var1;
-I have list page, with set of records(An arrayList of Java Objects is iterated).
- In the list page i have check box to select few records.
- Then there is a button Print.
- On click of the button, a pop should be thrown with the list of selected(checked) records.
- Now, i have to read the selected chekboxes to identify those selected.


Since we are not submitting the page , i cant read thru request.getParameter(). The values can be read thru "opener.document.forms[0]..." How can i use those JavaScript variables for selecting the selected records only from the (Java)ArrayList.
19 years ago
JSP
Hello,
I deployed a application on WAS 5.0 on a windows XP machine. The same application was accessed thru IIS server by installing the plugin in a remote machine.(which is also a windows XP ).
To make it work, the following was done:
Installed the WAS IIS server plugin in the remote IIS server machine;copied the plugin-cfg.xml from WAS machine & pasted it to IIS server ( \websphere\Appshere\config\cells).

However, when iam tryin to access a application on WAS 5.0 on AIX server. I am unable to access the application thru IIS server.
I copied the plugin-cfg.xml generated by WAS to IIS machine and tried all the steps given in he following URL.

http://publib.boulder.ibm.com/infocenter/wasinfo/v5r0/index.jsp?topic=/com.ibm.websphere.base.doc/info/aes/ae/tins_manualWebServer.html

Am I missing something??

Thanks in advance,

Prem.
19 years ago
Hey I too passed !!! when will i get the result...

Congrats to all u guyz..

Cheers,
Prem.
19 years ago
Hi,
Could someone please tell me how to view ur test results in prometric.com.

Also for I-7 database i got a reply from '[email protected]' giving my userId and password to login. How to get the information for 'first time user section'.
Once i Login i see lot of Sun-certified exam's ; i cudnt find SCJA Beta exam in the list though SCJA 1.0 is listed there.
Could someone help me how to look my score card .

Thanks in advance,

Rgds,
Prem.
19 years ago
We have a table which holds the column headers (header table) and an other table having the corresponding values(detail table).
Here we are unable to set the width for the td's.The problem is that we should not merge both the tables.As the number of columns are dynamic, please provide a solution on how to align the columns of both the tables?
Ajith:
yeah i agree i dont have any options either...but how can u simulate the same using javascript ...(getting the modified PDF and sending it to controller from other frame)..
20 years ago
Thnks ajith, but whtever u say is jus file upload rite; U have to save it then give the path where the file is stored.. well that should be my last option.
20 years ago
well im able to view both the frames(one with pdf and other with Html). wht u mean by normal html/jsp??
Still my query is how can i submit the changed PDF along with the Html form.
20 years ago
Hi,
I am able to retrieve a document from a fileserver and show it in a browser by setting :
response.setContentType("application/pdf");
ServletOutputStream outStream = response.getOutputStream();
outStream.write(content);

I am planning to have two frames one for the PDF and other frame will have the "SUBMIT" with other input form fields.Now if im adding some comment/annotations to the PDF( using PDF writer) and submitting the page, i need to save the modifed PDF to the file server back again along with the form fields to some DB.

Could somebody reply how it can be achieved?

Rgds,
prem.
20 years ago
Hi,
thou i set my classpath to the JDBC driver(mysql-connector-java-3.0.14-production-bin.jar), im getting the following error, when im tryin to connect Database(Mysql) in applet.

cant find Database Driver class:java.lang.ClassNotFoundException:com.mysql.jdbc.Driver

Rgds,
Prem.
20 years ago