Skip to content

k1729p/Study20

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Study20 README Contents


The diagram of the JPMS modules

Java module declarations
Maven Module Name JPMS Module Name Module Descriptor Link
service kp.service 'module-info.java'
service-provider kp.provider 'module-info.java'
service-client kp.client 'module-info.java'

Java source code. Packages:

module 'service': kp.service
module 'service-provider': kp.provider
module 'service-client': kp.client


module 'service': Java API Documentation
module 'service-provider': Java API Documentation
module 'service-client': Java API Documentation


Action:

1. Build and run the 'KpServiceClient' with the batch file '01 MVN clean install + Run Application.bat'.

1. Alternative action: build and run the 'KpServiceClient' with the batch file '02 Create Image And Run.bat'.
This process uses the local Maven repository.
It creates the run-time image with the Java linker jlink and uses the generated runtime for execution.

2. The service registering and loading.


The diagram of the service registering and loading

The two providers of the 'kp.service.KpService' implementation:

3. The main client method: 'kp.client.KpServiceClient::main'.
With the method 'java.util.ServiceLoader::load' the service providers are located and loaded.
The service method: 'kp.service.KpService::launch'.


The sequence diagram


The screenshot of the console log.

Back to the top of the page