@numaproj/numaflow-js - v0.0.0-alpha.4
    Preparing search index...

    Namespace sourceTransform

    Source Transform namespace for transforming data at the source level.

    Source transforms allow you to modify messages immediately after they are read from a source, before they enter the main pipeline. This is useful for tasks like:

    • Filtering messages early
    • Extracting and modifying event times
    • Adding or modifying keys and metadata
    import { sourceTransform } from '@numaproj/numaflow-js';

    const server = new sourceTransform.AsyncServer(async (datum) => {
    const data = JSON.parse(datum.value.toString());
    const eventTime = new Date(data.timestamp);
    return [new sourceTransform.Message(datum.value, eventTime, { keys: [data.id] })];
    });

    server.start();

    Classes

    AsyncServer
    Datum
    Message

    Interfaces

    MessageOptions
    SystemMetadata
    UserMetadata

    Variables

    UserMetadata