MCPcopy Create free account
hub / github.com/Effect-TS/effect / failConnect

Function failConnect

packages/sql/pg/src/PgConnection.ts:2460–2461  ·  view source on GitHub ↗
(cause: unknown, message: string, type: ConnectFailureType = "other")

Source from the content-addressed store, hash-verified

2458 resume(Effect.fail(new SqlError({ reason })))
2459 }
2460 const failConnect = (cause: unknown, message: string, type: ConnectFailureType = "other"): void =>
2461 fail(new ConnectionError({ cause, message, operation: "connect" }), type)
2462 const failAuth = (cause: unknown, message: string): void =>
2463 fail(new AuthenticationError({ cause, message, operation: "connect" }), "auth")
2464 const failErrorResponse = (fields: PgProtocol.ErrorFields, message: string): void => {

Callers 6

onErrorFunction · 0.85
onCloseFunction · 0.85
handleMessageFunction · 0.85
onDataFunction · 0.85
onSslResponseFunction · 0.85
connectFunction · 0.85

Calls 1

failFunction · 0.70

Tested by

no test coverage detected