Installation directory structure

  1. The microservice catalog is too complicated and it is not convenient to switch catalog management
  2. There is no unified startup script, which makes it more troublesome to start and stop microservices
  3. There are a large number of duplicate service configurations, and the same configuration often needs to be modified in many places
  4. There are a large number of repeated Lib dependencies, which increases the size of the installation package and the risk of dependency conflicts

Therefore, in Linkis 1.0, we have greatly optimized and adjusted the installation directory structure, reducing the number of microservice directories, reducing the jar packages that are repeatedly dependent, and reusing configuration files and microservice management scripts as much as possible. Mainly reflected in the following aspects:

1.The bin folder is no longer provided for each microservice, and modified to be shared by all microservices.

2.No longer provide a separate conf directory for each microservice, and modify it to be shared by all microservices.

3.The lib folder is no longer provided for each microservice, and modified to be shared by all microservices

The simplified directory structure of Linkis 1.0 is as follows.

Configuration item modification

After executing the install.sh in the bin directory to complete the Linkis installation, you need to modify the configuration items. All configuration items are located in the con directory. Normally, you need to modify the three configurations of db.sh, linkis.properties, and linkis-env.sh For documentation, project installation and configuration, please refer to the article “Linkis1.0 Installation”

Microservice start and stop

After modifying the configuration items, you can start the microservice in the sbin directory. The names of all microservices are as follows:

  1. ├── linkis-cg-entrance ──computing governance entrance service
  2. ├── linkis-cg-linkismanager ──computing governance management service
  3. ├── linkis-mg-eureka ──microservice registry service
  4. ├── linkis-mg-gateway ──Linkis gateway service
  5. ├── linkis-ps-cs ──context service
  6. ├── linkis-ps-datasource ──data source service

Microservice abbreviation:

In the past, to start and stop a single microservice, you need to enter the bin directory of each microservice and execute the start/stop script. When there are many microservices, it is troublesome to start and stop. A lot of additional directory switching operations are added. Linkis1.0 will all The scripts related to the start and stop of microservices are placed in the sbin directory, and only a single entry script needs to be executed.

Under the Linkis/sbin directory:

  1. sh linkis-start-all.sh

2.Shut down all microservices at once

  1. sh linkis-stop-all.sh

3.Start a single microservice (the service name needs to be removed from the Linkis prefix, such as mg-eureka)

For example:

4.Shut down a single microservice

  1. sh linkis-daemon.sh stop service-name

For example:

  1. sh linkis-daemon.sh stop mg-eureka

5.Restart a single microservice

For example:

  1. sh linkis-daemon.sh restart mg-eureka
  1. sh linkis-daemon.sh status service-name

For example: