網路冷眼@BlogJava

          熙熙攘攘一閑人 以冷靜的眼光觀察技術
          posts - 88, comments - 193, trackbacks - 0, articles - 28
            BlogJava :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理

          日歷

          <2011年1月>
          2627282930311
          2345678
          9101112131415
          16171819202122
          23242526272829
          303112345

          公告

          版權許可

          Creative Commons LicenseThis work is licensed under a Creative Commons License.

          訂閱

          Feed
          讓您不再錯過每一篇文章!
          用google訂閱此博客
        1. 通過bloglines訂閱
        2. 使用topim訂閱
        3. 添加到myyahoo

        4. hits

          文章分類(9)

          Friends

          Virtualization

          搜索

          •  

          積分與排名

          • 積分 - 314041
          • 排名 - 182

          最新評論

          1.4.2 Detailed process modeling (詳細的流程建模)

          Although a book ordering process may seem simple at first hand, when looking at it in more detail a lot of process logic is needed. In this section we’ll focus on detailing the process payment task by adding validation and error handling logic. This also means we’ll need BPMN 2.0 constructs that are part of the descriptive or level 2 palette. In figure 1.8 the subprocess process payment is shown, which is a more detailed model of the process payment task of figure 1.7.

          盡管訂書流程也許直接看起來很簡單,但是當深入觀察時,發現需要添加更多的流程邏輯。本節通過增加驗證和錯誤處理邏輯,我們將關注詳細的支付任務流程。這也意味著我們將需要描述性部分或者水平2調色板的BPMN 2.0構件。在圖1.8顯示了支付流程的子流程。它是圖1.7中描述的支付流程的詳細模型。

          clip_image002

           

          Figure 1.8 The extracted process payment subprocess from the book order process model. The subprocess shows the use of error end and start events and the use of terminate end event.

          圖 1.8 從訂書流程模型摘取的支付子流程。子流程顯示了錯誤和開始事件的使用和終止結束事件的使用。

           

          As you can see we use a number of additional BPMN 2.0 constructs in the process model of figure 1.8. So let’s first look at these extra element definitions in table 1.2.

          正如你所見,我們使用了圖1.8流程模型的額外的BPMN 2.0構件。所以讓我們來看看表1.2中那些另外的元素定義。

           

          Table 1.2 Overview of the additional BPMN 2.0 constructs used in figure 1.8.

          表1.2 圖1.8中使用的額外的BPMN 2.0構件的描述

          BPMN 2.0 icon

          BPMN 2.0 name

          Description
          clip_image002[5]

          Message start event

          消息開始事件

            A message start event is a more specific type of start event. The meaning is that the process is

          triggered by an external signal, in this case a customer book order request.

          消息開始事件是開始事件的特例。它的意義是流程由外部信號所觸發,本例是客戶訂書請求。

          clip_image004

          Error end event

          錯誤結束事件

          An error end event is a specific kind of end event, which can be used to throw an error inside the process model definition.

          錯誤結束事件是結束事件的特例。它能在流程模型里處理錯誤。

          clip_image006

          Error start event

          錯誤開始事件

          An error start event can be used to catch a specific error thrown by an error end event.

          錯誤開始事件可用來捕獲由錯誤事件拋出的錯誤。

          clip_image008 

          Error boundary event

          錯誤邊界事件

          An error boundary event can be used to indicate a fault on a task or a subprocess.

          錯誤邊界事件用來指示任務或子流程的故障。

          clip_image010

          Terminate end event

          終止結束事件

          A terminate end event is a special kind of end event that causes the process to be terminated. If a terminate end event is used in a subprocess it only causes the subprocess to be terminated, not the parent process.

          終止結束事件是一種特殊的,導致流程終止的結束事件。如果在子流程中使用終止結束事件。它只導致子流程終止,而不是父流程。

          clip_image002[11]

          Service task

          服務任務

          A service task is a specific type of task, which represents an automated activity. A service task can be a web service call or for example a Java class invocation.

          服務任務是一種特殊的任務類型,代表自動活動。服務任務既可以Web服務調用,也可以是Java類調用。

          clip_image002[9]

          User task

          用戶任務

          A user task is a specific type of task, which represents a manual activity. A user task can be claimed and completed by a configured individual or group of users.

          用戶任務也是一種特殊的任務類型,人工活動。通過配置建好的個人或組用戶,對任務進行領取和完成。

          clip_image002[7]

          Subprocess

          子流程

          A subprocess is a compound activity, which can contain multiple other activities including tasks, gateways and events. A subprocess can be embedded in the parent process or be a standalone process model that can be invoked by the parent process via a call activity.

          子流程是一種復合活動,它包括多個其它活動:任務,網關和事件。子流程可以嵌入到父流程中,或者是獨立的流程模型。獨立的流程模型能夠通過調用活動(call activity)由父流程調用。

           

          In figure 1.8 we made the tasks more specific by adding a type identifier. For example the check credit card task is modeled as a service task, because the validity of the credit card can be checked by invoking a web service. We also added a user task to indicate that the task has to be performed by a human. The contact customer activity is a user task, because an employee of the book store has to get in contact with the customer to solve the bad credit card problem.

          在圖 1.8中,通過增加類型標識符,我們讓任務更加特殊。例如,將信用卡檢查任務建模為服務任務。因為信用卡的有效性檢查可以通過調用Web Service來執行。我們也增加一個用戶任務指示它必須由人來執行。聯系客戶活動是一個用戶任務,因為書店員工不得不聯系客戶來解決信用卡問題。

          In the process payment subprocess shown in figure 1.8, we see a couple of other new BPMN 2.0 constructs. First note that a subprocess always starts with a start event. First the credit card information is validated by invoking an automated task. Then we check the outcome of this credit card validation with an exclusive gateway. In case the credit card validation was successful the payment is finished and the subprocess is ended.

          在圖1.8所示的支付流程中,我們看見一對其它的新的BPMN 2.0構件。首先注意子流程總是從開始事件開始。通過調用自動任務,首先驗證信用卡信息,然后采用排他網關檢查信用卡驗證的結果。一旦信用卡驗證成功,支付完成,那么子流程結束。

          When the credit card validation didn’t succeed an error end event throws an exception. This exception is caught within the subprocess by the error start event handling the bad credit card exception. In this case the customer is contacted personally by an employee of the book store to see if the credit card information was not received in a good manner or that the customer can pay in another way. If the payment can be settled with the customer a normal end event in the exception handler is reached and the subprocess is completed by executing the finish payment service task.

          當信用卡驗證不成功,一個錯誤結束事件拋出一個異常。通過錯誤開始事件處理失敗的信用卡異常,在子流程捕獲異常。在這種情況下,書店的員工查看是否收到信用卡信息,或者客戶以其它方式支付。如果是由客戶來處理,將到達一個異常處理的正常結束事件。通過執行完成的支付服務任務,完成子流程。


          評論

          # re: Activiti in Action(實戰Activiti)-第一章 BPMN 2.0: what&rsquo;s in it for developers?(6)  回復  更多評論   

          2011-01-03 19:23 by 網路冷眼@BlogJava
          @ugg boots stores
          Thanks!These images can be placed in cells of table. u can do it.
          主站蜘蛛池模板: 莎车县| 佛坪县| 清流县| 湖口县| 绥德县| 娄烦县| 师宗县| 含山县| 交口县| 柯坪县| 凌源市| 米易县| 台中市| 射阳县| 濮阳县| 博乐市| 大安市| 盱眙县| 内黄县| 涟源市| 花垣县| 郴州市| 漳平市| 湖州市| 瓦房店市| 门源| 德钦县| 五指山市| 栾川县| 乃东县| 罗江县| 泉州市| 乌什县| 平原县| 木兰县| 达日县| 卢氏县| 秦安县| 积石山| 固镇县| 会宁县|