ray/photon_client.h
Philipp Moritz ff8018db75 First pass at local scheduler (#2)
* draft of local scheduler

* API

* update APIs

* fix

* update

* Rename halo -> photon.

* Add build directory.

* Update common submodule.

* More renaming.

* Fix python ctypes.

* Compile in travis.

* Process generic messages and not just tasks.

* Move free outside of switch.

* Formatting and address comments.

* Remove event loop from local scheduler state.

* Use accept_client from common.

* Use bind_ipc_sock from common.

* Fix tests.

* Update common submodule.

* Fix formatting.
2016-09-27 19:11:09 -07:00

27 lines
731 B
C

#ifndef PHOTON_CLIENT_H
#define PHOTON_CLIENT_H
#include "common/task.h"
#include "photon.h"
typedef struct photon_conn_impl photon_conn;
/* Connect to the local scheduler. */
photon_conn *photon_connect(const char *photon_socket);
/* Submit a task to the local scheduler. */
void photon_submit(photon_conn *conn, task_spec *task);
/* Get next task for this client. */
task_spec *photon_get_task(photon_conn *conn);
/* Tell the local scheduler that the client has finished executing a task. */
void photon_task_done(photon_conn *conn);
/* Disconnect from the local scheduler. */
void photon_disconnect(photon_conn *conn);
/* Send a log message to the local scheduler. */
void photon_log_message(photon_conn *conn);
#endif