{"id":2675,"date":"2015-10-27T15:50:43","date_gmt":"2015-10-27T15:50:43","guid":{"rendered":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/maintenance\/messaging-system\/"},"modified":"2021-08-26T12:46:34","modified_gmt":"2021-08-26T12:46:34","slug":"messaging-system","status":"publish","type":"page","link":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/","title":{"rendered":"Messaging system"},"content":{"rendered":"<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-4917\" src=\"https:\/\/twproject.com\/support\/wp-content\/uploads\/user-subs.png\" alt=\"\" width=\"1513\" height=\"753\" \/><\/p>\n<p>We have already described Twproject\u2019s event\/subscription capability. Here is describe shortly how this engine works.<\/p>\n<p>When a user subscribes listening an event, say \u201cToDo created\u201d, it is creating an object called \u201clistener\u201d.<\/p>\n<p>A listener refers a Twproject object using class and id, has the event it is listening for (called \u201ccommand\u201d), has a validity period, has a user as owner, may be listening for children object too, etc. .<\/p>\n<p>Usually there are lots of listeners (thousands after some months of real usage).<\/p>\n<p>When something relevant happens, an \u201cevent\u201d is generated and inserted in the event queue.<\/p>\n<p>A scheduled job (\u201cEventListenerMatcher\u201d) checks (by default every minute) for each event if there is a subscription listening for. If there is nothing listening, the event is removed.<\/p>\n<p>If there is a subscription a message is generated by integrating \u201clistener\u201d and \u201cevent\u201d data; the message is inserted in the message queue. Then the event is removed.<\/p>\n<p>Usually the event queue is empty or contains only a few records.<br \/>\nOnce the message is queued it is available for dispatching: \u201cEmailMessageDispatcher\u201d and \u201cStickyMessageDispatcher\u201d are two scheduled jobs that send messages to their respective media channels. Messages for the \u201cnews\u201d or &#8220;digest&#8221; channel rest in the message list until they are read by the user, then removed. So the message queue should contain elements for \u201cnews\u201d or &#8220;digest&#8221; channel only.<\/p>\n<p>Twproject provides list\/search and edit pages for subscriptions, events and messages. Usually you do not need to operate in pages that are intended for monitoring purposes only:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-5030 size-full\" src=\"https:\/\/twproject.com\/support\/wp-content\/uploads\/admin-subs.png\" alt=\"\" width=\"1599\" height=\"895\" \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>We have already described Twproject\u2019s event\/subscription capability. Here is describe shortly how this engine works. When a user subscribes listening an event, say \u201cToDo created\u201d, it is creating an object called \u201clistener\u201d. A listener refers a Twproject object using class and id, has the event it is listening for (called \u201ccommand\u201d), has a validity period, [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":2565,"menu_order":8,"comment_status":"closed","ping_status":"open","template":"","meta":{"footnotes":""},"class_list":["post-2675","page","type-page","status-publish","hentry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.4 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Messaging system | Twproject support<\/title>\n<meta name=\"description\" content=\"We have already described Twproject\u2019s event\/subscription capability. Here is describe shortly how this engine works. When a user subscribes listening an\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Messaging system | Twproject support\" \/>\n<meta property=\"og:description\" content=\"We have already described Twproject\u2019s event\/subscription capability. Here is describe shortly how this engine works. When a user subscribes listening an\" \/>\n<meta property=\"og:url\" content=\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/\" \/>\n<meta property=\"og:site_name\" content=\"Twproject support\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/twproject\" \/>\n<meta property=\"article:modified_time\" content=\"2021-08-26T12:46:34+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/twproject.com\/support\/wp-content\/uploads\/user-subs.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1513\" \/>\n\t<meta property=\"og:image:height\" content=\"753\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/\",\"url\":\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/\",\"name\":\"Messaging system | Twproject support\",\"isPartOf\":{\"@id\":\"https:\/\/twproject.com\/support\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/twproject.com\/support\/wp-content\/uploads\/user-subs.png\",\"datePublished\":\"2015-10-27T15:50:43+00:00\",\"dateModified\":\"2021-08-26T12:46:34+00:00\",\"description\":\"We have already described Twproject\u2019s event\/subscription capability. Here is describe shortly how this engine works. When a user subscribes listening an\",\"breadcrumb\":{\"@id\":\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/#primaryimage\",\"url\":\"https:\/\/twproject.com\/support\/wp-content\/uploads\/user-subs.png\",\"contentUrl\":\"https:\/\/twproject.com\/support\/wp-content\/uploads\/user-subs.png\",\"width\":1513,\"height\":753},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/twproject.com\/support\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Advanced usage\",\"item\":\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Monitoring\",\"item\":\"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Messaging system\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/twproject.com\/support\/#website\",\"url\":\"https:\/\/twproject.com\/support\/\",\"name\":\"Twproject support\",\"description\":\"Twproject documentation online\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/twproject.com\/support\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Messaging system | Twproject support","description":"We have already described Twproject\u2019s event\/subscription capability. Here is describe shortly how this engine works. When a user subscribes listening an","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/","og_locale":"en_US","og_type":"article","og_title":"Messaging system | Twproject support","og_description":"We have already described Twproject\u2019s event\/subscription capability. Here is describe shortly how this engine works. When a user subscribes listening an","og_url":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/","og_site_name":"Twproject support","article_publisher":"https:\/\/www.facebook.com\/twproject","article_modified_time":"2021-08-26T12:46:34+00:00","og_image":[{"width":1513,"height":753,"url":"https:\/\/twproject.com\/support\/wp-content\/uploads\/user-subs.png","type":"image\/png"}],"twitter_misc":{"Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/","url":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/","name":"Messaging system | Twproject support","isPartOf":{"@id":"https:\/\/twproject.com\/support\/#website"},"primaryImageOfPage":{"@id":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/#primaryimage"},"image":{"@id":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/#primaryimage"},"thumbnailUrl":"https:\/\/twproject.com\/support\/wp-content\/uploads\/user-subs.png","datePublished":"2015-10-27T15:50:43+00:00","dateModified":"2021-08-26T12:46:34+00:00","description":"We have already described Twproject\u2019s event\/subscription capability. Here is describe shortly how this engine works. When a user subscribes listening an","breadcrumb":{"@id":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/#primaryimage","url":"https:\/\/twproject.com\/support\/wp-content\/uploads\/user-subs.png","contentUrl":"https:\/\/twproject.com\/support\/wp-content\/uploads\/user-subs.png","width":1513,"height":753},{"@type":"BreadcrumbList","@id":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/messaging-system\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/twproject.com\/support\/"},{"@type":"ListItem","position":2,"name":"Advanced usage","item":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/"},{"@type":"ListItem","position":3,"name":"Monitoring","item":"https:\/\/twproject.com\/support\/twproject-advanced-usage\/monitoring\/"},{"@type":"ListItem","position":4,"name":"Messaging system"}]},{"@type":"WebSite","@id":"https:\/\/twproject.com\/support\/#website","url":"https:\/\/twproject.com\/support\/","name":"Twproject support","description":"Twproject documentation online","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/twproject.com\/support\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"}]}},"_links":{"self":[{"href":"https:\/\/twproject.com\/support\/wp-json\/wp\/v2\/pages\/2675","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/twproject.com\/support\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/twproject.com\/support\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/twproject.com\/support\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/twproject.com\/support\/wp-json\/wp\/v2\/comments?post=2675"}],"version-history":[{"count":0,"href":"https:\/\/twproject.com\/support\/wp-json\/wp\/v2\/pages\/2675\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/twproject.com\/support\/wp-json\/wp\/v2\/pages\/2565"}],"wp:attachment":[{"href":"https:\/\/twproject.com\/support\/wp-json\/wp\/v2\/media?parent=2675"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}