| 156 | } |
| 157 | |
| 158 | export default class DevServer { |
| 159 | public cwd: string; |
| 160 | public repoRoot: string; |
| 161 | public proxy: httpProxy; |
| 162 | public envConfigs: EnvConfigs; |
| 163 | public files: BuilderInputs; |
| 164 | |
| 165 | private _address: URL | undefined; |
| 166 | public get address(): URL { |
| 167 | if (!this._address) { |
| 168 | throw new Error( |
| 169 | 'Invalid access to `address` because `start` has not yet populated `this.address`.' |
| 170 | ); |
| 171 | } |
| 172 | return this._address; |
| 173 | } |
| 174 | |
| 175 | public devCacheDir: string; |
| 176 | private currentDevCommand?: string; |
| 177 | private caseSensitive: boolean; |
| 178 | private apiDir: string | null; |
| 179 | private apiExtensions: Set<string>; |
| 180 | private server: http.Server; |
| 181 | private stopping: boolean; |
| 182 | private buildMatches: Map<string, BuildMatch>; |
| 183 | private inProgressBuilds: Map<string, Promise<void>>; |
| 184 | private watcher?: FSWatcher; |
| 185 | private watchAggregationId: NodeJS.Timer | null; |
| 186 | private watchAggregationEvents: FSEvent[]; |
| 187 | private watchAggregationTimeout: number; |
| 188 | private filter: (path: string) => boolean; |
| 189 | private podId: string; |
| 190 | private devProcess?: ChildProcess; |
| 191 | private devProcessOrigin?: string; |
| 192 | private shutdownCallbacks: Map< |
| 193 | number /* PID */, |
| 194 | undefined | (() => Promise<void>) |
| 195 | >; |
| 196 | private originalProjectSettings?: ProjectSettings; |
| 197 | private projectSettings?: ProjectSettings; |
| 198 | private services?: Service[]; |
| 199 | private orchestrator?: ServicesOrchestrator; |
| 200 | private queueBroker?: QueueBroker; |
| 201 | private serviceRoutesTable?: Map<string, Route[]>; |
| 202 | |
| 203 | private vercelConfigWarning: boolean; |
| 204 | private getVercelConfigPromise: Promise<VercelConfig> | null; |
| 205 | private blockingBuildsPromise: Promise<void> | null; |
| 206 | private startPromise: Promise<void> | null; |
| 207 | |
| 208 | private envValues: Record<string, string>; |
| 209 | private useImplicitServicesEnvInjection: boolean; |
| 210 | private projectId?: string; |
| 211 | private orgId?: string; |
| 212 | |
| 213 | private responseTransformsByReq = new WeakMap< |
| 214 | http.IncomingMessage, |
| 215 | Transform[] |
nothing calls this directly
no test coverage detected