diff --git a/examples/hello/datamanWriter/helloDataManWriter.cpp b/examples/hello/datamanWriter/helloDataManWriter.cpp index 45610d3a136786f910540ac06934de6b620c9d3f..dcdf4bff7f289f2d4f716e073a7d2221e3059af1 100644 --- a/examples/hello/datamanWriter/helloDataManWriter.cpp +++ b/examples/hello/datamanWriter/helloDataManWriter.cpp @@ -32,7 +32,7 @@ int main(int argc, char *argv[]) adios::IO &dataManIO = adios.DeclareIO("WANIO"); dataManIO.SetEngine("DataManWriter"); dataManIO.SetParameters("peer-to-peer=yes", "real_time=yes", - "compress=no", "method=cache"); + "compress=no", "method=dump"); // Define variable and local size auto bpFloats = diff --git a/source/dataman/DataMan.cpp b/source/dataman/DataMan.cpp index d3ba9a83fc147368a1cf0409a54cb2a9970b37d0..2c9ab9d27ac0b0330a3e9b48476ec963670f6526 100644 --- a/source/dataman/DataMan.cpp +++ b/source/dataman/DataMan.cpp @@ -72,11 +72,23 @@ void DataMan::add_stream(json a_jmsg) a_jmsg["num_channels"] = num_channels; } + int local_port = 12306, remote_port = 12307; + + if (a_jmsg["local_port"].is_number()) + { + local_port = a_jmsg["local_port"].get<int>(); + } + + if (a_jmsg["remote_port"].is_number()) + { + local_port = a_jmsg["remote_port"].get<int>(); + } + for (int i = 0; i < num_channels; i++) { a_jmsg["channel_id"] = i; - a_jmsg["local_port"] = a_jmsg["local_port"].get<int>() + 2; - a_jmsg["remote_port"] = a_jmsg["remote_port"].get<int>() + 2; + a_jmsg["local_port"] = local_port + 2; + a_jmsg["remote_port"] = remote_port + 2; auto man = get_man(method); if (man) { diff --git a/source/dataman/MdtmMan.cpp b/source/dataman/MdtmMan.cpp index 2f41d40c669d4f07439a31f437d4a112e4132517..6bfa3af8c5d860f8db16cfe8f9b380aca392bc42 100644 --- a/source/dataman/MdtmMan.cpp +++ b/source/dataman/MdtmMan.cpp @@ -19,6 +19,7 @@ int MdtmMan::init(json a_jmsg) { + std::cout << " 1 MdtmMan::init " << m_channel_id << std::endl; StreamMan::init(a_jmsg); if (a_jmsg["pipe_prefix"].is_string()) @@ -68,16 +69,22 @@ int MdtmMan::init(json a_jmsg) // Make pipes mkdir(m_pipepath.c_str(), 0755); + + std::cout << "making " << m_full_pipename << std::endl; mkfifo(m_full_pipename.c_str(), 0666); + std::cout << "made " << m_full_pipename << std::endl; if (m_stream_mode == "sender") { + std::cout << "opening " << m_full_pipename << std::endl; m_pipe_handler = open(m_full_pipename.c_str(), O_WRONLY); + std::cout << "opened " << m_full_pipename << std::endl; } if (m_stream_mode == "receiver") { m_pipe_handler = open(m_full_pipename.c_str(), O_RDONLY | O_NONBLOCK); } + return 0; }