LoginSignup
9
2

ログインして操作が行われなくなったら、セッションを無効化したいという要件があるときに使います。

環境

Spring Boot 3.3.0

変更方法

application.properties(またはapplication.yaml)で設定する

server.servlet.session.timeout=3h
server:
  servlet:
    session:
      timeout: 3h

指定の方法は上記の通りです、
数字+単位「s(秒)」「m(分)」「h(時間)」で指定します。デフォルトは30分です。

9
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
9
2