• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

HDFGroup / hermes / 4837090058

pending completion
4837090058

Pull #515

github

GitHub
Merge f2cf3160b into 87672e106
Pull Request #515: v1.0

5502 of 5502 new or added lines in 117 files covered. (100.0%)

4997 of 7300 relevant lines covered (68.45%)

6195627.43 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/data_placement_engine.h
1
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
2
 * Distributed under BSD 3-Clause license.                                   *
3
 * Copyright by The HDF Group.                                               *
4
 * Copyright by the Illinois Institute of Technology.                        *
5
 * All rights reserved.                                                      *
6
 *                                                                           *
7
 * This file is part of Hermes. The full Hermes copyright notice, including  *
8
 * terms governing use, modification, and redistribution, is contained in    *
9
 * the COPYING file, which can be found at the top directory. If you do not  *
10
 * have access to the file, you may request a copy from help@hdfgroup.org.   *
11
 * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
12

13
#ifndef HERMES_DATA_PLACEMENT_ENGINE_H_
14
#define HERMES_DATA_PLACEMENT_ENGINE_H_
15

16
#include <map>
17

18
#include "hermes.h"
19
#include "status.h"
20
#include "hermes_types.h"
21
#include "metadata_manager.h"
22

23
namespace hermes {
24

25
using api::Status;
26
using hermes::api::PlacementPolicy;
27

28
/**
29
 A class to represent data placement engine
30
*/
31
class DPE {
32
 protected:
33
  MetadataManager *mdm_; /**< A pointer to the MDM */
34

35
 public:
36
  /** Constructor. */
37
  DPE();
38

39
  /** Destructor. */
40
  virtual ~DPE() = default;
×
41

42
  /**
43
   * Calculate the placement of a set of blobs using a particular
44
   * algorithm given a context.
45
   * */
46
  virtual Status Placement(const std::vector<size_t> &blob_sizes,
47
                           std::vector<TargetInfo> &targets,
48
                           api::Context &ctx,
49
                           std::vector<PlacementSchema> &output) = 0;
50

51
  /**
52
   * Calculate the total placement for all blobs and output a schema for
53
   * each blob.
54
   * */
55
  Status CalculatePlacement(const std::vector<size_t> &blob_sizes,
56
                            std::vector<PlacementSchema> &output,
57
                            api::Context &api_context);
58
};
59

60
}  // namespace hermes
61
#endif  // HERMES_DATA_PLACEMENT_ENGINE_H_
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc