The project adopts the gitlab runner function that will be triggered automatically after the code is submitted, and then compile the project, make it into a docker image and upload it to the nexus warehouse.
There is a problem after using it for a period of time. An error is reported in the jar package generated after the project is compiled. The specific information is as follows:
This error message is the error message of the gitlab runner tool
ERROR: Could not create cache adapter error=cache factory not found: factory for cache adapter "" was not registere
The gitlab compilation page will also display relevant error messages. I forgot to save the screenshot here.
After investigation, I learned that it was not the problem of gitlab runner, but the problem of gitlab
The specific problems are as follows:
The jar package generated after compiling the project will be provided to the dockerfile file for use. Here, artifacts are used
However, after each compilation, a directory will be generated in the corresponding directory of gitlab to store the jar package. The default path is:
The directory inside is randomly generated to store the jar package generated after compiling with gitlab runner every time.
After a long time, this directory will occupy a large disk space. When the disk space is insufficient, the above error will be reported when compiling again.
Log in to gitlab with the administrator account, find the CI/CD in the settings, and set the validity period of the artifacts. In this way, you don’t have to delete them manually. When they expire, they will be deleted automatically
The solution here is to delete all folders except the tmp folder in this directory, that is, delete the existing folder for storing jar packages, and then use the gitlab runner tool to compile again
- java.io.StreamCorruptedException: invalid stream header: 00000000
- Summary of WebKit compiling on Windows platform
- CentOS Yum download package error: invalid space in download directory
- How to Solve Error: The project description file (.project) for i…
- How to Solve OpenCV3.4 error: ‘time’ was not declared in this scope
- How to Solve Oracle ORA-09925 error: Unable to create audit trail file
- [Solved] Springboot Error: found character ‘@’ that cannot start any token. (Do not use @ for indentation)
- Gitlab 403 Forbidden error [How to Solve]
- After npm5, execute NPM cache clean and report an error
- All tap-windows6 adapters on this system are currently in use or disabled.