{"action":"created","issue":{"url":"https://api.github.com/repos/p6spy/p6spy/issues/290","labels_url":"https://api.github.com/repos/p6spy/p6spy/issues/290/labels{/name}","comments_url":"https://api.github.com/repos/p6spy/p6spy/issues/290/comments","events_url":"https://api.github.com/repos/p6spy/p6spy/issues/290/events","html_url":"https://github.com/p6spy/p6spy/issues/290","id":77264780,"number":290,"title":"Lazily create spy.log","user":{"login":"felixbarny","id":2163464,"avatar_url":"https://avatars.githubusercontent.com/u/2163464?v=3","gravatar_id":"","url":"https://api.github.com/users/felixbarny","html_url":"https://github.com/felixbarny","followers_url":"https://api.github.com/users/felixbarny/followers","following_url":"https://api.github.com/users/felixbarny/following{/other_user}","gists_url":"https://api.github.com/users/felixbarny/gists{/gist_id}","starred_url":"https://api.github.com/users/felixbarny/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/felixbarny/subscriptions","organizations_url":"https://api.github.com/users/felixbarny/orgs","repos_url":"https://api.github.com/users/felixbarny/repos","events_url":"https://api.github.com/users/felixbarny/events{/privacy}","received_events_url":"https://api.github.com/users/felixbarny/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/p6spy/p6spy/labels/Enhancement","name":"Enhancement","color":"009800"}],"state":"closed","locked":false,"assignee":{"login":"quintonm","id":991413,"avatar_url":"https://avatars.githubusercontent.com/u/991413?v=3","gravatar_id":"","url":"https://api.github.com/users/quintonm","html_url":"https://github.com/quintonm","followers_url":"https://api.github.com/users/quintonm/followers","following_url":"https://api.github.com/users/quintonm/following{/other_user}","gists_url":"https://api.github.com/users/quintonm/gists{/gist_id}","starred_url":"https://api.github.com/users/quintonm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/quintonm/subscriptions","organizations_url":"https://api.github.com/users/quintonm/orgs","repos_url":"https://api.github.com/users/quintonm/repos","events_url":"https://api.github.com/users/quintonm/events{/privacy}","received_events_url":"https://api.github.com/users/quintonm/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/p6spy/p6spy/milestones/10","html_url":"https://github.com/p6spy/p6spy/milestones/2.2.0","labels_url":"https://api.github.com/repos/p6spy/p6spy/milestones/10/labels","id":1103306,"number":10,"title":"2.2.0","description":"","creator":{"login":"quintonm","id":991413,"avatar_url":"https://avatars.githubusercontent.com/u/991413?v=3","gravatar_id":"","url":"https://api.github.com/users/quintonm","html_url":"https://github.com/quintonm","followers_url":"https://api.github.com/users/quintonm/followers","following_url":"https://api.github.com/users/quintonm/following{/other_user}","gists_url":"https://api.github.com/users/quintonm/gists{/gist_id}","starred_url":"https://api.github.com/users/quintonm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/quintonm/subscriptions","organizations_url":"https://api.github.com/users/quintonm/orgs","repos_url":"https://api.github.com/users/quintonm/repos","events_url":"https://api.github.com/users/quintonm/events{/privacy}","received_events_url":"https://api.github.com/users/quintonm/received_events","type":"User","site_admin":false},"open_issues":0,"closed_issues":2,"state":"open","created_at":"2015-05-09T20:52:45Z","updated_at":"2015-05-20T20:29:11Z","due_on":null,"closed_at":null},"comments":5,"created_at":"2015-05-17T09:29:36Z","updated_at":"2015-05-30T08:27:33Z","closed_at":"2015-05-20T20:29:11Z","body":"Would it be possible to somehow lazily create the spy.log file? \r\n\r\nI want to change the appender at runtime by calling `P6SpyOptions.getActiveInstance().setAppender(\"my.Appender\")`, but when I do that the spy.log file is created anyway. The problem stems from P6Spy loading configuration when P6SpyOptions.getActiveInstance() is called for the first time. Since the default appender is the FileLogger, it gets initialized before you change the appender.\r\n\r\nEven when trying to set the appender via `System.setProperty`, the File is created when using wildfly. The problem ist, that wildfly initializes p6spy quite early on startup, because the DiverProcessor loads the P6SpyDriver which initializes the P6Core which leads to a creation of spy.log, because the FileLogger is the default appender. \r\n\r\nSee also our discussion at https://github.com/p6spy/p6spy/issues/286#issuecomment-100589576"},"comment":{"url":"https://api.github.com/repos/p6spy/p6spy/issues/comments/107008768","html_url":"https://github.com/p6spy/p6spy/issues/290#issuecomment-107008768","issue_url":"https://api.github.com/repos/p6spy/p6spy/issues/290","id":107008768,"user":{"login":"felixbarny","id":2163464,"avatar_url":"https://avatars.githubusercontent.com/u/2163464?v=3","gravatar_id":"","url":"https://api.github.com/users/felixbarny","html_url":"https://github.com/felixbarny","followers_url":"https://api.github.com/users/felixbarny/followers","following_url":"https://api.github.com/users/felixbarny/following{/other_user}","gists_url":"https://api.github.com/users/felixbarny/gists{/gist_id}","starred_url":"https://api.github.com/users/felixbarny/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/felixbarny/subscriptions","organizations_url":"https://api.github.com/users/felixbarny/orgs","repos_url":"https://api.github.com/users/felixbarny/repos","events_url":"https://api.github.com/users/felixbarny/events{/privacy}","received_events_url":"https://api.github.com/users/felixbarny/received_events","type":"User","site_admin":false},"created_at":"2015-05-30T08:27:33Z","updated_at":"2015-05-30T08:27:33Z","body":"Ok, that's good to know. Could you point me to the source? I'm curios about how that works.\r\n\r\nThx for creating the issues. It's awesome to see so much innovation in such a mature (not to say old :stuck_out_tongue_winking_eye:) project."}}