dlespiau / dlespiau/patchwork

Patchwork could store test logs server side

Open
#110 1 comment 0 reactions 0 assignees View on GitHub
documentation domain/API enhancement
Dominant language
Python
Stars
22
Forks
12
PR merge metrics
No merged PRs in 30d

Description

Log coming from tests should be store into DB
### Ideas

The system should be able to store the logs coming from the tests done for specific series. There are two possible ways to do this
1. Adding another field in the JSON POST request

POST /api/1.0/series/47/test-results/ HTTP/1.1

{
"test_name": "checkpatch.pl",
"state": "success",
"url": "",
"summary": "total: 0 errors, 0 warnings, 10 lines checked"
"log": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
}
2. Allowing another post route to accept the following request

POST /api/1.0/series/47/test-results/log HTTP/1.1

{
"log": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
}

Option 1 looks a bit redundant to have two fields (url and log) containing the same content. Option 2 is perhaps cleaner but users needs to do a second request, affecting the user experience and perhaps hitting the server performance.

Some related questions: can users post a log of any side? should log be stored into the DB, or just in the filesystem and server just need to store the filename?
### Refefences
- http://patchwork-freedesktop.readthedocs.org/en/latest/rest.html#post--api-1.0-series-(int-series_id)-revisions-(int- version)-test-results-

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.