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

Added summarize() API in DDS that generates summary tree and list of referenced routes #3975

Merged
merged 17 commits into from
Nov 20, 2020

Conversation

agarwal-navin
Copy link
Contributor

@agarwal-navin agarwal-navin commented Oct 16, 2020

Fixes #3967

This is a pre-cursor to garbage collection.

  • Garbage collection will re-use the data generated by snapshot for finding fluid objects that are referenced.
  • Added a summarize() API in DDS to generate summary tree a list of routes to fluid objects referenced by it.
  • I added a new IFluidSerializer implementation that can track the routes of handles that it serializes.
  • DDSes uses this serializer to serialize its data during snapshot. The serializer tracks the routes of all handles in the data and this list is returned along with the snapshot tree.

A follow up PR will use the routes tracked during the snapshot process for use during GC.

@agarwal-navin
Copy link
Contributor Author

@vladsud @anthony-murphy With this change, do we still need the IFluidSerializer at ContainerRuntime and DataStoreRuntime? I don't see them getting used in our code or in Bohemia's.

I do see that IFluidObject extends IProvideFluidSerializer but I am not sure if we need it.

@msfluid-bot
Copy link
Collaborator

msfluid-bot commented Oct 16, 2020

@fluidframework/base-host: No change
Metric NameBaseline SizeCompare SizeSize Diff
main.js 163.93 KB 163.93 KB No change
Total Size 163.93 KB 163.93 KB No change
@fluid-example/bundle-size-tests: +22.16 KB
Metric NameBaseline SizeCompare SizeSize Diff
container.js 180.7 KB 181.91 KB +1.21 KB
map.js 40.12 KB 46.25 KB +6.12 KB
matrix.js 137.35 KB 144.78 KB +7.43 KB
odspDriver.js 195.67 KB 195.67 KB +1 Bytes
sharedString.js 150.89 KB 158.29 KB +7.4 KB
Total Size 704.73 KB 726.89 KB +22.16 KB

Baseline commit: a8e56c3

Generated by 🚫 dangerJS against 21f1f25

@anthony-murphy
Copy link
Contributor

anthony-murphy commented Oct 16, 2020

Fixes #3962

that doesn't look right. is it supposed to an issue

@agarwal-navin
Copy link
Contributor Author

Fixes #3962

that doesn't look right. is it supposed to an issue

Updated it to reflect the correct issue.

@agarwal-navin
Copy link
Contributor Author

@anthony-murphy Did I delete your comment in SharedObject? I was replying to it and I refreshed the page. Now, its gone!

@curtisman
Copy link
Member

Closing and reopening to trigger build

@curtisman curtisman closed this Oct 23, 2020
@curtisman curtisman reopened this Oct 23, 2020
@agarwal-navin agarwal-navin changed the title Added FluidSerializer in SharedObject. Updated DDS to use this serializer to serialize / parse handles Updated snapshot() API in DDS to return referenced routes Oct 28, 2020
Copy link
Contributor

@vladsud vladsud left a comment

Choose a reason for hiding this comment

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

I must admit I reviewed it in chunks, between various commits, but overall looks good.

@agarwal-navin
Copy link
Contributor Author

I must admit I reviewed it in chunks, between various commits, but overall looks good.

Thanks Vlad! We can keep iterating on it as and when needed.

@agarwal-navin agarwal-navin merged commit c07a085 into microsoft:main Nov 20, 2020
@agarwal-navin agarwal-navin deleted the fluidSerializer branch November 25, 2020 05:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add summarize method to DDS and a new serializer for summaries
7 participants