http-add-on icon indicating copy to clipboard operation
http-add-on copied to clipboard

"Please hold" landing pages for slow scale from zero scenarios

Open worldspawn opened this issue 1 year ago • 16 comments

Proposal

If the service is scaling from zero and maybe needs to wait for a new node to provision a nicer user XP might be to just land on a page that says "Teamcity is starting up... please wait". Could be enabled and configured in the http scaled object resource. MVP could be a very simple page saying "{SomeValueFromHttpResource} is start up please wait" and it polls.

Use-Case

Nodes can be slow (well a cpl of minutes) to start up. The experience scaling from zero in this case is pretty ordinary. The default wait time is only 30s and then you Bad Gateway or something like that.

I nice web page telling people to sit tight and wait for the magic would be a lot nicer.

Is this a feature you are interested in implementing yourself?

Maybe

Anything else?

No response

worldspawn avatar Jan 04 '24 05:01 worldspawn

Hum... It's an interesting feature, but I'm not sure about how we can implement this. I mean, a simple message it's nice, but I'm afraid about if this has to scale to serve complex HTML and how we can do this. WDYT @tomkerkhove ? Maybe we can allow custom messages for HTTP Errors somehow (at HTTPScaledObject level)

JorTurFer avatar Jan 04 '24 20:01 JorTurFer

I come up with similar requirement, just customizing the error message is enough for me.

thincal avatar Jan 19 '24 00:01 thincal

@tomkerkhove ?

JorTurFer avatar Jan 19 '24 07:01 JorTurFer

i'm interesting too for this feature. Maybe have a light custom HTML by httpsScaleObject. For not afraid user, just only print a loading message.

lenglet-k avatar Feb 14 '24 14:02 lenglet-k

Yeah, this should be imho configurable. And serve the light custom HTML for users that want to. They should be able to provide their custom HTLM file.

zroubalik avatar Feb 14 '24 15:02 zroubalik

make sense, but maybe I'd add another CRD for this, as it's something that can be reusable (or not). WDYT? I guess that we could include the info in a more structured way, by content and return code

JorTurFer avatar Feb 14 '24 16:02 JorTurFer

by content and return code

+1

thincal avatar Mar 06 '24 10:03 thincal

Any progress here

thincal avatar Apr 12 '24 15:04 thincal

No, currently there isn't anybody working on this, are you willing to tackle it?

JorTurFer avatar Apr 12 '24 15:04 JorTurFer

No, currently there isn't anybody working on this, are you willing to tackle it?

Yes, I could have a try. My quick idea is to add the customized response content and code into existing http-scaled-object, but it seems that there is suggestion about using a new CRD, could help explain the consideration behind?

thincal avatar Apr 14 '24 14:04 thincal

Yeah, I suggested the new CRD because I can imagine a scenario where you have multiple services behind the proxy, and you want to provide a custom message for all of them. The new CRD could be just something like:

spec:
  httpStatus: XXX (number)
  html: |
    <html>....</html>

and then, we can include in the HTTPScaledObject with something like:

spec:
  loadingTemplate: xxxxxxx
  minReplicaCount: 0
  ....

Currently, these templates can be cluster scoped and maybe in the future we can support both, clustered and namespaced. This will keep the HTTPScaledObject cleaner because if you have to introduce the HTML within the HTTPScaledObject, it can introduce a lot of new lines (even more when you want to reuse them)

Does it make sense to you? Maybe I'm overthinking the case, and we could go just adding something inline and iterate in the future if it's something that users use

JorTurFer avatar Apr 14 '24 15:04 JorTurFer

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jun 13 '24 20:06 stale[bot]

Sablier has this feature: https://acouvreur.github.io/sablier/#/strategies

calvinbui avatar Jun 26 '24 05:06 calvinbui

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Aug 25 '24 18:08 stale[bot]