{"action":"created","comment":{"url":"https://api.github.com/repos/spring-projects/spring-boot/pulls/comments/56962783","id":56962783,"diff_hunk":"@@ -0,0 +1,47 @@\n+/*\n+ * Copyright 2012-2016 the original author or authors.\n+ *\n+ * Licensed under the Apache License, Version 2.0 (the \"License\");\n+ * you may not use this file except in compliance with the License.\n+ * You may obtain a copy of the License at\n+ *\n+ *      http://www.apache.org/licenses/LICENSE-2.0\n+ *\n+ * Unless required by applicable law or agreed to in writing, software\n+ * distributed under the License is distributed on an \"AS IS\" BASIS,\n+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+ * See the License for the specific language governing permissions and\n+ * limitations under the License.\n+ */\n+\n+package org.springframework.boot.autoconfigure.session;\n+\n+/**\n+ * Supported Spring Session data store types.\n+ *\n+ * @author Tommy Ludwig\n+ * @since 1.4.0\n+ */\n+public enum SessionStoreType {\n+\n+\t/**\n+\t * Redis backed sessions.\n+\t */\n+\tREDIS,\n+\n+\t/**\n+\t * Hazelcast backed sessions.\n+\t */\n+\tHAZELCAST,\n+\n+\t/**\n+\t * Simple in-memory map of sessions.\n+\t */\n+\tSIMPLE,","path":"spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/session/SessionStoreType.java","position":40,"original_position":40,"commit_id":"a437c2895c60ae4fe94e4c3d7628ce98a0e8ab9e","original_commit_id":"a437c2895c60ae4fe94e4c3d7628ce98a0e8ab9e","user":{"login":"snicoll","id":490484,"avatar_url":"https://avatars.githubusercontent.com/u/490484?v=3","gravatar_id":"","url":"https://api.github.com/users/snicoll","html_url":"https://github.com/snicoll","followers_url":"https://api.github.com/users/snicoll/followers","following_url":"https://api.github.com/users/snicoll/following{/other_user}","gists_url":"https://api.github.com/users/snicoll/gists{/gist_id}","starred_url":"https://api.github.com/users/snicoll/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/snicoll/subscriptions","organizations_url":"https://api.github.com/users/snicoll/orgs","repos_url":"https://api.github.com/users/snicoll/repos","events_url":"https://api.github.com/users/snicoll/events{/privacy}","received_events_url":"https://api.github.com/users/snicoll/received_events","type":"User","site_admin":false},"body":"I like simple as well: it denotes the fact that it's not using any of the 3rd party back-ends.","created_at":"2016-03-22T10:18:23Z","updated_at":"2016-03-22T10:18:23Z","html_url":"https://github.com/spring-projects/spring-boot/pull/5158#discussion_r56962783","pull_request_url":"https://api.github.com/repos/spring-projects/spring-boot/pulls/5158","_links":{"self":{"href":"https://api.github.com/repos/spring-projects/spring-boot/pulls/comments/56962783"},"html":{"href":"https://github.com/spring-projects/spring-boot/pull/5158#discussion_r56962783"},"pull_request":{"href":"https://api.github.com/repos/spring-projects/spring-boot/pulls/5158"}}},"pull_request":{"url":"https://api.github.com/repos/spring-projects/spring-boot/pulls/5158","id":59474022,"html_url":"https://github.com/spring-projects/spring-boot/pull/5158","diff_url":"https://github.com/spring-projects/spring-boot/pull/5158.diff","patch_url":"https://github.com/spring-projects/spring-boot/pull/5158.patch","issue_url":"https://api.github.com/repos/spring-projects/spring-boot/issues/5158","number":5158,"state":"open","locked":false,"title":"Spring Session auto-configuration expansion","user":{"login":"shakuzen","id":8924140,"avatar_url":"https://avatars.githubusercontent.com/u/8924140?v=3","gravatar_id":"","url":"https://api.github.com/users/shakuzen","html_url":"https://github.com/shakuzen","followers_url":"https://api.github.com/users/shakuzen/followers","following_url":"https://api.github.com/users/shakuzen/following{/other_user}","gists_url":"https://api.github.com/users/shakuzen/gists{/gist_id}","starred_url":"https://api.github.com/users/shakuzen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shakuzen/subscriptions","organizations_url":"https://api.github.com/users/shakuzen/orgs","repos_url":"https://api.github.com/users/shakuzen/repos","events_url":"https://api.github.com/users/shakuzen/events{/privacy}","received_events_url":"https://api.github.com/users/shakuzen/received_events","type":"User","site_admin":false},"body":"This implementation was inspired in large part by the cache auto-configuration.\r\nIn addition to the originally supported Redis, now Hazelcast, an in-memory `ConcurrentHashMap`,\r\nas well as a no-op (disabled) option are supported. It should be easy to extend this to\r\ninclude additional data stores in the future.\r\n\r\nI wanted to open this before writing tests and updating any documentation to get feedback on the approach here. Is this approach what the Spring Boot team has in mind for supporting additional data stores for the auto-configuration of Spring Session?\r\n\r\nI have done testing using [this sample project](https://github.com/shakuzen/session-auto-sample) and checking the data (or lack thereof) in Redis / Hazelcast. You can change the Spring Session implementation used via `spring.session.store-type` and/or what's on the classpath.\r\n\r\nSome discussion points I think might come up: the session timeout uses `ServerProperties` but the data store type is in `SessionProperties`. Should the timeout move to the `spring.session` namespace?\r\nShould we try to support auto-configuring a user-provided `MapSessionRepository` bean?\r\n\r\nTODO:\r\n- [ ] Write tests\r\n- [ ] Update documentation\r\n\r\nRelated #4508 \r\nResolves #3811 \r\n\r\n/cc @rwinch \r\n\r\nI have signed the CLA.","created_at":"2016-02-16T10:58:12Z","updated_at":"2016-03-22T10:18:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"46423cc79fd0880040d83b1fceab259351c0a64d","assignee":{"login":"snicoll","id":490484,"avatar_url":"https://avatars.githubusercontent.com/u/490484?v=3","gravatar_id":"","url":"https://api.github.com/users/snicoll","html_url":"https://github.com/snicoll","followers_url":"https://api.github.com/users/snicoll/followers","following_url":"https://api.github.com/users/snicoll/following{/other_user}","gists_url":"https://api.github.com/users/snicoll/gists{/gist_id}","starred_url":"https://api.github.com/users/snicoll/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/snicoll/subscriptions","organizations_url":"https://api.github.com/users/snicoll/orgs","repos_url":"https://api.github.com/users/snicoll/repos","events_url":"https://api.github.com/users/snicoll/events{/privacy}","received_events_url":"https://api.github.com/users/snicoll/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/spring-projects/spring-boot/milestones/58","html_url":"https://github.com/spring-projects/spring-boot/milestones/1.4.0.M2","labels_url":"https://api.github.com/repos/spring-projects/spring-boot/milestones/58/labels","id":1489613,"number":58,"title":"1.4.0.M2","description":"","creator":{"login":"philwebb","id":519772,"avatar_url":"https://avatars.githubusercontent.com/u/519772?v=3","gravatar_id":"","url":"https://api.github.com/users/philwebb","html_url":"https://github.com/philwebb","followers_url":"https://api.github.com/users/philwebb/followers","following_url":"https://api.github.com/users/philwebb/following{/other_user}","gists_url":"https://api.github.com/users/philwebb/gists{/gist_id}","starred_url":"https://api.github.com/users/philwebb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/philwebb/subscriptions","organizations_url":"https://api.github.com/users/philwebb/orgs","repos_url":"https://api.github.com/users/philwebb/repos","events_url":"https://api.github.com/users/philwebb/events{/privacy}","received_events_url":"https://api.github.com/users/philwebb/received_events","type":"User","site_admin":false},"open_issues":74,"closed_issues":54,"state":"open","created_at":"2016-01-07T14:25:32Z","updated_at":"2016-03-22T07:32:58Z","due_on":"2016-03-29T23:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/spring-projects/spring-boot/pulls/5158/commits","review_comments_url":"https://api.github.com/repos/spring-projects/spring-boot/pulls/5158/comments","review_comment_url":"https://api.github.com/repos/spring-projects/spring-boot/pulls/comments{/number}","comments_url":"https://api.github.com/repos/spring-projects/spring-boot/issues/5158/comments","statuses_url":"https://api.github.com/repos/spring-projects/spring-boot/statuses/a437c2895c60ae4fe94e4c3d7628ce98a0e8ab9e","head":{"label":"shakuzen:session-autoconfig-enhance","ref":"session-autoconfig-enhance","sha":"a437c2895c60ae4fe94e4c3d7628ce98a0e8ab9e","user":{"login":"shakuzen","id":8924140,"avatar_url":"https://avatars.githubusercontent.com/u/8924140?v=3","gravatar_id":"","url":"https://api.github.com/users/shakuzen","html_url":"https://github.com/shakuzen","followers_url":"https://api.github.com/users/shakuzen/followers","following_url":"https://api.github.com/users/shakuzen/following{/other_user}","gists_url":"https://api.github.com/users/shakuzen/gists{/gist_id}","starred_url":"https://api.github.com/users/shakuzen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shakuzen/subscriptions","organizations_url":"https://api.github.com/users/shakuzen/orgs","repos_url":"https://api.github.com/users/shakuzen/repos","events_url":"https://api.github.com/users/shakuzen/events{/privacy}","received_events_url":"https://api.github.com/users/shakuzen/received_events","type":"User","site_admin":false},"repo":{"id":35470823,"name":"spring-boot","full_name":"shakuzen/spring-boot","owner":{"login":"shakuzen","id":8924140,"avatar_url":"https://avatars.githubusercontent.com/u/8924140?v=3","gravatar_id":"","url":"https://api.github.com/users/shakuzen","html_url":"https://github.com/shakuzen","followers_url":"https://api.github.com/users/shakuzen/followers","following_url":"https://api.github.com/users/shakuzen/following{/other_user}","gists_url":"https://api.github.com/users/shakuzen/gists{/gist_id}","starred_url":"https://api.github.com/users/shakuzen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shakuzen/subscriptions","organizations_url":"https://api.github.com/users/shakuzen/orgs","repos_url":"https://api.github.com/users/shakuzen/repos","events_url":"https://api.github.com/users/shakuzen/events{/privacy}","received_events_url":"https://api.github.com/users/shakuzen/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/shakuzen/spring-boot","description":"Spring Boot","fork":true,"url":"https://api.github.com/repos/shakuzen/spring-boot","forks_url":"https://api.github.com/repos/shakuzen/spring-boot/forks","keys_url":"https://api.github.com/repos/shakuzen/spring-boot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/shakuzen/spring-boot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/shakuzen/spring-boot/teams","hooks_url":"https://api.github.com/repos/shakuzen/spring-boot/hooks","issue_events_url":"https://api.github.com/repos/shakuzen/spring-boot/issues/events{/number}","events_url":"https://api.github.com/repos/shakuzen/spring-boot/events","assignees_url":"https://api.github.com/repos/shakuzen/spring-boot/assignees{/user}","branches_url":"https://api.github.com/repos/shakuzen/spring-boot/branches{/branch}","tags_url":"https://api.github.com/repos/shakuzen/spring-boot/tags","blobs_url":"https://api.github.com/repos/shakuzen/spring-boot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/shakuzen/spring-boot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/shakuzen/spring-boot/git/refs{/sha}","trees_url":"https://api.github.com/repos/shakuzen/spring-boot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/shakuzen/spring-boot/statuses/{sha}","languages_url":"https://api.github.com/repos/shakuzen/spring-boot/languages","stargazers_url":"https://api.github.com/repos/shakuzen/spring-boot/stargazers","contributors_url":"https://api.github.com/repos/shakuzen/spring-boot/contributors","subscribers_url":"https://api.github.com/repos/shakuzen/spring-boot/subscribers","subscription_url":"https://api.github.com/repos/shakuzen/spring-boot/subscription","commits_url":"https://api.github.com/repos/shakuzen/spring-boot/commits{/sha}","git_commits_url":"https://api.github.com/repos/shakuzen/spring-boot/git/commits{/sha}","comments_url":"https://api.github.com/repos/shakuzen/spring-boot/comments{/number}","issue_comment_url":"https://api.github.com/repos/shakuzen/spring-boot/issues/comments{/number}","contents_url":"https://api.github.com/repos/shakuzen/spring-boot/contents/{+path}","compare_url":"https://api.github.com/repos/shakuzen/spring-boot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/shakuzen/spring-boot/merges","archive_url":"https://api.github.com/repos/shakuzen/spring-boot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/shakuzen/spring-boot/downloads","issues_url":"https://api.github.com/repos/shakuzen/spring-boot/issues{/number}","pulls_url":"https://api.github.com/repos/shakuzen/spring-boot/pulls{/number}","milestones_url":"https://api.github.com/repos/shakuzen/spring-boot/milestones{/number}","notifications_url":"https://api.github.com/repos/shakuzen/spring-boot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/shakuzen/spring-boot/labels{/name}","releases_url":"https://api.github.com/repos/shakuzen/spring-boot/releases{/id}","deployments_url":"https://api.github.com/repos/shakuzen/spring-boot/deployments","created_at":"2015-05-12T06:28:48Z","updated_at":"2016-01-26T07:58:27Z","pushed_at":"2016-02-16T10:52:44Z","git_url":"git://github.com/shakuzen/spring-boot.git","ssh_url":"git@github.com:shakuzen/spring-boot.git","clone_url":"https://github.com/shakuzen/spring-boot.git","svn_url":"https://github.com/shakuzen/spring-boot","homepage":"http://projects.spring.io/spring-boot","size":33457,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"spring-projects:master","ref":"master","sha":"89b7704977c0b32aa1c8cce2db1a3351ea2e6e55","user":{"login":"spring-projects","id":317776,"avatar_url":"https://avatars.githubusercontent.com/u/317776?v=3","gravatar_id":"","url":"https://api.github.com/users/spring-projects","html_url":"https://github.com/spring-projects","followers_url":"https://api.github.com/users/spring-projects/followers","following_url":"https://api.github.com/users/spring-projects/following{/other_user}","gists_url":"https://api.github.com/users/spring-projects/gists{/gist_id}","starred_url":"https://api.github.com/users/spring-projects/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/spring-projects/subscriptions","organizations_url":"https://api.github.com/users/spring-projects/orgs","repos_url":"https://api.github.com/users/spring-projects/repos","events_url":"https://api.github.com/users/spring-projects/events{/privacy}","received_events_url":"https://api.github.com/users/spring-projects/received_events","type":"Organization","site_admin":false},"repo":{"id":6296790,"name":"spring-boot","full_name":"spring-projects/spring-boot","owner":{"login":"spring-projects","id":317776,"avatar_url":"https://avatars.githubusercontent.com/u/317776?v=3","gravatar_id":"","url":"https://api.github.com/users/spring-projects","html_url":"https://github.com/spring-projects","followers_url":"https://api.github.com/users/spring-projects/followers","following_url":"https://api.github.com/users/spring-projects/following{/other_user}","gists_url":"https://api.github.com/users/spring-projects/gists{/gist_id}","starred_url":"https://api.github.com/users/spring-projects/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/spring-projects/subscriptions","organizations_url":"https://api.github.com/users/spring-projects/orgs","repos_url":"https://api.github.com/users/spring-projects/repos","events_url":"https://api.github.com/users/spring-projects/events{/privacy}","received_events_url":"https://api.github.com/users/spring-projects/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/spring-projects/spring-boot","description":"Spring Boot","fork":false,"url":"https://api.github.com/repos/spring-projects/spring-boot","forks_url":"https://api.github.com/repos/spring-projects/spring-boot/forks","keys_url":"https://api.github.com/repos/spring-projects/spring-boot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/spring-projects/spring-boot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/spring-projects/spring-boot/teams","hooks_url":"https://api.github.com/repos/spring-projects/spring-boot/hooks","issue_events_url":"https://api.github.com/repos/spring-projects/spring-boot/issues/events{/number}","events_url":"https://api.github.com/repos/spring-projects/spring-boot/events","assignees_url":"https://api.github.com/repos/spring-projects/spring-boot/assignees{/user}","branches_url":"https://api.github.com/repos/spring-projects/spring-boot/branches{/branch}","tags_url":"https://api.github.com/repos/spring-projects/spring-boot/tags","blobs_url":"https://api.github.com/repos/spring-projects/spring-boot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/spring-projects/spring-boot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/spring-projects/spring-boot/git/refs{/sha}","trees_url":"https://api.github.com/repos/spring-projects/spring-boot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/spring-projects/spring-boot/statuses/{sha}","languages_url":"https://api.github.com/repos/spring-projects/spring-boot/languages","stargazers_url":"https://api.github.com/repos/spring-projects/spring-boot/stargazers","contributors_url":"https://api.github.com/repos/spring-projects/spring-boot/contributors","subscribers_url":"https://api.github.com/repos/spring-projects/spring-boot/subscribers","subscription_url":"https://api.github.com/repos/spring-projects/spring-boot/subscription","commits_url":"https://api.github.com/repos/spring-projects/spring-boot/commits{/sha}","git_commits_url":"https://api.github.com/repos/spring-projects/spring-boot/git/commits{/sha}","comments_url":"https://api.github.com/repos/spring-projects/spring-boot/comments{/number}","issue_comment_url":"https://api.github.com/repos/spring-projects/spring-boot/issues/comments{/number}","contents_url":"https://api.github.com/repos/spring-projects/spring-boot/contents/{+path}","compare_url":"https://api.github.com/repos/spring-projects/spring-boot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/spring-projects/spring-boot/merges","archive_url":"https://api.github.com/repos/spring-projects/spring-boot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/spring-projects/spring-boot/downloads","issues_url":"https://api.github.com/repos/spring-projects/spring-boot/issues{/number}","pulls_url":"https://api.github.com/repos/spring-projects/spring-boot/pulls{/number}","milestones_url":"https://api.github.com/repos/spring-projects/spring-boot/milestones{/number}","notifications_url":"https://api.github.com/repos/spring-projects/spring-boot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/spring-projects/spring-boot/labels{/name}","releases_url":"https://api.github.com/repos/spring-projects/spring-boot/releases{/id}","deployments_url":"https://api.github.com/repos/spring-projects/spring-boot/deployments","created_at":"2012-10-19T15:02:57Z","updated_at":"2016-03-22T08:01:32Z","pushed_at":"2016-03-22T06:11:39Z","git_url":"git://github.com/spring-projects/spring-boot.git","ssh_url":"git@github.com:spring-projects/spring-boot.git","clone_url":"https://github.com/spring-projects/spring-boot.git","svn_url":"https://github.com/spring-projects/spring-boot","homepage":"http://projects.spring.io/spring-boot","size":42555,"stargazers_count":4774,"watchers_count":4774,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":4742,"mirror_url":null,"open_issues_count":609,"forks":4742,"open_issues":609,"watchers":4774,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/spring-projects/spring-boot/pulls/5158"},"html":{"href":"https://github.com/spring-projects/spring-boot/pull/5158"},"issue":{"href":"https://api.github.com/repos/spring-projects/spring-boot/issues/5158"},"comments":{"href":"https://api.github.com/repos/spring-projects/spring-boot/issues/5158/comments"},"review_comments":{"href":"https://api.github.com/repos/spring-projects/spring-boot/pulls/5158/comments"},"review_comment":{"href":"https://api.github.com/repos/spring-projects/spring-boot/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/spring-projects/spring-boot/pulls/5158/commits"},"statuses":{"href":"https://api.github.com/repos/spring-projects/spring-boot/statuses/a437c2895c60ae4fe94e4c3d7628ce98a0e8ab9e"}}}}