https://bugs.documentfoundation.org/show_bug.cgi?id=165774

--- Comment #5 from [email protected] ---
Here is part of the copy of my initial request:

> If we want to make this feature accessible to any extension written in Java, 
> it is necessary to make three modifications:
> - Add the UnoAgent.jar archive to the SDK.
> - Add an entry in the LibreOffice configuration (ie: xcu file) to enable or 
> disable instrumentation.
> - Load the JVM with the parameters needed for instrumentation depending on 
> the configuration.
> Please let me know what you think about this.

To this request, Noel Grandin responded:

> It sounds quite reasonable to add this to the core product behind an option.

I've always said that it's necessary to add an option in the configuration if
we want to make this usable. This is even the primary reason for my PR.

> But, more importantly, for another, and as I already had tried to explain 
> elsewhere:
> The LO code instantiating a JVM (jvmaccess, jvmfwk, stoc; all part of URE) 
> cannot access the LO configuration (configmgr, officecfg; both not part of 
> URE).

The only Java-related settings I found in the configuration are:
- VirtualMachine/Security
- VirtualMachine/NetAccess
- VirtualMachine/RunUnoComponentsOutOfProcess

These three options are read from the javavm.cxx file line 345 and for now I
have not found another place where the configuration for Java is used. So I
don't really see any reason to have to move the reading of the Java
configuration.

The instrumentation agent will allow me to redirect the use of the JVM's
java.lang.System.Logger interface to the UNO singleton
com.sun.star.logger.LoggerPool and thus make the logging of all Java
applications using System.Logger accessible in LibreOffice.
This should be a checkbox in the jdbcDriverOOo configuration to enable this
option. I don't want to ask users to: download a file then change the JVM
startup options and finally change the JVM ClassPath when I can do the same
thing by adding 50 lines of code in LibreOffice. And it was never meant to be
done by technically skilled people. Normally what I write, my mother should be
able to use it, and it's a pickaxe.

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to