CORBA for transportation control and command systems tutorial
CORBA ATC use case, Note to offline reader.




                                                                          ...
The open issue :



                                                           $   #
                                     ...
CORBA use case
                     Can we use CORBA in Large Distributed Control
                     System ?
          ...
Why CORBA ?

                      )quot;          quot;           #    (quot;           quot;               !
           ...
Practical Use Case


               0              #       #             !
                   +              +            ...
Complex system : ATC center

                                                     AFTN/CIDIN
                             ...
Object At system level ?

                    -                       quot;   !       )quot;       quot;    #
            ...
CORBA use case
                     Can we use CORBA in Large Distributed Control
                     System ?
          ...
What Do We Want

                          &+                +       #
                               quot;
              ...
What Do We Want !

                    quot;         #




                +                                              ...
What DO We Want !

                    quot;         #



                                                quot;   #

     ...
What DO We Want !




                                            quot;   #

                                             ...
We want to Increase Integrated software quality
31/03/03




                Thales Air Traffic Management
           14
CORBA use case
                      Can we use CORBA in Large Distributed Control
                      System ?
        ...
What We expect ?

                0        !

                                                quot;   #

                 ...
What We expect ?

                8




                                        +       #
31/03/03




                Tha...
What We May Have :
                                                         +   (quot;




                               ...
Spaghetti Plate Syndrome

                                 8

                      quot;
31/03/03




                Tha...
Spaghetti Plate Syndrome


                                                            +        quot;   quot;




        ...
Spaghetti Plate Syndrome


                                                          +          #




                    ...
CORBA use case
                      Can we use CORBA in Large Distributed Control
                      System ?
        ...
Why CORBA

                0                                   !
                                  (        (        !    ...
Software Component Integration Bus




                                                Software BUS
31/03/03




         ...
Object Software Component Integration Bus




                    #       $    #    #         !
                          ...
CORBA use case
                      Can we use CORBA in Large Distributed Control
                      System ?
        ...
Polymorphism



                         1    <                     '
                             )quot;                 ...
Object Software Component Integration Bus




                                           Object Software BUS
31/03/03




...
Object Software Component Integration Bus
                                                                 8!




        ...
Procedural versus Object



                      Procedural Design                Object Design




                     ...
CORBA use case
                      Can we use CORBA in Large Distributed Control
                      System ?
        ...
Design for changes

                0         quot;     >       (           ?quot;   #       @
                0          ...
Changes Sources* During Development

                      -
                                               quot;(       0...
Object Oriented Design

                   #                                #       !quot;                quot;#&         ...
Without OOD


                         Without OOD




                   Design for no Changes

                      Sta...
Change management before OOD

                          #(                            quot;
                (
            ...
Change management before OOD

                0                         !             quot;       quot;             quot;
...
Change management before OOD

                                                !                 '!           quot;        ...
Change management and code reuse before OO


                                                !       '!           quot;   ...
System Integration is a specific change case

                +                      #                          quot;     ...
Integration case

                 +                      #                            quot;           quot;   #quot;
    ...
Pervasive Change




                                       Replaced Module (Changed)
31/03/03




                Thales ...
Pervasive Change
31/03/03




                Thales Air Traffic Management
           43
Pervasive Change
31/03/03




                Thales Air Traffic Management
           44
Pervasive Change

                Several Changes Replace and Reused
31/03/03




                  Thales Air Traffic Man...
Pervasive Change = Spaghetti Plate

           After Several Changes Replace and Reused




                              ...
Procedural versus Object


                         Without OOD                     With OOD




                   Design...
Change management with OO reuse

                0                            %            !        quot;          quot;
 ...
Change management with OO reuse

                0                            %            !        quot;          quot;
 ...
With OOD : Software Bus
31/03/03




                Thales Air Traffic Management
           50
CORBA use case
                      Can we use CORBA in Large Distributed Control
                      System ?
        ...
Changes example : the printer


                             Client                           Printing Server




        ...
Changes example : the printer

                3                    quot;quot;   &                        #       quot;   ...
Changes example : the printer


                          Client                           Printing Server
31/03/03




  ...
Changes example : the printer


                       Old Client                          Printing Server




           ...
Change management with OOD reuse

                              #         #!                 quot;%     !




            ...
Change management with OOD reuse

                3         !              quot;          #       ( ( ?- quot;%      @    ...
Change management and code reuse before OOD


                                                 quot;            quot;    #...
Change management with OOD reuse

                              #      ?     )quot;@          quot;           !   quot;
  ...
Object properties


                ?     )quot;@                           !#

                      2quot;
             ...
CORBA = Distributed Polymorphism


                          )quot;                      #         #       quot;
         ...
CORBA use case
                      Can we use CORBA in Large Distributed Control
                      System ?
        ...
CORBA Distributed Polymorphism examples


                2&
                                    !               +8       ...
Example UML Diagram



                                                     Print
                                        ...
Example Interface Inheritance (IDL)

                                                           Printer


                ...
printer




                   &OLHQW                         Printer
                                                prin...
printer




                   &OLHQW                         Printer
                                                prin...
CORBA Distributed Polymorphism example 1


                                   8        #
                                 ...
CORBA = Distributed Polymorphism

                           ?           #        (quot; @
                          quot;...
Objet Reference and Naming

                                Client                       Naming                     Server...
CORBA = Distributed Polymorphism

                             %


                       !                        (      ...
CORBA = Distributed Polymorphism

                                                +quot;   !   quot;   #     Printer

    ...
CORBA Distributed Polymorphism

                                                +quot;   !   quot;   #     Printer

      ...
printer




                   &OLHQW                         Printer
                                                prin...
CORBA use case
                      Can we use CORBA in Large Distributed Control
                      System ?
        ...
We need design patterns

                0           (
                                                        #          ...
Distributed Pattern

                            #           #               .1   /               )quot;
                +...
The GOF Abstract Factory Design Pattern




       *GoF stand for Gang of Four. It refers to the famous books of John Vlis...
Polymorphism and Factory Pattern : example 2




                                         quot;
31/03/03




             ...
Life cycle


                                                Printer Factory
                    Client                   ...
FACTOY PATTERN (from OOC training)


                          quot;                         quot;                 !      ...
Polymorphism and Factory Pattern




                                        quot;
31/03/03




                Thales Air...
Polymorphism and Factory Pattern




                                        quot;
31/03/03




                Thales Air...
Factory And Code Generation


                &OLHQW                                     Printer

                        ...
Factory And Code Generation


                &OLHQW                                              Printer

               ...
Factory And Code Generation


                &OLHQW                                     Printer

                        ...
Factory And Code Generation


                       &OLHQW                                        Printer

              ...
Factory And Code Generation

                                                                     <<Interface>>
          ...
Factory And Code Generation

                                                       <<Interface>>
                &OLHQW
 ...
CORBA use case
                      Can we use CORBA in Large Distributed Control
                      System ?
        ...
Why is procedural design expensive to change ?


                      quot;                             quot;            ...
Why is OOD easy to change ?


                    quot;                     )quot;                  #
                    ...
Object collaboration
31/03/03




                Thales Air Traffic Management
           93
Why is OOD easy to change ?

                +      !                             quot;   #
                       !      ...
Example 3: The problem is in the User Input




                        Exit Coordination State

                        A...
Replace case and enum by object .



                 enum ExitCoordinationState {

                        NIL_EXIT_STATE...
Example of structural fragility : the switch

                +     quot;            +! quot;                          quo...
structural switch


                static void printsStatus(int status) {

                           switch(status) {

 ...
structural switch
                static void flightUpdate(int status) {

                          switch(status) {

    ...
structural switch
                                                                                       static void fligh...
The problem space and the solution space.

                                !quot;(                  quot;              &

...
User Imput




                         Exit Coordination State

                         A:   NIL_EXIT_STATE,
           ...
Replace case and enum by object .

                  enum ExitCoordinationState {

                           NIL_EXIT_STA...
structural switch
                 static void printsStatus(int status) {

                             switch(status) {

...
structural switch
                                                                               static void flightUpdate(...
OOD hides the problem space

                 0                      %            quot;    #      quot;       quot;
      ...
Polymorphism

                                           Print()
                                                         ...
Factory Pattern


                       &OLHQW                                           Status

                        ...
Factory Pattern

                            !quot;                !                       )quot;               quot;

   ...
Factory pseudo code
           static Status create(int status) {

                                                       ...
Polymorphism and changes


                       &OLHQW                                  Status

                        ...
Polymorphism and state patterns

                    !        (               )quot; ! quot;              quot;   quot;   ...
State Pattern (from the GoF)
31/03/03




           GoF stand for Gang of Four. It refers to the famous books of Vlisside...
Object Programming



                                                               Stat1
                 2&            ...
State Pattern

                                                             quot;   &       )quot;          quot;
        ...
Polymorphism




                       &OLHQW                                  Status

                                  ...
Polymorphism
                                                                  Context



                       &OLHQW   ...
Coarse Grain Examples

                                &                    (                    '       quot;
           ...
On line coordination with CORBA Objects




                                                                              ...
CORBA use case
                       Can we use CORBA in Large Distributed Control
                       System ?
      ...
CORBA = Coarse Grain Object

                 Local Object                     Remote Object

                            ...
CORBA = Coarse Grain Object

                 Local Object                     Remote Object

                           G...
Distributed Object Patterns

                                                 Façade                       Remote Object
 ...
Object By Value

                                                             Event Factory
           Local Object       ...
CORBA use case
                       Can we use CORBA in Large Distributed Control
                       System ?
      ...
Separation Of Concern




                  Security                 Fault       Load      Transaction
                   ...
Separation Of Concern

                            quot;                    quot;                                  !    (#...
Separation Of Concern




                   Fault                               Load
                                    ...
Separation Of Concern



                                               Fault
                                            ...
Separation Of Concern


                                               Fault     Security
                  Printer       ...
Y development cycle




                                                                   quot;
                         ...
Application Lay out




                                                   quot;
                                         ...
Application Lay out



                                                      quot;
                                       ...
Application Lay out



                         quot;                           quot;   $ #quot;
                     quot...
Y Standardization Process

                               quot;                      quot;       quot;   #       !
       ...
Y Standardization Process




             Domain Logic                                      Domain Technical
            ...
Upcoming SlideShare
Loading in …5
×

CORBA tutorial Boston2003

1,012 views

Published on

CORBA tutorial

Published in: Technology, Education
1 Comment
3 Likes
Statistics
Notes
No Downloads
Views
Total views
1,012
On SlideShare
0
From Embeds
0
Number of Embeds
28
Actions
Shares
0
Downloads
102
Comments
1
Likes
3
Embeds 0
No embeds

No notes for slide

CORBA tutorial Boston2003

  1. 1. CORBA for transportation control and command systems tutorial
  2. 2. CORBA ATC use case, Note to offline reader. ! quot; # ! ! # quot; # $% # quot; quot;! ! & ' ( )quot; quot; # # quot; % quot; & ! ( # # ! & ! * )quot; quot; # quot; ! quot; # ! ! % !! ! ! quot; # ! ( % ! # quot; quot; ' # quot; ( ( quot; ' quot; quot; # # quot; quot; % ! # 31/03/03 Thales Air Traffic Management 2
  3. 3. The open issue : $ # + quot; quot; + , , 31/03/03 Thales Air Traffic Management 3
  4. 4. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 4
  5. 5. Why CORBA ? )quot; quot; # (quot; quot; ! ( ( # - quot; . / 0 ! )quot; quot; # (quot; quot; # ! ( ( # - quot; ( )quot; 31/03/03 Thales Air Traffic Management 5
  6. 6. Practical Use Case 0 # # ! + + # 1 quot; + quot; 2( ! %, 3! ! %, 0 ( , 2& 31/03/03 Thales Air Traffic Management 6
  7. 7. Complex system : ATC center AFTN/CIDIN ATFM ADJACENT FIR'S/TWR'S MET Centres Supervisory Recording Radar Front Radar Data Flight Plan Simulator Control Supervisory Replay Processing Processing Recording Processing Radar Front Radar Data Flight Plan Simulator Control Replay Processing Processing Processing LAN Voice control controller controller controller controller and Voice control Working Working Working Working communications and Position Position Position Position communications • Intercom • Priority • Public 4 56 31/03/03 • RADIO A/G Thales Air Traffic Management 7
  8. 8. Object At system level ? - quot; ! )quot; quot; # ( , ! (quot; quot; ! ! )quot; , ! 7 ( ! # '! )quot; #( ! ( 31/03/03 Thales Air Traffic Management 8
  9. 9. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 9
  10. 10. What Do We Want &+ + # quot; # quot; # 31/03/03 Thales Air Traffic Management 10
  11. 11. What Do We Want ! quot; # + + Operator Display Supervision 31/03/03 System Thales Air Traffic Management 11
  12. 12. What DO We Want ! quot; # quot; # # # + + + + Operator Display Supervision 31/03/03 System Thales Air Traffic Management 12
  13. 13. What DO We Want ! quot; # # # + + Operator Display Supervision 31/03/03 System Thales Air Traffic Management 13
  14. 14. We want to Increase Integrated software quality 31/03/03 Thales Air Traffic Management 14
  15. 15. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 15
  16. 16. What We expect ? 0 ! quot; # # # + + Operator Display Supervision 31/03/03 System Thales Air Traffic Management 16
  17. 17. What We expect ? 8 + # 31/03/03 Thales Air Traffic Management 17
  18. 18. What We May Have : + (quot; + (quot; + (quot; + (quot; + (quot; 2 31/03/03 Thales Air Traffic Management 18
  19. 19. Spaghetti Plate Syndrome 8 quot; 31/03/03 Thales Air Traffic Management 19
  20. 20. Spaghetti Plate Syndrome + quot; quot; + # 31/03/03 Thales Air Traffic Management 20
  21. 21. Spaghetti Plate Syndrome + # + # 31/03/03 Thales Air Traffic Management 21
  22. 22. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 22
  23. 23. Why CORBA 0 ! ( ( ! quot; # ! )quot; + ! )quot; quot; # 0 ) quot; 'quot; # ( ( quot; quot; 31/03/03 Thales Air Traffic Management 23
  24. 24. Software Component Integration Bus Software BUS 31/03/03 Thales Air Traffic Management 24
  25. 25. Object Software Component Integration Bus # $ # # ! Distributed )quot; 99:; ( Polymorphism quot; Software Components Evolution And Replacement 31/03/03 Thales Air Traffic Management 25
  26. 26. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 26
  27. 27. Polymorphism 1 < ' )quot; quot; # quot; * ( ! quot; 0 ! ! quot; = *GoF stand for Gang of Four. It refers to the pattern seminal book of John Vlissides, Erich Gamma, Richard Helm, Ralph Johnson: Design Patterns: Elements of Reusable Object-Oriented Software. 31/03/03 Thales Air Traffic Management 27
  28. 28. Object Software Component Integration Bus Object Software BUS 31/03/03 Thales Air Traffic Management 28
  29. 29. Object Software Component Integration Bus 8! Object Software BUS 31/03/03 Thales Air Traffic Management 29
  30. 30. Procedural versus Object Procedural Design Object Design After Object Before Object 31/03/03 Thales Air Traffic Management 30
  31. 31. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 31
  32. 32. Design for changes 0 quot; > ( ?quot; # @ 0 ( quot; # # A ( # ( 0 ( quot; quot; # 0 quot; > A - ( # # & # quot; # # ( quot; # 31/03/03 Thales Air Traffic Management 32
  33. 33. Changes Sources* During Development - quot;( 0 0 # 2 ( quot; # quot; quot; #0 +% 0 $ B 0 quot;( # + ; + quot; 8 <. ! / 31/03/03 Thales Air Traffic Management 33
  34. 34. Object Oriented Design # # !quot; quot;#& # quot; ! !quot; )quot; #. / quot; - . / quot; #quot; #quot; ! quot; ## & #quot; 0 quot; quot; quot; !quot; ! quot; # 0 quot; quot; quot; !quot; 31/03/03 Thales Air Traffic Management 34
  35. 35. Without OOD Without OOD Design for no Changes Stationary System 31/03/03 Thales Air Traffic Management 35
  36. 36. Change management before OOD #( quot; ( quot; # quot; Caller called 31/03/03 Thales Air Traffic Management 36
  37. 37. Change management before OOD 0 ! quot; quot; quot; ( quot; # quot; quot; # !quot; quot; No changes Caller called 31/03/03 Thales Air Traffic Management 37
  38. 38. Change management before OOD ! '! quot; quot; quot; # quot; quot; quot; # !quot; Changes 31/03/03 Caller called Thales Air Traffic Management 38
  39. 39. Change management and code reuse before OO ! '! quot; quot; quot; # quot; quot; quot; # !quot; Caller called 31/03/03 Thales Air Traffic Management 39
  40. 40. System Integration is a specific change case + # quot; quot; #quot; quot;# quot; !quot; 0 !quot; # -( !quot; quot; # quot; quot; quot; quot; Caller Called Caller Called 31/03/03 Thales Air Traffic Management 40
  41. 41. Integration case + # quot; quot; #quot; quot;# quot; !quot; 0 !quot; # -( !quot; quot; # quot; quot; quot; quot; Old New Old New Code Code Code Code Caller Called Called Caller 31/03/03 Thales Air Traffic Management 41
  42. 42. Pervasive Change Replaced Module (Changed) 31/03/03 Thales Air Traffic Management 42
  43. 43. Pervasive Change 31/03/03 Thales Air Traffic Management 43
  44. 44. Pervasive Change 31/03/03 Thales Air Traffic Management 44
  45. 45. Pervasive Change Several Changes Replace and Reused 31/03/03 Thales Air Traffic Management 45
  46. 46. Pervasive Change = Spaghetti Plate After Several Changes Replace and Reused + # 31/03/03 Thales Air Traffic Management 46
  47. 47. Procedural versus Object Without OOD With OOD Design for no Changes Design For Changes Stationary System Evolutionary System 31/03/03 Thales Air Traffic Management 47
  48. 48. Change management with OO reuse 0 % ! quot; quot; quot; !quot; quot; OOD Caller called 31/03/03 Thales Air Traffic Management 48
  49. 49. Change management with OO reuse 0 % ! quot; quot; quot; !quot; quot; No changes Caller called OOD 31/03/03 Thales Air Traffic Management 49
  50. 50. With OOD : Software Bus 31/03/03 Thales Air Traffic Management 50
  51. 51. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 51
  52. 52. Changes example : the printer Client Printing Server From The CORBA Bible Michi Henning Steve Vinoski Advanced CORBA Programming with C++ 31/03/03 Thales Air Traffic Management 52
  53. 53. Changes example : the printer 3 quot;quot; & # quot; # (quot; # #! quot;% ! #( ' ! quot; # ( ( ?- quot;% @ ! quot; #! quot; ! !quot; 31/03/03 Thales Air Traffic Management 53
  54. 54. Changes example : the printer Client Printing Server 31/03/03 Thales Air Traffic Management 54
  55. 55. Changes example : the printer Old Client Printing Server New Client 31/03/03 Thales Air Traffic Management 55
  56. 56. Change management with OOD reuse # #! quot;% ! Printing Server Client 31/03/03 Thales Air Traffic Management 56
  57. 57. Change management with OOD reuse 3 ! quot; # ( ( ?- quot;% @ ! quot; #! quot; ! !quot; Printing Server Client 31/03/03 Thales Air Traffic Management 57
  58. 58. Change management and code reuse before OOD quot; quot; # quot; ! ( quot;quot; # 31/03/03 Thales Air Traffic Management 58
  59. 59. Change management with OOD reuse # ? )quot;@ quot; ! quot; quot; # ( quot; 31/03/03 Thales Air Traffic Management 59
  60. 60. Object properties ? )quot;@ !# 2quot; quot; quot; 2 &quot; # quot; quot; quot; ! # quot; # 31/03/03 Thales Air Traffic Management 60
  61. 61. CORBA = Distributed Polymorphism )quot; # # quot; # 0 # )quot; + (quot; . +/ 31/03/03 Thales Air Traffic Management 61
  62. 62. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 62
  63. 63. CORBA Distributed Polymorphism examples 2& ! +8 # (quot; 2& C # +$ quot; quot; quot; .1 / 2& D # 31/03/03 Thales Air Traffic Management 63
  64. 64. Example UML Diagram Print Strip Printer 1 Strip : string Print() Print() From The CORBA Bible Michi Henning Steve Vinoski ColorPrinter Advanced CORBA Programming with C++ Setcolor() 31/03/03 Thales Air Traffic Management 64
  65. 65. Example Interface Inheritance (IDL) Printer # quot; ColorPrinter ! quot; 31/03/03 Thales Air Traffic Management 65
  66. 66. printer &OLHQW Printer print() Colour set_color() 31/03/03 Thales Air Traffic Management 66
  67. 67. printer &OLHQW Printer print() 31/03/03 Thales Air Traffic Management 67
  68. 68. CORBA Distributed Polymorphism example 1 8 # Printer + (quot; 0 - & 31/03/03 Thales Air Traffic Management 68
  69. 69. CORBA = Distributed Polymorphism ? # (quot; @ quot; quot; # (quot; # #quot; quot;quot; 8 #+ (quot; ( !quot; # ! quot; # (quot; 31/03/03 Thales Air Traffic Management 69
  70. 70. Objet Reference and Naming Client Naming Server Service Client lookup Server exports for Interface IOR IOR Client submits request to server 31/03/03 Thales Air Traffic Management 70
  71. 71. CORBA = Distributed Polymorphism % ! ( quot; quot; # quot; 8 !quot; quot; ! quot; ! quot; quot; 31/03/03 Thales Air Traffic Management 71
  72. 72. CORBA = Distributed Polymorphism +quot; ! quot; # Printer 8 # + (quot; ColorPrinter 0 - & quot;% 0 31/03/03 Thales Air Traffic Management 72
  73. 73. CORBA Distributed Polymorphism +quot; ! quot; # Printer 8 # + (quot; ColorPrinter 0 - & 31/03/03 Thales Air Traffic Management 73
  74. 74. printer &OLHQW Printer print() Colour set_color() 31/03/03 Thales Air Traffic Management 74
  75. 75. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 75
  76. 76. We need design patterns 0 ( # quot; quot; - # # quot; quot;! quot; quot; # ! quot; quot; ! % ! )quot; # # 31/03/03 Thales Air Traffic Management 76
  77. 77. Distributed Pattern # # .1 / )quot; + # )quot; + ! #! quot; ( quot; # quot; 2& quot; ! quot;quot; quot; )quot; ! + ! quot; & # ! +quot; & quot; # ! & 31/03/03 Thales Air Traffic Management 77
  78. 78. The GOF Abstract Factory Design Pattern *GoF stand for Gang of Four. It refers to the famous books of John Vlissides, Erich Gamma, Richard Helm, 31/03/03 Ralph Johnson. Design Patterns: Elements of Reusable Object-Oriented Software. Thales Air Traffic Management 78
  79. 79. Polymorphism and Factory Pattern : example 2 quot; 31/03/03 Thales Air Traffic Management 79
  80. 80. Life cycle Printer Factory Client Printer Create Printer Create Printer Printer IOR Request 31/03/03 Thales Air Traffic Management 80
  81. 81. FACTOY PATTERN (from OOC training) quot; quot; ! ( 'quot; # !# +quot; A client is required to provide security information before the factory object will allow the client to have access to another object. $ * quot;# The factory object manages a pool of objects, often representing some limited resource, and assigns them to clients based on some utilization algorithm. A factory object enables the use of polymorphism by returning object references to different implementations depending on 31/03/03 the criteria specified by a client. Thales Air Traffic Management 81
  82. 82. Polymorphism and Factory Pattern quot; 31/03/03 Thales Air Traffic Management 82
  83. 83. Polymorphism and Factory Pattern quot; 31/03/03 Thales Air Traffic Management 83
  84. 84. Factory And Code Generation &OLHQW Printer +print() Black & White + print() 31/03/03 Thales Air Traffic Management 84
  85. 85. Factory And Code Generation &OLHQW Printer +print() Black & White Colour + print() + print() 31/03/03 Thales Air Traffic Management 85
  86. 86. Factory And Code Generation &OLHQW Printer +print() Black & White Colour FAX + print() + print() + print() 31/03/03 Thales Air Traffic Management 86
  87. 87. Factory And Code Generation &OLHQW Printer +print() Strip Black & White Colour FAX + print() + print() + print() + print() 31/03/03 Thales Air Traffic Management 87
  88. 88. Factory And Code Generation <<Interface>> &OLHQW Printer +print() Strip Black & White Colour FAX + print() + print() + print() + print() 31/03/03 Thales Air Traffic Management 88
  89. 89. Factory And Code Generation <<Interface>> &OLHQW Printer Factory Strip Black & White Colour FAX Factory Factory Factory Factory 1 quot; 31/03/03 Thales Air Traffic Management 89
  90. 90. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 90
  91. 91. Why is procedural design expensive to change ? quot; quot; quot; # quot; quot; + ! quot; # quot; quot; # 31/03/03 Thales Air Traffic Management 91
  92. 92. Why is OOD easy to change ? quot; )quot; # quot; quot; 2quot; )quot; quot; # )quot; )quot; quot; quot; 31/03/03 Thales Air Traffic Management 92
  93. 93. Object collaboration 31/03/03 Thales Air Traffic Management 93
  94. 94. Why is OOD easy to change ? + ! quot; # ! )quot; quot; # ! quot; quot; )quot; quot; # quot; # quot;# ? @ 31/03/03 Thales Air Traffic Management 94
  95. 95. Example 3: The problem is in the User Input Exit Coordination State A: NIL_EXIT_STATE, B: FLIGHT_ACTIVATION_PROPOSAL, C: FLIGHT_ACTIVATION_ALARM, D: FLIGHT_ACTIVATION_CONFIRMED, E: HANDOVER_TRANSFERED, F: COORDINATION_TERMINATED, G: UNKNOWN_EXIT_STATE Enter Exit Coordination State => 31/03/03 Thales Air Traffic Management 95
  96. 96. Replace case and enum by object . enum ExitCoordinationState { NIL_EXIT_STATE, FLIGHT_ACTIVATION_PROPOSAL, FLIGHT_ACTIVATION_ALARM, FLIGHT_ACTIVATION_CONFIRMED, HANDOVER_TRANSFERED, COORDINATION_TERMINATED, UNKNOWN_EXIT_STATE } 31/03/03 Thales Air Traffic Management 96
  97. 97. Example of structural fragility : the switch + quot; +! quot; quot; # 2( quot; # quot; #quot; quot; # ! !quot; quot; quot; !quot; #% quot; # quot;E 2( ! ( quot; quot;quot; # ( ' ( !quot; quot;quot; # ( 0 ( quot; # ( quot; # ( ! !quot;quot; 31/03/03 Thales Air Traffic Management 97
  98. 98. structural switch static void printsStatus(int status) { switch(status) { case NIL_EXIT_STATE : processing 1 case FLIGHT_ACTIVATION_PROPOSAL: processing 2 case FLIGHT_ACTIVATION_ALARM: processing 3 case FLIGHT_ACTIVATION_CONFIRMED: processing 4 case HANDOVER_TRANSFERED, processing 5 case COORDINATION_TERMINATED, processing 6 case UNKNOWN_EXIT_STATE processing 7 } } 31/03/03 Thales Air Traffic Management 98
  99. 99. structural switch static void flightUpdate(int status) { switch(status) { case NIL_EXIT_STATE : processing 1 case FLIGHT_ACTIVATION_PROPOSAL: processing 2 case FLIGHT_ACTIVATION_ALARM: processing 3 case FLIGHT_ACTIVATION_CONFIRMED: processing 4 case HANDOVER_TRANSFERED, processing 5 case COORDINATION_TERMINATED, processing 6 case UNKNOWN_EXIT_STATE processing 7 } 31/03/03 } Thales Air Traffic Management 99
  100. 100. structural switch static void flightUpdate(int status) { switch(status) { case NIL_EXIT_STATE: processing 1 case FLIGHT_ACTIVATION_PROPOSAL: static void flightUpdate(int status) { processing 2 case FLIGHT_ACTIVATION_ALARM: static void flightUpdate(int status) { switch(status) { processing 3 case FLIGHT_ACTIVATION_CONFIRMED: case NIL_EXIT_STATE : switch(status) { processing4 processing 1 case HANDOVER_TRANSFERED, case NIL_EXIT_STATE : case FLIGHT_ACTIVATION_PROPOSAL: processing 5 processing 2 processing 1 case COORDINATION_TERMINATED, case FLIGHT_ACTIVATION_PROPOSAL: case FLIGHT_ACTIVATION_ALARM: processing 6 processing 2 processing 3 case UNKNOWN_EXIT_STATE case FLIGHT_ACTIVATION_ALARM: case FLIGHT_ACTIVATION_CONFIRMED: processing 7 processing 3 processing 4 } case FLIGHT_ACTIVATION_CONFIRMED: case HANDOVER_TRANSFERED, } processing 5 processing 4 case HANDOVER_TRANSFERED, case COORDINATION_TERMINATED, processing 5 processing 6 case COORDINATION_TERMINATED, case UNKNOWN_EXIT_STATE processing 6 processing 7 case UNKNOWN_EXIT_STATE } processing 7 } Software } } Module B Software Module A Software Module D Software Software static void flightUpdate(int status) { Module E Module C switch(status) { static void flightUpdate(int status) { case NIL_EXIT_STATE : processing 1 switch(status) { case FLIGHT_ACTIVATION_PROPOSAL: processing 2 case NIL_EXIT_STATE : case FLIGHT_ACTIVATION_ALARM: processing 1 processing 3 case FLIGHT_ACTIVATION_PROPOSAL: processing 2 case FLIGHT_ACTIVATION_CONFIRMED: case FLIGHT_ACTIVATION_ALARM: processing 4 processing 3 case HANDOVER_TRANSFERED, case FLIGHT_ACTIVATION_CONFIRMED: processing 5 processing 4 case COORDINATION_TERMINATED, case HANDOVER_TRANSFERED, processing 6 processing 5 case UNKNOWN_EXIT_STATE case COORDINATION_TERMINATED, processing 7 processing 6 } case UNKNOWN_EXIT_STATE } processing 7 31/03/03 } } Thales Air Traffic Management 100
  101. 101. The problem space and the solution space. !quot;( quot; & 0 - !quot; ( quot; # ( ! !quot;( 31/03/03 Thales Air Traffic Management 101
  102. 102. User Imput Exit Coordination State A: NIL_EXIT_STATE, B: FLIGHT_ACTIVATION_PROPOSAL, C: FLIGHT_ACTIVATION_ALARM, D: FLIGHT_ACTIVATION_CONFIRMED, E: HANDOVER_TRANSFERED, F: COORDINATION_TERMINATED, G: NewState H: UNKNOWN_EXIT_STATE Enter Exit Coordination State => 31/03/03 Thales Air Traffic Management 102
  103. 103. Replace case and enum by object . enum ExitCoordinationState { NIL_EXIT_STATE, FLIGHT_ACTIVATION_PROPOSAL, FLIGHT_ACTIVATION_ALARM, FLIGHT_ACTIVATION_CONFIRMED, HANDOVER_TRANSFERED, COORDINATION_TERMINATED, NewState, UNKNOWN_EXIT_STATE } 31/03/03 Thales Air Traffic Management 103
  104. 104. structural switch static void printsStatus(int status) { switch(status) { case NIL_EXIT_STATE : processing 1 case FLIGHT_ACTIVATION_PROPOSAL: processing 2 case FLIGHT_ACTIVATION_ALARM: processing 3 case FLIGHT_ACTIVATION_CONFIRMED: processing 4 case HANDOVER_TRANSFERED, processing 5 case COORDINATION_TERMINATED, processing 6 case New_State, processing 7 case UNKNOWN_EXIT_STATE processing 8 31/03/03 } } Thales Air Traffic Management 104
  105. 105. structural switch static void flightUpdate(int status) { switch(status) { case NIL_EXIT_STATE: processing 1 case FLIGHT_ACTIVATION_PROPOSAL: static void flightUpdate(int status) { processing 2 case FLIGHT_ACTIVATION_ALARM: switch(status) { processing 3 case FLIGHT_ACTIVATION_CONFIRMED: case NIL_EXIT_STATE : processing4 processing 1 case HANDOVER_TRANSFERED, case FLIGHT_ACTIVATION_PROPOSAL: processing 5 processing 2 static void flightUpdate(int status) { case COORDINATION_TERMINATED, case FLIGHT_ACTIVATION_ALARM: processing 6 processing 3 switch(status) { case UNKNOWN_EXIT_STATE case FLIGHT_ACTIVATION_CONFIRMED: processing 7 case NIL_EXIT_STATE : processing 4 } case HANDOVER_TRANSFERED, processing 1 } processing 5 case FLIGHT_ACTIVATION_PROPOSAL: case COORDINATION_TERMINATED, processing 2 processing 6 case FLIGHT_ACTIVATION_ALARM: case UNKNOWN_EXIT_STATE processing 3 case FLIGHT_ACTIVATION_CONFIRMED: processing 7 processing 4 } case HANDOVER_TRANSFERED, } Software processing 5 case COORDINATION_TERMINATED, processing 6 case UNKNOWN_EXIT_STATE Module B processing 7 } Software } Module A Software Module D Software Software static void flightUpdate(int status) { Module E Module C switch(status) { static void flightUpdate(int status) { case NIL_EXIT_STATE : processing 1 switch(status) { case FLIGHT_ACTIVATION_PROPOSAL: processing 2 case NIL_EXIT_STATE : case FLIGHT_ACTIVATION_ALARM: processing 1 processing 3 case FLIGHT_ACTIVATION_PROPOSAL: processing 2 case FLIGHT_ACTIVATION_CONFIRMED: case FLIGHT_ACTIVATION_ALARM: processing 4 processing 3 case HANDOVER_TRANSFERED, case FLIGHT_ACTIVATION_CONFIRMED: processing 5 processing 4 case COORDINATION_TERMINATED, case HANDOVER_TRANSFERED, processing 6 processing 5 case UNKNOWN_EXIT_STATE case COORDINATION_TERMINATED, processing 7 processing 6 } case UNKNOWN_EXIT_STATE } Changes processing 7 31/03/03 } } Thales Air Traffic Management 105
  106. 106. OOD hides the problem space 0 % quot; # quot; quot; )quot; 3! 0 0 3! 31/03/03 Thales Air Traffic Management 106
  107. 107. Polymorphism Print() Status Client +print() UNKNOWN_EXI NIL_EXIT FLIGHT_ACTIVATION FLIGHT_ACTIVATION T_STATE _STATE _PROPOSAL _ALARM + print() + print() + print() + print() 31/03/03 Thales Air Traffic Management 107
  108. 108. Factory Pattern &OLHQW Status +print() UNKNOWN_EXIT NIL_EXIT FLIGHT_ACTIVATION FLIGHT_ACTIVATION _STATE _ALARM _STATE _PROPOSAL + print() + print() + print() + print() StatusFactory 31/03/03 + create() Thales Air Traffic Management 108
  109. 109. Factory Pattern !quot; ! )quot; quot; quot; ! )quot; # ( quot; # !quot;quot; # quot; quot; ! quot; )quot; + 2quot; )quot; % ! ! #quot; (quot; quot; 31/03/03 Thales Air Traffic Management 109
  110. 110. Factory pseudo code static Status create(int status) { New Object switch(status) { case NIL_EXIT_STATE : return status = new nil_exit_state(); break; case FLIGHT_ACTIVATION_PROPOSAL: return status = new flight_activation_proposal(); break; case FLIGHT_ACTIVATION_ALARM: return status = new flight_activation_alarm(); break; case FLIGHT_ACTIVATION_CONFIRMED: return status = new flight_activation_confirmed(); break; case HANDOVER_TRANSFERED, return status = new handover_transfered(); break; case COORDINATION_TERMINATED, return status = new coordination_terminated(); break; case UNKNOWN_EXIT_STATE return status = new unknown_exit_state(); 31/03/03 } } Thales Air Traffic Management 110
  111. 111. Polymorphism and changes &OLHQW Status +print() No Changes UNKNOWN_EXIT NIL_EXIT FLIGHT_ACTIVATION FLIGHT_ACTIVATION _STATE _PROPOSAL _ALARM _STATE + print() + print() + print() + print() NEW_STATE 31/03/03 + print() Thales Air Traffic Management 111
  112. 112. Polymorphism and state patterns ! ( )quot; ! quot; quot; quot; # # ! ( quot;quot; # )quot; ! + ( !quot; ( )quot; quot; ## + quot; )quot; quot; quot; (quot; 31/03/03 Thales Air Traffic Management 112
  113. 113. State Pattern (from the GoF) 31/03/03 GoF stand for Gang of Four. It refers to the famous books of Vlisside and Co. Design Patterns: Elements of Reusable Object-Oriented Software. Thales Air Traffic Management 113
  114. 114. Object Programming Stat1 2& + F State2 State4 State5 G + # 31/03/03 Thales Air Traffic Management 114
  115. 115. State Pattern quot; & )quot; quot; !quot; )quot; )quot; & '# quot; % ! ! # ' ! quot; quot; (quot; 31/03/03 Thales Air Traffic Management 115
  116. 116. Polymorphism &OLHQW Status +print() UNKNOWN_EXIT NIL_EXIT FLIGHT_ACTIVATION FLIGHT_ACTIVATION _STATE _PROPOSAL _ALARM _STATE + print() + print() + print() + print() 31/03/03 Thales Air Traffic Management 116
  117. 117. Polymorphism Context &OLHQW Status status +print() +print() Concrete state UNKNOWN_EXIT NIL_EXIT FLIGHT_ACTIVATION FLIGHT_ACTIVATION _STATE _PROPOSAL _ALARM _STATE + print() + print() + print() + print() 31/03/03 Thales Air Traffic Management 117
  118. 118. Coarse Grain Examples & ( ' quot; quot; # quot; quot; quot; ' # ( )quot; # & quot; # & + ! )quot; quot; # )quot; 31/03/03 Thales Air Traffic Management 118
  119. 119. On line coordination with CORBA Objects Status Status Status Status 31/03/03 Air Traffic Control Centre Thales Air Traffic Management 119
  120. 120. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 120
  121. 121. CORBA = Coarse Grain Object Local Object Remote Object NO Operation1() Operation2() Fine Grain Object Operation3() Operation4() 31/03/03 Thales Air Traffic Management 121
  122. 122. CORBA = Coarse Grain Object Local Object Remote Object GroupOperation() YES 31/03/03 Thales Air Traffic Management 122
  123. 123. Distributed Object Patterns Façade Remote Object Local Object GetRemoteObject() H Operation1() $quot; quot; Operation2() Operation3() 31/03/03 Thales Air Traffic Management 123
  124. 124. Object By Value Event Factory Local Object Remote Object $quot; )quot; OBV new Event Type Operation1() Operation2() Operation3() 31/03/03 Thales Air Traffic Management 124
  125. 125. CORBA use case Can we use CORBA in Large Distributed Control System ? What do We want ! Complex System Seamless Integration Why CORBA ? Object Software Bus Design for changes Change example : Printer CORBA distributed polymorphism example CORBA and Distributed Design pattern example Procedural design versus Object design Designing Distributed Object 31/03/03 Normalisation processes Thales Air Traffic Management 125
  126. 126. Separation Of Concern Security Fault Load Transaction Tolerance Balancing Printer Printer Printer Printer 31/03/03 Thales Air Traffic Management 126
  127. 127. Separation Of Concern quot; quot; ! (# quot; quot; quot; quot; quot; )quot; )quot; quot; )quot; quot; )quot; quot; quot; ! quot; quot; )quot; quot; 31/03/03 Thales Air Traffic Management 127
  128. 128. Separation Of Concern Fault Load Security Transaction Tolerance Balancing Printer 31/03/03 Thales Air Traffic Management 128
  129. 129. Separation Of Concern Fault Load Transaction Security Tolerance Balancing Printer 31/03/03 Thales Air Traffic Management 129
  130. 130. Separation Of Concern Fault Security Printer Load Transaction Tolerance Balancing Technical Services Domain Services 31/03/03 Thales Air Traffic Management 130
  131. 131. Y development cycle quot; ! $ quot;# quot; quot; 1 quot; ! 31/03/03 Thales Air Traffic Management 131
  132. 132. Application Lay out quot; $ #quot; quot;- 31/03/03 Thales Air Traffic Management 132
  133. 133. Application Lay out quot; $quot; quot; # $ #quot; quot;- quot; quot; - 31/03/03 Thales Air Traffic Management 133
  134. 134. Application Lay out quot; quot; $ #quot; quot; quot; quot; quot; quot; quot; - quot; quot; 31/03/03 Thales Air Traffic Management 134
  135. 135. Y Standardization Process quot; quot; quot; # ! # quot; quot; ( # quot; ! quot; quot; quot; quot; quot; 0 ( ! quot;% ( A quot; 31/03/03 Thales Air Traffic Management 135
  136. 136. Y Standardization Process Domain Logic Domain Technical Patterns Patterns Transportation DTF 31/03/03 Thales Air Traffic Management 136

×