chore: moar deprecations

Signed-off-by: benjdlambert <ben@blam.sh>
This commit is contained in:
benjdlambert
2025-09-23 16:15:36 +02:00
parent 62e3e83bb4
commit 6e2bda78bd
5 changed files with 46 additions and 13 deletions
+9
View File
@@ -0,0 +1,9 @@
---
'@backstage/plugin-scaffolder-node': patch
---
**DEPRECATION**: We're going to be working on refactoring a lot of the internals of the Scaffolder backend plugin, and with that comes a lot of deprecations and removals for public types that are making these things hard.
If you're using these types, please reach out to us either on Discord or a GitHub issue with your use cases.
- `SerializedTask`, `SerializedTaskEvent`, `TaskBroker`, `TaskContext`, `TaskBrokerDispatchOptions`, `TaskBrokerDispatchResult`, `TaskCompletionState`, `TaskEventType`, `TaskFilter`, `TaskFilters`, `TaskStatus` are the types that have now been marked as deprecated, and will be removed in a future release.
+1 -1
View File
@@ -147,7 +147,7 @@ export interface ScaffolderAutocompleteExtensionPoint {
// @alpha
export const scaffolderAutocompleteExtensionPoint: ExtensionPoint<ScaffolderAutocompleteExtensionPoint>;
// @alpha
// @alpha @deprecated
export interface ScaffolderTaskBrokerExtensionPoint {
// (undocumented)
setTaskBroker(taskBroker: TaskBroker): void;
+11 -11
View File
@@ -327,7 +327,7 @@ export function serializeDirectoryContents(
},
): Promise<SerializedFile[]>;
// @public
// @public @deprecated
export type SerializedTask = {
id: string;
spec: TaskSpec;
@@ -339,7 +339,7 @@ export type SerializedTask = {
state?: JsonObject;
};
// @public
// @public @deprecated
export type SerializedTaskEvent = {
id: number;
isTaskRecoverable?: boolean;
@@ -353,7 +353,7 @@ export type SerializedTaskEvent = {
createdAt: string;
};
// @public
// @public @deprecated
export interface TaskBroker {
// (undocumented)
cancel(taskId: string): Promise<void>;
@@ -396,22 +396,22 @@ export interface TaskBroker {
vacuumTasks(options: { timeoutS: number }): Promise<void>;
}
// @public
// @public @deprecated
export type TaskBrokerDispatchOptions = {
spec: TaskSpec;
secrets?: TaskSecrets;
createdBy?: string;
};
// @public
// @public @deprecated
export type TaskBrokerDispatchResult = {
taskId: string;
};
// @public
// @public @deprecated
export type TaskCompletionState = 'failed' | 'completed';
// @public
// @public @deprecated
export interface TaskContext {
// (undocumented)
cancelSignal: AbortSignal;
@@ -455,16 +455,16 @@ export interface TaskContext {
updateCheckpoint?(options: UpdateTaskCheckpointOptions): Promise<void>;
}
// @public
// @public @deprecated
export type TaskEventType = 'completion' | 'log' | 'cancelled' | 'recovered';
// @public
// @public @deprecated
export type TaskFilter = {
key: string;
values?: string[];
};
// @public
// @public @deprecated
export type TaskFilters =
| {
anyOf: TaskFilter[];
@@ -482,7 +482,7 @@ export type TaskSecrets = Record<string, string> & {
backstageToken?: string;
};
// @public
// @public @deprecated
export type TaskStatus =
| 'cancelled'
| 'completed'
@@ -53,6 +53,7 @@ export const scaffolderActionsExtensionPoint =
* Extension point for replacing the scaffolder task broker.
*
* @alpha
* @deprecated this extension point is planned to be removed, please reach out to us in an issue if you're using this extension point and your use cases.
*/
export interface ScaffolderTaskBrokerExtensionPoint {
setTaskBroker(taskBroker: TaskBroker): void;
+24 -1
View File
@@ -33,6 +33,8 @@ export type TaskSecrets = Record<string, string> & {
* The status of each step of the Task
*
* @public
* @deprecated this type is planned to be removed.
* Please reach out to us in an issue if you're using this type and your use cases.
*/
export type TaskStatus =
| 'cancelled'
@@ -46,6 +48,8 @@ export type TaskStatus =
* The state of a completed task.
*
* @public
* @deprecated this interface is planned to be removed.
* Please reach out to us in an issue if you're using this interface and your use cases.
*/
export type TaskCompletionState = 'failed' | 'completed';
@@ -53,6 +57,8 @@ export type TaskCompletionState = 'failed' | 'completed';
* SerializedTask
*
* @public
* @deprecated this type is planned to be removed.
* Please reach out to us in an issue if you're using this type and your use cases.
*/
export type SerializedTask = {
id: string;
@@ -69,6 +75,8 @@ export type SerializedTask = {
* TaskEventType
*
* @public
* @deprecated this type is planned to be removed.
* Please reach out to us in an issue if you're using this type and your use cases.
*/
export type TaskEventType = 'completion' | 'log' | 'cancelled' | 'recovered';
@@ -76,6 +84,8 @@ export type TaskEventType = 'completion' | 'log' | 'cancelled' | 'recovered';
* SerializedTaskEvent
*
* @public
* @deprecated this type is planned to be removed.
* Please reach out to us in an issue if you're using this type and your use cases.
*/
export type SerializedTaskEvent = {
id: number;
@@ -94,6 +104,8 @@ export type SerializedTaskEvent = {
* The result of {@link TaskBroker.dispatch}
*
* @public
* @deprecated this interface is planned to be removed.
* Please reach out to us in an issue if you're using this interface and your use cases.
*/
export type TaskBrokerDispatchResult = {
taskId: string;
@@ -104,6 +116,8 @@ export type TaskBrokerDispatchResult = {
* Currently a spec and optional secrets
*
* @public
* @deprecated this interface is planned to be removed.
* Please reach out to us in an issue if you're using this interface and your use cases.
*/
export type TaskBrokerDispatchOptions = {
spec: TaskSpec;
@@ -114,6 +128,8 @@ export type TaskBrokerDispatchOptions = {
/**
* TaskFilter
* @public
* @deprecated this type is planned to be removed.
* Please reach out to us in an issue if you're using this type and your use cases.
*/
export type TaskFilter = {
key: string;
@@ -123,6 +139,8 @@ export type TaskFilter = {
/**
* TaskFilters
* @public
* @deprecated this type is planned to be removed.
* Please reach out to us in an issue if you're using this type and your use cases.
*/
export type TaskFilters =
| { anyOf: TaskFilter[] }
@@ -131,9 +149,12 @@ export type TaskFilters =
| TaskFilter;
/**
* Task
* TaskContext
*
* @public
*
* @deprecated this interface is planned to be removed.
* Please reach out to us in an issue if you're using this interface and your use cases.
*/
export interface TaskContext {
taskId?: string;
@@ -175,6 +196,8 @@ export interface TaskContext {
* TaskBroker
*
* @public
* @deprecated this interface is planned to be removed.
* Please reach out to us in an issue if you're using this interface and your use cases.
*/
export interface TaskBroker {
cancel(taskId: string): Promise<void>;