Questions tagged [servlet-3.0]

Java Servlets 3.0 is a new API that supports extensibility/pluggability, Ease of Development (EoD) using the newer language features, Async and Comet support, Security, and other features being as part of the revision for Java EE 6.

Version 3 of the servlet API adds the following to version 2.5

  • async response
  • multipart support
  • annotation configuration (no web.xml)
  • generics in the API
  • resources (including JSPs) in JARs under META-INF/resources

Links

941 questions
0
votes
1 answer

How to apply filter for one particular servlet using a servlet3.0?

I'm using servlet 3.0 but i can't specify filter for only one servlet using annotations? can anyone help me?
jmt
  • 223
  • 1
  • 8
  • 28
0
votes
1 answer

servlet 3.0 jquery comet

hi i'm attempting to implement the java servlet 3.0 chat example from [http://code.google.com/p/jquery-stream/wiki/ChatExample][1]. it runs ok on localhost, but when uploaded to a remote server the stream won't open/start or send message. what am i…
Ever Forth
  • 23
  • 4
0
votes
5 answers

Servlet 3.0 HTTP 404 - The requested resource () is not available

Environment: Ubuntu 12.04 Apache Tomcat 7.0.27 Eclipse 4.2 (Juno) Servlet 3.0 Openjdk 7 Trying to do a FileCounter with Servlet 3.0, I get this error on URL http://localhost:8080/wtp.filecounter/. Wouldn't have to be…
Joe
  • 7,749
  • 19
  • 60
  • 110
0
votes
1 answer

How to post data to logged in user from servlet without any HTTP request from user

There are number of users logged in to servlet. How to send data to specific logged in user from servlet without any HTTP request from the logged in user. Which approach i should follow. Admin once logged in to servlet can see number of users with…
user1537457
  • 109
  • 2
  • 9
0
votes
1 answer

How to keep track of logged in users with JSF2 and Servlet 3

I have a JSF login page using form authentication. I login users by calling HttpServletRequest.login(username, password). Logging out is done by first calling ExternalContext.invalidateSession() and then calling HttpServletRequest.logout() for the…
Zak
  • 359
  • 2
  • 10
0
votes
1 answer

encoding a list of key/value pairs into a URL request parameter

Is there a standard API call (or set of calls) that allows me to encode a list of key/value pairs into a SINGLE request parameter? Somehow I have never done this before. What I am looking for is to generate a URL which encodes an arbitrarily long…
AlanObject
  • 9,613
  • 19
  • 86
  • 142
0
votes
2 answers

httponly cookie web 3.0 causing unexpected timeout

Just recently, I migrated from web 2.4 to web 3.0. One of the requirements of this migration was that, I need to introduce the 'httponly' cookie in my application. So, I added the following sessionconfig element to my…
user1066568
  • 717
  • 3
  • 15
  • 32
0
votes
1 answer

Jetty servlet 3.0 and error-page

I tried to use a new servlet 3.0 feature with jetty maven plugin. org.mortbay.jetty jetty-maven-plugin 8.1.5.v20120716 part of my web.xml
Janning Vygen
  • 8,877
  • 9
  • 71
  • 102
0
votes
2 answers

Cannot get rid of #.{jsessionid} in urls

So far I have tried two approaches: -1. Add to web.xml: COOKIE -2. Using pretty faces, add to pretty-config.xml:
alehro
  • 2,198
  • 2
  • 25
  • 41
0
votes
1 answer

call a servlet's post method from another application's servlet

I want to call a servlet's POST method from another application, in which I am passing request and response. Can anyone tell me how is that possible?
0
votes
1 answer

Can't compile servlet file.

I was testing a demo servlet file But, the servlet doesn't seem to respond. I'm not able to understand the problem. When I click submit on the HTML form the URL is localhost:8080/Beer-V1/SelectBeer.do But, shouldn't it be /BeerSelect? Because…
AppSensei
  • 8,270
  • 22
  • 71
  • 99
0
votes
1 answer

Dispatch request to an Async Servlet from managed bean generate exception

when a button click, I need to have stuff running in my background, so I have a async Servlet. From my managed bean, if I do redirect, it works great (meaning that it execute my run() method inside my class that extends Runnable correctly). Like…
Thang Pham
  • 38,125
  • 75
  • 201
  • 285
0
votes
1 answer

Communication between JSP servlets (alternative to static field)

I'm implementing a serlvet that, using AsyncContext, can send messages back to the client asynchronously. Other servlets need to be able to queue up messages for the client, that are then served to the client when the browser asks for messages via…
J. Dimeo
  • 829
  • 8
  • 10
0
votes
0 answers

Is it safe to suspend a http servlet request in jersey?

Assuming a Jersey ContainerResponseFilter implementation like this: public class MyFilter implements ContainerResponseFilter { @Context HttpServletRequest request; public ContainerRersponse(ContainerRequest req, ContainerResponse resp)…
forty-two
  • 12,204
  • 2
  • 26
  • 36
0
votes
1 answer

GSON with servlet

My Folder Structure: Servlet: @WebServlet(name = "KPItoGSON", urlPatterns = {"/KPItoGSON/*"}) public class KPItoGSON extends HttpServlet { /** * Processes requests for both HTTP * GET and * POST
kinkajou
  • 3,664
  • 25
  • 75
  • 128