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

MergeTree Client Legacy API Removed #22697

Merged
merged 42 commits into from
Nov 5, 2024

Conversation

anthony-murphy
Copy link
Contributor

@anthony-murphy anthony-murphy commented Oct 1, 2024

The Client class in the merge-tree package has been removed. Additionally, types that directly or indirectly expose the merge-tree Client class have also been removed.

The removed types were not meant to be used directly, and direct usage was not supported:

  • AttributionPolicy
  • IClientEvents
  • IMergeTreeAttributionOptions
  • SharedSegmentSequence
  • SharedStringClass

Some classes that referenced the Client class have been transitioned to interfaces. Direct instantiation of these classes was not supported or necessary for any supported scenario, so the change to an interface should not impact usage. This applies to the following types:

  • SequenceInterval
  • SequenceEvent
  • SequenceDeltaEvent
  • SequenceMaintenanceEvent

The initial deprecations of the now changed or removed types were announced in Fluid Framework v2.4.0:
Several MergeTree Client Legacy APIs are now deprecated

@github-actions github-actions bot added area: dds Issues related to distributed data structures area: dds: sharedstring area: framework Framework is a tag for issues involving the developer framework. Eg Aqueduct area: tests Tests to add, test infrastructure improvements, etc public api change Changes to a public API base: main PRs targeted against main branch labels Oct 1, 2024
@msfluid-bot
Copy link
Collaborator

msfluid-bot commented Oct 1, 2024

@fluid-example/bundle-size-tests: -123 Bytes
Metric NameBaseline SizeCompare SizeSize Diff
aqueduct.js 464.21 KB 464.06 KB -149 Bytes
azureClient.js 562.45 KB 562.5 KB +49 Bytes
connectionState.js 724 Bytes 724 Bytes No change
containerRuntime.js 261.86 KB 261.87 KB +14 Bytes
fluidFramework.js 424.82 KB 424.84 KB +14 Bytes
loader.js 134.17 KB 134.19 KB +14 Bytes
map.js 42.71 KB 42.71 KB +7 Bytes
matrix.js 148.54 KB 148.55 KB +7 Bytes
odspClient.js 528.3 KB 528.34 KB +49 Bytes
odspDriver.js 97.84 KB 97.86 KB +21 Bytes
odspPrefetchSnapshot.js 42.81 KB 42.83 KB +14 Bytes
sharedString.js 164.76 KB 164.58 KB -177 Bytes
sharedTree.js 415.28 KB 415.29 KB +7 Bytes
Total Size 3.36 MB 3.36 MB -123 Bytes

Baseline commit: 99fbaf4

Generated by 🚫 dangerJS against 02adda5

@anthony-murphy anthony-murphy force-pushed the test/internal-merge-tree-client branch from 7e8d1c7 to 2ae3b9e Compare October 2, 2024 19:56
@anthony-murphy
Copy link
Contributor Author

anthony-murphy commented Oct 16, 2024

#22827

@anthony-murphy anthony-murphy requested review from a team as code owners November 2, 2024 00:36
@anthony-murphy anthony-murphy added the breaking change This PR or issue would introduce a breaking change label Nov 2, 2024
@github-actions github-actions bot removed the breaking change This PR or issue would introduce a breaking change label Nov 2, 2024
@@ -152,7 +152,7 @@ export type {
ISharedSegmentSequence,
} from "@fluidframework/sequence/internal";

export {
export type {
Copy link
Contributor

Choose a reason for hiding this comment

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

why this change? seems like SharedString still needs to be usable as a value in public api, e.g. in dynamic DDS creation:

const myNewString = await container.create(SharedString)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

interesting. i don't think i made an direct modifications to this file, maybe an auto-formatter bug. i'll revert.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

image

Copy link
Contributor Author

Choose a reason for hiding this comment

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

this breaks the build. the error doesn't actually call out SharedString. I'll split the import to fix, but odd the autofix does the wrong thing. FYI @Josmithr @tylerbutler

Copy link
Contributor Author

Choose a reason for hiding this comment

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

i also don't think we type test fluid-framework, so nothing catches this.

Copy link
Contributor

Choose a reason for hiding this comment

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

this breaks the build. the error doesn't actually call out SharedString. I'll split the import to fix, but odd the autofix does the wrong thing. FYI @Josmithr @tylerbutler

I don't think I've seen the auto-fixer change an export that was not type-only to a type-export before. If it's doing that, we may want to disable auto-fix for that rule.

i also don't think we type test fluid-framework, so nothing catches this.

This seems like a pretty serious oversight in our tooling. We should schedule work for this.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@Josmithr do you know the right place to file a bug like this, and which team would own it? if you do would you mind filing it, and linking it here?

Copy link
Contributor

@Josmithr Josmithr Nov 4, 2024

Choose a reason for hiding this comment

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

Ownership of some of this tooling stuff remains pretty ambiguous (something my team has been pushing on in retrospectives). I would love for there to be more clarity around this for the team.

I'm happy to take on the eslint update (I have another update I want to make in that space anyways). https://dev.azure.com/fluidframework/internal/_workitems/edit/22618

I think Team Sasha/Jason has been owning the type-test infra? Is that right? @jason-ha

Copy link
Member

Choose a reason for hiding this comment

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

In the past we haven't worried about type testing fluid-framework since it just re-exports APIs that are type-tested in their "real" packages. But that was a long time ago, and we have since stopped using export * so messing up the exports is more likely now. It was also based on the fact that the entire API surface was type-tested, though, and that's no longer the case for most packages which only type-test a subset of their API. It should still be a super-set of what's exposed in fluid-framework, though.

Copy link
Member

@tylerbutler tylerbutler left a comment

Choose a reason for hiding this comment

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

Minor nit; docs look good.

.changeset/rude-views-bake.md Outdated Show resolved Hide resolved
@anthony-murphy anthony-murphy enabled auto-merge (squash) November 5, 2024 20:06
@anthony-murphy anthony-murphy enabled auto-merge (squash) November 5, 2024 22:31
Copy link
Contributor

github-actions bot commented Nov 5, 2024

🔗 No broken links found! ✅

Your attention to detail is admirable.

linkcheck output


> [email protected] ci:linkcheck /home/runner/work/FluidFramework/FluidFramework/docs
> start-server-and-test ci:start 1313 linkcheck:full

1: starting server using command "npm run ci:start"
and when url "[ 'http://127.0.0.1:1313' ]" is responding with HTTP status code 200
running tests using command "npm run linkcheck:full"


> [email protected] ci:start
> http-server ./public --port 1313 --silent


> [email protected] linkcheck:full
> npm run linkcheck:fast -- --external


> [email protected] linkcheck:fast
> linkcheck http://localhost:1313 --skip-file skipped-urls.txt --external

Crawling...

Stats:
  447786 links
    3441 destination URLs
       2 URLs ignored
       0 warnings
       0 errors


@anthony-murphy anthony-murphy merged commit 2aa0b5e into main Nov 5, 2024
30 checks passed
@anthony-murphy anthony-murphy deleted the test/internal-merge-tree-client branch November 5, 2024 23:22
Josmithr pushed a commit that referenced this pull request Nov 5, 2024
The `Client` class in the merge-tree package has been removed.
Additionally, types that directly or indirectly expose the merge-tree
`Client` class have also been removed.

The removed types were not meant to be used directly, and direct usage
was not supported:

- AttributionPolicy
- IClientEvents
- IMergeTreeAttributionOptions
- SharedSegmentSequence
- SharedStringClass

Some classes that referenced the `Client` class have been transitioned
to interfaces. Direct instantiation of these classes was not supported
or necessary for any supported scenario, so the change to an interface
should not impact usage. This applies to the following types:

- SequenceInterval
- SequenceEvent
- SequenceDeltaEvent
- SequenceMaintenanceEvent

The initial deprecations of the now changed or removed types were
announced in Fluid Framework v2.4.0:
[Several MergeTree Client Legacy APIs are now
deprecated](https://github.com/microsoft/FluidFramework/blob/main/RELEASE_NOTES/2.4.0.md#several-mergetree-client-legacy-apis-are-now-deprecated-22629)

---------

Co-authored-by: Tyler Butler <[email protected]>
sonalideshpandemsft added a commit that referenced this pull request Nov 6, 2024
sonalideshpandemsft added a commit that referenced this pull request Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: dds: sharedstring area: dds Issues related to distributed data structures area: framework Framework is a tag for issues involving the developer framework. Eg Aqueduct area: tests Tests to add, test infrastructure improvements, etc base: main PRs targeted against main branch changeset-present public api change Changes to a public API
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants