Questions tagged [servletconfig]
37 questions
1
vote
2 answers
Error getting file name using getServletConfig
I am using JasperReport for generation reports in Java Web Application.
I have a following line to get report file.
JasperReport report = (JasperReport)…

Bhushan
- 6,151
- 13
- 58
- 91
1
vote
1 answer
spring-flex 1.5.2 JUnit test error servletContext null
My project flex 4 + spring-flex 1.5.2 + spring 3.1 + hibernate 3.6(jpa2.0),
can run in browser, but not work with JUnit4.
JUnit error:
org.springframework.beans.factory.BeanCreationException: Error creating bean with name…

codesve
- 35
- 1
- 6
1
vote
1 answer
ServletContex attribute in a clustered application environment
I have my application deployed in a cluster with two servers. When I set any attribute using:
this.getServletContext().setAttribute("test", testObj);
Will testObj attribute with key test be available to access via
both the servers?
Does number of…

Deena
- 297
- 2
- 7
- 17
1
vote
1 answer
is there any wayout to set init parameter in servletconfig or servletContext object?
if i want to modify init-parameter value in any of ServletContext or ServletConfig.
any want it to be updated after servlet is destroyed by container.
is there any wayout?

Maddy.Shik
- 6,609
- 18
- 69
- 98
0
votes
0 answers
Why HttpServletRequest object does not have getServletConfig() method?
I am new to Java Servlets and while going through one tutorial I found this.
ServletContext context = getServletContext();
When I tried using the request object to get the ServletContext object it also worked.
ServletContext context =…

Stolaine
- 25
- 4
0
votes
1 answer
servlet problem while passing values of float from one servlet to other servlet
package bhatti;
public class find extends HttpServlet {
@Override
protected void doGet(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
…

Hamza
- 13
- 3
0
votes
1 answer
Does Servlet Container create ServletConfig object if there are no init-params?
I know, that when Servlet Container instantiates Servlet object, it also creates respective ServletConfig object, where it stored all init-params for that servlet (which we can later fetch via servlet by .getServletConfig().getInitParameter(..)
My…

Giorgi Tsiklauri
- 9,715
- 8
- 45
- 66
0
votes
1 answer
JAX-RS, Spring & ServletConfig: How to access Servlet Config in Configurator
I have troubles getting a javax.servlet.ServletConfig into a class annotated with org.springframework.context.annotation.Configuration.
My team decided that we should use spring for dependency injection and I'm trying to use it to migrate one of our…

Normegil
- 157
- 1
- 2
- 9
0
votes
0 answers
ATG rest services
I tried to create a rest service in atg with following urls
/services/v1/PassbookActor/Create,\
/services/v1/PassbookActor/Register
I'm using advanced rest client to run the webservices.
When i execute create url, I'm getting the output correctly…
0
votes
0 answers
Exception report when this.getServletConfig() if I have ServletConfig member variable
When I run :
Enumeration enums = this.getServletConfig().getInitParameterNames();
I get the HTTP Status 500 error in my broswer.
HTTP Status 500 -
type Exception report
message
description The server encountered an internal error that…

aircraft
- 25,146
- 28
- 91
- 166
0
votes
1 answer
How are ServletConfig and ServletContext Objects created
In Servlets we have ServletConfig and ServletContext. Going through the API i see that both are interfaces. Following are my doubts
1.ServletConfig and ServletContext are interfaces, how are these object created if they are interfaces?
2.Is that the…

Avinash Reddy
- 2,204
- 3
- 25
- 44
0
votes
2 answers
calling normal java class from servlet
Every time im trying to access a normal java class from servlet (from other project) it gives me classNotFound exception, any idea how to fix this problem
thanks in advance

Mohd_Q
- 61
- 3
- 10
0
votes
2 answers
ServletConfig with out xml configuration in jsp?
How to set ServeltConfig param name and value in index.jsp page with out xml configuration like initParams in Servlet ? is Possible ?
welcome
/index.jsp
…

Balaji
- 21
- 5
0
votes
1 answer
How getServletName() works in Java?
Out of curiosity I was looking at the HttpServlet class's code and found that its parent class "GenericServlet" defines the method "getServletName()" declared in the interface "ServletConfig".
However the GenericServlet's getServletName() method…

Shubhankit Roy
- 39
- 9
0
votes
1 answer
How to get ServeletConfig in Jersey Provider?
So I have a Jersey REST service and I need to get access to a ServletConfig so that I can pull a param out of the web.xml. I can use @Context to wire one in but I don't think it will get me the params I need. Only the ones in the ServletContext.…

user447607
- 5,149
- 13
- 33
- 55