Skip to content
Merged
26 changes: 26 additions & 0 deletions .changeset/heavy-bugs-thank.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
---
"@fluidframework/container-definitions": minor
"@fluidframework/runtime-definitions": minor
"__section": breaking
---
Deprecated properties have been removed from IRuntimeStorageService and IContainerStorageService

The following deprecated properties have been removed from `IRuntimeStorageService`:

- `createBlob`
- `dispose`
- `disposed`
- `downloadSummary`
- `getSnapshot`
- `getSnapshotTree`
- `getVersions`
- `policies`
- `uploadSummaryWithContext`

The following deprecated properties have been removed from `IContainerStorageService`:

- `dispose`
- `disposed`
- `downloadSummary`

Please see [this Github issue](https://github.com/microsoft/FluidFramework/issues/25069) for more details.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚫 [vale] reported by reviewdog 🐶
[Vale.Spelling] Did you really mean 'Github'?

Original file line number Diff line number Diff line change
Expand Up @@ -209,12 +209,6 @@ export type IContainerPolicies = {
// @beta @legacy
export interface IContainerStorageService {
createBlob(file: ArrayBufferLike): Promise<ICreateBlobResponse>;
// @deprecated
dispose?(error?: Error): void;
// @deprecated
readonly disposed?: boolean;
// @deprecated
downloadSummary(handle: ISummaryHandle): Promise<ISummaryTree>;
getSnapshot?(snapshotFetchOptions?: ISnapshotFetchOptions): Promise<ISnapshot>;
getSnapshotTree(version?: IVersion, scenarioName?: string): Promise<ISnapshotTree | null>;
getVersions(versionId: string | null, count: number, scenarioName?: string, fetchSource?: FetchSource): Promise<IVersion[]>;
Expand Down
9 changes: 8 additions & 1 deletion packages/common/container-definitions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,14 @@
"typescript": "~5.4.5"
},
"typeValidation": {
"broken": {},
"broken": {
"Interface_IContainerContext": {
"backCompat": false
},
"Interface_IContainerStorageService": {
"backCompat": false
}
},
"entrypoint": "legacy"
}
}
29 changes: 0 additions & 29 deletions packages/common/container-definitions/src/runtime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ import type {
ISnapshotFetchOptions,
FetchSource,
IDocumentStorageServicePolicies,
ISummaryHandle,
} from "@fluidframework/driver-definitions/internal";

import type { IAudience } from "./audience.js";
Expand Down Expand Up @@ -143,25 +142,6 @@ export interface IBatchMessage {
* @legacy @beta
*/
export interface IContainerStorageService {
/**
* Whether or not the object has been disposed.
* If true, the object should be considered invalid, and its other state should be disregarded.
*
* @deprecated - This API is deprecated and will be removed in a future release. No replacement is planned as
* it is unused in the Runtime layer.
*/
readonly disposed?: boolean;

/**
* Dispose of the object and its resources.
* @param error - Optional error indicating the reason for the disposal, if the object was
* disposed as the result of an error.
*
* @deprecated - This API is deprecated and will be removed in a future release. No replacement is planned as
* it is unused in the Runtime layer.
*/
dispose?(error?: Error): void;

/**
* Policies implemented/instructed by driver.
*
Expand Down Expand Up @@ -230,15 +210,6 @@ export interface IContainerStorageService {
* Returns the uploaded summary handle.
*/
uploadSummaryWithContext(summary: ISummaryTree, context: ISummaryContext): Promise<string>;

/**
* Retrieves the commit that matches the packfile handle. If the packfile has already been committed and the
* server has deleted it this call may result in a broken promise.
*
* @deprecated - This API is deprecated and will be removed in a future release. No replacement is planned as
* it is unused in the Runtime and below layers.
*/
downloadSummary(handle: ISummaryHandle): Promise<ISummaryTree>;
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,7 @@ declare type old_as_current_for_Interface_IContainerContext = requireAssignableT
* typeValidation.broken:
* "Interface_IContainerContext": {"backCompat": false}
*/
// @ts-expect-error compatibility expected to be broken
declare type current_as_old_for_Interface_IContainerContext = requireAssignableTo<TypeOnly<current.IContainerContext>, TypeOnly<old.IContainerContext>>

/*
Expand Down Expand Up @@ -265,6 +266,7 @@ declare type old_as_current_for_Interface_IContainerStorageService = requireAssi
* typeValidation.broken:
* "Interface_IContainerStorageService": {"backCompat": false}
*/
// @ts-expect-error compatibility expected to be broken
declare type current_as_old_for_Interface_IContainerStorageService = requireAssignableTo<TypeOnly<current.IContainerStorageService>, TypeOnly<old.IContainerStorageService>>

/*
Expand Down
6 changes: 5 additions & 1 deletion packages/framework/aqueduct/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,11 @@
"typescript": "~5.4.5"
},
"typeValidation": {
"broken": {},
"broken": {
"Interface_IDataObjectProps": {
"backCompat": false
}
},
"entrypoint": "legacy"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -319,4 +319,5 @@ declare type old_as_current_for_Interface_IDataObjectProps = requireAssignableTo
* typeValidation.broken:
* "Interface_IDataObjectProps": {"backCompat": false}
*/
// @ts-expect-error compatibility expected to be broken
declare type current_as_old_for_Interface_IDataObjectProps = requireAssignableTo<TypeOnly<current.IDataObjectProps>, TypeOnly<old.IDataObjectProps>>
12 changes: 1 addition & 11 deletions packages/loader/container-loader/src/containerStorageAdapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import type {
} from "@fluidframework/container-definitions/internal";
import type { IDisposable } from "@fluidframework/core-interfaces";
import { assert } from "@fluidframework/core-utils/internal";
import type { ISummaryHandle, ISummaryTree } from "@fluidframework/driver-definitions";
import type { ISummaryTree } from "@fluidframework/driver-definitions";
import type {
FetchSource,
IDocumentService,
Expand Down Expand Up @@ -247,16 +247,6 @@ export class ContainerStorageAdapter
public async createBlob(file: ArrayBufferLike): Promise<ICreateBlobResponse> {
return this._storageService.createBlob(file);
}

/**
* {@link IRuntimeStorageService.downloadSummary}.
*
* @deprecated - This API is deprecated and will be removed in a future release. No replacement is planned as
* it is unused in the Runtime and below layers.
*/
public async downloadSummary(handle: ISummaryHandle): Promise<ISummaryTree> {
return this._storageService.downloadSummary(handle);
}
}

/**
Expand Down
9 changes: 8 additions & 1 deletion packages/runtime/container-runtime-definitions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,14 @@
"typescript": "~5.4.5"
},
"typeValidation": {
"broken": {},
"broken": {
"Interface_IContainerRuntime": {
"backCompat": false
},
"Interface_IContainerRuntimeWithResolveHandle_Deprecated": {
"backCompat": false
}
},
"entrypoint": "legacy"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ declare type MakeUnusedImportErrorsGoAway<T> = TypeOnly<T> | MinimalType<T> | Fu
* typeValidation.broken:
* "Interface_IContainerRuntime": {"backCompat": false}
*/
// @ts-expect-error compatibility expected to be broken
declare type current_as_old_for_Interface_IContainerRuntime = requireAssignableTo<TypeOnly<current.IContainerRuntime>, TypeOnly<old.IContainerRuntime>>

/*
Expand Down Expand Up @@ -49,6 +50,7 @@ declare type old_as_current_for_Interface_IContainerRuntimeWithResolveHandle_Dep
* typeValidation.broken:
* "Interface_IContainerRuntimeWithResolveHandle_Deprecated": {"backCompat": false}
*/
// @ts-expect-error compatibility expected to be broken
declare type current_as_old_for_Interface_IContainerRuntimeWithResolveHandle_Deprecated = requireAssignableTo<TypeOnly<current.IContainerRuntimeWithResolveHandle_Deprecated>, TypeOnly<old.IContainerRuntimeWithResolveHandle_Deprecated>>

/*
Expand Down
3 changes: 3 additions & 0 deletions packages/runtime/container-runtime/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,9 @@
},
"typeValidation": {
"broken": {
"Interface_LoadContainerRuntimeParams": {
"backCompat": false
},
"TypeAlias_MinimumVersionForCollab": {
"backCompat": false,
"forwardCompat": false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,7 @@
* Licensed under the MIT License.
*/

import type {
FetchSource,
ICreateBlobResponse,
IDocumentStorageServicePolicies,
ISnapshot,
ISnapshotFetchOptions,
ISnapshotTree,
ISummaryContext,
ISummaryHandle,
ISummaryTree,
IVersion,
} from "@fluidframework/driver-definitions/internal";
import type { IRuntimeStorageService } from "@fluidframework/runtime-definitions/internal";
import { UsageError } from "@fluidframework/telemetry-utils/internal";

/**
* IRuntimeStorageService proxy which intercepts requests if they can be satisfied by the blobs received in the
Expand All @@ -28,14 +15,6 @@ export class StorageServiceWithAttachBlobs implements IRuntimeStorageService {
private readonly attachBlobs: Map<string, ArrayBufferLike>,
) {}

/**
* {@link IRuntimeStorageService.policies}.
* @deprecated - This will be removed in a future release. The DataStore layer does not need this.
*/
public get policies(): IDocumentStorageServicePolicies | undefined {
return this.internalStorageService.policies;
}

public async readBlob(id: string): Promise<ArrayBufferLike> {
const blob = this.attachBlobs.get(id);
if (blob !== undefined) {
Expand All @@ -46,75 +25,4 @@ export class StorageServiceWithAttachBlobs implements IRuntimeStorageService {
// IRuntimeStorageService to cache appropriately, no need to double-cache.
return this.internalStorageService.readBlob(id);
}

/**
* {@link IRuntimeStorageService.getSnapshotTree}.
* @deprecated - This will be removed in a future release. The DataStore layer does not need this.
*/
public async getSnapshotTree(
version?: IVersion,
scenarioName?: string,
// eslint-disable-next-line @rushstack/no-new-null
): Promise<ISnapshotTree | null> {
return this.internalStorageService.getSnapshotTree(version, scenarioName);
}

/**
* {@link IRuntimeStorageService.getSnapshot}.
* @deprecated - This will be removed in a future release. The DataStore layer does not need this.
*/
public async getSnapshot(snapshotFetchOptions?: ISnapshotFetchOptions): Promise<ISnapshot> {
if (this.internalStorageService.getSnapshot !== undefined) {
return this.internalStorageService.getSnapshot(snapshotFetchOptions);
}
throw new UsageError(
"getSnapshot api should exist on internal storage in documentStorageServiceProxy class",
);
}

/**
* {@link IRuntimeStorageService.getVersions}.
* @deprecated - This will be removed in a future release. The DataStore layer does not need this.
*/
public async getVersions(
// eslint-disable-next-line @rushstack/no-new-null
versionId: string | null,
count: number,
scenarioName?: string,
fetchSource?: FetchSource,
): Promise<IVersion[]> {
return this.internalStorageService.getVersions(
versionId,
count,
scenarioName,
fetchSource,
);
}

/**
* {@link IRuntimeStorageService.uploadSummaryWithContext}.
* @deprecated - This will be removed in a future release. The DataStore layer does not need this.
*/
public async uploadSummaryWithContext(
summary: ISummaryTree,
context: ISummaryContext,
): Promise<string> {
return this.internalStorageService.uploadSummaryWithContext(summary, context);
}

/**
* {@link IRuntimeStorageService.createBlob}.
* @deprecated - This will be removed in a future release. The DataStore layer does not need this.
*/
public async createBlob(file: ArrayBufferLike): Promise<ICreateBlobResponse> {
return this.internalStorageService.createBlob(file);
}

/**
* {@link IRuntimeStorageService.downloadSummary}.
* @deprecated - This will be removed in a future release. The DataStore layer does not need this.
*/
public async downloadSummary(handle: ISummaryHandle): Promise<ISummaryTree> {
return this.internalStorageService.downloadSummary(handle);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -697,6 +697,7 @@ declare type old_as_current_for_Interface_LoadContainerRuntimeParams = requireAs
* typeValidation.broken:
* "Interface_LoadContainerRuntimeParams": {"backCompat": false}
*/
// @ts-expect-error compatibility expected to be broken
declare type current_as_old_for_Interface_LoadContainerRuntimeParams = requireAssignableTo<TypeOnly<current.LoadContainerRuntimeParams>, TypeOnly<old.LoadContainerRuntimeParams>>

/*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -309,25 +309,7 @@ export interface IRuntimeMessagesContent {

// @beta @legacy
export interface IRuntimeStorageService {
// @deprecated (undocumented)
createBlob(file: ArrayBufferLike): Promise<ICreateBlobResponse>;
// @deprecated
dispose?(error?: Error): void;
// @deprecated
readonly disposed?: boolean;
// @deprecated (undocumented)
downloadSummary(handle: ISummaryHandle): Promise<ISummaryTree>;
// @deprecated (undocumented)
getSnapshot?(snapshotFetchOptions?: ISnapshotFetchOptions): Promise<ISnapshot>;
// @deprecated (undocumented)
getSnapshotTree(version?: IVersion, scenarioName?: string): Promise<ISnapshotTree | null>;
// @deprecated (undocumented)
getVersions(versionId: string | null, count: number, scenarioName?: string, fetchSource?: FetchSource): Promise<IVersion[]>;
// @deprecated (undocumented)
readonly policies?: IDocumentStorageServicePolicies | undefined;
readBlob(id: string): Promise<ArrayBufferLike>;
// @deprecated (undocumented)
uploadSummaryWithContext(summary: ISummaryTree, context: ISummaryContext): Promise<string>;
}

// @beta @legacy
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -300,25 +300,7 @@ export interface IRuntimeMessagesContent {

// @beta @legacy
export interface IRuntimeStorageService {
// @deprecated (undocumented)
createBlob(file: ArrayBufferLike): Promise<ICreateBlobResponse>;
// @deprecated
dispose?(error?: Error): void;
// @deprecated
readonly disposed?: boolean;
// @deprecated (undocumented)
downloadSummary(handle: ISummaryHandle): Promise<ISummaryTree>;
// @deprecated (undocumented)
getSnapshot?(snapshotFetchOptions?: ISnapshotFetchOptions): Promise<ISnapshot>;
// @deprecated (undocumented)
getSnapshotTree(version?: IVersion, scenarioName?: string): Promise<ISnapshotTree | null>;
// @deprecated (undocumented)
getVersions(versionId: string | null, count: number, scenarioName?: string, fetchSource?: FetchSource): Promise<IVersion[]>;
// @deprecated (undocumented)
readonly policies?: IDocumentStorageServicePolicies | undefined;
readBlob(id: string): Promise<ArrayBufferLike>;
// @deprecated (undocumented)
uploadSummaryWithContext(summary: ISummaryTree, context: ISummaryContext): Promise<string>;
}

// @beta @legacy
Expand Down
Loading
Loading