{"action":"closed","issue":{"url":"https://api.github.com/repos/hawtio/hawtio/issues/1208","labels_url":"https://api.github.com/repos/hawtio/hawtio/issues/1208/labels{/name}","comments_url":"https://api.github.com/repos/hawtio/hawtio/issues/1208/comments","events_url":"https://api.github.com/repos/hawtio/hawtio/issues/1208/events","html_url":"https://github.com/hawtio/hawtio/issues/1208","id":31069961,"number":1208,"title":"Using multiple embedded Hawtio instances on one machine/user can error on startup","user":{"login":"alex-sherwin","id":2175618,"avatar_url":"https://avatars.githubusercontent.com/u/2175618?v=3","gravatar_id":"","url":"https://api.github.com/users/alex-sherwin","html_url":"https://github.com/alex-sherwin","followers_url":"https://api.github.com/users/alex-sherwin/followers","following_url":"https://api.github.com/users/alex-sherwin/following{/other_user}","gists_url":"https://api.github.com/users/alex-sherwin/gists{/gist_id}","starred_url":"https://api.github.com/users/alex-sherwin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alex-sherwin/subscriptions","organizations_url":"https://api.github.com/users/alex-sherwin/orgs","repos_url":"https://api.github.com/users/alex-sherwin/repos","events_url":"https://api.github.com/users/alex-sherwin/events{/privacy}","received_events_url":"https://api.github.com/users/alex-sherwin/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/hawtio/hawtio/labels/apprentice%20tasks","name":"apprentice tasks","color":"f7d358"},{"url":"https://api.github.com/repos/hawtio/hawtio/labels/bug","name":"bug","color":"fc2929"}],"state":"closed","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/hawtio/hawtio/milestones/6","html_url":"https://github.com/hawtio/hawtio/milestones/1.5.0","labels_url":"https://api.github.com/repos/hawtio/hawtio/milestones/6/labels","id":501688,"number":6,"title":"1.5.0","description":"","creator":{"login":"jstrachan","id":30140,"avatar_url":"https://avatars.githubusercontent.com/u/30140?v=3","gravatar_id":"","url":"https://api.github.com/users/jstrachan","html_url":"https://github.com/jstrachan","followers_url":"https://api.github.com/users/jstrachan/followers","following_url":"https://api.github.com/users/jstrachan/following{/other_user}","gists_url":"https://api.github.com/users/jstrachan/gists{/gist_id}","starred_url":"https://api.github.com/users/jstrachan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jstrachan/subscriptions","organizations_url":"https://api.github.com/users/jstrachan/orgs","repos_url":"https://api.github.com/users/jstrachan/repos","events_url":"https://api.github.com/users/jstrachan/events{/privacy}","received_events_url":"https://api.github.com/users/jstrachan/received_events","type":"User","site_admin":false},"open_issues":96,"closed_issues":37,"state":"open","created_at":"2013-12-01T18:51:40Z","updated_at":"2016-01-24T08:21:26Z","due_on":null,"closed_at":null},"comments":4,"created_at":"2014-04-08T13:27:26Z","updated_at":"2016-01-24T08:21:26Z","closed_at":"2016-01-24T08:21:26Z","body":"When starting up multiple applications on the same machine as the same user, sometimes embedded hawtio fails.  All the embedded apps are hardcoded inside io.hawt.embedded.Main.run() to use ~/.hawtio/tmp as the temp directory.\r\n\r\nDuring the jetty WebAppContext initialization, if the tmp dir is non-persistent, it attempts to delete/recreate it, which will fail occassionally with multiple apps starting at the same time\r\n\r\n```\r\n2014/04/08 09:14:10.924 [main] WARN [org.eclipse.jetty.webapp.WebAppContext:501] - Failed startup of context o.e.j.w.WebAppContext@697f186a{/hawtio,null,null}{apps/hawtio/hawtio-web-1.2.2.war}\r\njava.lang.IllegalStateException: Failed to delete temp dir /home/acadiait/.hawtio/tmp\r\n        at org.eclipse.jetty.webapp.WebInfConfiguration.configureTempDirectory(WebInfConfiguration.java:372) ~[jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at org.eclipse.jetty.webapp.WebInfConfiguration.resolveTempDirectory(WebInfConfiguration.java:260) ~[jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at org.eclipse.jetty.webapp.WebInfConfiguration.preConfigure(WebInfConfiguration.java:69) ~[jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at org.eclipse.jetty.webapp.WebAppContext.preConfigure(WebAppContext.java:455) ~[jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:491) ~[jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:69) [jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:117) [jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at org.eclipse.jetty.server.Server.start(Server.java:355) [jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:99) [jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:60) [jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at org.eclipse.jetty.server.Server.doStart(Server.java:324) [jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:69) [jetty-all-9.1.2.v20140210.jar:9.1.2.v20140210]\r\n        at io.hawt.embedded.Main.run(Main.java:109) [hawtio-embedded-1.2.2.jar:na]\r\n```"}}