Merge pull request #517 from KeyboardNerd/master

api,database: updated version_format documentation.
This commit is contained in:
Jimmy Zelinskie 2018-02-02 13:51:48 -05:00 committed by GitHub
commit 12b47b0854
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 12 additions and 6 deletions

View File

@ -158,9 +158,11 @@ func (m *ClairStatus) GetLastUpdateTime() *google_protobuf2.Timestamp {
}
type Feature struct {
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
NamespaceName string `protobuf:"bytes,2,opt,name=namespace_name,json=namespaceName" json:"namespace_name,omitempty"`
Version string `protobuf:"bytes,3,opt,name=version" json:"version,omitempty"`
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
NamespaceName string `protobuf:"bytes,2,opt,name=namespace_name,json=namespaceName" json:"namespace_name,omitempty"`
Version string `protobuf:"bytes,3,opt,name=version" json:"version,omitempty"`
// version_format is the format used by installer package manager to store
// package versions.
VersionFormat string `protobuf:"bytes,4,opt,name=version_format,json=versionFormat" json:"version_format,omitempty"`
Vulnerabilities []*Vulnerability `protobuf:"bytes,5,rep,name=vulnerabilities" json:"vulnerabilities,omitempty"`
}

View File

@ -45,6 +45,9 @@ message Feature{
string name = 1;
string namespace_name = 2;
string version = 3;
// version_format is the format used by installer package manager to store
// package versions.
string version_format = 4;
repeated Vulnerability vulnerabilities = 5;
}

View File

@ -232,7 +232,8 @@
"type": "string"
},
"version_format": {
"type": "string"
"type": "string",
"description": "version_format is the format used by installer package manager to store\npackage versions."
},
"vulnerabilities": {
"type": "array",

View File

@ -71,8 +71,8 @@ type Namespace struct {
// determined.
//
// e.g. Name: OpenSSL, Version: 1.0, VersionFormat: dpkg.
// dpkg implies the installer package manager but the namespace (might be
// debian:7, debian:8, ...) could not be determined.
// dpkg is the version format of the installer package manager, which in this
// case could be dpkg or apk.
type Feature struct {
Name string
Version string