Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
thallium
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
2
Issues
2
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
sds
thallium
Commits
17734667
Commit
17734667
authored
Aug 09, 2018
by
Matthieu Dorier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added enable_remote_shutdown and shutdown_remote_engine
parent
92825352
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
0 deletions
+22
-0
include/thallium/engine.hpp
include/thallium/engine.hpp
+12
-0
src/engine.cpp
src/engine.cpp
+10
-0
No files found.
include/thallium/engine.hpp
View file @
17734667
...
...
@@ -333,6 +333,18 @@ public:
m_finalize_callbacks
.
emplace
(
std
::
forward
<
F
>
(
f
));
}
/**
* @brief Shuts down a remote thallium engine. The remote engine
* should have enabled remote shutdown by calling enable_remote_shutdown().
*
* @param ep endpoint of the remote engine.
*/
void
shutdown_remote_engine
(
const
endpoint
&
ep
)
const
;
/**
* @brief Enables this engine to be shutdown remotely.
*/
void
enable_remote_shutdown
();
};
}
// namespace thallium
...
...
src/engine.cpp
View file @
17734667
...
...
@@ -54,5 +54,15 @@ bulk engine::expose(const std::vector<std::pair<void*,size_t>>& segments, bulk_m
return
bulk
(
*
this
,
handle
,
true
);
}
void
engine
::
shutdown_remote_engine
(
const
endpoint
&
ep
)
const
{
int
ret
=
margo_shutdown_remote_instance
(
m_mid
,
ep
.
m_addr
);
hg_return_t
r
=
ret
==
0
?
HG_SUCCESS
:
HG_OTHER_ERROR
;
MARGO_ASSERT
(
r
,
margo_shutdown_remote_instance
);
}
void
engine
::
enable_remote_shutdown
()
{
margo_enable_remote_shutdown
(
m_mid
);
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment