Skip to content

Conversation

@elcasteel
Copy link

Add an implementation of the memory resource client that does not clone resources as they are written and read. In gloo edge, we use the memory client to hold proxies that are only generated by the gloo pod. Because proxies can be quite large, the clones take up significant space and GC resources and we can make decisions about when clones are necessary outside of the client.

@solo-changelog-bot
Copy link

Issues linked to changelog:
solo-io/gloo#7166

Copy link
Member

@EItanya EItanya left a comment

Choose a reason for hiding this comment

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

Since the behavior of this type is exactly the same without the clone, should the other client extend this one so we ensure the other behavior remains the same?

@elcasteel
Copy link
Author

I think we need locks around more of the methods in this client - we should not be able to call Write and List at the same time.
Also, I was planning to let the caller clone resources that it intends to modify after reading but given that we've recently learned that clones can modify the original, I'm going to add methods to return a cloned resource.

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.

5 participants