Backstage
    Preparing search index...

    Factory class producing a collator that can be used to index documents sourced from the latest newline delimited JSON file matching a given search pattern. "Latest" is determined by the name of the file (last alphabetically is considered latest).

    The reader provided must implement the search() method as well as the readUrl method whose response includes the stream() method. Naturally, the reader must also be configured to understand the given search pattern.

    Here's an example configuration using Google Cloud Storage, which would return the latest file under the bucket GCS bucket with files like xyz-2021.ndjson or xyz-2022.ndjson.

    indexBuilder.addCollator({
    schedule,
    factory: NewlineDelimitedJsonCollatorFactory.fromConfig(env.config, {
    type: 'techdocs',
    searchPattern: 'https://storage.cloud.google.com/bucket/xyz-*',
    reader: env.reader,
    logger: env.logger,
    })
    });

    Implements

    Index

    Properties

    type: string

    The type or name of the document set returned by this collator. Used as an index name by Search Engines.

    visibilityPermission: Permission | undefined

    The @backstage/plugin-permission-common#Permission that controls visibility of resources associated with this collator's documents.

    Methods