Commit 33af5922 authored by ale's avatar ale

Retrieve also the full path so we can count numVersions on it

parent 28845ae3
Pipeline #3649 passed with stages
in 2 minutes and 5 seconds
...@@ -224,7 +224,7 @@ func (s *Service) FindAtoms(ctx context.Context, req *tabacco.FindRequest) ([]*t ...@@ -224,7 +224,7 @@ func (s *Service) FindAtoms(ctx context.Context, req *tabacco.FindRequest) ([]*t
`SELECT `SELECT
backup_id, backup_timestamp, backup_host, backup_id, backup_timestamp, backup_host,
dataset_id, dataset_source, dataset_id, dataset_source,
atom_name, atom_path atom_name, atom_path, atom_full_path
FROM log WHERE %s FROM log WHERE %s
ORDER BY backup_timestamp DESC`, ORDER BY backup_timestamp DESC`,
strings.Join(where, " AND "), strings.Join(where, " AND "),
...@@ -241,7 +241,7 @@ func (s *Service) FindAtoms(ctx context.Context, req *tabacco.FindRequest) ([]*t ...@@ -241,7 +241,7 @@ func (s *Service) FindAtoms(ctx context.Context, req *tabacco.FindRequest) ([]*t
if err := rows.Scan( if err := rows.Scan(
&a.BackupID, &a.BackupTimestamp, &a.BackupHost, &a.BackupID, &a.BackupTimestamp, &a.BackupHost,
&a.DatasetID, &a.DatasetSource, &a.DatasetID, &a.DatasetSource,
&a.AtomName, &a.AtomPath, &a.AtomName, &a.AtomPath, &a.AtomFullPath,
); err != nil { ); err != nil {
log.Printf("bad row: %v", err) log.Printf("bad row: %v", err)
continue continue
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment