You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
One simple but very useful feature would be to allow to ignore existing native configuration with the tracing agent. For example, the agent could be aware of the configuration in META-INF/native-image/*.json in the project and generate only what is not already present in this existing configuration.
A very interesting use case would be with Spring Native that generates all the configuration it can using an analysis of the Spring application via the Spring AOT build plugins. Currently even with all that inferred configuration, if just a few entries were missing, they are totally lost in the huge configuration files generated by the agent.
This enhancement would allow the tracing agent to just generate "the useful diff" that could then be taken and used as it is or converted to Spring @NativeHint. We think that feature would be useful outside of Spring as well.
I would be in favor of that being the default behavior. If that's not possible or if you consider that's not a good idea, providing a configuration flag on the agent would be fine.
The text was updated successfully, but these errors were encountered:
It's a bit unfinished but the principles are there:
it discovers META-INF/native-image entries on the classpath (in directories, don't think it goes into jars yet)
loads them up into a separate configurationset
subtracts that configurationset from the collected set before it is written out (possible to do this as you go I suppose, I just did something quick).
it attempts to simplify entries in the agent output as much as possible, so it is quite granular, it doesn't just remove them if they are identical, it strips them down (for example if the existing config named 3 methods and the computed config contained 5, it should remove 3 from the computed config)
For our webmvc-tomcat sample, I saw the line count for reflect-config.json go from 2800 to 1900.
Hey @aclement! Your approach for this change is good, and the principles it follows (filtering configuration when it's written out and simplifying entries) is basically the same as it's now implemented on master: a461aa0
There are two different agent flags related to this mode:
experimental-omit-config-from-classpath omits configuration present on the classpath, both in directories and JARs
config-to-omit=<path> omits configuration from a specified directory
This feature won't be in the upcoming 21.2 release, but it's on master and should soon be available in the dev builds. If anyone has a chance to test it out - please do and let me if it works for you
One simple but very useful feature would be to allow to ignore existing native configuration with the tracing agent. For example, the agent could be aware of the configuration in
META-INF/native-image/*.json
in the project and generate only what is not already present in this existing configuration.A very interesting use case would be with Spring Native that generates all the configuration it can using an analysis of the Spring application via the Spring AOT build plugins. Currently even with all that inferred configuration, if just a few entries were missing, they are totally lost in the huge configuration files generated by the agent.
This enhancement would allow the tracing agent to just generate "the useful diff" that could then be taken and used as it is or converted to Spring
@NativeHint
. We think that feature would be useful outside of Spring as well.I would be in favor of that being the default behavior. If that's not possible or if you consider that's not a good idea, providing a configuration flag on the agent would be fine.
The text was updated successfully, but these errors were encountered: