Questions tagged [context-param]

`context-param` tag is used in the web application configuration file `web.xml` to set a context parameter to the application context.

context-param tag is used in the web application configuration file web.xml to set a context parameter to the application context.

The web components in a web module share an object that represents their application context. It's used to pass context parameters to the context, or initialization parameters to a servlet. Context parameters are available to all components of a web application, but initialization parameters provide data needed by a particular servlet.

27 questions
36
votes
1 answer

Overview of all JSF-related web.xml context parameter names and values

There are several JavaServer Faces in web.xml: facelets.REFRESH_PERIOD, facelets.DEVELOPMENT, facelets.SKIP_COMMENTS etc. Where I can find a complete list of all those params?
Cherry
  • 31,309
  • 66
  • 224
  • 364
13
votes
1 answer

Servlet-spec: vs in web.xml?

Why does the Servlet specification define two distinct ways (context parameters and environment entries) to provide a web application with configuration parameters? What are the respective advantages of these approaches (when should which be…
meriton
  • 68,356
  • 14
  • 108
  • 175
8
votes
2 answers

How to configure programmatically without web.xml

Is there any other way to configure a context parameter excluding the one which uses web.xml as in the below example? com.sun.faces.numberOfLogicalViews
HappyMeal
  • 81
  • 1
  • 4
4
votes
1 answer

How to edit web.xml context param in Websphere console

I have made a web application to be deployed in the Websphere server but i came up with a problem. I have 20 servlets that use a common parameter so i have this declared on web.xml: filePath
4
votes
1 answer

Context-params use inside the web.xml

Is there a way to use the context-params inside the web.xml example AUTH_SERVER 10.126.35.10 ... NtlmHttpFilter
Apostelis
  • 65
  • 6
3
votes
1 answer

How to define context parameters in the WebSphere config, instead of the web.xml?

With Tomcat, with a placed inside a (e.g. in Tomcat's server.xml), it is possible to define context parameters for a web app outside of the web app itself, i.e. without having to change the web.xml. This is convenient in cases…
avernet
  • 30,895
  • 44
  • 126
  • 163
2
votes
1 answer

JSP: getting context-param in JSP doesnt work

I have my web.xml file where i define the context-param and then i want to get the value from the variable in my jsp-file. so i tried ${initParam.variablename} but the ouput is empty. the xml file
bonbon
  • 243
  • 4
  • 11
2
votes
4 answers

How to put two param-values in one context-param in Spring?

Problem: I have two contextConfigLocation parameters, one with @Configuration classes for spring-social-facebook and one with xml-file for app: contextConfigLocation
uncle Lem
  • 4,954
  • 8
  • 33
  • 53
1
vote
1 answer

Define context parameters in different way than web.xml

Let's say I have servlet based web application which uses web.xml to define context parameters:
Patrik Mihalčin
  • 3,341
  • 7
  • 33
  • 68
1
vote
0 answers

Migration from tomcat to wildfly

I am migrating my web application from tomcat to wildfly. I was able to deploy the app using a temporary workaround of placing the configurations inside the WEB-INF/web.xml (). But I wanted it outside my war file. Is there any equivalent for…
Aparna
  • 11
  • 1
1
vote
1 answer

bind data source to Context Parameters in Web Performance Test using Visual Studio?

I have a web performance test which tests an API. My API has Context parameters for which I would like to fetch values form database. I can find how to fetch/bind values to Form Post parameters, but I need for Context Parameters. Please help me in…
1
vote
2 answers

How to acces other servlet's init-parameters or context's contex-parameters inside quartz jobs?

I have defined my quartz job with the XML jobs configuration as in here example 2 http://www.mkyong.com/java/example-to-run-multiple-jobs-in-quartz/ I have other servlets wich have some init-params and my web app also has some context-params. How…
user494461
1
vote
1 answer

Split web.xml context-param into separate config file

I have too many context-parameters inside web.xml, which I would like to put in a separate config-file. ..... SYSTEM.UPLOADS.DIR
Rami.Q
  • 2,486
  • 2
  • 19
  • 30
1
vote
2 answers

Context Parameters value not string

Let's say you write a Deployment Descriptor with some context parameters and you want one of them to be an object,unfortunatelly I read that you cand only add string values to the tag. Is there a way to do this?I understood an example when it came…
tudoricc
  • 709
  • 1
  • 12
  • 31
0
votes
0 answers

How to initialize context parameters in Spring Boot?

I need to set a context param on startup. @Bean public ServletContextInitializer initializer() { return new ServletContextInitializer() { @Override public void onStartup(ServletContext servletContext) throws ServletException { …
1
2