Dr. Dobb's Journal - July 2008 - (Page 25) Perforce Fast Software Configuration Management Figure 3: A wiring diagram showing typed call notifications. 200,000 developers rely on Perforce to manage their code. continued from page 23 associations between the classes. You would essentially end up with a diagram just listing all the classes, with no lines connecting them. A better way to document EBAs is to use “Signal Wiring Diagrams” (usually just called “Wiring Diagrams”) which show who sends signals (notifications) to whom. I developed wiring diagrams several years ago to better model EBAs; see Figure 2. The large boxes in Figure 2 denote objects. The names in the boxes show the object types. The small black boxes on the object borders are pins. Pins are the inputs and outputs of an object, in terms of notification signals. Each signal has arrows to denote the direction of flow. A small label above the signal line indicates the name of the notification. In Figure 2, the signal Print is sent from PrintManager to DocumentPrinter. Input pins can also contain the name of the method they connect to. You may have noticed that there are no interfaces shown in the diagram. When notifications are sent using untyped calls, interfaces are not involved. PrintManager doesn’t know anything about the DocumentPrinter type. Indeed, PrintManager need not even know that DocumentPrinter is handling its Print notifications. When notifications are sent using typed calls, interfaces are involved. In such cases, the interfaces are shown as gray boxes enclosing the pins that are associated with the interface methods; see Figure 3. Signal wiring diagrams get their name because they look like hardware circuit diagrams used by electrical engineers. Software objects look like integrated circuits, with input and output pins. Notifications appear as interconnection wires. From a systems perspective, both hardware diagrams and signal wiring diagrams are representations of systems composed by parts wired together. Whether the boxes are implemented with hardware or software matters little, conceptually. The software objects might be replaced by hardware equivalents, with minimal changes to the overall diagram. Figure 4 shows the complete wiring diagram of SystemBrowser, a program I present in this article. You can find a Visio stencil for wiring diagrams online (see “Resource Center,” page 3 and www.faisoncomputing.com/samples/ EventBasedProgramming/VisioSignalWiring DiagramStencil.zip). Here’s what they’re saying “Perforce is absolutely the only tool I would trust to manage our source code.” Nick Triantos NVIDIA “Perforce has been a breath of fresh air; a product which does what it's supposed to do and does it well.” Scott Buchholz Sybase “Perforce is the cornerstone of Monster’s software production lines.” Mark Conway Monster Worldwide “The bottom line is that Perforce has proven itself to be a reliable platform for global development at Symantec.” Hooking the Parts Together Again, an EBA relies on parts that are independent of each other and that communicate using event notifications. If the parts are essentially oblivious of each other, then how do the parts get created and wired together? Good question. Before answering it, let’s look at how things work in traditional objectoriented systems. The operating system calls a program’s entry point, which typically instantiates a top-level class, which in turn instantiates other intermediate-level classes, each of which might instantiate other Russell Jackson Symantec See for yourself Free evaluation at www.perforce.com July 2008 l www.ddj.com l Dr. Dobb’s Journal 25 http://www.faisoncomputing.com/samples/EventBasedProgramming/VisioSignalWiringDiagramStencil.zip http://www.faisoncomputing.com/samples/EventBasedProgramming/VisioSignalWiringDiagramStencil.zip http://www.faisoncomputing.com/samples/EventBasedProgramming/VisioSignalWiringDiagramStencil.zip http://www.perforce.com http://www.ddj.com
Table of Contents Feed for the Digital Edition of Dr. Dobb's Journal - July 2008 Dr. Dobb's Journal - July 2008 Contents Friday Night Fish Fry Alia Vox Developer Diaries Developer’s Notebook Engineers Without Borders Conversations Patricia Tries Event-Based Architectures Graphs Versus Objects Lock-Free Queues Dr. Dobb’s Architecture & Design World Java and the Nokia N10 Internet Tablet Effective Concurrency The Agile Edge Swaine’s Flames Dr. Dobb's Journal - July 2008 Dr. Dobb's Journal - July 2008 - (Page Belly1) Dr. Dobb's Journal - July 2008 - (Page Belly2) Dr. Dobb's Journal - July 2008 - Dr. Dobb's Journal - July 2008 (Page Cover1) Dr. Dobb's Journal - July 2008 - Dr. Dobb's Journal - July 2008 (Page Cover2) Dr. Dobb's Journal - July 2008 - Dr. Dobb's Journal - July 2008 (Page 1) Dr. Dobb's Journal - July 2008 - Contents (Page 2) Dr. Dobb's Journal - July 2008 - Contents (Page 3) Dr. Dobb's Journal - July 2008 - Friday Night Fish Fry (Page 4) Dr. Dobb's Journal - July 2008 - Friday Night Fish Fry (Page 5) Dr. Dobb's Journal - July 2008 - Friday Night Fish Fry (Page 6) Dr. Dobb's Journal - July 2008 - Friday Night Fish Fry (Page 7) Dr. Dobb's Journal - July 2008 - Alia Vox (Page 8) Dr. Dobb's Journal - July 2008 - Alia Vox (Page 9) Dr. Dobb's Journal - July 2008 - Developer Diaries (Page 10) Dr. Dobb's Journal - July 2008 - Developer Diaries (Page 11) Dr. Dobb's Journal - July 2008 - Developer’s Notebook (Page 12) Dr. Dobb's Journal - July 2008 - Developer’s Notebook (Page 13) Dr. Dobb's Journal - July 2008 - Engineers Without Borders (Page 14) Dr. Dobb's Journal - July 2008 - Engineers Without Borders (Page 15) Dr. Dobb's Journal - July 2008 - Engineers Without Borders (Page 16) Dr. Dobb's Journal - July 2008 - Engineers Without Borders (Page 17) Dr. Dobb's Journal - July 2008 - Conversations (Page 18) Dr. Dobb's Journal - July 2008 - Conversations (Page 19) Dr. Dobb's Journal - July 2008 - Patricia Tries (Page 20) Dr. Dobb's Journal - July 2008 - Patricia Tries (Page 21) Dr. Dobb's Journal - July 2008 - Event-Based Architectures (Page 22) Dr. Dobb's Journal - July 2008 - Event-Based Architectures (Page 23) Dr. Dobb's Journal - July 2008 - Event-Based Architectures (Page 24) Dr. Dobb's Journal - July 2008 - Event-Based Architectures (Page 25) Dr. Dobb's Journal - July 2008 - Event-Based Architectures (Page 26) Dr. Dobb's Journal - July 2008 - Event-Based Architectures (Page 27) Dr. Dobb's Journal - July 2008 - Event-Based Architectures (Page 28) Dr. Dobb's Journal - July 2008 - Event-Based Architectures (Page 29) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 30) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 31) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 32) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 33) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 34) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 35) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 36) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 37) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 38) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 39) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 40) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 41) Dr. Dobb's Journal - July 2008 - Graphs Versus Objects (Page 42) Dr. Dobb's Journal - July 2008 - Lock-Free Queues (Page 43) Dr. Dobb's Journal - July 2008 - Lock-Free Queues (Page 44) Dr. Dobb's Journal - July 2008 - Lock-Free Queues (Page 45) Dr. Dobb's Journal - July 2008 - Lock-Free Queues (Page 46) Dr. Dobb's Journal - July 2008 - Lock-Free Queues (Page 47) Dr. Dobb's Journal - July 2008 - Dr. Dobb’s Architecture & Design World (Page 48) Dr. Dobb's Journal - July 2008 - Dr. Dobb’s Architecture & Design World (Page 49) Dr. Dobb's Journal - July 2008 - Java and the Nokia N10 Internet Tablet (Page 50) Dr. Dobb's Journal - July 2008 - Java and the Nokia N10 Internet Tablet (Page 51) Dr. Dobb's Journal - July 2008 - Java and the Nokia N10 Internet Tablet (Page 52) Dr. Dobb's Journal - July 2008 - Java and the Nokia N10 Internet Tablet (Page 53) Dr. Dobb's Journal - July 2008 - Java and the Nokia N10 Internet Tablet (Page 54) Dr. Dobb's Journal - July 2008 - Java and the Nokia N10 Internet Tablet (Page 55) Dr. Dobb's Journal - July 2008 - Java and the Nokia N10 Internet Tablet (Page 56) Dr. Dobb's Journal - July 2008 - Effective Concurrency (Page 57) Dr. Dobb's Journal - July 2008 - Effective Concurrency (Page 58) Dr. Dobb's Journal - July 2008 - Effective Concurrency (Page 59) Dr. Dobb's Journal - July 2008 - The Agile Edge (Page 60) Dr. Dobb's Journal - July 2008 - The Agile Edge (Page 61) Dr. Dobb's Journal - July 2008 - The Agile Edge (Page 62) Dr. Dobb's Journal - July 2008 - The Agile Edge (Page 63) Dr. Dobb's Journal - July 2008 - Swaine’s Flames (Page 64) Dr. Dobb's Journal - July 2008 - Swaine’s Flames (Page Cover3) Dr. Dobb's Journal - July 2008 - Swaine’s Flames (Page Cover4)
For optimal viewing of this digital publication, please enable JavaScript and then refresh the page. If you would like to try to load the digital publication without using Flash Player detection, please click here.