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

Add explicit declaration of batch class #216

Closed
charphi opened this issue Mar 28, 2023 · 1 comment
Closed

Add explicit declaration of batch class #216

charphi opened this issue Mar 28, 2023 · 1 comment
Labels
enhancement New feature or request
Milestone

Comments

@charphi
Copy link
Member

charphi commented Mar 28, 2023

Batch loading in @ServiceDefinition is specified by the properties batch and batchName. These properties generates a new class.
Example:

@ServiceDefinition ( batch = true, batchName = "a.b.c.SomeBatch" )
interface SomeService { }

A better approach would be to replace these properties by one that specifies the class to use.
Example:

@ServiceDefinition ( batchType = SomeBatch.class )
interface SomeService { }

interface SomeBatch {
  Stream<SomeService > getProviders();
}
@charphi
Copy link
Member Author

charphi commented Feb 6, 2024

Done in 6d43f0e

@charphi charphi closed this as completed Feb 6, 2024
@charphi charphi added this to the 1.9.0 milestone Feb 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant