-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Revision should manage activation #1997
Comments
I suspect that we want the networking abstractions to land first. |
cc @tcnghia |
There is no doubt about the issue itself. But we might want to see #1583 land first? |
I believe this can be achieved this way:
In this design, it's the job of the revision controller to update the revision facade k8s-service. Route becomes completely activation-agnostic. In fact, it becomes even revision agnostic, because all it cares about is just a k8s-service to hit. |
This won't provide the activator with enough context to activate the revision. The way we provide this context today is decorating the request with an extra header. |
What component does add the header now? |
When we change |
i was asking about using host header instead of headers recently in slack. planning to bring this up in upcoming networking call for discussion.
…Sent from my iPhone
On Oct 29, 2018, at 6:17 PM, Matt Moore ***@***.***> wrote:
When we change ClusterIngress (backed by Istio) to point at the Activator service, we include rewrite logic to decorate the request with the extra header.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
/assign |
@cppforlife I've got the same question! Why not use Host header? |
Why not append headers to all requests, not just to inactive revisions? |
May be it is doable using a Route header, not a Host header because we can't add header per split. For example, for a split like 60% -> Blue, 40% -> Green we can only add the same header for Blue and Green. However, with a Route header we could probably do this. Both Blue and Green are pointing to activator, and activator can flip coins to route to either Blue-internal or Green-internal. |
Or, instead of a Route header we could probably send a Split header, like |
Trying to sum up the header stuff:
Another more ideal approach is to add revision host header in VitualService. This way, activator does not need to do the choice, but honestly pass though the revision header. |
@lichuqiang How does splitting work now when all revisions are active? |
Got it (after staring at the current code for a while): VirtualService doesn't currently support adding different headers to different splits of traffic! 🦆 |
Istio currently (as of v1.1-snapshot2) can't correctly work with ExternalName services: istio/istio#9950 But there's a workaround (also mentioned in the issue ☝️) |
Thanks for digging this! |
Well, that's exactly my concern. So, my current plan is
|
For #1997. This will be reused in HPA and KPA changes.
* Use generic pkg/resources helpers for endpoint counting * Move SKS helpers to a shared place. For #1997. This will be reused in HPA and KPA changes. * some transient state * remove public service and endpoint reconciliation * remove public service and endpoint reconciliation * formatting unification
* Use generic pkg/resources helpers for endpoint counting * Move SKS helpers to a shared place. For knative#1997. This will be reused in HPA and KPA changes. * some transient state * remove public service and endpoint reconciliation * remove public service and endpoint reconciliation * formatting unification
Bring back public service and manual endpoint reconciliation This is part of the knative#1997.
) * Revert the change that removed the public service creation in SKS Bring back public service and manual endpoint reconciliation This is part of the #1997. * remove the transient state * fix logging * some random test
@vagababov I think where we are qualifies. Let's close this now? |
once the global resync tests merge in, |
Now we can close this one :) |
/close |
@vagababov: Closing this issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Yay! |
- move port related funcs and constants to its own file. register.go sounded wrong for that - update the SKS code and tests to deal with the change - also move a new function there that will be used for probing quite often
* Use generic pkg/resources helpers for endpoint counting * Move SKS helpers to a shared place. For knative#1997. This will be reused in HPA and KPA changes. * some transient state * remove public service and endpoint reconciliation * remove public service and endpoint reconciliation * formatting unification
In my opinion, the fact that today Route manages the deactivation of Revisions feels like a layering violation.
In more detail, activation is widely viewed as a feature of Revisions, but today the semantic boundary is that the Revision surfaces inactivity via
Active: False
, Route(s) referring to inactive Revisions then wire in the activator, and after a grace period the Revision (really KPA) scales the Revision to zero.However, this means that when inactivate the Revision is
Ready: False
, which is often a source of confusion, and presents another interesting race (during initial deployment) where the Revision must pass areadinessProbe
before it is scaled to zero or the Configuration may never witness its readiness.I believe that Revision (possibly through the KPA) should manage its own activation.
cc @vaikas-google @evankanderson @tcnghia @grantr @dprotaso for thoughts.
The text was updated successfully, but these errors were encountered: