payload: {"action":"created","comment":{"url":"https://api.github.com/repos/argoproj/argo/pulls/comments/284050507","pull_request_review_id":237440124,"id":284050507,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDI4NDA1MDUwNw==","diff_hunk":"@@ -10,13 +10,14 @@ import (\n \n // Externally visible error codes\n const (\n-\tCodeUnauthorized   = \"ERR_UNAUTHORIZED\"\n-\tCodeBadRequest     = \"ERR_BAD_REQUEST\"\n-\tCodeForbidden      = \"ERR_FORBIDDEN\"\n-\tCodeNotFound       = \"ERR_NOT_FOUND\"\n-\tCodeNotImplemented = \"ERR_NOT_IMPLEMENTED\"\n-\tCodeTimeout        = \"ERR_TIMEOUT\"\n-\tCodeInternal       = \"ERR_INTERNAL\"\n+\tCodeUnauthorized        = \"ERR_UNAUTHORIZED\"\n+\tCodeBadRequest          = \"ERR_BAD_REQUEST\"\n+\tCodeForbidden           = \"ERR_FORBIDDEN\"\n+\tCodeNotFound            = \"ERR_NOT_FOUND\"\n+\tCodeNotImplemented      = \"ERR_NOT_IMPLEMENTED\"\n+\tCodeTimeout             = \"ERR_TIMEOUT\"\n+\tCodeInternal            = \"ERR_INTERNAL\"\n+\tCodeDBUpdateRowNotFound = \"ERR_DB_UPDATE_ROW_NOT_FOUND\"","path":"errors/errors.go","position":18,"original_position":18,"commit_id":"2de02e880d085de81761d20517ea0b5f127c7b23","original_commit_id":"2de02e880d085de81761d20517ea0b5f127c7b23","user":{"login":"jessesuen","id":12677113,"node_id":"MDQ6VXNlcjEyNjc3MTEz","avatar_url":"https://avatars0.githubusercontent.com/u/12677113?v=4","gravatar_id":"","url":"https://api.github.com/users/jessesuen","html_url":"https://github.com/jessesuen","followers_url":"https://api.github.com/users/jessesuen/followers","following_url":"https://api.github.com/users/jessesuen/following{/other_user}","gists_url":"https://api.github.com/users/jessesuen/gists{/gist_id}","starred_url":"https://api.github.com/users/jessesuen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jessesuen/subscriptions","organizations_url":"https://api.github.com/users/jessesuen/orgs","repos_url":"https://api.github.com/users/jessesuen/repos","events_url":"https://api.github.com/users/jessesuen/events{/privacy}","received_events_url":"https://api.github.com/users/jessesuen/received_events","type":"User","site_admin":false},"body":"Further review shows that the way that we use this code is to implement Upsert. But that is an implementation detail of the `sqldb` package to implement Save(). This should be handled there and errors package should not be touched.","created_at":"2019-05-15T00:34:06Z","updated_at":"2019-05-15T00:48:32Z","html_url":"https://github.com/argoproj/argo/pull/1344#discussion_r284050507","pull_request_url":"https://api.github.com/repos/argoproj/argo/pulls/1344","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/argoproj/argo/pulls/comments/284050507"},"html":{"href":"https://github.com/argoproj/argo/pull/1344#discussion_r284050507"},"pull_request":{"href":"https://api.github.com/repos/argoproj/argo/pulls/1344"}},"in_reply_to_id":283951612},"pull_request":{"url":"https://api.github.com/repos/argoproj/argo/pulls/1344","id":273957013,"node_id":"MDExOlB1bGxSZXF1ZXN0MjczOTU3MDEz","html_url":"https://github.com/argoproj/argo/pull/1344","diff_url":"https://github.com/argoproj/argo/pull/1344.diff","patch_url":"https://github.com/argoproj/argo/pull/1344.patch","issue_url":"https://api.github.com/repos/argoproj/argo/issues/1344","number":1344,"state":"open","locked":false,"title":"Centralized Longterm workflow persistence storage ","user":{"login":"sarabala1979","id":33908564,"node_id":"MDQ6VXNlcjMzOTA4NTY0","avatar_url":"https://avatars0.githubusercontent.com/u/33908564?v=4","gravatar_id":"","url":"https://api.github.com/users/sarabala1979","html_url":"https://github.com/sarabala1979","followers_url":"https://api.github.com/users/sarabala1979/followers","following_url":"https://api.github.com/users/sarabala1979/following{/other_user}","gists_url":"https://api.github.com/users/sarabala1979/gists{/gist_id}","starred_url":"https://api.github.com/users/sarabala1979/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sarabala1979/subscriptions","organizations_url":"https://api.github.com/users/sarabala1979/orgs","repos_url":"https://api.github.com/users/sarabala1979/repos","events_url":"https://api.github.com/users/sarabala1979/events{/privacy}","received_events_url":"https://api.github.com/users/sarabala1979/received_events","type":"User","site_admin":false},"body":"This feature implementation will enable to long term workflow resource persistence storage on configured Database.  This feature supports only centralized DB configuration.\r\n\r\nImplementations:\r\n1. Added upper.io/db/v3 adapter package to support most of the database drivers with a common interface\r\n2. Implemented Postgres and Mysql\r\n4. Added persistConfig in **workflow-controller-configmap**\r\n\r\nExample Config (Mysql):\r\n```   \r\n persistConfig:\r\n      persistConnectPool:\r\n        maxIdleConns: 100\r\n        maxOpenConns: 0\r\n      supportLargeWorkflow: false\r\n      tableName: argo_workflow\r\n      mysql:\r\n        host: localhost\r\n        port: 3306\r\n        database: argo\r\n        userNameSecret:\r\n          name: argo-mysql-persist\r\n          key: username\r\n        passwordSecret:\r\n          name: argo-mysql-persist\r\n          key: password\r\n```\r\nPostgres:\r\n\r\n```\r\n persistConfig:\r\n      persistConnectPool:\r\n        maxIdleConns: 100\r\n        maxOpenConns: 0\r\n      supportLargeWorkflow: false\r\n      tableName: argo_workflow\r\n      postgresql:\r\n        host: localhost\r\n        port: 31233\r\n        database: postgresdb\r\n        userNameSecret:\r\n          name: argo-postgres-config\r\n          key: username\r\n        passwordSecret:\r\n          name: argo-postgres-config\r\n          key: password\r\n```\r\n\r\n**Table Schema - Postgres**\r\n\r\n```\r\ncreate table argo_workflow (\r\nid varchar(128) ,\r\nname varchar(256),\r\nphase varchar(25),\r\nnamespace varchar(256),\r\nworkflow text,\r\nstartedAt timestamp,\r\nfinishedAt timestamp,\r\nprimary key (id, namespace)\r\n)\r\n```\r\n\r\n**Table Schema - MYSQL**\r\n```\r\nCREATE  TABLE `argo_workflow` (\r\n  `id` varchar(24) NOT NULL DEFAULT \"\", \r\n  `name` varchar(128) DEFAULT NULL,\r\n  `phase` varchar(24) DEFAULT NULL,\r\n  `namespace` varchar(24) NOT NULL DEFAULT \"\" ,\r\n  `workflow` longtext,\r\n  `startedAt` datetime DEFAULT NULL,\r\n  `finishedAt` datetime DEFAULT NULL,\r\n  PRIMARY KEY (`id`(24), `namespace`(24))\r\n) ENGINE=InnoDB DEFAULT CHARSET=utf8;\r\n```\r\n\r\nThis PR will enable the partial support on large workflow with config variable supportLargeWorkflow.\r\n**supportLargeWorkflow = false**\r\nArgo will save the entire workflow into etcd and DB. \r\n**supportLargeWorkflow = true**\r\nArgo will save the workflow without nodestatus in etcd  and workflow+nodestatus in DB.  ArgoUI and argo cli will not support this feature in v2.4. \r\n\r\n\r\nInstalling Postgres on Kube:\r\nhttps://github.com/helm/charts/tree/master/stable/postgresql\r\n\r\n","created_at":"2019-04-26T16:15:21Z","updated_at":"2019-05-15T00:48:32Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6a320e5fc491d09e93a9faaf155e68d97fb42e9f","assignee":null,"assignees":[],"requested_reviewers":[{"login":"alexmt","id":426437,"node_id":"MDQ6VXNlcjQyNjQzNw==","avatar_url":"https://avatars1.githubusercontent.com/u/426437?v=4","gravatar_id":"","url":"https://api.github.com/users/alexmt","html_url":"https://github.com/alexmt","followers_url":"https://api.github.com/users/alexmt/followers","following_url":"https://api.github.com/users/alexmt/following{/other_user}","gists_url":"https://api.github.com/users/alexmt/gists{/gist_id}","starred_url":"https://api.github.com/users/alexmt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexmt/subscriptions","organizations_url":"https://api.github.com/users/alexmt/orgs","repos_url":"https://api.github.com/users/alexmt/repos","events_url":"https://api.github.com/users/alexmt/events{/privacy}","received_events_url":"https://api.github.com/users/alexmt/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/argoproj/argo/pulls/1344/commits","review_comments_url":"https://api.github.com/repos/argoproj/argo/pulls/1344/comments","review_comment_url":"https://api.github.com/repos/argoproj/argo/pulls/comments{/number}","comments_url":"https://api.github.com/repos/argoproj/argo/issues/1344/comments","statuses_url":"https://api.github.com/repos/argoproj/argo/statuses/2de02e880d085de81761d20517ea0b5f127c7b23","head":{"label":"sarabala1979:Issue745","ref":"Issue745","sha":"2de02e880d085de81761d20517ea0b5f127c7b23","user":{"login":"sarabala1979","id":33908564,"node_id":"MDQ6VXNlcjMzOTA4NTY0","avatar_url":"https://avatars0.githubusercontent.com/u/33908564?v=4","gravatar_id":"","url":"https://api.github.com/users/sarabala1979","html_url":"https://github.com/sarabala1979","followers_url":"https://api.github.com/users/sarabala1979/followers","following_url":"https://api.github.com/users/sarabala1979/following{/other_user}","gists_url":"https://api.github.com/users/sarabala1979/gists{/gist_id}","starred_url":"https://api.github.com/users/sarabala1979/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sarabala1979/subscriptions","organizations_url":"https://api.github.com/users/sarabala1979/orgs","repos_url":"https://api.github.com/users/sarabala1979/repos","events_url":"https://api.github.com/users/sarabala1979/events{/privacy}","received_events_url":"https://api.github.com/users/sarabala1979/received_events","type":"User","site_admin":false},"repo":{"id":172997048,"node_id":"MDEwOlJlcG9zaXRvcnkxNzI5OTcwNDg=","name":"argo","full_name":"sarabala1979/argo","private":false,"owner":{"login":"sarabala1979","id":33908564,"node_id":"MDQ6VXNlcjMzOTA4NTY0","avatar_url":"https://avatars0.githubusercontent.com/u/33908564?v=4","gravatar_id":"","url":"https://api.github.com/users/sarabala1979","html_url":"https://github.com/sarabala1979","followers_url":"https://api.github.com/users/sarabala1979/followers","following_url":"https://api.github.com/users/sarabala1979/following{/other_user}","gists_url":"https://api.github.com/users/sarabala1979/gists{/gist_id}","starred_url":"https://api.github.com/users/sarabala1979/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sarabala1979/subscriptions","organizations_url":"https://api.github.com/users/sarabala1979/orgs","repos_url":"https://api.github.com/users/sarabala1979/repos","events_url":"https://api.github.com/users/sarabala1979/events{/privacy}","received_events_url":"https://api.github.com/users/sarabala1979/received_events","type":"User","site_admin":false},"html_url":"https://github.com/sarabala1979/argo","description":"ArgoProj: Get stuff done with Kubernetes.","fork":true,"url":"https://api.github.com/repos/sarabala1979/argo","forks_url":"https://api.github.com/repos/sarabala1979/argo/forks","keys_url":"https://api.github.com/repos/sarabala1979/argo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sarabala1979/argo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sarabala1979/argo/teams","hooks_url":"https://api.github.com/repos/sarabala1979/argo/hooks","issue_events_url":"https://api.github.com/repos/sarabala1979/argo/issues/events{/number}","events_url":"https://api.github.com/repos/sarabala1979/argo/events","assignees_url":"https://api.github.com/repos/sarabala1979/argo/assignees{/user}","branches_url":"https://api.github.com/repos/sarabala1979/argo/branches{/branch}","tags_url":"https://api.github.com/repos/sarabala1979/argo/tags","blobs_url":"https://api.github.com/repos/sarabala1979/argo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sarabala1979/argo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sarabala1979/argo/git/refs{/sha}","trees_url":"https://api.github.com/repos/sarabala1979/argo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sarabala1979/argo/statuses/{sha}","languages_url":"https://api.github.com/repos/sarabala1979/argo/languages","stargazers_url":"https://api.github.com/repos/sarabala1979/argo/stargazers","contributors_url":"https://api.github.com/repos/sarabala1979/argo/contributors","subscribers_url":"https://api.github.com/repos/sarabala1979/argo/subscribers","subscription_url":"https://api.github.com/repos/sarabala1979/argo/subscription","commits_url":"https://api.github.com/repos/sarabala1979/argo/commits{/sha}","git_commits_url":"https://api.github.com/repos/sarabala1979/argo/git/commits{/sha}","comments_url":"https://api.github.com/repos/sarabala1979/argo/comments{/number}","issue_comment_url":"https://api.github.com/repos/sarabala1979/argo/issues/comments{/number}","contents_url":"https://api.github.com/repos/sarabala1979/argo/contents/{+path}","compare_url":"https://api.github.com/repos/sarabala1979/argo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sarabala1979/argo/merges","archive_url":"https://api.github.com/repos/sarabala1979/argo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sarabala1979/argo/downloads","issues_url":"https://api.github.com/repos/sarabala1979/argo/issues{/number}","pulls_url":"https://api.github.com/repos/sarabala1979/argo/pulls{/number}","milestones_url":"https://api.github.com/repos/sarabala1979/argo/milestones{/number}","notifications_url":"https://api.github.com/repos/sarabala1979/argo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sarabala1979/argo/labels{/name}","releases_url":"https://api.github.com/repos/sarabala1979/argo/releases{/id}","deployments_url":"https://api.github.com/repos/sarabala1979/argo/deployments","created_at":"2019-02-27T22:00:07Z","updated_at":"2019-04-09T19:11:42Z","pushed_at":"2019-05-10T16:03:07Z","git_url":"git://github.com/sarabala1979/argo.git","ssh_url":"git@github.com:sarabala1979/argo.git","clone_url":"https://github.com/sarabala1979/argo.git","svn_url":"https://github.com/sarabala1979/argo","homepage":"https://argoproj.github.io","size":36134,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"disabled":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"argoproj:master","ref":"master","sha":"4e37a444bde2a034885d0db35f7b38684505063e","user":{"login":"argoproj","id":30269780,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMwMjY5Nzgw","avatar_url":"https://avatars3.githubusercontent.com/u/30269780?v=4","gravatar_id":"","url":"https://api.github.com/users/argoproj","html_url":"https://github.com/argoproj","followers_url":"https://api.github.com/users/argoproj/followers","following_url":"https://api.github.com/users/argoproj/following{/other_user}","gists_url":"https://api.github.com/users/argoproj/gists{/gist_id}","starred_url":"https://api.github.com/users/argoproj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/argoproj/subscriptions","organizations_url":"https://api.github.com/users/argoproj/orgs","repos_url":"https://api.github.com/users/argoproj/repos","events_url":"https://api.github.com/users/argoproj/events{/privacy}","received_events_url":"https://api.github.com/users/argoproj/received_events","type":"Organization","site_admin":false},"repo":{"id":100982449,"node_id":"MDEwOlJlcG9zaXRvcnkxMDA5ODI0NDk=","name":"argo","full_name":"argoproj/argo","private":false,"owner":{"login":"argoproj","id":30269780,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMwMjY5Nzgw","avatar_url":"https://avatars3.githubusercontent.com/u/30269780?v=4","gravatar_id":"","url":"https://api.github.com/users/argoproj","html_url":"https://github.com/argoproj","followers_url":"https://api.github.com/users/argoproj/followers","following_url":"https://api.github.com/users/argoproj/following{/other_user}","gists_url":"https://api.github.com/users/argoproj/gists{/gist_id}","starred_url":"https://api.github.com/users/argoproj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/argoproj/subscriptions","organizations_url":"https://api.github.com/users/argoproj/orgs","repos_url":"https://api.github.com/users/argoproj/repos","events_url":"https://api.github.com/users/argoproj/events{/privacy}","received_events_url":"https://api.github.com/users/argoproj/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/argoproj/argo","description":"ArgoProj: Get stuff done with Kubernetes.","fork":false,"url":"https://api.github.com/repos/argoproj/argo","forks_url":"https://api.github.com/repos/argoproj/argo/forks","keys_url":"https://api.github.com/repos/argoproj/argo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/argoproj/argo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/argoproj/argo/teams","hooks_url":"https://api.github.com/repos/argoproj/argo/hooks","issue_events_url":"https://api.github.com/repos/argoproj/argo/issues/events{/number}","events_url":"https://api.github.com/repos/argoproj/argo/events","assignees_url":"https://api.github.com/repos/argoproj/argo/assignees{/user}","branches_url":"https://api.github.com/repos/argoproj/argo/branches{/branch}","tags_url":"https://api.github.com/repos/argoproj/argo/tags","blobs_url":"https://api.github.com/repos/argoproj/argo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/argoproj/argo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/argoproj/argo/git/refs{/sha}","trees_url":"https://api.github.com/repos/argoproj/argo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/argoproj/argo/statuses/{sha}","languages_url":"https://api.github.com/repos/argoproj/argo/languages","stargazers_url":"https://api.github.com/repos/argoproj/argo/stargazers","contributors_url":"https://api.github.com/repos/argoproj/argo/contributors","subscribers_url":"https://api.github.com/repos/argoproj/argo/subscribers","subscription_url":"https://api.github.com/repos/argoproj/argo/subscription","commits_url":"https://api.github.com/repos/argoproj/argo/commits{/sha}","git_commits_url":"https://api.github.com/repos/argoproj/argo/git/commits{/sha}","comments_url":"https://api.github.com/repos/argoproj/argo/comments{/number}","issue_comment_url":"https://api.github.com/repos/argoproj/argo/issues/comments{/number}","contents_url":"https://api.github.com/repos/argoproj/argo/contents/{+path}","compare_url":"https://api.github.com/repos/argoproj/argo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/argoproj/argo/merges","archive_url":"https://api.github.com/repos/argoproj/argo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/argoproj/argo/downloads","issues_url":"https://api.github.com/repos/argoproj/argo/issues{/number}","pulls_url":"https://api.github.com/repos/argoproj/argo/pulls{/number}","milestones_url":"https://api.github.com/repos/argoproj/argo/milestones{/number}","notifications_url":"https://api.github.com/repos/argoproj/argo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/argoproj/argo/labels{/name}","releases_url":"https://api.github.com/repos/argoproj/argo/releases{/id}","deployments_url":"https://api.github.com/repos/argoproj/argo/deployments","created_at":"2017-08-21T18:50:44Z","updated_at":"2019-05-14T23:07:20Z","pushed_at":"2019-05-14T01:17:08Z","git_url":"git://github.com/argoproj/argo.git","ssh_url":"git@github.com:argoproj/argo.git","clone_url":"https://github.com/argoproj/argo.git","svn_url":"https://github.com/argoproj/argo","homepage":"https://argoproj.github.io","size":21355,"stargazers_count":2912,"watchers_count":2912,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":398,"mirror_url":null,"archived":false,"disabled":false,"open_issues_count":161,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":398,"open_issues":161,"watchers":2912,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/argoproj/argo/pulls/1344"},"html":{"href":"https://github.com/argoproj/argo/pull/1344"},"issue":{"href":"https://api.github.com/repos/argoproj/argo/issues/1344"},"comments":{"href":"https://api.github.com/repos/argoproj/argo/issues/1344/comments"},"review_comments":{"href":"https://api.github.com/repos/argoproj/argo/pulls/1344/comments"},"review_comment":{"href":"https://api.github.com/repos/argoproj/argo/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/argoproj/argo/pulls/1344/commits"},"statuses":{"href":"https://api.github.com/repos/argoproj/argo/statuses/2de02e880d085de81761d20517ea0b5f127c7b23"}},"author_association":"CONTRIBUTOR"}}
other: {"actor":{"display_login":"jessesuen"}}