HP Service Manager 活動HP Service Manager Activities

重要

此版本的 Orchestrator 已達終止支援,建議您 升級至 Orchestrator 2019This version of Orchestrator has reached the end of support, we recommend you to upgrade to Orchestrator 2019.

下列設定指示適用于此整合套件中的所有活動。The following configuration instructions apply to all activities in this integration pack.

活動屬性Activity Properties

每個活動都有一組必要或選擇性的屬性,可定義該活動的設定。Each activity has a set of required or optional properties that define the configuration of that activity. 這包括它連接到其他活動的方式,或活動執行其動作的方式。This includes how it connects to other activities or how the activity performs its actions. 您可以在 Runbook Designer 中查看或修改活動屬性。You can view or modify activity properties in the Runbook Designer.

設定活動的屬性To configure the properties for an activity

  1. 按兩下活動。Double-click the activity. 或者,您可以用滑鼠右鍵按一下活動,然後按一下 [ 屬性]。Alternatively, you can right-click the activity, and then click Properties.
  2. 若要儲存您的設定專案,請按一下 [完成]To save your configuration entries, click Finish.

在 [活動屬性] 對話方塊中,左側有幾個索引標籤可讓您存取活動的一般和特定設定。In the activity properties dialog box, several tabs along the left side provide access to general and specific settings for the activity. 物件屬性的可用索引標籤數目與活動之間的不同The number of available tabs for object properties differs from activity to activity

General TabGeneral Tab

此索引標籤包含活動的 [ 名稱 ] 和 [ 描述 ] 屬性。This tab contains the Name and Description properties for the activity. 根據預設,活動的 名稱 與其活動類型相同,而且 描述 是空白的。By default, the Name of the activity is the same as its activity type, and the Description is blank. 您可以修改這些屬性來建立更具描述性的名稱,或提供活動動作的詳細說明。You can modify these properties to create more descriptive names or provide detailed descriptions of the actions of the activity.

[內容] 索引標籤Properties Tab

此索引標籤包含活動特有的屬性。This tab contains properties that are specific to the activity. 此整合套件中的所有活動都具有 [屬性] 或 [篩選] 索引標籤頂端的 [設定名稱] 屬性。這個屬性是用來指定與 HP Service Manager server 的連接。All activities in this integration pack have the Configuration Name property at the top of the Properties or Filters tab. This property is used to specify the connection to the HP Service Manager server.

設定 Configuration Name 屬性To configure the Configuration Name property

  1. 按一下 [名稱] 欄位旁的省略號** ( ... ) **按鈕。Click the ellipsis (...) button next to the Name field.

  2. 選取適用的連接名稱。Select the applicable connection name. 清單中顯示的連線先前已依照設定 HP Service Manager連線中所述的方式進行設定。Connections displayed in the list have been previously configured as described in Configuring the HP Service Manager Connections.

篩選行為Filter Behavior

監視器和取得活動會使用篩選來判斷將叫用 runbook 或抓取活動的值。The Monitor and Get activities use filters to determine the values that will invoke a runbook or retrieve activities. 可能候選項目的屬性值會與篩選準則的值進行比較,以判斷它們是否符合準則。Property values of potential candidates are compared to the values of the filters to determine if they meet the criteria. 當比對值時,您可以選取其中一個可用的比較方法。When matching against values, you select one of the available methods of comparison. 您可以使用每個方法來比對或不符合篩選準則的選項。An option is provided to either match or not match the filter using each method. 例如,方法的「不」版本會尋找不符合篩選準則的訊息來觸發原則。For example, the "Does not" version of a method finds messages that do not match the filter to trigger the policy.

  • 等於:訊息的屬性完全符合篩選中指定的文字或數位。Equals: the property of the message exactly matches the text or number specified in the filter.
  • 等於:訊息的屬性不完全符合篩選中指定的文字或數位。Does not equal: the property of the message does not exactly match the text or number specified in the filter.
  • 小於:訊息的屬性小於篩選中指定的數位。Is less than: the property of the message is less than the number specified in the filter.
  • 小於或等於:訊息的屬性小於或等於篩選中指定的數位。Is less than or equal to: the property of the message is less than or equal to the number specified in the filter.
  • 大於:訊息的屬性大於篩選的數位 n。Is greater than: the property of the message is greater than the number n the filter.
  • 大於或等於:訊息的屬性大於或等於篩選中指定的數位。Is greater than or equal to: the property of the message is greater than or equal to the number specified in the filter.
  • Contains:訊息的屬性包含篩選中指定的確切文字。Contains: the property of the message contains the exact text specified in the filter. 與 Equals 行為不同的是,相符文字周圍可以有其他文字。Unlike the Equals behavior, there can be other text surrounding the matching text.
  • 包含:訊息的屬性不包含篩選中指定的確切文字。Does not contain: the property of the message does not contain the exact text specified in the filter. 與 Equals 行為不同的是,相符文字周圍可以有其他文字。Unlike the Equals behavior, there can be other text surrounding the matching text.
  • 符合模式:使用正則運算式來指定文字必須符合的模式。Matches pattern: use regular expressions to specify a pattern that the text must match.
  • 符合模式:使用正則運算式來指定文字必須不相符的模式。Does not match pattern: use regular expressions to specify a pattern that the text must not match.
  • 開頭為:訊息的屬性開頭為篩選中指定的確切文字。Starts with: the property of the message starts with the exact text specified in the filter.
  • 結尾為:訊息的屬性開頭為篩選中指定的確切文字。Ends with: the property of the message starts with the exact text specified in the filter.
  • 之後:訊息的屬性是在篩選中指定的日期/時間之後。After: the property of the message is after the date/time specified in the filter.
  • 之前:訊息的屬性是在篩選中指定的日期/時間之前。Before: the property of the message is before the date/time specified in the filter.

提示

篩選屬性只能在活動中使用一次。Filter properties can only be used once in an activity. 例如,如果專案的搜尋準則包含日期範圍,您就不能在相同的活動中使用 TimeAdded 濾波器屬性兩次。For example, if your search criteria for an entry include a date range, you cannot use the TimeAdded filter property twice in the same activity. 不過,您可以使用 [日期] 和 [ TimeRaised 之前TimeAdded日期] 篩選屬性來達成所需的結果。However, you may be able to use the TimeAdded After Date and TimeRaised Before Date filter properties to achieve the desired results.

注意

某些 HP Service Manager 字串欄位(例如 Description)不支援 Contains 和不 包含 關聯性。Some HP Service Manager string fields, such as Description, do not support the Contains and Does not contain relations. 不過,這些關聯性可能仍會顯示在欄位的可用選項清單中。However, these relations may still be displayed in the list of available options for the field.

[執行行為] 索引標籤Run Behavior Tab

此索引標籤包含的屬性可決定活動如何處理多重值已發佈資料,以及如果活動失敗或執行過多一段時間,會傳送哪些通知。This tab contains the properties that determine how the activity handles multi-value published data and what notifications will be sent if the activity fails or runs for an excessive period of time.

多重值已發佈資料行為Multi-Value Published Data Behavior

Get 活動會從另一個活動或外部來源取得資訊,而且可以傳回已發佈資料中的一個或多個值。Get activities retrieve information from another activity or outside source, and can return one or more values in the published data. 例如,當您使用 [取得集合成員] 活動時,該活動的資料輸出可能是屬於指定集合的電腦清單。For example, when you use the Get Collection Member activity, the data output from that activity might be a list of computers that belong to the specified collection.

根據預設,Get 活動中的資料將會以多個個別輸出的形式傳遞。By default, the data from the Get activity will be passed on as multiple individual outputs. 這會叫用下一個活動,就像輸出中的專案一樣多次。This invokes the next activity as many times as there are items in the output. 或者,您可以啟用壓 合併選項,以提供活動的單一輸出。Alternatively, you can provide a single output for the activity by enabling the Flatten option. 當您啟用此選項時,您也可以選擇格式化選項:When you enable this option, you also choose a formatting option:

  • 以分行符號分隔Separate with line breaks. 每個專案都在新的一行上。Each item is on a new line. 此格式適用于為輸出建立人們可讀取的文字檔。This format is useful for creating human-readable text files for the output.
  • **分隔方式 _ **.Separate with _ . 每個專案會以您選擇的一或多個字元分隔。Each item is separated by one or more characters of your choice.
  • 使用 CSV 格式Use CSV format. 所有專案都是 CSV (逗點分隔值) 格式。All items are in CSV (comma-separated value) format. 此格式適用于將資料匯入試算表或其他應用程式。This format is useful for importing data into spreadsheets or other applications.

活動會在每次執行時產生一組新的資料。The activity will produce a new set of data every time it runs. 合併功能不會將相同活動之多個實例的資料壓平合併。The Flatten feature does not flatten data across multiple instances of the same activity.

事件通知Event Notifications

某些活動預期需要花費一段時間才能完成。Some activities are expected to take a limited amount of time to complete. 如果它們未在這段時間內完成,則可能已停止,或可能有另一個問題導致無法完成。If they do not complete within that time they may be stalled or there may be another issue preventing them from completing. 您可以定義等候動作完成的秒數。You can define the number of seconds to wait for completion of the action. 在這段期間之後,系統會傳送平臺事件並回報問題。After this period a platform event will be sent and the issue will be reported. 您還可以選擇是否要在活動傳回失敗時產生平台事件。You can also choose whether to generate a platform event if the activity returns a failure.

當活動花費的時間超過指定的時間執行或無法執行時收到通知To be notified when the activity takes longer than a specified time to run or fails to run

  1. 在 [ 事件通知 ] 方塊中,輸入產生通知之前的執行時間 秒數In the Event Notifications box, enter the number of seconds of run time before a notification is generated.
  2. 如果活動無法執行,請選取 [報表] 以產生執行失敗通知。Select Report if activity fails to run to generate run failure notifications.

如需 Orchestrator 事件的詳細資訊,請參閱 活動事件For more information about Orchestrator events, see Activity Events.

已發佈資料Published Data

已發佈資料是工作中 runbook 的基礎。Published data is the foundation of a working runbook. 它是活動動作產生的資料。It is the data produced as a result of the actions of an activity. 這項資料會發佈至每個 runbook 唯一的內部資料匯流排。This data is published to an internal data bus that is unique for each runbook. Runbook 中的後續活動可以訂閱這項資料,並在其設定中使用。Subsequent activities in the runbook can subscribe to this data and use it in their configuration. 連結條件也會使用此資訊,將決策制定功能新增至 runbook。Link conditions also use this information to add decision-making capabilities to runbooks.

活動只能訂閱在 runbook 中之前連結之活動的資料。An activity can only subscribe to data from the activities that are linked before it in the runbook. 您可以使用已發佈資料來自動填入活動所需的屬性值。You can use published data to automatically populate the property values needed by activities.

使用已發佈資料To use published data

  1. 在 [屬性值] 方塊上按一下滑鼠右鍵,按一下 [ 訂閱],然後按一下 [ 已發佈資料]。Right-click the property value box, click Subscribe, and then click Published Data.
  2. 按一下 [ 活動 ] 下拉式清單方塊,然後選取您想要從中取得資料的活動。Click the Activity drop-down box and select the activity from which you want to obtain the data. 若要查看所有 runbook 通用的其他資料元素,請選取 [ 顯示一般已發佈資料]。To view additional data elements common to all runbooks, select Show Common Published Data.
  3. 按一下您要使用的已發佈資料元素,然後按一下 [確定]Click the published data element that you want to use, and then click OK.

如需每個活動所發行之資料元素的清單,請參閱活動主題中的已發行資料表格。For a list of the data elements published by each activity, see the Published Data tables in the activity topic. 如需一般已發佈資料項目的詳細資訊,請參閱 一般已發佈資料For information about the common published data items, see Common Published Data.

活動Activities

此整合套件會將 HP Service Manager 分類新增至 Runbook Designer 的 [ 活動 ] 窗格中。This integration pack adds the HP Service Manager category to the Activity pane in the Runbook Designer. 此類別包含下列活動:This category contains the following activities:

關閉項目Close Entry
建立項目Create Entry
取得項目Get Entry
監視項目Monitor Entry
更新項目Update Entry