1/*
2 * scan.h
3 *
4 * Copyright (C) 2015 Aerospike, Inc.
5 *
6 * Portions may be licensed to Aerospike, Inc. under one or more contributor
7 * license agreements.
8 *
9 * This program is free software: you can redistribute it and/or modify it under
10 * the terms of the GNU Affero General Public License as published by the Free
11 * Software Foundation, either version 3 of the License, or (at your option) any
12 * later version.
13 *
14 * This program is distributed in the hope that it will be useful, but WITHOUT
15 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
16 * FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
17 * details.
18 *
19 * You should have received a copy of the GNU Affero General Public License
20 * along with this program. If not, see http://www.gnu.org/licenses/
21 */
22
23#pragma once
24
25//==========================================================
26// Includes.
27//
28
29#include <stdint.h>
30
31#include "dynbuf.h"
32
33
34//==========================================================
35// Forward declarations.
36//
37
38struct as_mon_jobstat_s;
39struct as_namespace_s;
40struct as_transaction_s;
41
42
43//==========================================================
44// Public API.
45//
46
47void as_scan_init(void);
48int as_scan(struct as_transaction_s *tr, struct as_namespace_s *ns);
49void as_scan_limit_finished_jobs(void);
50int as_scan_get_active_job_count(void);
51int as_scan_list(char* name, cf_dyn_buf* db);
52struct as_mon_jobstat_s* as_scan_get_jobstat(uint64_t trid);
53struct as_mon_jobstat_s* as_scan_get_jobstat_all(int* size);
54int as_scan_abort(uint64_t trid);
55int as_scan_abort_all(void);
56