{"action":"created","issue":{"url":"https://api.github.com/repos/openshift/origin/issues/7403","repository_url":"https://api.github.com/repos/openshift/origin","labels_url":"https://api.github.com/repos/openshift/origin/issues/7403/labels{/name}","comments_url":"https://api.github.com/repos/openshift/origin/issues/7403/comments","events_url":"https://api.github.com/repos/openshift/origin/issues/7403/events","html_url":"https://github.com/openshift/origin/issues/7403","id":134400656,"number":7403,"title":"Router should test config before reloading","user":{"login":"pweil-","id":5230419,"avatar_url":"https://avatars.githubusercontent.com/u/5230419?v=3","gravatar_id":"","url":"https://api.github.com/users/pweil-","html_url":"https://github.com/pweil-","followers_url":"https://api.github.com/users/pweil-/followers","following_url":"https://api.github.com/users/pweil-/following{/other_user}","gists_url":"https://api.github.com/users/pweil-/gists{/gist_id}","starred_url":"https://api.github.com/users/pweil-/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pweil-/subscriptions","organizations_url":"https://api.github.com/users/pweil-/orgs","repos_url":"https://api.github.com/users/pweil-/repos","events_url":"https://api.github.com/users/pweil-/events{/privacy}","received_events_url":"https://api.github.com/users/pweil-/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/openshift/origin/labels/area/reliability","name":"area/reliability","color":"006b75"},{"url":"https://api.github.com/repos/openshift/origin/labels/component/routing","name":"component/routing","color":"0052cc"},{"url":"https://api.github.com/repos/openshift/origin/labels/kind/enhancement","name":"kind/enhancement","color":"84b6eb"},{"url":"https://api.github.com/repos/openshift/origin/labels/priority/P2","name":"priority/P2","color":"fbca04"}],"state":"open","locked":false,"assignee":{"login":"ramr","id":928868,"avatar_url":"https://avatars.githubusercontent.com/u/928868?v=3","gravatar_id":"","url":"https://api.github.com/users/ramr","html_url":"https://github.com/ramr","followers_url":"https://api.github.com/users/ramr/followers","following_url":"https://api.github.com/users/ramr/following{/other_user}","gists_url":"https://api.github.com/users/ramr/gists{/gist_id}","starred_url":"https://api.github.com/users/ramr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ramr/subscriptions","organizations_url":"https://api.github.com/users/ramr/orgs","repos_url":"https://api.github.com/users/ramr/repos","events_url":"https://api.github.com/users/ramr/events{/privacy}","received_events_url":"https://api.github.com/users/ramr/received_events","type":"User","site_admin":false},"milestone":null,"comments":12,"created_at":"2016-02-17T21:11:36Z","updated_at":"2016-03-24T12:22:13Z","closed_at":null,"body":"In order to prevent a completely broken router the router should be able to:\r\n\r\n1.  test config if the implementation supports it to ensure validity before reloading\r\n2.  if there isn't a way to ensure validity it should be able to revert to a previous config if it cannot restart with the new config\r\n\r\nIn the event that an invalid configuration is generated the router should send an event and log any message received from validation or command execution.\r\n\r\n@ramr @rajatchopra \r\n"},"comment":{"url":"https://api.github.com/repos/openshift/origin/issues/comments/200808822","html_url":"https://github.com/openshift/origin/issues/7403#issuecomment-200808822","issue_url":"https://api.github.com/repos/openshift/origin/issues/7403","id":200808822,"user":{"login":"pweil-","id":5230419,"avatar_url":"https://avatars.githubusercontent.com/u/5230419?v=3","gravatar_id":"","url":"https://api.github.com/users/pweil-","html_url":"https://github.com/pweil-","followers_url":"https://api.github.com/users/pweil-/followers","following_url":"https://api.github.com/users/pweil-/following{/other_user}","gists_url":"https://api.github.com/users/pweil-/gists{/gist_id}","starred_url":"https://api.github.com/users/pweil-/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pweil-/subscriptions","organizations_url":"https://api.github.com/users/pweil-/orgs","repos_url":"https://api.github.com/users/pweil-/repos","events_url":"https://api.github.com/users/pweil-/events{/privacy}","received_events_url":"https://api.github.com/users/pweil-/received_events","type":"User","site_admin":false},"created_at":"2016-03-24T12:22:13Z","updated_at":"2016-03-24T12:22:13Z","body":"> Do some validation on route creation (we can add more here as golang gets better support).\r\n\r\nWhat additional validation would you implement? If we can't guarantee the integrity of a cert I'm not sure it's worth all the extra effort.  Especially if we're going to say that the router needs to handle it gracefully. \r\n\r\n> We would then run a config checker script\r\n\r\nI think this is the way to go.  Are you thinking that we would do this in a separate worker process or in the main thread that calls AddRoute?  I guess for simplicity doing it inline may be a good first step and if it's fast enough then no big deal.\r\n\r\nWould you do the config check write with total state or just the incoming route?  Using a single route would be faster but I guess there is still the chance that something goes wrong when it is written in conjunction with other routes."}}