{"action":"created","comment":{"url":"https://api.github.com/repos/Jasig/cas/pulls/comments/24888113","id":24888113,"diff_hunk":"@@ -34,12 +35,9 @@\n         Deployers should not have to edit this file.\n     </description>\n \n-    <bean id=\"log4jInitialization\" class=\"org.springframework.beans.factory.config.MethodInvokingFactoryBean\"\n-        p:targetClass=\"org.springframework.util.Log4jConfigurer\" p:targetMethod=\"initLogging\" p:arguments-ref=\"arguments\"/>\n-    \n-    <util:list id=\"arguments\">\n-       <value>${log4j.config.location:classpath:log4j.xml}</value>\n-       <value>${log4j.refresh.interval:60000}</value>\n-    </util:list>\n+    <bean id=\"log4jInitialization\" class=\"org.jasig.cas.util.CasLoggerContextInitializer\"","path":"cas-management-webapp/src/main/webapp/WEB-INF/spring-configuration/log4jConfiguration.xml","position":19,"original_position":19,"commit_id":"c7556030abf8085f643bcc22e8fada33fc1e8a21","original_commit_id":"c7556030abf8085f643bcc22e8fada33fc1e8a21","user":{"login":"leleuj","id":1038508,"avatar_url":"https://avatars.githubusercontent.com/u/1038508?v=3","gravatar_id":"","url":"https://api.github.com/users/leleuj","html_url":"https://github.com/leleuj","followers_url":"https://api.github.com/users/leleuj/followers","following_url":"https://api.github.com/users/leleuj/following{/other_user}","gists_url":"https://api.github.com/users/leleuj/gists{/gist_id}","starred_url":"https://api.github.com/users/leleuj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leleuj/subscriptions","organizations_url":"https://api.github.com/users/leleuj/orgs","repos_url":"https://api.github.com/users/leleuj/repos","events_url":"https://api.github.com/users/leleuj/events{/privacy}","received_events_url":"https://api.github.com/users/leleuj/received_events","type":"User","site_admin":false},"body":"How do we set the refresh interval now?","created_at":"2015-02-18T09:26:49Z","updated_at":"2015-02-18T09:26:49Z","html_url":"https://github.com/Jasig/cas/pull/870#discussion_r24888113","pull_request_url":"https://api.github.com/repos/Jasig/cas/pulls/870","_links":{"self":{"href":"https://api.github.com/repos/Jasig/cas/pulls/comments/24888113"},"html":{"href":"https://github.com/Jasig/cas/pull/870#discussion_r24888113"},"pull_request":{"href":"https://api.github.com/repos/Jasig/cas/pulls/870"}}},"pull_request":{"url":"https://api.github.com/repos/Jasig/cas/pulls/870","id":29468838,"html_url":"https://github.com/Jasig/cas/pull/870","diff_url":"https://github.com/Jasig/cas/pull/870.diff","patch_url":"https://github.com/Jasig/cas/pull/870.patch","issue_url":"https://api.github.com/repos/Jasig/cas/issues/870","number":870,"state":"open","locked":false,"title":"Log4j v2 upgrade: metrics and statistics","user":{"login":"mmoayyed","id":1205228,"avatar_url":"https://avatars.githubusercontent.com/u/1205228?v=3","gravatar_id":"","url":"https://api.github.com/users/mmoayyed","html_url":"https://github.com/mmoayyed","followers_url":"https://api.github.com/users/mmoayyed/followers","following_url":"https://api.github.com/users/mmoayyed/following{/other_user}","gists_url":"https://api.github.com/users/mmoayyed/gists{/gist_id}","starred_url":"https://api.github.com/users/mmoayyed/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mmoayyed/subscriptions","organizations_url":"https://api.github.com/users/mmoayyed/orgs","repos_url":"https://api.github.com/users/mmoayyed/repos","events_url":"https://api.github.com/users/mmoayyed/events{/privacy}","received_events_url":"https://api.github.com/users/mmoayyed/received_events","type":"User","site_admin":false},"body":"Handles https://github.com/Jasig/cas/issues/863 and https://github.com/Jasig/cas/issues/485\r\n\r\n## Scope\r\nThis is a fairly large pull, but the majority of changes are related to configuration. I'll highlight some of the significant changes that have gone in:\r\n\r\n- Upgrade from log4j v1 to log4j v2\r\n- Removal of perf4j and use of dropwizard's metrics\r\n- Inclusion of additional metrics and stats into the CAS statistics\r\n- Fixes to log statements and controllers that deal with stats in general\r\n\r\n### Upgrade\r\nLog4j v2 is not as easily configurable by Spring. Instead of the previous method invoker for log4j v1, there is now a `CasLoggerContextInitializer` that scans the classpath for the log4j context initializer and starts it for the log configuration file. [I explored all other options. None were better] The log4j auto initialization feature is disabled.\r\n\r\nAll logging configuration is converted to log4j v2's syntax and format. All log data and configuration should have been preserved.\r\n\r\n### Statistics\r\n\r\nI had to remove perf4j entirely, because none of the appenders are compatible. Instead, I used dropwizard's various metrics and annotated the appropriate classes with timers and metrics. There is a new metricsConfiguration.xml file that handles all of that via Spring. \r\n\r\nStats data includes JVM info and is exposed via JMX as well. \r\n\r\nThere are several new stats on the /statistics endpoint that output metrics, thread dumps and active sso sessions. These are all, just as before, secured via spring security and simply output JSON data. Links are provided on the statistics JSP page.\r\n\r\nThe statistics and status controllers were also converted to use annotations instead to help with autowiring of the configuration.\r\n\r\n### Others\r\nVarious other fixes that relate to logging, such as typos, duplicate and double logging and etc are also applied. ","created_at":"2015-02-17T19:12:56Z","updated_at":"2015-02-18T09:26:49Z","closed_at":null,"merged_at":null,"merge_commit_sha":"39095ab869263a4c160cba1b0601d9ba8dbee2ad","assignee":{"login":"mmoayyed","id":1205228,"avatar_url":"https://avatars.githubusercontent.com/u/1205228?v=3","gravatar_id":"","url":"https://api.github.com/users/mmoayyed","html_url":"https://github.com/mmoayyed","followers_url":"https://api.github.com/users/mmoayyed/followers","following_url":"https://api.github.com/users/mmoayyed/following{/other_user}","gists_url":"https://api.github.com/users/mmoayyed/gists{/gist_id}","starred_url":"https://api.github.com/users/mmoayyed/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mmoayyed/subscriptions","organizations_url":"https://api.github.com/users/mmoayyed/orgs","repos_url":"https://api.github.com/users/mmoayyed/repos","events_url":"https://api.github.com/users/mmoayyed/events{/privacy}","received_events_url":"https://api.github.com/users/mmoayyed/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/Jasig/cas/milestones/2","labels_url":"https://api.github.com/repos/Jasig/cas/milestones/2/labels","id":721279,"number":2,"title":"4.1","description":"CAS 4.1 Release","creator":{"login":"mmoayyed","id":1205228,"avatar_url":"https://avatars.githubusercontent.com/u/1205228?v=3","gravatar_id":"","url":"https://api.github.com/users/mmoayyed","html_url":"https://github.com/mmoayyed","followers_url":"https://api.github.com/users/mmoayyed/followers","following_url":"https://api.github.com/users/mmoayyed/following{/other_user}","gists_url":"https://api.github.com/users/mmoayyed/gists{/gist_id}","starred_url":"https://api.github.com/users/mmoayyed/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mmoayyed/subscriptions","organizations_url":"https://api.github.com/users/mmoayyed/orgs","repos_url":"https://api.github.com/users/mmoayyed/repos","events_url":"https://api.github.com/users/mmoayyed/events{/privacy}","received_events_url":"https://api.github.com/users/mmoayyed/received_events","type":"User","site_admin":false},"open_issues":17,"closed_issues":219,"state":"open","created_at":"2014-07-15T06:16:10Z","updated_at":"2015-02-17T19:13:24Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/Jasig/cas/pulls/870/commits","review_comments_url":"https://api.github.com/repos/Jasig/cas/pulls/870/comments","review_comment_url":"https://api.github.com/repos/Jasig/cas/pulls/comments/{number}","comments_url":"https://api.github.com/repos/Jasig/cas/issues/870/comments","statuses_url":"https://api.github.com/repos/Jasig/cas/statuses/c7556030abf8085f643bcc22e8fada33fc1e8a21","head":{"label":"Unicon:log4j-v2-upgrade","ref":"log4j-v2-upgrade","sha":"c7556030abf8085f643bcc22e8fada33fc1e8a21","user":{"login":"Unicon","id":835400,"avatar_url":"https://avatars.githubusercontent.com/u/835400?v=3","gravatar_id":"","url":"https://api.github.com/users/Unicon","html_url":"https://github.com/Unicon","followers_url":"https://api.github.com/users/Unicon/followers","following_url":"https://api.github.com/users/Unicon/following{/other_user}","gists_url":"https://api.github.com/users/Unicon/gists{/gist_id}","starred_url":"https://api.github.com/users/Unicon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Unicon/subscriptions","organizations_url":"https://api.github.com/users/Unicon/orgs","repos_url":"https://api.github.com/users/Unicon/repos","events_url":"https://api.github.com/users/Unicon/events{/privacy}","received_events_url":"https://api.github.com/users/Unicon/received_events","type":"Organization","site_admin":false},"repo":{"id":6410069,"name":"cas","full_name":"Unicon/cas","owner":{"login":"Unicon","id":835400,"avatar_url":"https://avatars.githubusercontent.com/u/835400?v=3","gravatar_id":"","url":"https://api.github.com/users/Unicon","html_url":"https://github.com/Unicon","followers_url":"https://api.github.com/users/Unicon/followers","following_url":"https://api.github.com/users/Unicon/following{/other_user}","gists_url":"https://api.github.com/users/Unicon/gists{/gist_id}","starred_url":"https://api.github.com/users/Unicon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Unicon/subscriptions","organizations_url":"https://api.github.com/users/Unicon/orgs","repos_url":"https://api.github.com/users/Unicon/repos","events_url":"https://api.github.com/users/Unicon/events{/privacy}","received_events_url":"https://api.github.com/users/Unicon/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Unicon/cas","description":"Jasig CAS - Single Sign On for the Web","fork":true,"url":"https://api.github.com/repos/Unicon/cas","forks_url":"https://api.github.com/repos/Unicon/cas/forks","keys_url":"https://api.github.com/repos/Unicon/cas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Unicon/cas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Unicon/cas/teams","hooks_url":"https://api.github.com/repos/Unicon/cas/hooks","issue_events_url":"https://api.github.com/repos/Unicon/cas/issues/events{/number}","events_url":"https://api.github.com/repos/Unicon/cas/events","assignees_url":"https://api.github.com/repos/Unicon/cas/assignees{/user}","branches_url":"https://api.github.com/repos/Unicon/cas/branches{/branch}","tags_url":"https://api.github.com/repos/Unicon/cas/tags","blobs_url":"https://api.github.com/repos/Unicon/cas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Unicon/cas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Unicon/cas/git/refs{/sha}","trees_url":"https://api.github.com/repos/Unicon/cas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Unicon/cas/statuses/{sha}","languages_url":"https://api.github.com/repos/Unicon/cas/languages","stargazers_url":"https://api.github.com/repos/Unicon/cas/stargazers","contributors_url":"https://api.github.com/repos/Unicon/cas/contributors","subscribers_url":"https://api.github.com/repos/Unicon/cas/subscribers","subscription_url":"https://api.github.com/repos/Unicon/cas/subscription","commits_url":"https://api.github.com/repos/Unicon/cas/commits{/sha}","git_commits_url":"https://api.github.com/repos/Unicon/cas/git/commits{/sha}","comments_url":"https://api.github.com/repos/Unicon/cas/comments{/number}","issue_comment_url":"https://api.github.com/repos/Unicon/cas/issues/comments/{number}","contents_url":"https://api.github.com/repos/Unicon/cas/contents/{+path}","compare_url":"https://api.github.com/repos/Unicon/cas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Unicon/cas/merges","archive_url":"https://api.github.com/repos/Unicon/cas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Unicon/cas/downloads","issues_url":"https://api.github.com/repos/Unicon/cas/issues{/number}","pulls_url":"https://api.github.com/repos/Unicon/cas/pulls{/number}","milestones_url":"https://api.github.com/repos/Unicon/cas/milestones{/number}","notifications_url":"https://api.github.com/repos/Unicon/cas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Unicon/cas/labels{/name}","releases_url":"https://api.github.com/repos/Unicon/cas/releases{/id}","created_at":"2012-10-26T20:34:46Z","updated_at":"2015-02-10T14:05:26Z","pushed_at":"2015-02-17T18:44:49Z","git_url":"git://github.com/Unicon/cas.git","ssh_url":"git@github.com:Unicon/cas.git","clone_url":"https://github.com/Unicon/cas.git","svn_url":"https://github.com/Unicon/cas","homepage":"http://www.jasig.org/cas","size":44012,"stargazers_count":23,"watchers_count":23,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":20,"mirror_url":null,"open_issues_count":0,"forks":20,"open_issues":0,"watchers":23,"default_branch":"master"}},"base":{"label":"Jasig:master","ref":"master","sha":"b0592bd5169073793a0181dadf6c4a58b68c3c17","user":{"login":"Jasig","id":884285,"avatar_url":"https://avatars.githubusercontent.com/u/884285?v=3","gravatar_id":"","url":"https://api.github.com/users/Jasig","html_url":"https://github.com/Jasig","followers_url":"https://api.github.com/users/Jasig/followers","following_url":"https://api.github.com/users/Jasig/following{/other_user}","gists_url":"https://api.github.com/users/Jasig/gists{/gist_id}","starred_url":"https://api.github.com/users/Jasig/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jasig/subscriptions","organizations_url":"https://api.github.com/users/Jasig/orgs","repos_url":"https://api.github.com/users/Jasig/repos","events_url":"https://api.github.com/users/Jasig/events{/privacy}","received_events_url":"https://api.github.com/users/Jasig/received_events","type":"Organization","site_admin":false},"repo":{"id":2352744,"name":"cas","full_name":"Jasig/cas","owner":{"login":"Jasig","id":884285,"avatar_url":"https://avatars.githubusercontent.com/u/884285?v=3","gravatar_id":"","url":"https://api.github.com/users/Jasig","html_url":"https://github.com/Jasig","followers_url":"https://api.github.com/users/Jasig/followers","following_url":"https://api.github.com/users/Jasig/following{/other_user}","gists_url":"https://api.github.com/users/Jasig/gists{/gist_id}","starred_url":"https://api.github.com/users/Jasig/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jasig/subscriptions","organizations_url":"https://api.github.com/users/Jasig/orgs","repos_url":"https://api.github.com/users/Jasig/repos","events_url":"https://api.github.com/users/Jasig/events{/privacy}","received_events_url":"https://api.github.com/users/Jasig/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Jasig/cas","description":"Apereo CAS - Single Sign On for the Web","fork":false,"url":"https://api.github.com/repos/Jasig/cas","forks_url":"https://api.github.com/repos/Jasig/cas/forks","keys_url":"https://api.github.com/repos/Jasig/cas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Jasig/cas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Jasig/cas/teams","hooks_url":"https://api.github.com/repos/Jasig/cas/hooks","issue_events_url":"https://api.github.com/repos/Jasig/cas/issues/events{/number}","events_url":"https://api.github.com/repos/Jasig/cas/events","assignees_url":"https://api.github.com/repos/Jasig/cas/assignees{/user}","branches_url":"https://api.github.com/repos/Jasig/cas/branches{/branch}","tags_url":"https://api.github.com/repos/Jasig/cas/tags","blobs_url":"https://api.github.com/repos/Jasig/cas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Jasig/cas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Jasig/cas/git/refs{/sha}","trees_url":"https://api.github.com/repos/Jasig/cas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Jasig/cas/statuses/{sha}","languages_url":"https://api.github.com/repos/Jasig/cas/languages","stargazers_url":"https://api.github.com/repos/Jasig/cas/stargazers","contributors_url":"https://api.github.com/repos/Jasig/cas/contributors","subscribers_url":"https://api.github.com/repos/Jasig/cas/subscribers","subscription_url":"https://api.github.com/repos/Jasig/cas/subscription","commits_url":"https://api.github.com/repos/Jasig/cas/commits{/sha}","git_commits_url":"https://api.github.com/repos/Jasig/cas/git/commits{/sha}","comments_url":"https://api.github.com/repos/Jasig/cas/comments{/number}","issue_comment_url":"https://api.github.com/repos/Jasig/cas/issues/comments/{number}","contents_url":"https://api.github.com/repos/Jasig/cas/contents/{+path}","compare_url":"https://api.github.com/repos/Jasig/cas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Jasig/cas/merges","archive_url":"https://api.github.com/repos/Jasig/cas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Jasig/cas/downloads","issues_url":"https://api.github.com/repos/Jasig/cas/issues{/number}","pulls_url":"https://api.github.com/repos/Jasig/cas/pulls{/number}","milestones_url":"https://api.github.com/repos/Jasig/cas/milestones{/number}","notifications_url":"https://api.github.com/repos/Jasig/cas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Jasig/cas/labels{/name}","releases_url":"https://api.github.com/repos/Jasig/cas/releases{/id}","created_at":"2011-09-09T01:36:42Z","updated_at":"2015-02-17T17:48:12Z","pushed_at":"2015-02-17T17:48:11Z","git_url":"git://github.com/Jasig/cas.git","ssh_url":"git@github.com:Jasig/cas.git","clone_url":"https://github.com/Jasig/cas.git","svn_url":"https://github.com/Jasig/cas","homepage":"https://www.apereo.org/cas","size":364408,"stargazers_count":556,"watchers_count":556,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":423,"mirror_url":null,"open_issues_count":114,"forks":423,"open_issues":114,"watchers":556,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Jasig/cas/pulls/870"},"html":{"href":"https://github.com/Jasig/cas/pull/870"},"issue":{"href":"https://api.github.com/repos/Jasig/cas/issues/870"},"comments":{"href":"https://api.github.com/repos/Jasig/cas/issues/870/comments"},"review_comments":{"href":"https://api.github.com/repos/Jasig/cas/pulls/870/comments"},"review_comment":{"href":"https://api.github.com/repos/Jasig/cas/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/Jasig/cas/pulls/870/commits"},"statuses":{"href":"https://api.github.com/repos/Jasig/cas/statuses/c7556030abf8085f643bcc22e8fada33fc1e8a21"}}}}