{"id":5923,"date":"2017-12-12T23:52:52","date_gmt":"2017-12-12T23:52:52","guid":{"rendered":"https:\/\/alt2.minisoft.com\/support\/?p=5923"},"modified":"2020-07-01T16:23:48","modified_gmt":"2020-07-01T23:23:48","slug":"web-service-post-call-to-wake-up-a-sleeping-queue-part-2","status":"publish","type":"post","link":"https:\/\/c002.minisoft.com\/support\/web-service-post-call-to-wake-up-a-sleeping-queue-part-2\/","title":{"rendered":"Web Service POST call to \u201cWake Up\u201d a \u201cSleeping\u201d Queue: Part 2"},"content":{"rendered":"<p><strong>Web Service Call Options:<\/strong><\/p>\n<p>In the <a href=\"\/support\/index.php\/web-service-post-call-to-wake-up-a-sleeping-queue-part-1\/\">previous post<\/a>, the Director was configured and an explanation for what a sleeping queue is was given. In this post, the options that a web service call has will be explored. Version 10 of eFORMz has the ability to <a href=\"\/support\/index.php\/eformz-api\/\">call a web service to post data to a queue<\/a>. To process a web service call, eFORMz will need a URL. A sample URL could be:<\/p>\n<pre>https:\/\/localhost:8000\/servlet\/com.minisoft.AppServer.AppServer?APP=com.minisoft.eformz.eFORMzApp&amp;director&amp;Host=localhost&amp;Port=9996&amp;User=minisoft&amp;Password=password&amp;ConfigurationName=accessible.cfg&amp;QueueName=Accessible&amp;NameTemplate=data_.dat<\/pre>\n<p>Below are all the options available for a web request call URL.<\/p>\n<table>\n<tbody>\n<tr>\n<td width=\"204\">base URL<\/td>\n<td width=\"461\"><a href=\"https:\/\/localhost:8000\/servlet\/com.minisoft.AppServer.AppServer\">https:\/\/localhost:8000\/servlet\/com.minisoft.AppServer.AppServer<\/a><\/td>\n<\/tr>\n<tr>\n<td width=\"204\">Parameter to AppServer<\/td>\n<td width=\"461\">?APP=com.minisoft.eformz.eFORMzApp<\/td>\n<\/tr>\n<tr>\n<td width=\"204\">Decide how to process<\/td>\n<td width=\"461\">\n<table>\n<tbody>\n<tr>\n<td width=\"96\">Service Type<\/td>\n<td width=\"203\">&amp;director<\/td>\n<\/tr>\n<tr>\n<td width=\"96\">Service Type<\/td>\n<td width=\"203\">&amp;output<\/td>\n<\/tr>\n<tr>\n<td width=\"94\"><\/td>\n<td width=\"211\">&amp;config=configuration file\u00a0 name<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/td>\n<\/tr>\n<tr>\n<td width=\"205\">Parameters for DirectorService<\/td>\n<td width=\"472\">\n<table>\n<tbody>\n<tr>\n<td width=\"232\">Service Type<\/td>\n<td width=\"224\">&amp;director<\/td>\n<\/tr>\n<tr>\n<td width=\"232\">which host<\/td>\n<td width=\"224\">&amp;Host=localhost<br \/>\n&amp;Port=9996<\/td>\n<\/tr>\n<tr>\n<td width=\"232\">Authentication for director<\/td>\n<td width=\"224\">&amp;User=minisoft<br \/>\n&amp;Password=password<\/td>\n<\/tr>\n<tr>\n<td width=\"234\">Toolkit file *<br \/>\nMust be started with -ac parameter<\/td>\n<td width=\"229\">&amp;ConfigurationName=accessible.cfg<\/td>\n<\/tr>\n<tr>\n<td width=\"232\">Queue name in toolkit file<\/td>\n<td width=\"224\">&amp;QueueName=Accessible<\/td>\n<\/tr>\n<tr>\n<td width=\"232\">File name for POSTed data<\/td>\n<td width=\"224\">&amp;NameTemplate=data_.xml<\/td>\n<\/tr>\n<tr>\n<td width=\"232\">Wake a sleeping queue<\/td>\n<td width=\"224\">&amp;ProcessData=true<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/td>\n<\/tr>\n<tr>\n<td width=\"204\">Parameters for OutputService<\/td>\n<td width=\"461\">\n<table>\n<tbody>\n<tr>\n<td width=\"126\">Service Type<\/td>\n<td width=\"82\">&amp;output<\/td>\n<\/tr>\n<tr>\n<td width=\"126\">Project Name<\/td>\n<td width=\"82\">&amp;project<\/td>\n<\/tr>\n<tr>\n<td width=\"126\">Project Key<\/td>\n<td width=\"88\">&amp;projectkey<\/td>\n<\/tr>\n<tr>\n<td width=\"126\">Output Format<\/td>\n<td width=\"82\">&amp;format<\/td>\n<\/tr>\n<tr>\n<td width=\"126\">Pages<\/td>\n<td width=\"82\">&amp;pages<\/td>\n<\/tr>\n<tr>\n<td width=\"126\">Start Page<\/td>\n<td width=\"84\">&amp;startpage<\/td>\n<\/tr>\n<tr>\n<td width=\"126\">End Page<\/td>\n<td width=\"82\">&amp;endpage<\/td>\n<\/tr>\n<tr>\n<td width=\"128\">Other parameters<\/td>\n<td width=\"80\">*<\/td>\n<\/tr>\n<tr>\n<td width=\"126\">Data File Name<\/td>\n<td width=\"82\">&amp;datafile<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/td>\n<\/tr>\n<tr>\n<td width=\"204\">Service Type can be<\/td>\n<td width=\"461\">\n<table>\n<tbody>\n<tr>\n<td width=\"70\">Director<\/td>\n<td width=\"61\">director<\/td>\n<\/tr>\n<tr>\n<td width=\"68\">Output<\/td>\n<td width=\"58\">output<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/td>\n<\/tr>\n<tr>\n<td width=\"204\">Parameters<\/td>\n<td width=\"461\">\n<table>\n<tbody>\n<tr>\n<td width=\"146\">&amp;project<\/td>\n<td width=\"124\">m_ProjectName<\/td>\n<td width=\"121\">String<\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;projectkey<\/td>\n<td width=\"124\">m_ProjectKey<\/td>\n<td width=\"121\">String<\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;format<\/td>\n<td width=\"126\">m_OutputFormat<\/td>\n<td width=\"119\">String<\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;datafile<\/td>\n<td width=\"126\">m_DataFileName<\/td>\n<td width=\"119\">String<\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;pages<\/td>\n<td width=\"124\">m_OutputPages<\/td>\n<td width=\"134\">PageRangeSelection<\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;startpage<\/td>\n<td width=\"124\">m_StartPage<\/td>\n<td width=\"121\">Int (1)<\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;endpage<\/td>\n<td width=\"124\">m_EndPage<\/td>\n<td width=\"124\">Int (999999)<\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;Host<\/td>\n<td width=\"124\"><\/td>\n<td width=\"121\"><\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;Port<\/td>\n<td width=\"124\"><\/td>\n<td width=\"121\"><\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;User<\/td>\n<td width=\"124\"><\/td>\n<td width=\"121\"><\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;Password<\/td>\n<td width=\"124\"><\/td>\n<td width=\"121\"><\/td>\n<\/tr>\n<tr>\n<td width=\"148\">&amp;ConfigurationName<\/td>\n<td width=\"124\"><\/td>\n<td width=\"119\"><\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;QueueName<\/td>\n<td width=\"124\"><\/td>\n<td width=\"121\"><\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;NameTemplate<\/td>\n<td width=\"124\"><\/td>\n<td width=\"121\"><\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;ProcessData<\/td>\n<td width=\"124\"><\/td>\n<td width=\"121\">Boolean<\/td>\n<\/tr>\n<tr>\n<td width=\"146\">&amp;Sync<\/td>\n<td width=\"124\"><\/td>\n<td width=\"121\">Boolean<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/td>\n<\/tr>\n<tr>\n<td width=\"204\">PageRangeSelection can be<\/td>\n<td width=\"461\">all( &#8220;All pages&#8221; ),<br \/>\ncurrent( &#8220;Current pages&#8221; ),<br \/>\nrangeFromStart( &#8220;Page Range (from start)&#8221; ),<br \/>\nrangeFromEnd(&#8220;Page Range (from end)&#8221; ),<br \/>\nobsolete0( &#8220;Page Range (from end )&#8221; )<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>There are many options that the URL can have. Here are some of the following:<\/p>\n<p>If <code>&amp;ProcessData=true<\/code> is added, the web service will wake up the queue monitor (if it is sleeping)\u00a0to process anything in the queue immediately. Any data sent as content will be put in a file in the named queue. The Director has to be running the named configuration and it has to be accessible to web services.<\/p>\n<p>Any content type can be used except <code>text\/plain<\/code>. Specifying the content type isn&#8217;t necessary. If you use <code>text\/plain<\/code> it tries to parse it for parameters and if you use <code>text\/xml<\/code> it tries to parse it for a Service Configuration xml file.<\/p>\n<p>NOTE: A posted file <code>text\/xml<\/code> that is not a <code>ServiceConfiguration<\/code> will be handled as a posted data file. A posted file <code>text\/xml<\/code> that is a <code>ServiceConfiguration<\/code> will skip the URL parameters.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Web Service Call Options: In the previous post, the Director was configured and an explanation for what a sleeping queue is was given. In this post, the options that a web service call has will be explored. Version 10 of eFORMz has the ability to call a web service to post data to a queue. [&hellip;]<\/p>\n","protected":false},"author":15,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[349,346,325,341,348,347],"_links":{"self":[{"href":"https:\/\/c002.minisoft.com\/support\/wp-json\/wp\/v2\/posts\/5923"}],"collection":[{"href":"https:\/\/c002.minisoft.com\/support\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/c002.minisoft.com\/support\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/c002.minisoft.com\/support\/wp-json\/wp\/v2\/users\/15"}],"replies":[{"embeddable":true,"href":"https:\/\/c002.minisoft.com\/support\/wp-json\/wp\/v2\/comments?post=5923"}],"version-history":[{"count":4,"href":"https:\/\/c002.minisoft.com\/support\/wp-json\/wp\/v2\/posts\/5923\/revisions"}],"predecessor-version":[{"id":8179,"href":"https:\/\/c002.minisoft.com\/support\/wp-json\/wp\/v2\/posts\/5923\/revisions\/8179"}],"wp:attachment":[{"href":"https:\/\/c002.minisoft.com\/support\/wp-json\/wp\/v2\/media?parent=5923"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/c002.minisoft.com\/support\/wp-json\/wp\/v2\/categories?post=5923"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/c002.minisoft.com\/support\/wp-json\/wp\/v2\/tags?post=5923"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}