mirror of
https://github.com/wassname/ray.git
synced 2026-07-02 22:13:16 +08:00
[cpp worker] support cluster mode and object Put/Get works (#9682)
This commit is contained in:
@@ -33,6 +33,9 @@ class Ray {
|
||||
/// Initialize Ray runtime.
|
||||
static void Init();
|
||||
|
||||
/// Shutdown Ray runtime.
|
||||
static void Shutdown();
|
||||
|
||||
/// Store an object in the object store.
|
||||
///
|
||||
/// \param[in] obj The object which should be stored.
|
||||
|
||||
@@ -2,22 +2,27 @@
|
||||
#pragma once
|
||||
#include <memory>
|
||||
#include <string>
|
||||
#include "ray/core.h"
|
||||
|
||||
namespace ray {
|
||||
namespace api {
|
||||
|
||||
enum class RunMode { SINGLE_PROCESS, SINGLE_BOX, CLUSTER };
|
||||
|
||||
enum class WorkerMode { NONE, DRIVER, WORKER };
|
||||
enum class RunMode { SINGLE_PROCESS, CLUSTER };
|
||||
|
||||
/// TODO(Guyang Song): Make configuration complete and use to initialize.
|
||||
class RayConfig {
|
||||
public:
|
||||
WorkerMode worker_mode = WorkerMode::DRIVER;
|
||||
WorkerType worker_type = WorkerType::DRIVER;
|
||||
|
||||
RunMode run_mode = RunMode::SINGLE_PROCESS;
|
||||
|
||||
std::string redis_address;
|
||||
std::string redis_ip;
|
||||
|
||||
int redis_port = 6379;
|
||||
|
||||
std::string redis_password = "5241590000000000";
|
||||
|
||||
int node_manager_port = 62665;
|
||||
|
||||
static std::shared_ptr<RayConfig> GetInstance();
|
||||
|
||||
|
||||
@@ -8,6 +8,10 @@
|
||||
#include "ray/common/task/task_common.h"
|
||||
#include "ray/common/task/task_spec.h"
|
||||
#include "ray/common/task/task_util.h"
|
||||
#include "ray/common/test_util.h"
|
||||
#include "ray/core_worker/common.h"
|
||||
#include "ray/core_worker/context.h"
|
||||
#include "ray/core_worker/core_worker.h"
|
||||
#include "ray/core_worker/store_provider/memory_store/memory_store.h"
|
||||
#include "ray/gcs/gcs_client.h"
|
||||
#include "ray/util/logging.h"
|
||||
|
||||
Reference in New Issue
Block a user