Re: [log4j] Annotation processing alternatives

2023-10-23 Thread Apache
We really don’t have much choice. With JPMS you really need to use ServiceLoader to locate things like plugins across modules. Using a s file like spring.factories doesn’t really help anyway. You wouldn’t want to force users to hand create the entries in that file and so would use annotations an

Re: [log4j] Annotation processing alternatives

2023-10-23 Thread Matt Sicker
So really, the question is whether we can make the generated service classes easier to create without annotation processing? > On Oct 23, 2023, at 12:11 PM, Gary Gregory wrote: > > Staying from the built-in Service Loader is a recipe for even more > custom code and complications. I say we stick

Re: [log4j] Annotation processing alternatives

2023-10-23 Thread Gary Gregory
Staying from the built-in Service Loader is a recipe for even more custom code and complications. I say we stick with the built-in Service Loader. Gary On Sun, Oct 22, 2023 at 5:01 PM Piotr P. Karwasz wrote: > > Hi Matt, > > On Sun, 22 Oct 2023 at 22:49, Matt Sicker wrote: > > So now we come to

Re: [log4j] Annotation processing alternatives

2023-10-22 Thread Piotr P. Karwasz
Hi Matt, On Sun, 22 Oct 2023 at 22:49, Matt Sicker wrote: > So now we come to your question about a factories file. That’s an interesting > idea, though it’s extremely similar to what we’re doing here with > ServiceLoader (though the split between META-INF/services/ files and > module-info.jav

Re: [log4j] Annotation processing alternatives

2023-10-22 Thread Matt Sicker
Let me expand on this question with further context as it relates to why the annotation processor exists in the first place. Back when the initial plugin system was developed by Ralph, we had an option to specify a comma-separated list of packages to scan for plugins (note that scanning the enti