{"action":"created","issue":{"url":"https://api.github.com/repos/eHealthAfrica/kazana-server/issues/81","labels_url":"https://api.github.com/repos/eHealthAfrica/kazana-server/issues/81/labels{/name}","comments_url":"https://api.github.com/repos/eHealthAfrica/kazana-server/issues/81/comments","events_url":"https://api.github.com/repos/eHealthAfrica/kazana-server/issues/81/events","html_url":"https://github.com/eHealthAfrica/kazana-server/issues/81","id":117316980,"number":81,"title":"Auto-run of PouchDB server breaks Guinea Connect Universal App in dev mode","user":{"login":"patriciagarcia","id":572958,"avatar_url":"https://avatars.githubusercontent.com/u/572958?v=3","gravatar_id":"","url":"https://api.github.com/users/patriciagarcia","html_url":"https://github.com/patriciagarcia","followers_url":"https://api.github.com/users/patriciagarcia/followers","following_url":"https://api.github.com/users/patriciagarcia/following{/other_user}","gists_url":"https://api.github.com/users/patriciagarcia/gists{/gist_id}","starred_url":"https://api.github.com/users/patriciagarcia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/patriciagarcia/subscriptions","organizations_url":"https://api.github.com/users/patriciagarcia/orgs","repos_url":"https://api.github.com/users/patriciagarcia/repos","events_url":"https://api.github.com/users/patriciagarcia/events{/privacy}","received_events_url":"https://api.github.com/users/patriciagarcia/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-17T09:38:15Z","updated_at":"2015-11-17T10:11:24Z","closed_at":null,"body":"latest version working is 3.3.0\r\n\r\n@karlwestin, anything else to add? feel free also to correct anything if it's not correct."},"comment":{"url":"https://api.github.com/repos/eHealthAfrica/kazana-server/issues/comments/157326879","html_url":"https://github.com/eHealthAfrica/kazana-server/issues/81#issuecomment-157326879","issue_url":"https://api.github.com/repos/eHealthAfrica/kazana-server/issues/81","id":157326879,"user":{"login":"karl-ehealth","id":15029272,"avatar_url":"https://avatars.githubusercontent.com/u/15029272?v=3","gravatar_id":"","url":"https://api.github.com/users/karl-ehealth","html_url":"https://github.com/karl-ehealth","followers_url":"https://api.github.com/users/karl-ehealth/followers","following_url":"https://api.github.com/users/karl-ehealth/following{/other_user}","gists_url":"https://api.github.com/users/karl-ehealth/gists{/gist_id}","starred_url":"https://api.github.com/users/karl-ehealth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/karl-ehealth/subscriptions","organizations_url":"https://api.github.com/users/karl-ehealth/orgs","repos_url":"https://api.github.com/users/karl-ehealth/repos","events_url":"https://api.github.com/users/karl-ehealth/events{/privacy}","received_events_url":"https://api.github.com/users/karl-ehealth/received_events","type":"User","site_admin":false},"created_at":"2015-11-17T10:11:24Z","updated_at":"2015-11-17T10:11:24Z","body":"just telling the story of what happened:\r\nwe were loading kazana-server ^3.0.0 in package.json\r\nsince we have a watcher in dev-mode, that looks for code-changes and restarts the server, we have set the start of the pouchdb outside the part that gets restarted on code changes, and then starting a kazana-server inside our watched handler. The idea was that pouchdb would stay on, and the kazana-server would restart. \r\n\r\nWith version 3.4.0, which was covered by the semver range, kazana-server starts a pouchdb as well. We got this error:\r\n```\r\n[1] Error: Port 4999 is already in use.\r\n[1] Try another one, e.g. pouchdb-server -p 5000\r\n[1] Unhandled rejection OpenError: IO error: lock ./.db/_replicator/LOCK: Resource temporarily unavailable\r\n```\r\nit was pretty hard to debug\r\n\r\nanyway not sure what the resolution is. I was asked to fill in details here. We fixed it by locking to 3.3.0 which doesn't auto-start pouchdb, so its not blocking us."}}