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

Change ExecutionStrategy methods from package-private to protected #3573

Closed
wants to merge 1 commit into from

Conversation

rayokota
Copy link

@rayokota rayokota commented Apr 18, 2024

I would like to override/customize the behavior of getAsyncFieldValueInfo in a custom subclass of AsyncExecutionStrategy but cannot easily do it. Since the method getAsyncFieldValueInfo is called in both AsyncExecutionStrategy.execute and ExecutionStrategy.executeObject, I can try to override both those methods in my subclass, but I end up copying in a lot more code than if I could simply override getAsyncFieldValueInfo.

Also, in the future I may want to override createDeferredExecutionSupport but I can omit the change to the signature of this method for now if it makes the PR more acceptable.

Thank you in advance.

@bbakerman
Copy link
Member

I would like to override/customize the behavior of getAsyncFieldValueInfo

Can you expand more on what new behavior you would like to introduce.

Can you explain more about how much extra code you need to copy?

The background thinking on ExecutionStrategy is that we should never have made it public API. Why? Because the locking that comes from public API in this special case is not worth the price of being unable to change in order to be efficient.

Some people want to write whole new algorithms on how a query is executed and this can't be done via inheritance. The current ExecutionStrategy code is intimately tied to the breath first execution of fields along with the peer Instrumentation classes that reflect that algorithm. Its hard (damn well near impossible) to make new ones.

@bbakerman
Copy link
Member

I am closing this PR because we don't have any insight into why its needed.

@bbakerman bbakerman closed this May 21, 2024
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.

None yet

2 participants