Integrating "servicelease" concept, for use with Telepresence?

I’ve asked here in the past about integrating Istio with Telepresence, so that developers can debug existing or new code in a running cluster. There have also been a couple of articles on this topic.

The “static” view of how this would work is to change the VirtualService, adding a route based on a header value to a cloned zombie of the service, and the developer would replace the zombie with the telepresence pod redirecting to their desktop process.

I’ve been thinking more about the dynamic and “for real” details about this. I was thinking that there would be a local web site that a dev goes to which allows them to create “service leases”. They enter a cluster id and a service name, and the webapp uses the logged-in userid to create a “service lease”, which will create the service object and augment the VirtualService to add the aforementioned route.

I was thinking about how I would handle the persistence of the lease, but then I realized that this should just be considered another k8s metadata object, a “ServiceLease”.

If I’m not changing Istio at all for this, my “desired state” is to have the VirtualService dynamically changed to add the details specified in the ServiceLease. However, I would think this would be more effective if the presence of the ServiceLease simply dynamically changes the behavior of the VirtualService. This would obviously require changing how Istio works.

I’m just throwing this out there, for feedback. Anyone have any thoughts about this?