j2ee

Including JSP multiple HEAD section

HI I would like to include a jsp page into another jsp. Let's say that I have master.jsp that is including slave.jsp. Since slave.jsp has its own set of section for dealing with Javascript and CSS. Is there a way or maybe another method to merge the master/slave HEADs section into one ? There will be also the same issue with the BODY...

Is it possible to architect the web component tier in J2EE to support different client types?

How can you architect the web component tier in J2EE to support different client types? ...

Brand new to gwt

Can you go from module to module with gwt. For instance when you click to submit login information can you get rid of that ui and go to a new ui for whatever your app happens to do? Also are there any books or tutorials anyone recommends? I have a good understanding of how the ui structures work, but am confused when it comes to things...

How to add a persistence unit in jndi for ejb modules

Hi! I am working on a simple ejb module, sample code where i am trying to implement CURD operation through a SOAP webservice. My problem is like this. I have a persistence unit defined in persistence.xml file. Here is the code for my implementation. The problem is that I cannot create the instance of PersistenceService class since, th...

HttpSession.setMaxInactiveInterval not working in Tomcat 6

I'm trying to adjust the session timeout using HttpSession.setMaxInactiveInterval and it's not working. Here is my code (Groovy), which is executing without exceptions: def paramValue = WebAttributes.REQUEST.getParameter('maxInactiveSeconds'); println 'paramValue=' + paramValue; if (paramValue != null) { def seconds = Integer.parseIn...

GWT extending DecoratorPanel and adding to rootPanel

I am new to using gwt, although I am starting to get the hang of things. One perplexing situation I came across today was the following. (This is abbreviated to simplify my question) public class MyPanel extends DecoratorPanel{ public MyPanel(){ final TextBox tb = new TextBox(); tb .setText("test"); this.add(tb); ...

HttpServletRequest.getRemotePort()

How could a possible vendor implementation of HttpServletRequest.getRemotePort() get the remote port ? Is it parsed from the actual request sent ? I could not see any request headers like "Client-port", "Request-port" or the like. ...

Deliver JMS message to all nodes in the cluster in Weblogic

Is there a way to configure WebLogic 9.x cluster to receive a JMS message on a single JMS queue address from remote client and that the message is delivered to each cluster node? Any links would be great. ...

gwt access rootpanel from outside of onModuleLoad

I can use removeFromParent to get rid of something on the RootPanel from a class that doesnt have onModuleLoad in it. However, can you add a widget to the RootPanel from another class? I cannot figure out how to do so. So for example: public classA extends EntryPoint{ public void onModuleLoad(){ MyPanel panel = new MyPanel(); RootPan...

code review ExecutorService usage correct?

List sychronizedList = Collections.synchronizedList(new ArrayList()); //is this ok? try { ExecutorService executor = Executors.newFixedThreadPool(10); for (final Object item : fromCollection) { executor.submit(new ARunnableClass(sychronizedList)); } executor.shutdown(); //do i need this ...

Why should javax.servlet.GenericServlet implement javax.servlet.ServletConfig ?

I was having a look through the servlet-api.jar source code and found out (to my utter bewilderment) that javax.servlet.GenericServlet implements javax.servlet.ServletConfig. Now, I don't boast to be an OOP scholar, but I do remember reading that although OOP provides the concept of inheritance, inheritance as a feature should be applie...

Pure Java app on Glassfish?

I may be barking up the wrong tree here -- it's relatively easy to wrap a vanilla Java app in a daemon/service -- but it'd be really helpful for deployment if we could push pure Java apps onto a Glassfish server and have them start up automatically. We use JMS to connect this app to several other beans living on the Glassfish server. We...

Can fatwire run on tomcat?

Currently running fatwire on weblogic, would it be easy to port it to to tomcat, does it require J2EE? If not tomcat how about Jboss? ...

How to get original page url/uri after request dispatcher forward

I have a Error404Servlet which is configured as error-page for 404 in web.xml: <servlet> <servlet-name>Error404</servlet-name> <servlet-class>com.foo.bar.Error404Servlet</servlet-class> </servlet> <error-page> <error-code>404</error-code> <location>/error404</location> </error-page> In this servlet...

RequestDispatcher.forward() versus RequestDispatcher.include()

Hi, I have observed that while RequestDispatcher.forward(request, response) can throw an IllegalStateException (if the response is committed) , RequestDispatcher.include(request, response) does not throw an IllegalStateException(even if the response was committed before). I have verified this on Tomcat 6.0.20. I am aware that the incl...

handling forms and textbox for multiple button

As you can see here that I have a text box with three submit buttons each redirecting to a different jsp page, however in those jsp pages, when I do request.getParameter("bid"), all I get is null... How can I fix this the simplest way possible? <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtm...

How is HttpSession implemented?

I just finished taking a final exam on web applications. Capping off what had been a rather easy (albeit lengthy - 12 pages) exam was a question asking us to code an implementation of sessions, similar to that done by javax.http.HttpSession. I hate to admit, it stumped me. I cranked out a rather BS implemetation using a HashMap and did...

HibernateTemplate Composite Key fetching value null

Hello All... I have one table that has composite key 'rid' and 'sid'. For that i have made following beans to map with hibernate annotations : WBList.java ============ @Entity @IdClass(WBListPK.class) public class WBList { private int rid; private int sid; private String wb; @Id @JoinColumn(name="rid") public ...

Weblogic application complains about some classes missing, how to debug?

I have a rather complex J2EE app I don't have any documentation for and I am trying to get it to run. I have gotten the ant build script to compile a EAR file that contains a WAR file, but this application even though I get "successfully deployed" on weblogic console is still not working. There are many required jars missing from the...

Getting Hibernate Exception : org.hibernate.QueryException: could not resolve property

Hello All... I have one table with composite key attribute.. For that i have made 2 beans for hibernate annotations mappings.. Now, it works fine for save, update and delete.. But when I am fetching using some criteria, it's giving me "could not resolve property" exception. My Beans are as follows : WBList.java @Entity public clas...