update API reports for backend system factory function refactor

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
This commit is contained in:
Patrik Oldsberg
2023-01-12 10:57:11 +01:00
parent ecbec4ec4c
commit d1e86013ef
21 changed files with 159 additions and 119 deletions
+5 -1
View File
@@ -6,11 +6,15 @@
import { BackendFeature } from '@backstage/backend-plugin-api';
import { Config } from '@backstage/config';
import express from 'express';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { Logger } from 'winston';
import { PluginDatabaseManager } from '@backstage/backend-common';
// @alpha
export const appPlugin: (options: AppPluginOptions) => BackendFeature;
export const appPlugin: FactoryFunction<
BackendFeature,
[options: AppPluginOptions]
>;
// @alpha (undocumented)
export type AppPluginOptions = {
@@ -11,6 +11,7 @@ import { Config } from '@backstage/config';
import { Credentials } from 'aws-sdk';
import { EntityProvider } from '@backstage/plugin-catalog-backend';
import { EntityProviderConnection } from '@backstage/plugin-catalog-backend';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { LocationSpec } from '@backstage/plugin-catalog-backend';
import { Logger } from 'winston';
import { PluginTaskScheduler } from '@backstage/backend-tasks';
@@ -90,7 +91,8 @@ export class AwsS3EntityProvider implements EntityProvider {
}
// @alpha
export const awsS3EntityProviderCatalogModule: (
options?: undefined,
) => BackendFeature;
export const awsS3EntityProviderCatalogModule: FactoryFunction<
BackendFeature,
[]
>;
```
@@ -9,6 +9,7 @@ import { CatalogProcessorEmit } from '@backstage/plugin-catalog-backend';
import { Config } from '@backstage/config';
import { EntityProvider } from '@backstage/plugin-catalog-backend';
import { EntityProviderConnection } from '@backstage/plugin-catalog-backend';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { LocationSpec } from '@backstage/plugin-catalog-backend';
import { Logger } from 'winston';
import { PluginTaskScheduler } from '@backstage/backend-tasks';
@@ -58,7 +59,8 @@ export class AzureDevOpsEntityProvider implements EntityProvider {
}
// @alpha
export const azureDevOpsEntityProviderCatalogModule: (
options?: undefined,
) => BackendFeature;
export const azureDevOpsEntityProviderCatalogModule: FactoryFunction<
BackendFeature,
[]
>;
```
@@ -11,6 +11,7 @@ import { EntityProviderConnection } from '@backstage/plugin-catalog-backend';
import { EventParams } from '@backstage/plugin-events-node';
import { Events } from '@backstage/plugin-bitbucket-cloud-common';
import { EventSubscriber } from '@backstage/plugin-events-node';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { Logger } from 'winston';
import { PluginTaskScheduler } from '@backstage/backend-tasks';
import { TaskRunner } from '@backstage/backend-tasks';
@@ -48,7 +49,8 @@ export class BitbucketCloudEntityProvider
}
// @alpha (undocumented)
export const bitbucketCloudEntityProviderCatalogModule: (
options?: undefined,
) => BackendFeature;
export const bitbucketCloudEntityProviderCatalogModule: FactoryFunction<
BackendFeature,
[]
>;
```
@@ -9,6 +9,7 @@ import { Config } from '@backstage/config';
import { Entity } from '@backstage/catalog-model';
import { EntityProvider } from '@backstage/plugin-catalog-backend';
import { EntityProviderConnection } from '@backstage/plugin-catalog-backend';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { LocationSpec } from '@backstage/plugin-catalog-backend';
import { Logger } from 'winston';
import { PluginTaskScheduler } from '@backstage/backend-tasks';
@@ -69,9 +70,10 @@ export class BitbucketServerEntityProvider implements EntityProvider {
}
// @alpha (undocumented)
export const bitbucketServerEntityProviderCatalogModule: (
options?: undefined,
) => BackendFeature;
export const bitbucketServerEntityProviderCatalogModule: FactoryFunction<
BackendFeature,
[]
>;
// @public (undocumented)
export type BitbucketServerListOptions = {
@@ -7,6 +7,7 @@ import { BackendFeature } from '@backstage/backend-plugin-api';
import { Config } from '@backstage/config';
import { EntityProvider } from '@backstage/plugin-catalog-backend';
import { EntityProviderConnection } from '@backstage/plugin-catalog-backend';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { Logger } from 'winston';
import { PluginTaskScheduler } from '@backstage/backend-tasks';
import { TaskRunner } from '@backstage/backend-tasks';
@@ -31,9 +32,10 @@ export class GerritEntityProvider implements EntityProvider {
}
// @alpha (undocumented)
export const gerritEntityProviderCatalogModule: (
options?: undefined,
) => BackendFeature;
export const gerritEntityProviderCatalogModule: FactoryFunction<
BackendFeature,
[]
>;
// (No @packageDocumentation comment for this package)
```
@@ -13,6 +13,7 @@ import { EntityProvider } from '@backstage/plugin-catalog-backend';
import { EntityProviderConnection } from '@backstage/plugin-catalog-backend';
import { EventParams } from '@backstage/plugin-events-node';
import { EventSubscriber } from '@backstage/plugin-events-node';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { GithubCredentialsProvider } from '@backstage/integration';
import { GithubIntegrationConfig } from '@backstage/integration';
import { graphql } from '@octokit/graphql';
@@ -101,9 +102,10 @@ export class GithubEntityProvider implements EntityProvider, EventSubscriber {
}
// @alpha
export const githubEntityProviderCatalogModule: (
options?: undefined,
) => BackendFeature;
export const githubEntityProviderCatalogModule: FactoryFunction<
BackendFeature,
[]
>;
// @public (undocumented)
export class GithubLocationAnalyzer implements ScmLocationAnalyzer {
@@ -9,6 +9,7 @@ import { CatalogProcessorEmit } from '@backstage/plugin-catalog-backend';
import { Config } from '@backstage/config';
import { EntityProvider } from '@backstage/plugin-catalog-backend';
import { EntityProviderConnection } from '@backstage/plugin-catalog-backend';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { LocationSpec } from '@backstage/plugin-catalog-backend';
import { Logger } from 'winston';
import { PluginTaskScheduler } from '@backstage/backend-tasks';
@@ -34,9 +35,10 @@ export class GitlabDiscoveryEntityProvider implements EntityProvider {
}
// @alpha
export const gitlabDiscoveryEntityProviderCatalogModule: (
options?: undefined,
) => BackendFeature;
export const gitlabDiscoveryEntityProviderCatalogModule: FactoryFunction<
BackendFeature,
[]
>;
// @public
export class GitLabDiscoveryProcessor implements CatalogProcessor {
@@ -10,6 +10,7 @@ import { CatalogBuilder } from '@backstage/plugin-catalog-backend';
import type { Config } from '@backstage/config';
import type { DeferredEntity } from '@backstage/plugin-catalog-backend';
import type { DurationObjectUnits } from 'luxon';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import type { Logger } from 'winston';
import type { PermissionEvaluator } from '@backstage/plugin-permission-common';
import type { PluginDatabaseManager } from '@backstage/backend-common';
@@ -68,12 +69,17 @@ export interface IncrementalEntityProviderOptions {
}
// @alpha
export const incrementalIngestionEntityProviderCatalogModule: (options: {
providers: {
provider: IncrementalEntityProvider<unknown, unknown>;
options: IncrementalEntityProviderOptions;
}[];
}) => BackendFeature;
export const incrementalIngestionEntityProviderCatalogModule: FactoryFunction<
BackendFeature,
[
options: {
providers: {
provider: IncrementalEntityProvider<unknown, unknown>;
options: IncrementalEntityProviderOptions;
}[];
},
]
>;
// @public (undocumented)
export type PluginEnvironment = {
@@ -9,6 +9,7 @@ import { CatalogProcessorEmit } from '@backstage/plugin-catalog-backend';
import { Config } from '@backstage/config';
import { EntityProvider } from '@backstage/plugin-catalog-backend';
import { EntityProviderConnection } from '@backstage/plugin-catalog-backend';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { GroupEntity } from '@backstage/catalog-model';
import { LocationSpec } from '@backstage/plugin-catalog-backend';
import { Logger } from 'winston';
@@ -135,9 +136,10 @@ export class MicrosoftGraphOrgEntityProvider implements EntityProvider {
}
// @alpha
export const microsoftGraphOrgEntityProviderCatalogModule: (
options?: MicrosoftGraphOrgEntityProviderCatalogModuleOptions | undefined,
) => BackendFeature;
export const microsoftGraphOrgEntityProviderCatalogModule: FactoryFunction<
BackendFeature,
[]
>;
// @alpha
export interface MicrosoftGraphOrgEntityProviderCatalogModuleOptions {
+2 -1
View File
@@ -34,6 +34,7 @@ import { EntityProvider } from '@backstage/plugin-catalog-node';
import { EntityProviderConnection } from '@backstage/plugin-catalog-node';
import { EntityProviderMutation } from '@backstage/plugin-catalog-node';
import { EntityRelationSpec } from '@backstage/plugin-catalog-node';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { GetEntitiesRequest } from '@backstage/catalog-client';
import { JsonValue } from '@backstage/types';
import { LocationEntityV1alpha1 } from '@backstage/catalog-model';
@@ -237,7 +238,7 @@ export type CatalogPermissionRule<
> = PermissionRule<Entity, EntitiesSearchFilter, 'catalog-entity', TParams>;
// @alpha
export const catalogPlugin: (options?: undefined) => BackendFeature;
export const catalogPlugin: FactoryFunction<BackendFeature, []>;
// @public
export interface CatalogProcessingEngine {
@@ -7,6 +7,7 @@ import { BackendFeature } from '@backstage/backend-plugin-api';
import { Config } from '@backstage/config';
import { EventBroker } from '@backstage/plugin-events-node';
import { EventPublisher } from '@backstage/plugin-events-node';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { Logger } from 'winston';
import { PluginTaskScheduler } from '@backstage/backend-tasks';
@@ -23,7 +24,8 @@ export class AwsSqsConsumingEventPublisher implements EventPublisher {
}
// @alpha
export const awsSqsConsumingEventPublisherEventsModule: (
options?: undefined,
) => BackendFeature;
export const awsSqsConsumingEventPublisherEventsModule: FactoryFunction<
BackendFeature,
[]
>;
```
@@ -5,6 +5,7 @@
```ts
import { BackendFeature } from '@backstage/backend-plugin-api';
import { EventParams } from '@backstage/plugin-events-node';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { SubTopicEventRouter } from '@backstage/plugin-events-node';
// @public
@@ -15,7 +16,8 @@ export class AzureDevOpsEventRouter extends SubTopicEventRouter {
}
// @alpha
export const azureDevOpsEventRouterEventsModule: (
options?: undefined,
) => BackendFeature;
export const azureDevOpsEventRouterEventsModule: FactoryFunction<
BackendFeature,
[]
>;
```
@@ -5,6 +5,7 @@
```ts
import { BackendFeature } from '@backstage/backend-plugin-api';
import { EventParams } from '@backstage/plugin-events-node';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { SubTopicEventRouter } from '@backstage/plugin-events-node';
// @public
@@ -15,7 +16,8 @@ export class BitbucketCloudEventRouter extends SubTopicEventRouter {
}
// @alpha
export const bitbucketCloudEventRouterEventsModule: (
options?: undefined,
) => BackendFeature;
export const bitbucketCloudEventRouterEventsModule: FactoryFunction<
BackendFeature,
[]
>;
```
@@ -5,6 +5,7 @@
```ts
import { BackendFeature } from '@backstage/backend-plugin-api';
import { EventParams } from '@backstage/plugin-events-node';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { SubTopicEventRouter } from '@backstage/plugin-events-node';
// @public
@@ -15,7 +16,5 @@ export class GerritEventRouter extends SubTopicEventRouter {
}
// @alpha
export const gerritEventRouterEventsModule: (
options?: undefined,
) => BackendFeature;
export const gerritEventRouterEventsModule: FactoryFunction<BackendFeature, []>;
```
@@ -6,6 +6,7 @@
import { BackendFeature } from '@backstage/backend-plugin-api';
import { Config } from '@backstage/config';
import { EventParams } from '@backstage/plugin-events-node';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { RequestValidator } from '@backstage/plugin-events-node';
import { SubTopicEventRouter } from '@backstage/plugin-events-node';
@@ -22,10 +23,8 @@ export class GithubEventRouter extends SubTopicEventRouter {
}
// @alpha
export const githubEventRouterEventsModule: (
options?: undefined,
) => BackendFeature;
export const githubEventRouterEventsModule: FactoryFunction<BackendFeature, []>;
// @alpha
export const githubWebhookEventsModule: (options?: undefined) => BackendFeature;
export const githubWebhookEventsModule: FactoryFunction<BackendFeature, []>;
```
@@ -6,6 +6,7 @@
import { BackendFeature } from '@backstage/backend-plugin-api';
import { Config } from '@backstage/config';
import { EventParams } from '@backstage/plugin-events-node';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { RequestValidator } from '@backstage/plugin-events-node';
import { SubTopicEventRouter } from '@backstage/plugin-events-node';
@@ -20,10 +21,8 @@ export class GitlabEventRouter extends SubTopicEventRouter {
}
// @alpha
export const gitlabEventRouterEventsModule: (
options?: undefined,
) => BackendFeature;
export const gitlabEventRouterEventsModule: FactoryFunction<BackendFeature, []>;
// @alpha
export const gitlabWebhookEventsModule: (options?: undefined) => BackendFeature;
export const gitlabWebhookEventsModule: FactoryFunction<BackendFeature, []>;
```
+2 -1
View File
@@ -9,6 +9,7 @@ import { EventBroker } from '@backstage/plugin-events-node';
import { EventPublisher } from '@backstage/plugin-events-node';
import { EventSubscriber } from '@backstage/plugin-events-node';
import express from 'express';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { HttpPostIngressOptions } from '@backstage/plugin-events-node';
import { Logger } from 'winston';
@@ -29,7 +30,7 @@ export class EventsBackend {
}
// @alpha
export const eventsPlugin: (options?: undefined) => BackendFeature;
export const eventsPlugin: FactoryFunction<BackendFeature, []>;
// @public
export class HttpPostIngressEventPublisher implements EventPublisher {
+6 -4
View File
@@ -13,6 +13,7 @@ import { Config } from '@backstage/config';
import { createPullRequest } from 'octokit-plugin-create-pull-request';
import { Entity } from '@backstage/catalog-model';
import express from 'express';
import { FactoryFunction } from '@backstage/backend-plugin-api/src/types';
import { GithubCredentialsProvider } from '@backstage/integration';
import { IdentityApi } from '@backstage/plugin-auth-node';
import { JsonObject } from '@backstage/types';
@@ -625,7 +626,7 @@ export type RunCommandOptions = {
};
// @alpha
export const scaffolderCatalogModule: (options?: undefined) => BackendFeature;
export const scaffolderCatalogModule: FactoryFunction<BackendFeature, []>;
// @public (undocumented)
export class ScaffolderEntitiesProcessor implements CatalogProcessor {
@@ -642,9 +643,10 @@ export class ScaffolderEntitiesProcessor implements CatalogProcessor {
}
// @alpha
export const scaffolderPlugin: (
options: ScaffolderPluginOptions,
) => BackendFeature;
export const scaffolderPlugin: FactoryFunction<
BackendFeature,
[options: ScaffolderPluginOptions]
>;
// @alpha
export type ScaffolderPluginOptions = {