[cf-dev] Apps/microservices that have long request processing times.

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[cf-dev] Apps/microservices that have long request processing times.

Jonathan Stockley

Hi,

According to https://docs.cloudfoundry.org/devguide/deploy-apps/prepare-to-deploy.html#moving-apps an app instance has only 10 seconds to finish processing a request before being killed off.

I have an app that does document rendition generation and it can take upwards of 10 minutes for long documents.

Is the 10 seconds grace period configurable?

 

Thanks,

Jo

_._,_._,_

Links:

You receive all messages sent to this group.

View/Reply Online (#8266) | [hidden email] | [hidden email] | Mute This Topic | New Topic

Your Subscription | [hidden email] | Unsubscribe [[hidden email]]

_._,_._,_
Reply | Threaded
Open this post in threaded view
|

Re: [cf-dev] Apps/microservices that have long request processing times.

Liu Liming

Hi Jo,

I think there’s one config in the rep job:

  containers.graceful_shutdown_interval_in_seconds:

    description: "EXPERIMENTAL: time in seconds between signalling a container to shutdown gracefully and stopping it forcefully. Should not be less than 10."

default: 10

if you are using the open source version of CF, I think you can overrite it under this path:

 

  - name: rep

    release: diego

    properties:

      diego:

        executor:

          instance_identity_ca_cert: ((diego_instance_identity_ca.certificate))

          instance_identity_key: ((diego_instance_identity_ca.private_key))

        rep:

          preloaded_rootfses:

          - cflinuxfs2:/var/vcap/packages/cflinuxfs2/rootfs.tar

          use_vcontainer: false

          vcontainer:

            api_location: "vcontainer.service.cf.internal:8892"

            ca_cert: "((service_cf_internal_ca.certificate))"

            client_cert: "((diego_vcontainer_client.certificate))"

            client_key: "((diego_vcontainer_client.private_key))"

      containers:

       graceful_shutdown_interval_in_seconds: 10000000

        trusted_ca_certificates:

          - ((application_ca.certificate))

 

And if you are using the PCF, I think you can use the ops manager to override the value if it provided one way to do this.

 

Thanks,

Andy

 

From: <[hidden email]> on behalf of Jonathan Stockley <[hidden email]>
Reply-To: "[hidden email]" <[hidden email]>
Date: Tuesday, September 18, 2018 at 6:31 AM
To: "[hidden email]" <[hidden email]>
Subject: [cf-dev] Apps/microservices that have long request processing times.

 

Hi,

According to https://docs.cloudfoundry.org/devguide/deploy-apps/prepare-to-deploy.html#moving-apps an app instance has only 10 seconds to finish processing a request before being killed off.

I have an app that does document rendition generation and it can take upwards of 10 minutes for long documents.

Is the 10 seconds grace period configurable?

 

Thanks,

Jo

_._,_._,_

Links:

You receive all messages sent to this group.

View/Reply Online (#8270) | [hidden email] | [hidden email] | Mute This Topic | New Topic

Your Subscription | [hidden email] | Unsubscribe [[hidden email]]

_._,_._,_