Aditya Narayan

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

Recent posts by Aditya Narayan

HI All,
Is there a way to allow user to modify the web flow of a running application in spring using spring web flow. Let me know any reference, or related solutions.
8 years ago
Thanks Morgan, I will try to implement it and let you know . It was great help to give me some starting points. Thanks again.
9 years ago
Hi All,
I have come across a requirement in project:
1. Reading of pathological images (input file in .tif format of around 500 mb or more size)
2. This has to be read by doctors on go (so mobile app may be apt)
3. Feature to compare two such images (one of the patient , and another of the normal sized person).
I am open to all suggestions, but primarily i think of something like google map, where the image is always expandable and can be zoomed to very minute details. I have googled for google map logic of satellite images , with such details. I wasn't able to get much information.
I would request some suggestions if someone has some experience. Any idea is welcomed .
9 years ago
Hi All,
After working through all this, I am stuck to a point where I learn that jsp cannot be explicitly made as a listener. Would appreciate some help.
@ Ulf Dittmer
Well if I am trying to implement observer pattern of java in servlet jsp, I would really look forward to implement the required interface. This is a practical scenario I am currently working on.
11 years ago
JSP
Hi Ramu Karnati,
Your question seems apt .

Hi William Brogden ,
Just consider a scenario where this event listener is not about the client based event(browser events), but may be because of the servlet events. Think , as jsp is eventually converted to servlets. Since servlets support the various event listeners like session, servlet context etc events. So the question is correctly asked whether a jsp(which converts to servlet) may also act as an event listener like servlets do for the aforesaid events.
11 years ago
JSP
Hi All,
Currently I am working on a web application on BEA Weblogic10.3.4 and ejb3.0. I need to send a pop up warning after 20 min if inactive and then invalidate the session after 30th min if continue to be inactive.
I would need some guidance here. I have a set of ideas.
1. Pick up the interceptor concept ,
2. start ejb timer for each session call ,
3. and if time reaches 20 min being inactive ,fire an event which JSP is listening to,
4. and alert the user with a pop.
5. If still no response comes for next 10 min, invalidate the session.
6. If response comes, reset the timer.

Well this is a complex way of achieving the goal. It would be kindful , if someone can come with something much simpler.
Regards,
Aditya
Dear Vincent.
I had similar problem. I reconfigured the settings.xml file too.But nothing worked till i switched off the windows firewall . After that the things were working smoothly
12 years ago
Hi I just found that I needed to set an extra property after which my project run succesfully .
The property set is as follows :

Properties prop = new Properties();
prop.setProperty(Context.INITIAL_CONTEXT_FACTORY,"org.jnp.interfaces.NamingContextFactory");
prop.setProperty(Context.URL_PKG_PREFIXES, "org.jboss.naming.client");
prop.setProperty(Context.PROVIDER_URL, "jnp://localhost:1099");
prop.setProperty("j2ee.clientName", "ANSessionBeanClient"); //on adding this my project is running succesfully


On searching on web I found out at here the usage of this
Dear All,
I am new to EJB and working for it.
I have created two projects ANSessionBean and ANSessionBeanClient.
After deploying my ANSessionBean to Jboss6.1, I am trying to run ANSessionBeanClient.java from ANSessionBeanClient project , then I am getting an exception in the main thread which is

Exception in thread "main" javax.naming.CommunicationException: Receive timed out [Root exception is java.net.SocketTimeoutException: Receive timed out]
at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:1690)
at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1812)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:695)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:688)
at javax.naming.InitialContext.lookup(Unknown Source)
at ANSessionBeanClient.main(ANSessionBeanClient.java:10)
Caused by: java.net.SocketTimeoutException: Receive timed out
at java.net.PlainDatagramSocketImpl.receive0(Native Method)
at java.net.PlainDatagramSocketImpl.receive(Unknown Source)
at java.net.DatagramSocket.receive(Unknown Source)
at org.jnp.interfaces.NamingContext.discoverServer(NamingContext.java:1659)
... 5 more


I dont know how to solve this problem .

The sessionBean class is as follows:
package org.anc.com;


import javax.ejb.Stateless;

@Stateless
public class ANSessionBean implements ANSessionBeanRemote,ANSessionBeanLocal {

/**
*
*/
private static final long serialVersionUID = 1L;

@Override
public void anSessionBeanMethod() {
System.out.println("anSessionBeanMethod Executed");

}

}


and the client is

import java.util.Properties;
import javax.naming.Context;
import javax.naming.InitialContext;
import javax.naming.NamingException;

import org.anc.com.ANSessionBeanRemote;
public class ANSessionBeanClient {
public static void main(String[] args) throws NamingException {
Context context=ANSessionBeanClient.getContext();
ANSessionBeanRemote anSessionBean=(ANSessionBeanRemote)context.lookup("ANSessionBean/remote");
anSessionBean.anSessionBeanMethod();
}
public static Context getContext() throws NamingException{
Properties properties =new Properties();
properties.setProperty("java.naming.factory.initial", "org.jnp.interfaces.NamingContextFactory");
properties.setProperty( "java.naming.factory.url.pkgs", "org.jboss.naming:org.jnp.interfaces");
properties.setProperty("javax.naming.provider.url", "jnp://localhost:1099");
return new InitialContext(properties);
}


}
Hi PeroZ ,
I just passed this exam on 24 Nov,2012 and finished within an hour time. There are only two types of questions ,either you know the answe or you dont. So it wont take much time . If you get confused then only the time is consumed. So study well and you will get good score .
Hi Sanjay ,
As Frits Walraven correctly told , when you are forwarding the request using request dispatcher , donot play with the response. The purpose of request dispatcher is that if the current servlet or jsp cannot handle the task on its own, delegate it to another jsp or even servlet using request dispatcher . Hence let the target jsp or servlet create the required response. Yeah there are absurdities produced when you try to work otherwise.
Hi Alejandro Herrera,
Well I think you might like to visit the below link:

https://coderanch.com/t/592844/java-Web-Component-SCWCD/certification/OCWCD-information-required

Actually HDFS claims to be for version 1.5 but at some places they have older examples of V1.4 . So it not a complete reference at all for SCWCD5.
Hi Meghna,
Sorry for late reply. I have just passed SCWCD5. There are few reasons why I choose SCWCD5 instead of SCWCD6 . First I want to go for furthur certifications like SCBCD5 which consists of both EJB3.0 and JPA1.0. The preparation material is also available for this exam. Besides, my project in office also is on J2EE 1.5 .Thats why. But before taking the exam I have done some research. I would like to share the result.
The equivalent exam of 1z0-858(SCWCD5) was 1Z0-894 which has been discontinued and new exam is 1Z0-899. Name might be misnomer and people often get confused in keywords, professional and expert but here in this case they are the same.

The topics which are added in SCWCD6 are-

More options for the Model
Understand the roles of JDBC and JPA
Understand the many elements that make up the model
Understand fundamentals of connecting to a database using JDBC or JPA

Asynchronous web applications
Understand the interactions that are essential to asynchronous web pages
Understand the role of AJAX-style client side programming
Implement asynchronous servlets using the facilities of Java EE 6

Understand the role of JAAS in pluggable/extensible authentication for web applications


Manning Servlet in action book for SCWCD is a good preparation material. Well some of these materials are available in black book for j2ee 6 and rest on Google. Hope you find this reply useful. If any furthur querries , I would imeediately respond. Please mail or reply here .
Thanks to all of u.
12 years ago