Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

disable message batching for Azure customers #11568

Merged
merged 4 commits into from
Aug 19, 2022
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion packages/framework/fluid-static/src/rootDataObject.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import {
} from "@fluidframework/aqueduct";
import { IContainerRuntime } from "@fluidframework/container-runtime-definitions";
import { IFluidLoadable } from "@fluidframework/core-interfaces";
import { FlushMode } from "@fluidframework/runtime-definitions";
import { requestFluidObject } from "@fluidframework/runtime-utils";
import {
ContainerSchema,
Expand Down Expand Up @@ -156,7 +157,11 @@ export class DOProviderContainerRuntimeFactory extends BaseContainerRuntimeFacto
{},
registryEntries,
);
super([rootDataObjectFactory.registryEntry], undefined, [defaultRouteRequestHandler(rootDataStoreId)]);
super([rootDataObjectFactory.registryEntry], undefined, [defaultRouteRequestHandler(rootDataStoreId)],
// temporary workaround to disable message batching until the message batch size issue is resolved
// resolution progress is tracked by the Feature 465 work item in AzDO
{ flushMode: FlushMode.Immediate },
);
alpaix marked this conversation as resolved.
Show resolved Hide resolved
this.rootDataObjectFactory = rootDataObjectFactory;
this.initialObjects = schema.initialObjects;
}
Expand Down
15 changes: 15 additions & 0 deletions packages/test/test-end-to-end-tests/src/test/messageSize.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import { describeNoCompat, itExpects } from "@fluidframework/test-version-utils"
import { IContainer, IErrorBase } from "@fluidframework/container-definitions";
import { ConfigTypes, IConfigProviderBase } from "@fluidframework/telemetry-utils";
import { GenericError } from "@fluidframework/container-utils";
import { FlushMode } from "@fluidframework/runtime-definitions";

describeNoCompat("Message size", (getTestObjectProvider) => {
const mapId = "mapId";
Expand Down Expand Up @@ -139,4 +140,18 @@ describeNoCompat("Message size", (getTestObjectProvider) => {

assertMapValues(dataObject2map, messageCount, largeString);
});

it("Batched small ops pass when batch is larger than max op size", async function() {
// flush mode is not applicable for the local driver
if (provider.driver.type === "local") {
this.skip();
}
await setupContainers({ ...testContainerConfig, runtimeOptions: { flushMode: FlushMode.Immediate } }, {});
const largeString = generateStringOfSize(500000);
const messageCount = 10;
setMapKeys(dataObject1map, messageCount, largeString);
await provider.ensureSynchronized();

assertMapValues(dataObject2map, messageCount, largeString);
});
});