Blame view

doc/uml/activities/scheduler/Scheduling.txt 2.43 KB
2a8d74fa   Quentin Durand   A general oveview...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
@startuml

'skinparam backgroundColor #AAFFFF

skinparam activity {
  'StartColor red
  'BarColor SaddleBrown
  'EndColor Silver
  'BackgroundColor Peru
  BackgroundColor<<MODULE>> Orange
  'BorderColor Peru
  'FontName Impact
}

0092f443   Etienne Pallier   update diagram
15
title **Current (2017) scheduling activity diagram (general overview)**
2a8d74fa   Quentin Durand   A general oveview...
16

0092f443   Etienne Pallier   update diagram
17
18
(*) --> "schedule = (Schedule Creation)"
	--> "Set night limits (schedule.plan_start and schedule.plan_end)"
2a8d74fa   Quentin Durand   A general oveview...
19
20
    --> if "First Schedule ?" then
        -->[yes] "schedule.plan_night_start = schedule.plan_start"
0092f443   Etienne Pallier   update diagram
21
        --> "Setting of <b>sequences</b> :  a list of all the observable sequences (from database)" as A2
2a8d74fa   Quentin Durand   A general oveview...
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
    else
        -->[no] "<b>Recovery of previous schedule's data:</b>
         EXECUTED sequences, plan_night_start, plan_end
                copy_from_previous_schedule()\l" <<MODULE>>
    endif
    --> A2
    --> "//Add to each sequence its schedule id://
    sequences = [(sequence, shs) for sequence in sequences]"

    --> "Creation of the interval [plan_start ; plan_end] \land insertion in the intervals list"

    --> "<b>Remove invalid sequences</b>
    bad parameters : jd1 < 0 for example
    removeInvalidSequences()"<<MODULE>>

0092f443   Etienne Pallier   update diagram
37
    --> "// TODO: <b>Determine priorities according to user and SP</b>"<<MODULE>>
2a8d74fa   Quentin Durand   A general oveview...
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70

    -->"<b>Remove non eligible sequences</b>
    //remove UNPLANNABLE sequences : overlap [jd1; jd2], [plan_start; plan_end] < duration for example//
    removeNonEligibleSequences()" <<MODULE>>

    --> "<b>Sort Sequences</b>
    //Sort sequences by priority and soonest jd2//
    sortSequences()"<<MODULE>>

    --> "<b>Check Quota</b>
    //Check if the user's quota is sufficient//"
    -->if "Is Quota Sufficient ?" then
        -->[no] "<b>Reject Sequence</b>"

    else
        -->[yes]"<b>Get matching intervals</b>
        //Get the matching intervals for the sequence//"
    endif
    -->if "Intervals Found ?" then
     -->[yes] "<b>Place sequence</b>
       placeSequence(sequence, shs, matching)" <<MODULE>>
       --> ==P==
    else
     -->[no] "<b>Try Shifting Sequences</b>
     //Trying to shift the left or/and right sequences//
     //in order to fit the current sequence//" <<MODULE>>

    endif
    --> ==P==

    --> if "Sequence PLACED ?" then
        -->[yes] "Decrease quota()" <<MODULE>>
        -->"<b>Save Schedule</b>
0092f443   Etienne Pallier   update diagram
71
         //set the sequence status to PLANNED//
2a8d74fa   Quentin Durand   A general oveview...
72
73
74
75
76
77
78
79
          //and save the new schedule//
          saveSchedule()"<<MODULE>>
     else
        -->[no] "<b>Reject Sequence</b>"
    endif


@enduml