---
title: ServeManyOptions
summary: ServeManyOptions controls the exit conditions for ServeMany. Note that Compute might terminate the request hander earlier.
url: https://www.fastly.com/documentation/reference/compute/sdks/go/compute-sdk-go/fsthttp/struct.ServeManyOptions/
---

**Kind:** Struct  
**Module:** [fsthttp](https://www.fastly.com/documentation/reference/compute/sdks/go/compute-sdk-go/fsthttp/)  
**Package:** compute-sdk-go v1.11.0  
**Source:** https://github.com/fastly/compute-sdk-go/blob/d6bf71b04516ed72d6018cab6fff701a865f86e5/fsthttp/handle.go#L56

```go
type ServeManyOptions struct {
	NextTimeout time.Duration

	MaxLifetime time.Duration

	MaxRequests int

	Continue func() bool
}
```

ServeManyOptions controls the exit conditions for ServeMany.  Note that Compute might terminate the request hander earlier.

## Fields

### NextTimeout

**Type:** `time.Duration`

NextTimeout is the amount of time to wait for the next request

### MaxLifetime

**Type:** `time.Duration`

MaxLifetime is the total max lifetime for an instance

### MaxRequests

**Type:** `int`

MaxRequests is the maximum number of requests to serve for a single instance

### Continue

**Type:** `func() bool`

Continue is a function that determines whether to continue
serving requests after the other conditions have been checked.
If Continue returns false, ServeMany will exit.  If Continue is
nil or returns true, ServeMany will continue.
