Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 624637
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T19:13:19+00:00 2026-05-13T19:13:19+00:00

Building a JSF application with Spring on Tomcat. The target is a web farm,

  • 0

Building a JSF application with Spring on Tomcat. The target is a web farm, and the client has requested that we design our application so that it can be load balanced without relying on “sticky sessions” in the LB.

In .NET, you can configure the session store to be SQL Server or the ASP.NET State Service. What alternatives are there in the Java world? Is there a standard way to plug in a different session state store that points to a MySQL database for example? Does Spring provide any hooks?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T19:13:20+00:00Added an answer on May 13, 2026 at 7:13 pm

    This is servletcontainer specific which in this case is Tomcat. The servletcontainer is the one which manages and provides the sessions. So JSF and Spring have nothing to do here. They just transparently gets it from the servletcontainer by request.getSession() and so on.

    In Tomcat, you can provide a custom session manager implementation in the webapp’s Context:

    <Context ...>
        <Manager className="com.example.SessionManager">
    

    ..where com.example.SessionManager implements org.apache.catalina.Manager as per its contract. Therein you can write code to back the sessions by a database.

    However, there are alternatives for your particular requirement, you can choose for Tomcat’s builtin clustering/session-replication capabilities instead of reinventing it with a custommade manager/database. Read more about it at the Tomcat Clustering/Session Replication HOW-TO.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 307k
  • Answers 307k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer The oldest question asked by adopters of XML is when… May 13, 2026 at 9:33 pm
  • Editorial Team
    Editorial Team added an answer 1: -sh-3.00$ ps auxww|egrep "(http|apache)" root 8074 0.0 0.3 14236… May 13, 2026 at 9:33 pm
  • Editorial Team
    Editorial Team added an answer I would recommend following approach which I feel is simple… May 13, 2026 at 9:33 pm

Related Questions

I'm building a JSF+Facelets web app, one piece of which is a method that
We are in the process of re-evaluating our usage of JSF (brought in before
Soon I will have to start a web project for a company, and I
A friend and I are building a fairly complex website based on java. (PHP
I've been writing Java web (JSF, Struts, JSR168) apps for a number of years.

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.