{"id":162,"date":"2015-06-19T14:47:51","date_gmt":"2015-06-19T14:47:51","guid":{"rendered":"http:\/\/carleton.ca\/nmai\/?page_id=162"},"modified":"2026-02-10T10:24:56","modified_gmt":"2026-02-10T15:24:56","slug":"climanager","status":"publish","type":"page","link":"https:\/\/carleton.ca\/nmai\/research-projects\/magenta-2\/climanager\/","title":{"rendered":"CLIManager"},"content":{"rendered":"\n<section class=\"w-screen px-6 cu-section cu-section--white ml-offset-center md:px-8 lg:px-14\">\n    <div class=\"space-y-6 cu-max-w-child-5xl  md:space-y-10 cu-prose-first-last\">\n\n            <div class=\"cu-textmedia flex flex-col lg:flex-row mx-auto gap-6 md:gap-10 my-6 md:my-12 first:mt-0 max-w-5xl\">\n        <div class=\"justify-start cu-textmedia-content cu-prose-first-last\" style=\"flex: 0 0 100%;\">\n            <header class=\"font-light prose-xl cu-pageheader md:prose-2xl cu-component-updated cu-prose-first-last\">\n                                    <h1 class=\"cu-prose-first-last font-semibold !mt-2 mb-4 md:mb-6 relative after:absolute after:h-px after:bottom-0 after:bg-cu-red after:left-px text-3xl md:text-4xl lg:text-5xl lg:leading-[3.5rem] pb-5 after:w-10 text-cu-black-700 not-prose\">\n                        CLIManager\n                    <\/h1>\n                \n                                \n                            <\/header>\n\n                    <\/div>\n\n            <\/div>\n\n    <\/div>\n<\/section>\n\n<p>The <strong>CLIManager<\/strong> is a simple console application that extends the Magenta&nbsp;Agent. It doesn&#8217;t add much except the ability to interactively send messages to itself and other Agents. This is useful for creating local and remote objects and setting their attributes. Since these objects can also be Agents, the CLIManager can be used as a launcher for other Agents.<\/p>\n\n\n\n<p>To start CLIManager type the following from the magenta-user directory. (if host:port is not specified it defaults to localhost:4444)<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>% java CLIManager [host:port]<\/li>\n<\/ul>\n\n\n\n<p>Once running you will see the prompt:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>hostname:port%<\/li>\n<\/ul>\n\n\n\n<p>Available CLIManager commands:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>quit\n<ul class=\"wp-block-list\">\n<li>exit the CLIManager application, all the contained objects (including other Magenta Agents that have been launched from the manager) will also be destroyed.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li>destination-agent message\n<ul class=\"wp-block-list\">\n<li>destination-agent is the the name of a\u00a0GdmoObject\u00a0stored by the CLIManager&#8217;s ObjectManager?. The object should be either an\u00a0AgentProxy\u00a0or a derived class (for example Agent, CLIManager, etc.)<\/li>\n\n\n\n<li>message is a CMIP-style action or query (see Protocol)<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n\n\n\n<p>The&nbsp;CLIManagerThread&nbsp;will send the message to the destination-agent and then display the reply.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Example commands\n<ul class=\"wp-block-list\">\n<li>localhost:4444% root print<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li>Prints the contents of the current Agent&#8217;s ObjectManager??\n<ul class=\"wp-block-list\">\n<li>localhost:4444% root create*magenta.AgentProxy*root*calcutta<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li>Create an\u00a0AgentProxy\u00a0called root\/calcutta\n<ul class=\"wp-block-list\">\n<li>localhost:4444% root set*root\/calcutta*HostInfo*www.calcutta.com:4444<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li>Set the host:port of the object root\/calcutta to www.calcutta.com:4444\n<ul class=\"wp-block-list\">\n<li>localhost:4444% root\/calcutta print<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li>Prints the contents of the Agent listening at www.calcutta.com:4444 (root\/calcutta&#8217;s\u00a0HostInfo)<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>The CLIManager is a simple console application that extends the Magenta&nbsp;Agent. It doesn&#8217;t add much except the ability to interactively send messages to itself and other Agents. This is useful for creating local and remote objects and setting their attributes. Since these objects can also be Agents, the CLIManager can be used as a launcher [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"parent":145,"menu_order":0,"comment_status":"open","ping_status":"closed","template":"","meta":{"_acf_changed":false,"_cu_dining_location_slug":"","footnotes":"","_links_to":"","_links_to_target":""},"cu_page_type":[],"class_list":["post-162","page","type-page","status-publish","hentry"],"acf":{"cu_post_thumbnail":false},"_links":{"self":[{"href":"https:\/\/carleton.ca\/nmai\/wp-json\/wp\/v2\/pages\/162","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/carleton.ca\/nmai\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/carleton.ca\/nmai\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/carleton.ca\/nmai\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/carleton.ca\/nmai\/wp-json\/wp\/v2\/comments?post=162"}],"version-history":[{"count":1,"href":"https:\/\/carleton.ca\/nmai\/wp-json\/wp\/v2\/pages\/162\/revisions"}],"predecessor-version":[{"id":163,"href":"https:\/\/carleton.ca\/nmai\/wp-json\/wp\/v2\/pages\/162\/revisions\/163"}],"up":[{"embeddable":true,"href":"https:\/\/carleton.ca\/nmai\/wp-json\/wp\/v2\/pages\/145"}],"wp:attachment":[{"href":"https:\/\/carleton.ca\/nmai\/wp-json\/wp\/v2\/media?parent=162"}],"wp:term":[{"taxonomy":"cu_page_type","embeddable":true,"href":"https:\/\/carleton.ca\/nmai\/wp-json\/wp\/v2\/cu_page_type?post=162"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}