On 15/02/2017 8:03 PM, Langer, Christoph wrote:
Hi Chris, Max,

thanks for your quick answers. So the service approach seems to fit quite well.

But can I assume that my service implementation will be available already at 
"bootstrap time" of the JDK? E.g. if I need to register/reach my service 
already at the early stages of JVM initialization, e.g. when a class java.lang.Thread 
gets initialized, can I assume a service from my extension module would be available?

I'm pretty sure the answer to that will be No! Thread is one of the earlier classes to be initialized, the module system is initialized much later.

David
-----

Thanks,
Christoph


-----Original Message-----
From: Chris Hegarty [mailto:[email protected]]
Sent: Mittwoch, 15. Februar 2017 10:04
To: Weijun Wang <[email protected]>
Cc: Langer, Christoph <[email protected]>; jigsaw-
[email protected]
Subject: Re: Extending java.base module


On 15 Feb 2017, at 08:51, Weijun Wang <[email protected]> wrote:

Disclaimer: I am not a jigsaw expert.

The provides/uses mechanism is certainly more formal, but you can also do
http://hg.openjdk.java.net/jdk9/dev/jdk/rev/d282c1a8d20b.

This is, at best, a hack. The use of Services is a better approach, where
possible.

-Chris.

Reply via email to