-
Notifications
You must be signed in to change notification settings - Fork 340
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pluggable storage #142
Comments
FTR https://www.jenkins.io/sigs/cloud-native/pluggable-storage/ @timja Thanks for re-starting it! Do you have a particular database in mind for the reference implementation? |
I wonder whether we could unify the Data serialization logic with https://github.com/jenkinsci/postgresql-fingerprint-storage-plugin . CC @stellargo . Test result storage also has extensible data structure |
Yes but a very different structure. I do not think it would be productive to mix those. |
Graduation criteria should include a (draft) JEP. See 202 for an example predecessor. |
Pretty close to hosting and releasing a beta. After #164 is merged it pretty much all works. What's left:
|
Update: I've released v0.2 of the Junit SQL Storage plugin I've been doing some benchmarking, caught one deadlock doing that, need to review reports and see if there's anything else that needs doing. After #165 I would say this is pretty much complete other than announcements / jep and pending any feedback |
I've done some benchmarks, seems slightly slower for the trend chart, but I expect that's relative to what's in memory, not sure if worth trying to figure out how to test that. it was something like .0015s vs .0003s. |
The relevant comparison would be to a job with thousands of build records, most of which are not in memory, if you disable my hack to avoid displaying results from unloaded builds! |
I tried to set it up while investigating test history performance issues, but got this while running a test pipeline that uploads some junit test results:
Any ideas? EDIT: Turns out I had to restart Jenkins for this to fully work. |
I got it running using postgresql, but it was still impossibly slow to load anything. I guess for retrieving the test results externally it is ok, but for our case where we use Jenkins it did not improve the situation. Also, the plugin is bursting out of the seams in part to other additions as well. |
what do you mean by?
|
I spent around a day trying to understand where the performance issue comes from just to detect a lot of unused SQL that don't improve performance for our case. Then I noticed that the charts don't work properly, then I saw that it was ported to echarts and the old behavior of single chart with both duration and result was scrapped. The new implementation seems broken on our side. I was just referring to the general design patterned chaos in the plugin. |
On a second thought, I think the pluggable storage should have an option to only export data to SQL instead of completely replacing the storage. I think a complete replacement of storage makes it significantly less maintainable but at the same time exporting test results to SQL can have its usefulness. |
In common CI/CD use-cases a lot of the space is being consumed by test reports. This data is stored within JENKINS_HOME, and the current storage format requires huge overheads when retrieving statistics and, especially, trends. In order to display trends, each report has to be loaded and then processed in-memory.
The main purpose of externalising Test Results is to optimize Jenkins logic by querying the desired data from specialized external storages, e.g. from Document-based databases like Elasticsearch. According to the current plan, JUnit Plugin will be extended in order to support such external storage in its APIs being widely used by test reporting plugins.
Status:
Foundation work started
Prototype API: #110
Continued in: #141
Todo:
Test strategy:
The junit plugin will provide a sample implementation using h2 database that can be used to verify pluggable storage functionality.
The Postgres implementation will be able to use something like test containers and replicate a similar test inside it's own plugin.
Performance tests will be written using the Microbenchmark harness, see https://www.jenkins.io/blog/2019/06/21/performance-testing-jenkins/
Graduation criteria
This API will be released in Beta initially and will likely change as it's developed.
The text was updated successfully, but these errors were encountered: