{"action":"created","comment":{"url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/comments/238556683","pull_request_review_id":180979499,"id":238556683,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzODU1NjY4Mw==","diff_hunk":"@@ -0,0 +1,451 @@\n+package await\n+\n+import (\n+\t\"fmt\"\n+\t\"reflect\"\n+\t\"time\"\n+\n+\t\"github.com/golang/glog\"\n+\t\"github.com/pkg/errors\"\n+\t\"github.com/pulumi/pulumi-kubernetes/pkg/client\"\n+\t\"github.com/pulumi/pulumi-kubernetes/pkg/openapi\"\n+\t\"github.com/pulumi/pulumi/pkg/diag\"\n+\tmetav1 \"k8s.io/apimachinery/pkg/apis/meta/v1\"\n+\t\"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured\"\n+\t\"k8s.io/apimachinery/pkg/runtime\"\n+\t\"k8s.io/apimachinery/pkg/runtime/schema\"\n+\t\"k8s.io/apimachinery/pkg/watch\"\n+\t\"k8s.io/client-go/dynamic\"\n+)\n+\n+// ------------------------------------------------------------------------------------------------\n+\n+// Await logic for apps/v1beta1/StatefulSet, apps/v1beta2/StatefulSet,\n+// and apps/v1/StatefulSet.\n+//\n+// The goal of this code is to provide a fine-grained account of the status of a Kubernetes\n+// StatefulSet as it is being initialized. The idea is that if something goes wrong early, we want to\n+// alert the user so they can cancel the operation instead of waiting for timeout (~10 minutes).\n+//\n+// A StatefulSet is a construct that allows users to specify how to execute an update to a stateful\n+// application that is replicated some number of times in a cluster. When an application is updated,\n+// the StatefulSet will incrementally roll out the new version (according to the policy requested by\n+// the user). When the new application Pods becomes \"live\" (as specified by the liveness and\n+// readiness probes), the old Pods are killed and deleted.\n+//\n+// The success conditions are somewhat complex:\n+//\n+//   1. `.status.replicas`, `.status.currentReplicas` and `.status.readyReplicas` match the\n+//      value of `.spec.replicas`.\n+//   2. `.status.updateRevision` matches `.status.currentRevision`.\n+//\n+// The event loop depends on the following channels:\n+//\n+//   1. The StatefulSet channel, to which the Kubernetes API server will push every change\n+//      (additions, modifications, deletions) to any StatefulSet it knows about.\n+//   2. The Pod channel, which is the same idea as the StatefulSet channel, except it gets updates\n+//      to Pod objects. These are then aggregated and any errors are bundled together and\n+//      periodically reported to the user.\n+//   3. A timeout channel, which fires after some minutes.\n+//   4. A cancellation channel, with which the user can signal cancellation (e.g., using SIGINT).\n+//   5. A period channel, which is used to signal when we should display an aggregated report of\n+//      Pod errors we know about.\n+//\n+// The `statefulsetInitAwaiter` will synchronously process events from the union of all these\n+// channels. Any time the success conditions described above are reached, we will terminate\n+// the awaiter.\n+//\n+// The opportunity to display intermediate results will typically appear after a container in the\n+// Pod fails, (e.g., volume fails to mount, image fails to pull, exited with code 1, etc.).\n+//\n+// NB: Deleting a StatefulSet does not automatically delete any associated PersistentVolumes. We\n+//     may wish to address this case separately, but for now, PersistentVolumes are ignored by\n+//     the await logic. The await logic will still catch misconfiguration problems with\n+//     PersistentVolumeClaims because the related Pod will fail to go active, preventing success\n+//     condition 3 from being met.\n+//\n+// x-refs:\n+//   * https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/\n+//   * https://kubernetes.io/docs/tutorials/stateful-application/basic-stateful-set/\n+//   * https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.12/#statefulset-v1-apps\n+\n+// ------------------------------------------------------------------------------------------------\n+\n+type statefulsetInitAwaiter struct {\n+\tconfig            updateAwaitConfig\n+\trevisionReady     bool\n+\treplicasReady     bool\n+\tcurrentGeneration int64\n+\n+\tstatefulsetErrors map[string]string\n+\n+\tstatefulset     *unstructured.Unstructured\n+\tpods            map[string]*unstructured.Unstructured\n+\tcurrentReplicas int64\n+\ttargetReplicas  int64\n+}\n+\n+func makeStatefulSetInitAwaiter(c updateAwaitConfig) *statefulsetInitAwaiter {\n+\treturn &statefulsetInitAwaiter{\n+\t\tconfig:        c,\n+\t\trevisionReady: false,\n+\t\treplicasReady: false,\n+\n+\t\t// NOTE: Generation 0 is invalid, so this is a good sentinel value.\n+\t\tcurrentGeneration: 0,\n+\n+\t\tstatefulsetErrors: map[string]string{},\n+\n+\t\tstatefulset: c.currentOutputs,\n+\t\tpods:        map[string]*unstructured.Unstructured{},\n+\t}\n+}\n+\n+// Await blocks until a StatefulSet is \"active\" or encounters an error.\n+//\n+// We succeed when only when all of the following are true:\n+//\n+//   1. The value of `spec.replicas` matches `.status.replicas`, `.status.currentReplicas`,\n+//      and `.status.readyReplicas`.\n+//   2. The value of `.status.updateRevision` matches `.status.currentRevision`.\n+func (sia *statefulsetInitAwaiter) Await() error {\n+\n+\tpodClient, err := sia.makeClients()\n+\tif err != nil {\n+\t\treturn err\n+\t}\n+\n+\t// Create Deployment watcher.\n+\tstatefulsetWatcher, err := sia.config.clientForResource.Watch(metav1.ListOptions{})\n+\tif err != nil {\n+\t\treturn errors.Wrapf(err, \"Could not set up watch for StatefulSet object %q\",\n+\t\t\tsia.config.currentInputs.GetName())\n+\t}\n+\tdefer statefulsetWatcher.Stop()\n+\n+\t// Create Pod watcher.\n+\tpodWatcher, err := podClient.Watch(metav1.ListOptions{})\n+\tif err != nil {\n+\t\treturn errors.Wrapf(err,\n+\t\t\t\"Could not create watcher for Pods objects associated with StatefulSet %q\",\n+\t\t\tsia.config.currentInputs.GetName())\n+\t}\n+\tdefer podWatcher.Stop()\n+\n+\tperiod := time.NewTicker(10 * time.Second)\n+\tdefer period.Stop()\n+\n+\treturn sia.await(statefulsetWatcher, podWatcher, time.After(5*time.Minute), period.C)\n+}\n+\n+func (sia *statefulsetInitAwaiter) Read() error {\n+\t// Get clients needed to retrieve live versions of relevant Deployments, ReplicaSets, and Pods.\n+\tpodClient, err := sia.makeClients()\n+\tif err != nil {\n+\t\treturn err\n+\t}\n+\n+\t// Get live versions of StatefulSet and Pods.\n+\tstatefulset, err := sia.config.clientForResource.Get(sia.config.currentInputs.GetName(),\n+\t\tmetav1.GetOptions{})\n+\tif err != nil {\n+\t\t// IMPORTANT: Do not wrap this error! If this is a 404, the provider need to know so that it\n+\t\t// can mark the statefulset as having been deleted.\n+\t\treturn err\n+\t}\n+\n+\t//\n+\t// In contrast to the case of `statefulset`, an error getting the Pod lists does\n+\t// not indicate that this resource was deleted, and we therefore should report the wrapped error\n+\t// in a way that is useful to the user.\n+\t//\n+\n+\tpodList, err := podClient.List(metav1.ListOptions{})\n+\tif err != nil {\n+\t\tglog.V(3).Infof(\"Error retrieving Pod list for StatefulSet %q: %v\",\n+\t\t\tstatefulset.GetName(), err)\n+\t\tpodList = &unstructured.UnstructuredList{Items: []unstructured.Unstructured{}}\n+\t}\n+\n+\treturn sia.read(statefulset, podList.(*unstructured.UnstructuredList))\n+}\n+\n+// read is a helper companion to `Read` designed to make it easy to test this module.\n+func (sia *statefulsetInitAwaiter) read(\n+\tstatefulset *unstructured.Unstructured, pods *unstructured.UnstructuredList,\n+) error {\n+\tsia.processStatefulSetEvent(watchAddedEvent(statefulset))\n+\n+\terr := pods.EachListItem(func(pod runtime.Object) error {\n+\t\tsia.processPodEvent(watchAddedEvent(pod.(*unstructured.Unstructured)))\n+\t\treturn nil\n+\t})\n+\tif err != nil {\n+\t\tglog.V(3).Infof(\"Error iterating over Pod list for StatefulSet %q: %v\",\n+\t\t\tstatefulset.GetName(), err)\n+\t}\n+\n+\tif sia.checkAndLogStatus() {\n+\t\treturn nil\n+\t}\n+\n+\treturn &initializationError{\n+\t\tsubErrors: sia.errorMessages(),\n+\t\tobject:    statefulset,\n+\t}\n+}\n+\n+// await is a helper companion to `Await` designed to make it easy to test this module.\n+func (sia *statefulsetInitAwaiter) await(\n+\tstatefulsetWatcher, podWatcher watch.Interface, timeout, period <-chan time.Time,\n+) error {\n+\tfor {\n+\t\tif sia.checkAndLogStatus() {\n+\t\t\treturn nil\n+\t\t}\n+\n+\t\t// Else, wait for updates.\n+\t\tselect {\n+\t\tcase <-sia.config.ctx.Done():\n+\t\t\treturn &cancellationError{\n+\t\t\t\tobject:    sia.statefulset,\n+\t\t\t\tsubErrors: sia.errorMessages(),\n+\t\t\t}\n+\t\tcase <-timeout:\n+\t\t\treturn &timeoutError{\n+\t\t\t\tobject:    sia.statefulset,\n+\t\t\t\tsubErrors: sia.errorMessages(),\n+\t\t\t}\n+\t\tcase <-period:\n+\t\t\tscheduleErrors, containerErrors := sia.aggregatePodErrors()\n+\t\t\tfor _, message := range scheduleErrors {\n+\t\t\t\tsia.config.logStatus(diag.Warning, message)\n+\t\t\t}\n+\n+\t\t\tfor _, message := range containerErrors {\n+\t\t\t\tsia.config.logStatus(diag.Warning, message)\n+\t\t\t}\n+\t\tcase event := <-statefulsetWatcher.ResultChan():\n+\t\t\tsia.processStatefulSetEvent(event)\n+\t\tcase event := <-podWatcher.ResultChan():\n+\t\t\tsia.processPodEvent(event)\n+\t\t}\n+\t}\n+}\n+\n+// checkAndLogStatus checks whether we've succeeded, and logs the result as a status message to\n+// the provider.\n+func (sia *statefulsetInitAwaiter) checkAndLogStatus() bool {\n+\tif sia.replicasReady && sia.revisionReady {\n+\t\tsia.config.logStatus(diag.Info, \"✅ StatefulSet initialization complete\")\n+\t\treturn true\n+\t}\n+\n+\tisInitialDeployment := sia.currentGeneration <= 1\n+\n+\t// For initial generation, the revision doesn't need to be updated, so skip that step in the log.\n+\tif isInitialDeployment {\n+\t\tsia.config.logStatus(diag.Info, fmt.Sprintf(\"[1/2] Waiting for StatefulSet to create Pods (%d/%d Pods ready)\",\n+\t\t\tsia.currentReplicas, sia.targetReplicas))\n+\t} else {\n+\t\tswitch {\n+\t\tcase !sia.replicasReady:\n+\t\t\tsia.config.logStatus(diag.Info, fmt.Sprintf(\"[1/3] Waiting for StatefulSet update to roll out (%d/%d Pods ready)\",\n+\t\t\t\tsia.currentReplicas, sia.targetReplicas))\n+\t\tcase !sia.revisionReady:\n+\t\t\tsia.config.logStatus(diag.Info, \"[2/3] Waiting for StatefulSet to update .status.currentRevision\")\n+\t\t}\n+\t}\n+\n+\treturn false\n+}\n+\n+func (sia *statefulsetInitAwaiter) processStatefulSetEvent(event watch.Event) {\n+\tinputStatefulSetName := sia.config.currentInputs.GetName()\n+\n+\tstatefulset, isUnstructured := event.Object.(*unstructured.Unstructured)\n+\tif !isUnstructured {\n+\t\tglog.V(3).Infof(\"StatefulSet watch received unknown object type %q\",\n+\t\t\treflect.TypeOf(statefulset))\n+\t\treturn\n+\t}\n+\n+\t// Start over, prove that rollout is complete.\n+\tsia.statefulsetErrors = map[string]string{}\n+\tsia.revisionReady = false\n+\tsia.replicasReady = false\n+\n+\t// Do nothing if this is not the StatefulSet we're waiting for.\n+\tif statefulset.GetName() != inputStatefulSetName {\n+\t\treturn\n+\t}\n+\n+\t// Mark the rollout as incomplete if it's deleted.\n+\tif event.Type == watch.Deleted {\n+\t\treturn\n+\t}\n+\n+\tsia.statefulset = statefulset\n+\n+\t// Get current generation of the StatefulSet.\n+\tsia.currentGeneration = statefulset.GetGeneration()\n+\n+\tif sia.currentGeneration == 0 {\n+\t\t// No current generation, StatefulSet controller has not yet created a StatefulSet.\n+\t\t// Do nothing.\n+\t\treturn\n+\t}\n+\n+\t// Check if current revision matches update revision.\n+\tvar currentRevision, updateRevision string\n+\tif rawCurrentRevision, ok := openapi.Pluck(statefulset.Object, \"status\", \"currentRevision\"); ok {\n+\t\tcurrentRevision = rawCurrentRevision.(string)\n+\t}\n+\tif rawUpdateRevision, ok := openapi.Pluck(statefulset.Object, \"status\", \"updateRevision\"); ok {\n+\t\tupdateRevision = rawUpdateRevision.(string)\n+\t}\n+\tsia.revisionReady = (currentRevision != \"\") && (currentRevision == updateRevision)\n+\n+\t// Check if all expected replicas are ready.\n+\tvar replicas, statusReplicas, statusReadyReplicas, statusCurrentReplicas, statusUpdatedReplicas int64\n+\tif rawReplicas, ok := openapi.Pluck(statefulset.Object, \"spec\", \"replicas\"); ok {\n+\t\treplicas = rawReplicas.(int64)\n+\t}\n+\tif rawStatusReplicas, ok := openapi.Pluck(statefulset.Object, \"status\", \"replicas\"); ok {\n+\t\tstatusReplicas = rawStatusReplicas.(int64)\n+\t}\n+\tif rawStatusReadyReplicas, ok := openapi.Pluck(statefulset.Object, \"status\", \"readyReplicas\"); ok {\n+\t\tstatusReadyReplicas = rawStatusReadyReplicas.(int64)\n+\t}\n+\tif rawStatusCurrentReplicas, ok := openapi.Pluck(statefulset.Object, \"status\", \"currentReplicas\"); ok {\n+\t\tstatusCurrentReplicas = rawStatusCurrentReplicas.(int64)\n+\t}\n+\tif rawStatusUpdatedReplicas, ok := openapi.Pluck(statefulset.Object, \"status\", \"updatedReplicas\"); ok {\n+\t\tstatusUpdatedReplicas = rawStatusUpdatedReplicas.(int64)\n+\t} else {\n+\t\tstatusUpdatedReplicas = 0\n+\t}\n+\tsia.replicasReady = (replicas == statusReplicas) &&\n+\t\t(replicas == statusReadyReplicas) &&\n+\t\t(replicas == statusCurrentReplicas)\n+\n+\t// Set current and target replica counts for logging purposes.\n+\tsia.targetReplicas = replicas\n+\t// For the initial rollout, .status.readyReplicas is an accurate gauge of progress.\n+\t// For subsequent updates, we must also account for .status.updatedReplicas.\n+\tif sia.revisionReady {\n+\t\tsia.currentReplicas = statusReadyReplicas\n+\t} else {\n+\t\t// During a rollout, the number of \"ready\" replicas can include instances of the previous revision,\n+\t\t// so don't count those towards the target count.","path":"pkg/await/apps_statefulset.go","position":340,"original_position":340,"commit_id":"75b71be37d346a148e189490a34b5be339544f65","original_commit_id":"75b71be37d346a148e189490a34b5be339544f65","user":{"login":"hausdorff","id":1409156,"node_id":"MDQ6VXNlcjE0MDkxNTY=","avatar_url":"https://avatars1.githubusercontent.com/u/1409156?v=4","gravatar_id":"","url":"https://api.github.com/users/hausdorff","html_url":"https://github.com/hausdorff","followers_url":"https://api.github.com/users/hausdorff/followers","following_url":"https://api.github.com/users/hausdorff/following{/other_user}","gists_url":"https://api.github.com/users/hausdorff/gists{/gist_id}","starred_url":"https://api.github.com/users/hausdorff/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hausdorff/subscriptions","organizations_url":"https://api.github.com/users/hausdorff/orgs","repos_url":"https://api.github.com/users/hausdorff/repos","events_url":"https://api.github.com/users/hausdorff/events{/privacy}","received_events_url":"https://api.github.com/users/hausdorff/received_events","type":"User","site_admin":false},"body":"I did not know this. I thought we always killed all replicas, then boot up new ones. Is that not true?","created_at":"2018-12-04T07:55:25Z","updated_at":"2018-12-04T07:57:00Z","html_url":"https://github.com/pulumi/pulumi-kubernetes/pull/307#discussion_r238556683","pull_request_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/307","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/comments/238556683"},"html":{"href":"https://github.com/pulumi/pulumi-kubernetes/pull/307#discussion_r238556683"},"pull_request":{"href":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/307"}}},"pull_request":{"url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/307","id":235145777,"node_id":"MDExOlB1bGxSZXF1ZXN0MjM1MTQ1Nzc3","html_url":"https://github.com/pulumi/pulumi-kubernetes/pull/307","diff_url":"https://github.com/pulumi/pulumi-kubernetes/pull/307.diff","patch_url":"https://github.com/pulumi/pulumi-kubernetes/pull/307.patch","issue_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/issues/307","number":307,"state":"open","locked":false,"title":"Implement incremental update for StatefulSet","user":{"login":"lblackstone","id":9253463,"node_id":"MDQ6VXNlcjkyNTM0NjM=","avatar_url":"https://avatars1.githubusercontent.com/u/9253463?v=4","gravatar_id":"","url":"https://api.github.com/users/lblackstone","html_url":"https://github.com/lblackstone","followers_url":"https://api.github.com/users/lblackstone/followers","following_url":"https://api.github.com/users/lblackstone/following{/other_user}","gists_url":"https://api.github.com/users/lblackstone/gists{/gist_id}","starred_url":"https://api.github.com/users/lblackstone/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lblackstone/subscriptions","organizations_url":"https://api.github.com/users/lblackstone/orgs","repos_url":"https://api.github.com/users/lblackstone/repos","events_url":"https://api.github.com/users/lblackstone/events{/privacy}","received_events_url":"https://api.github.com/users/lblackstone/received_events","type":"User","site_admin":false},"body":"Fixes #300 ","created_at":"2018-11-30T23:35:47Z","updated_at":"2018-12-04T07:56:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ec72f34c3d4668e4fd0c4d8c35bcc9c952e55c30","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/307/commits","review_comments_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/307/comments","review_comment_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/comments{/number}","comments_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/issues/307/comments","statuses_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/statuses/75b71be37d346a148e189490a34b5be339544f65","head":{"label":"pulumi:lblackstone/statefulset-awaiter","ref":"lblackstone/statefulset-awaiter","sha":"75b71be37d346a148e189490a34b5be339544f65","user":{"login":"pulumi","id":21992475,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIxOTkyNDc1","avatar_url":"https://avatars0.githubusercontent.com/u/21992475?v=4","gravatar_id":"","url":"https://api.github.com/users/pulumi","html_url":"https://github.com/pulumi","followers_url":"https://api.github.com/users/pulumi/followers","following_url":"https://api.github.com/users/pulumi/following{/other_user}","gists_url":"https://api.github.com/users/pulumi/gists{/gist_id}","starred_url":"https://api.github.com/users/pulumi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pulumi/subscriptions","organizations_url":"https://api.github.com/users/pulumi/orgs","repos_url":"https://api.github.com/users/pulumi/repos","events_url":"https://api.github.com/users/pulumi/events{/privacy}","received_events_url":"https://api.github.com/users/pulumi/received_events","type":"Organization","site_admin":false},"repo":{"id":116869354,"node_id":"MDEwOlJlcG9zaXRvcnkxMTY4NjkzNTQ=","name":"pulumi-kubernetes","full_name":"pulumi/pulumi-kubernetes","private":false,"owner":{"login":"pulumi","id":21992475,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIxOTkyNDc1","avatar_url":"https://avatars0.githubusercontent.com/u/21992475?v=4","gravatar_id":"","url":"https://api.github.com/users/pulumi","html_url":"https://github.com/pulumi","followers_url":"https://api.github.com/users/pulumi/followers","following_url":"https://api.github.com/users/pulumi/following{/other_user}","gists_url":"https://api.github.com/users/pulumi/gists{/gist_id}","starred_url":"https://api.github.com/users/pulumi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pulumi/subscriptions","organizations_url":"https://api.github.com/users/pulumi/orgs","repos_url":"https://api.github.com/users/pulumi/repos","events_url":"https://api.github.com/users/pulumi/events{/privacy}","received_events_url":"https://api.github.com/users/pulumi/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/pulumi/pulumi-kubernetes","description":"A Kubernetes Pulumi resource provider, providing the full Kubernetes API to multiple languages","fork":false,"url":"https://api.github.com/repos/pulumi/pulumi-kubernetes","forks_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/forks","keys_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/teams","hooks_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/hooks","issue_events_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/issues/events{/number}","events_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/events","assignees_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/assignees{/user}","branches_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/branches{/branch}","tags_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/tags","blobs_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/git/refs{/sha}","trees_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/statuses/{sha}","languages_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/languages","stargazers_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/stargazers","contributors_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/contributors","subscribers_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/subscribers","subscription_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/subscription","commits_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/commits{/sha}","git_commits_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/git/commits{/sha}","comments_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/comments{/number}","issue_comment_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/issues/comments{/number}","contents_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/contents/{+path}","compare_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/merges","archive_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/downloads","issues_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/issues{/number}","pulls_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls{/number}","milestones_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/milestones{/number}","notifications_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/labels{/name}","releases_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/releases{/id}","deployments_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/deployments","created_at":"2018-01-09T20:50:33Z","updated_at":"2018-12-03T23:21:57Z","pushed_at":"2018-12-03T23:29:56Z","git_url":"git://github.com/pulumi/pulumi-kubernetes.git","ssh_url":"git@github.com:pulumi/pulumi-kubernetes.git","clone_url":"https://github.com/pulumi/pulumi-kubernetes.git","svn_url":"https://github.com/pulumi/pulumi-kubernetes","homepage":"","size":2172,"stargazers_count":36,"watchers_count":36,"language":"TypeScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":12,"mirror_url":null,"archived":false,"open_issues_count":55,"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":12,"open_issues":55,"watchers":36,"default_branch":"master"}},"base":{"label":"pulumi:master","ref":"master","sha":"1d8daf7bd10d2cb500c9902aa7f5b23a634ffbd1","user":{"login":"pulumi","id":21992475,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIxOTkyNDc1","avatar_url":"https://avatars0.githubusercontent.com/u/21992475?v=4","gravatar_id":"","url":"https://api.github.com/users/pulumi","html_url":"https://github.com/pulumi","followers_url":"https://api.github.com/users/pulumi/followers","following_url":"https://api.github.com/users/pulumi/following{/other_user}","gists_url":"https://api.github.com/users/pulumi/gists{/gist_id}","starred_url":"https://api.github.com/users/pulumi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pulumi/subscriptions","organizations_url":"https://api.github.com/users/pulumi/orgs","repos_url":"https://api.github.com/users/pulumi/repos","events_url":"https://api.github.com/users/pulumi/events{/privacy}","received_events_url":"https://api.github.com/users/pulumi/received_events","type":"Organization","site_admin":false},"repo":{"id":116869354,"node_id":"MDEwOlJlcG9zaXRvcnkxMTY4NjkzNTQ=","name":"pulumi-kubernetes","full_name":"pulumi/pulumi-kubernetes","private":false,"owner":{"login":"pulumi","id":21992475,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIxOTkyNDc1","avatar_url":"https://avatars0.githubusercontent.com/u/21992475?v=4","gravatar_id":"","url":"https://api.github.com/users/pulumi","html_url":"https://github.com/pulumi","followers_url":"https://api.github.com/users/pulumi/followers","following_url":"https://api.github.com/users/pulumi/following{/other_user}","gists_url":"https://api.github.com/users/pulumi/gists{/gist_id}","starred_url":"https://api.github.com/users/pulumi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pulumi/subscriptions","organizations_url":"https://api.github.com/users/pulumi/orgs","repos_url":"https://api.github.com/users/pulumi/repos","events_url":"https://api.github.com/users/pulumi/events{/privacy}","received_events_url":"https://api.github.com/users/pulumi/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/pulumi/pulumi-kubernetes","description":"A Kubernetes Pulumi resource provider, providing the full Kubernetes API to multiple languages","fork":false,"url":"https://api.github.com/repos/pulumi/pulumi-kubernetes","forks_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/forks","keys_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/teams","hooks_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/hooks","issue_events_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/issues/events{/number}","events_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/events","assignees_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/assignees{/user}","branches_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/branches{/branch}","tags_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/tags","blobs_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/git/refs{/sha}","trees_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/statuses/{sha}","languages_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/languages","stargazers_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/stargazers","contributors_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/contributors","subscribers_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/subscribers","subscription_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/subscription","commits_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/commits{/sha}","git_commits_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/git/commits{/sha}","comments_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/comments{/number}","issue_comment_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/issues/comments{/number}","contents_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/contents/{+path}","compare_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/merges","archive_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/downloads","issues_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/issues{/number}","pulls_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls{/number}","milestones_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/milestones{/number}","notifications_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/labels{/name}","releases_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/releases{/id}","deployments_url":"https://api.github.com/repos/pulumi/pulumi-kubernetes/deployments","created_at":"2018-01-09T20:50:33Z","updated_at":"2018-12-03T23:21:57Z","pushed_at":"2018-12-03T23:29:56Z","git_url":"git://github.com/pulumi/pulumi-kubernetes.git","ssh_url":"git@github.com:pulumi/pulumi-kubernetes.git","clone_url":"https://github.com/pulumi/pulumi-kubernetes.git","svn_url":"https://github.com/pulumi/pulumi-kubernetes","homepage":"","size":2172,"stargazers_count":36,"watchers_count":36,"language":"TypeScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":12,"mirror_url":null,"archived":false,"open_issues_count":55,"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":12,"open_issues":55,"watchers":36,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/307"},"html":{"href":"https://github.com/pulumi/pulumi-kubernetes/pull/307"},"issue":{"href":"https://api.github.com/repos/pulumi/pulumi-kubernetes/issues/307"},"comments":{"href":"https://api.github.com/repos/pulumi/pulumi-kubernetes/issues/307/comments"},"review_comments":{"href":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/307/comments"},"review_comment":{"href":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/pulumi/pulumi-kubernetes/pulls/307/commits"},"statuses":{"href":"https://api.github.com/repos/pulumi/pulumi-kubernetes/statuses/75b71be37d346a148e189490a34b5be339544f65"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"hausdorff"}}