Skip to content

@codesoul-co/hypha-adapters-local / local-filesystem-execution-artifact-store

Using this module

Use the Local filesystem execution artifact store module for persisting and reading data at this boundary. It exports 1 class, 3 interfaces.

Import from the package entrypoint

ts
import {
  LocalFilesystemExecutionArtifactStore,
} from '@codesoul-co/hypha-adapters-local';

import type {
  LocalArtifactGarbageCollectionResult,
  LocalFilesystemExecutionArtifactStoreOptions,
  LocalFilesystemExecutionArtifactStoreStats,
} from '@codesoul-co/hypha-adapters-local';

Usage patterns

  • Use the 3 type/interface exports as static contracts in application code, adapters, or tests. Import them with import type; they do not exist at runtime.
  • The module exposes 1 class as constructable runtime implementations. Each symbol entry lists its constructor and public methods.

Public exports

SymbolKindSignatureDescription
LocalFilesystemExecutionArtifactStoreclassnew LocalFilesystemExecutionArtifactStore(options: LocalFilesystemExecutionArtifactStoreOptions): LocalFilesystemExecutionArtifactStoreLocal Filesystem Execution Artifact Store class with 13 public constructor or member entries; its exact declarations are listed below.
LocalArtifactGarbageCollectionResultinterfaceinterface LocalArtifactGarbageCollectionResultLocal Artifact Garbage Collection Result interface with 2 public fields or methods.
LocalFilesystemExecutionArtifactStoreOptionsinterfaceinterface LocalFilesystemExecutionArtifactStoreOptionsLocal Filesystem Execution Artifact Store Options interface with 4 public fields or methods.
LocalFilesystemExecutionArtifactStoreStatsinterfaceinterface LocalFilesystemExecutionArtifactStoreStatsLocal Filesystem Execution Artifact Store Stats interface with 3 public fields or methods.

LocalFilesystemExecutionArtifactStore

Local Filesystem Execution Artifact Store class with 13 public constructor or member entries; its exact declarations are listed below.

Declaration

text
export declare class LocalFilesystemExecutionArtifactStore implements ArtifactStoreProvider {
    readonly id: string;
    constructor(options: LocalFilesystemExecutionArtifactStoreOptions);
    capabilities(): Promise<ArtifactStoreCapabilities>;
    put(input: ArtifactPutRequest, options?: ArtifactOperationOptions): Promise<ArtifactStorageRef>;
    get(input: ArtifactGetRequest, options?: ArtifactOperationOptions): Promise<ArtifactContent>;
    head(input: ArtifactStorageRef): Promise<ArtifactObjectMetadata | null>;
    exists(input: ArtifactStorageRef): Promise<boolean>;
    delete(input: ArtifactStorageRef): Promise<void>;
    copy(input: ArtifactCopyRequest): Promise<ArtifactStorageRef>;
    health(): Promise<ProviderHealth>;
    close(): Promise<void>;
    stats(): Promise<LocalFilesystemExecutionArtifactStoreStats>;
    collectGarbage(): Promise<LocalArtifactGarbageCollectionResult>;
}

Public members

MemberKindSignatureDescription
capabilitiesmethodcapabilities(): Promise<ArtifactStoreCapabilities>Public method; parameters and return type are shown in the signature.
closemethodclose(): Promise<void>Public method; parameters and return type are shown in the signature.
collectGarbagemethodcollectGarbage(): Promise<LocalArtifactGarbageCollectionResult>Public method; parameters and return type are shown in the signature.
constructorconstructor(options: LocalFilesystemExecutionArtifactStoreOptions): LocalFilesystemExecutionArtifactStoreCreates an instance of this class.
copymethodcopy(input: ArtifactCopyRequest): Promise<ArtifactStorageRef>Public method; parameters and return type are shown in the signature.
deletemethoddelete(input: ArtifactStorageRef): Promise<void>Public method; parameters and return type are shown in the signature.
existsmethodexists(input: ArtifactStorageRef): Promise<boolean>Public method; parameters and return type are shown in the signature.
getmethodget(input: ArtifactGetRequest, options?: ArtifactOperationOptions): Promise<ArtifactContent>Public method; parameters and return type are shown in the signature.
headmethodhead(input: ArtifactStorageRef): Promise<ArtifactObjectMetadata | null>Public method; parameters and return type are shown in the signature.
healthmethodhealth(): Promise<ProviderHealth>Public method; parameters and return type are shown in the signature.
idpropertyreadonly id: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
putmethodput(input: ArtifactPutRequest, options?: ArtifactOperationOptions): Promise<ArtifactStorageRef>Public method; parameters and return type are shown in the signature.
statsmethodstats(): Promise<LocalFilesystemExecutionArtifactStoreStats>Public method; parameters and return type are shown in the signature.

LocalArtifactGarbageCollectionResult

Local Artifact Garbage Collection Result interface with 2 public fields or methods.

Declaration

text
export interface LocalArtifactGarbageCollectionResult {
    deletedBlobs: number;
    reclaimedBytes: number;
}

Contract members

MemberKindSignatureDescription
deletedBlobspropertydeletedBlobs: numberPublic property; its type, readonly modifier and optionality are shown in the signature.
reclaimedBytespropertyreclaimedBytes: numberPublic property; its type, readonly modifier and optionality are shown in the signature.

LocalFilesystemExecutionArtifactStoreOptions

Local Filesystem Execution Artifact Store Options interface with 4 public fields or methods.

Declaration

text
export interface LocalFilesystemExecutionArtifactStoreOptions {
    id?: string;
    rootPath: string;
    maxObjectBytes?: number;
    now?: () => string;
}

Contract members

MemberKindSignatureDescription
idpropertyid?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
maxObjectBytespropertymaxObjectBytes?: numberPublic property; its type, readonly modifier and optionality are shown in the signature.
nowmethodnow?(): stringPublic method; parameters and return type are shown in the signature.
rootPathpropertyrootPath: stringPublic property; its type, readonly modifier and optionality are shown in the signature.

LocalFilesystemExecutionArtifactStoreStats

Local Filesystem Execution Artifact Store Stats interface with 3 public fields or methods.

Declaration

text
export interface LocalFilesystemExecutionArtifactStoreStats {
    objects: number;
    blobs: number;
    storedBytes: number;
}

Contract members

MemberKindSignatureDescription
blobspropertyblobs: numberPublic property; its type, readonly modifier and optionality are shown in the signature.
objectspropertyobjects: numberPublic property; its type, readonly modifier and optionality are shown in the signature.
storedBytespropertystoredBytes: numberPublic property; its type, readonly modifier and optionality are shown in the signature.