{"action":"created","issue":{"url":"https://api.github.com/repos/dotmesh-io/dotmesh/issues/262","repository_url":"https://api.github.com/repos/dotmesh-io/dotmesh","labels_url":"https://api.github.com/repos/dotmesh-io/dotmesh/issues/262/labels{/name}","comments_url":"https://api.github.com/repos/dotmesh-io/dotmesh/issues/262/comments","events_url":"https://api.github.com/repos/dotmesh-io/dotmesh/issues/262/events","html_url":"https://github.com/dotmesh-io/dotmesh/issues/262","id":294852936,"number":262,"title":"Add IP of nodes into checkpoint service to be sent out to segment","user":{"login":"prisamuel","id":151395,"avatar_url":"https://avatars1.githubusercontent.com/u/151395?v=4","gravatar_id":"","url":"https://api.github.com/users/prisamuel","html_url":"https://github.com/prisamuel","followers_url":"https://api.github.com/users/prisamuel/followers","following_url":"https://api.github.com/users/prisamuel/following{/other_user}","gists_url":"https://api.github.com/users/prisamuel/gists{/gist_id}","starred_url":"https://api.github.com/users/prisamuel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/prisamuel/subscriptions","organizations_url":"https://api.github.com/users/prisamuel/orgs","repos_url":"https://api.github.com/users/prisamuel/repos","events_url":"https://api.github.com/users/prisamuel/events{/privacy}","received_events_url":"https://api.github.com/users/prisamuel/received_events","type":"User","site_admin":false},"labels":[{"id":629187884,"url":"https://api.github.com/repos/dotmesh-io/dotmesh/labels/task","name":"task","color":"84b6eb","default":false}],"state":"closed","locked":false,"assignee":{"login":"prisamuel","id":151395,"avatar_url":"https://avatars1.githubusercontent.com/u/151395?v=4","gravatar_id":"","url":"https://api.github.com/users/prisamuel","html_url":"https://github.com/prisamuel","followers_url":"https://api.github.com/users/prisamuel/followers","following_url":"https://api.github.com/users/prisamuel/following{/other_user}","gists_url":"https://api.github.com/users/prisamuel/gists{/gist_id}","starred_url":"https://api.github.com/users/prisamuel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/prisamuel/subscriptions","organizations_url":"https://api.github.com/users/prisamuel/orgs","repos_url":"https://api.github.com/users/prisamuel/repos","events_url":"https://api.github.com/users/prisamuel/events{/privacy}","received_events_url":"https://api.github.com/users/prisamuel/received_events","type":"User","site_admin":false},"assignees":[{"login":"prisamuel","id":151395,"avatar_url":"https://avatars1.githubusercontent.com/u/151395?v=4","gravatar_id":"","url":"https://api.github.com/users/prisamuel","html_url":"https://github.com/prisamuel","followers_url":"https://api.github.com/users/prisamuel/followers","following_url":"https://api.github.com/users/prisamuel/following{/other_user}","gists_url":"https://api.github.com/users/prisamuel/gists{/gist_id}","starred_url":"https://api.github.com/users/prisamuel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/prisamuel/subscriptions","organizations_url":"https://api.github.com/users/prisamuel/orgs","repos_url":"https://api.github.com/users/prisamuel/repos","events_url":"https://api.github.com/users/prisamuel/events{/privacy}","received_events_url":"https://api.github.com/users/prisamuel/received_events","type":"User","site_admin":false}],"milestone":null,"comments":3,"created_at":"2018-02-06T17:49:11Z","updated_at":"2018-04-09T10:46:48Z","closed_at":"2018-04-09T10:46:48Z","author_association":"CONTRIBUTOR","body":"The metrics that we have now are the following (userId being the unique ID for the node which runs the dotmesh-server)\r\n\r\n```  \r\nUserId: \"a0b1933a49c3dd0b\",\r\n  Event: \"VersionUpdateCheck\",\r\n  Properties: map[string]interface{}{\r\n    \"Arch\": \"Linux 95317b08a2e4 4.13.0-32-generic #35~16.04.1-Ubuntu SMP Thu Jan 25 10:13:43 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux\",\r\n    \"ForwardProxyIP\": \"10.154.0.3\",\r\n    \"InstalledVersion\": \"master-a5270d8\",\r\n    \"NumberOfDots\": \"0\",\r\n    \"OS\": \"Ubuntu 17.10 \\n \\l\",\r\n    \"Product\": \"dotmesh-server\",\r\n    \"RemoteIP\": \"10.36.1.6\",\r\n    \"ServersInCluster\": \"\",\r\n    \"TotalCurrentDotSizeBytes\": \"0\",\r\n\r\n```\r\nThere are several metrics that we can track in addition to this. One metric that was suggested early on was the originating IP address. That seems to be quite tricky as checkpoint is behind kubelego(nginx ingress) and cloudflare, and we seem to only get an internal IP in the metrics.\r\n\r\nMetrics to add:\r\n- [ ] The highest priority appears to be the orignating IP address i.e the external IP address of the machine running dotmesh-server\r\n- [ ] Number of remotes\r\n- [ ] Whether dothub is a remote, and if present, the dothub username/id"},"comment":{"url":"https://api.github.com/repos/dotmesh-io/dotmesh/issues/comments/379711218","html_url":"https://github.com/dotmesh-io/dotmesh/issues/262#issuecomment-379711218","issue_url":"https://api.github.com/repos/dotmesh-io/dotmesh/issues/262","id":379711218,"user":{"login":"prisamuel","id":151395,"avatar_url":"https://avatars1.githubusercontent.com/u/151395?v=4","gravatar_id":"","url":"https://api.github.com/users/prisamuel","html_url":"https://github.com/prisamuel","followers_url":"https://api.github.com/users/prisamuel/followers","following_url":"https://api.github.com/users/prisamuel/following{/other_user}","gists_url":"https://api.github.com/users/prisamuel/gists{/gist_id}","starred_url":"https://api.github.com/users/prisamuel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/prisamuel/subscriptions","organizations_url":"https://api.github.com/users/prisamuel/orgs","repos_url":"https://api.github.com/users/prisamuel/repos","events_url":"https://api.github.com/users/prisamuel/events{/privacy}","received_events_url":"https://api.github.com/users/prisamuel/received_events","type":"User","site_admin":false},"created_at":"2018-04-09T10:46:48Z","updated_at":"2018-04-09T10:46:48Z","author_association":"CONTRIBUTOR","body":"https://support.cloudflare.com/hc/en-us/articles/115000219871\r\n\r\nI read the manual (cloudflare) and I've updated the cloudflare settings to now do two things\r\n- Redirect all requests with scheme “http” to “https”. This applies to all http requests to the zone.\r\n- Full SSL (strict): Your origin has a valid certificate (not expired and signed by a trusted CA or Cloudflare Origin CA) installed. Cloudflare will connect over HTTPS and verify the cert on each request.\r\n\r\nWe now get the client-IP and the country code into segment. Cloudflare sets the X-forwarded-for, X-real-ip and cf-connectig-ip to be the client external IP address. It also set a cf-country which is the two letter country code determined from the connecting ip. This info is now in segment.\r\n\r\n```\r\nclient.Track(&analytics.Track{\r\n  UserId: \"3fb75f4cd58a41f1\",\r\n  Event: \"VersionUpdateCheck\",\r\n  Properties: map[string]interface{}{\r\n    \"Arch\": \"Linux b621b575ba49 4.4.0-116-generic #140-Ubuntu SMP Mon Feb 12 21:23:04 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux\",\r\n    \"CFCountry\": \"DE\",\r\n    \"InstalledVersion\": \"release-0.4.0\",\r\n    \"NumberOfDots\": \"0\",\r\n    \"OS\": \"Ubuntu 17.10 \\n \\l\",\r\n    \"OtherServersInCluster\": \"\",\r\n    \"Product\": \"dotmesh-server\",\r\n    \"RequestHeaders\": \"Cf-Visitor:[{\\\"scheme\\\":\\\"https\\\"}] Accept:[application/json] Connection:[close] X-Forwarded-For:[148.251.0.20, 148.251.0.20] X-Forwarded-Host:[checkpoint.dotmesh.com] Accept-Encoding:[gzip] User-Agent:[HashiCorp/go-checkpoint] X-Real-Ip:[148.251.0.20] X-Forwarded-Proto:[https] Cf-Ipcountry:[DE] Cf-Connecting-Ip:[148.251.0.20] X-Forwarded-Port:[443] Cf-Ray:[408c59ddd8fe231e-FRA] \",\r\n    \"TotalCurrentDotSizeBytes\": \"0\",\r\n    \"X-Forwarded-For\": \"148.251.0.20, 148.251.0.20\",\r\n  },\r\n})\r\n```\r\n\r\nCurrently creating basic reports on google studio."}}
{"actor":{"display_login":"prisamuel"}}