Rekayasa Perangkat Lunak (Software Engineering)

Catatan Kuliah

  Rekayasa Perangkat Lunak (Software Engineering)

  Software Engineering: A Practitioner’s Approach, 6/e

  copyright © 1996, 2001, 2005 R.S. Pressman & Associates, Inc.

  For University Use Only May be reproduced ONLY for student use at the university level when used in conjunction with Software Engineering: A Practitioner's Approach.

  Any other reproduction or use is expressly prohibited.

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Kenapa Arsitektur ?

Arsitektur bukanlah PL operasional, namun dia merupakan

representasi yang memungkinkan pengembang PL untuk :

(1)menganalisa efektivitas desain dalam memenuhi kebutuhan, (2) Mengetahui alternatif2x arsitektur pada keadaan dimana membuat perubahan desain masih relatif lebih mudah, dan (3) Mengurangi resiko terkait dengan konstruksi PL.

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Mengapa Arsitektur Penting?

  Representasi dari arsitektur PL adalah enabler bagi komunikasi antar pihak (stakeholder) yang tertarik dengan pengembangan sistem berbasis komputer.

  

Arsitketur menyoroti keputusan desain awal yang akan mempunyai

pengaruh yang sangat besar pada pekerjaan RPL yang mengikutinya, dan keberhasilan pada entitas sistem operasional.

   Arsitektur membangun model yang relatif kecil dan mudah digenggam secara intelektual tentang bagaimana sistem

distrukturkan dan bagaimana komponen2x bekerja sama [BAS03].

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Desain Data

  Pada level arsitektur … 

  

Desain satu atau lebih database untuk mendukung arsitektur

aplikasi 

  Desain method untuk mining „ ‟ isi dari berbagai database 

  Navigasi melalui database2x yang ada dalam usaha untuk mengambil informasi level bisnis yang sesuai

  

  Desain sebuah data warehouse —sebuah database besar, independen yang mempunyai akses pada data yang disipan dalam database yang melayani sekelompok aplikasi yang dibutuhkan bisnis

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Desain Data

  Pada level komponen … 

  Mengambil objek2x data dan mengembangkan satu set abstraksi data 

  Implementasi atribut2x objek data sebagai satu atau lebih struktur data  review struktur data untuk memastikan bahwa relasi yang tepat sudah dibuat

   Sederhanakan struktur data sesuai dengan kebutuhan

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

Desain Data —Level Komponen

  1. Prinsip2x analisis semantik yang diterapkan pada fungsi dan perilaku harus juga dapat berjalan pada data.

  2. Seluruh struktur data dan operasi yang akan dilakukan harus dapat diidentifikasi.

  3. Sebuah data dictionary harus dibuat dan digunakan untuk menentukan desain program dan data.

  4. Keputusan desain data level rendah harus ditunda hingga akhir proses desain.

  5. Representasi struktur dara harus diketahui oleh modul yang menggunakannya langsung dalam struktur tersebut (enkapsulasi).

  6. Sebuah pustaka struktur data dan operasi yang memungkinkan untuk diterapkan harus dikembangkan.

  7. Desain PL dan bahasa pemrograman harus mendukung spesifikasi dan realisasi dari tipe data abstrak.

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Ragam Gaya Arsitektur

  Masing2x menggambarkan kategori sistem yang menunjukkan : (1) a

  sekumpulan komponen (mis database, modul komputasi) yang

  menunjukkan fungsi yan dibutuhkan sistem, (2) sekumpulan connectors yang memungkinkan komunikasi, koordinasi dan kerjasama antar komponen components, (3) batasan yang menentukan bagaimana komponen dapat diintegrasikan untuk membentuk sistem, dan (4)

  smodel semantik yang memungkinkan desainer untk memahami properti

  keseluruhan dari sistem dengan menganlisai properti dalam bagian2x di dalamnya.

   Data-centered architectures

   Data flow architectures

   Call and return architectures  Object-oriented architectures 

  Layered architectures

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  Data-Centered Architecture

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  Data Flow Architecture

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Call and Return Architecture

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Layered Architecture

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Pattern Arsitektural

  Concurrency

  —aplikasi harus menangani banyak tugas dalam pola yang mensimulasikan paralelisasi

   operating system process management pattern

   task scheduler pattern

   Persistence

  —Data ada jika dia bertahan setelah eksekusi proses yang membuatnya. Ada dua pattern umum ::

   database management system pattern yang menerapkan penyimpanan dan pengambilan dari DBMS kepada arsitektur aplikasi

  

application level persistence pattern yang membangun fitur

persistence pada aristektur aplikasi

   Distribution

  — pola dimana sistem atau komponen2x di antaranya berkomunkasi dalam lingkungan terdistribusi

   broker bertindak sebagai orang di tengah antara komponen klient dan komponen server.

  

Desain Arsitektur

  PL harus ditempatkan pada konteks 

  Desain harus menentukan entitas eksternal (sistem lain, piranti, orang) dimana PL berinteraksi dengannya 

  Sekumpulan arsitektur archetypes harus diidentifikasi  archetype adalah abstraksi (mirip dengan class) yang menampilkan satu elemen dari perilaku sistem

   Desainer menentukan struktur sistem dengan memilih komponen PL yang mengimplmentasi masing2x archetype

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

Architectural Context

  Safehome Internet-based

  Pro duct system control panel target system: surveillance

  Security Function function uses homeowner peers uses uses sensors sensors

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  Archetypes

Figure 10.7 UML relat ionships f or Saf eHome securit y f unct ion archet ypes (adapt ed f rom [ BOS00] ) Cont roller Node communicat es wit h Det ect or Indicat or

  

Component Structure

SafeHome

  Execut ive select ion Funct ion Communicat ion Management Ext ernal GUI Int ernet Int erface Securit y Surveillance management Home processing Cont rol alarm panel processing management det ect or These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Refined Component

Structure

  Ext ernal se n so r se n so r se n so r se n so r se n so r se n so r se n so r se n so r Communicat ion Management GUI Internet Interface Security

Co n t ro l

p an e l

p ro ce ssin g

d e t e ct o r m an ag e m e n t alarm p ro ce ssin g Ke y p ad p ro ce ssin g CP d isp lay fu n ct io n s sch e d u le r se n so r se n so r se n so r se n so r p h o n e co m m u n icat io n alarm Saf eHome Executive

  Analisis Desain Arsitektur 1. Kumpulkan semua skenario.

  2. Dapatkan kebutuhan2x, batasan2x, dan gambaran lingkungan.

  3. Gambarkan pola/gaya arsitektur yang telah dipilih untuk menangani skenario2x dan kebutuhan2x ::

  • module view
  • process view
  • data flow view

  4. Evaluasi kualitas atribut2x dengan melihat setiap atribut dalam isolasi.

  5. Kenali kualitas atribut untuk setiap atribut arsitektural untuk masing-masik gaya arsitektur yang spesifik.

  6. Lakukkan kritik pada arsitektur2x kandidat (yg dikembangkan pada langkah 3) menggunakan analisis pada langkah 5.

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

Metode Desain Arsitektur

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  "four bedrooms, three baths, lots of glass ..."

  customer requirements architectural design These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  Memperoleh Arsitektur Program Program Architecture These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Partisi Arsitektur

  Partisi

“horizontal” dan “vertical”

dibutuhkan

  

Partisi Horizontal

  Tentukan cabang yang terpisah pada hierarki modul untuk setiap fungsi utama 

Gunakan modul kontrol untuk koodinasi komunikasi antar fungsi2x

  function 3 function 1 These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided function 2

Partisi Vertikal : Factoring

   Didesain sehingga pengambilan keputusan dan pekerjaan distratifikasi

   Modul pengambilan keputusan tetap ada di puncak arsitektur decision-makers workers

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Mengapa Arsitektur Terpartisi?

  Hasilnya adalah PL yang mudah diuji 

  Membawa kepada PL yang lebih mudah dikelola 

  Hasilnya efek samping yang semakin sedikit 

  Hasilnya adalah PL yang lebih mudah dikembangkan

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Desain Terstruktur

  Tujuan : untuk mendapatkan arsitektur program yang terpartisi  pendekatan:

  

DFD dipetakan ke arsitektur program

   PSPEC dan STD digunakan untuk mengindikasikan setiap modul

   notasi: diagram struktur

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  Karakteristik Aliran Aliran Transformasi Aliran Transaksi

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

Pendekatan Pemetaan Umum

  Isolasi aliran ke dalam dan ke luar batasan; untuk aliran transaksi, isolasi Pusat transaksi Bekerja dari batasan luar, petakan Transformasi DFD ke modul terkait

Tambahkan modul kontrol jika dibutuhkan

Sempurnakan struktur program

Menggunakan konsep modularitas efektif

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

Pemetaan Transformasi

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  data flow model "Transform" mapping a b c d e

f g h i j x1 x2 x3 x4 b c a d e f g i

h j These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Factoring

typical "worker" modules typical "decision making" modules direction of increasing decision making

First Level Factoring

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  main program controller input controller processing controller output controller

  

Second Level Mapping

  main

  D C

  control

  A B A B C D mapping from the flow boundary outward

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Transaction Flow

incoming flow action path T

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Transaction Example

operator commands process operator commands fixture setting report robot control fixture servos display screen robot control software in reality, other commands would also be shown assembly record

Refining the Analysis Model

  write an English language processing narrative 1. for the level 01 flow model apply noun/verb parse to isolate processes, data

  2. items, store and entities develop level 02 and 03 flow models

  3. create corresponding data dictionary entries 4. refine flow models as appropriate 5.

  ... now, we're ready to begin design!

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  

Deriving Level 1

Processing narrative for " process operator commands"

  Process operator command software reads operator commands from the cell operator. An error message is displayed for invalid commands. The command type is determined for valid commands and appropriate action is taken. When fixture commands are encountered, fixture status is analyzed and a fixture setting is output to the fixture servos. When a report is selected, the assembly record file is read and a report is generated and displayed on the operator display screen. When robot control switches are selected, control values are sent to the robot control system.

  Processing narrative for " process operator commands"

  Process operator command software reads operator commands from the cell operator . An error message is displayed for invalid commands . The command type is determined for valid commands and appropriate action is taken . When fixture commands are encountered , fixture

  status is analyzed and a fixture setting is output to the fixture servos .

  When a report is selected , the assembly record file is read and a report is generated and displayed on the operator display screen . When robot control switches are selected , control value

  s are sent to the robot control system.

  noun-verb parse

Level 1 Data Flow Diagram

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  operator commands read operator commands determine command type analyze f ix ture status generate report send control value f ix ture servos display sc reen robot control sy stem Error msg as sembly record valid command f ix ture setting report robot control f ix ture select report control robot status

Level 2 Data Flow Diagram

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  read co mmand prod uce error msg va li da te co mmand de te rmi ne type read fixtu re sta tus de te rmi ne setti ng format setti ng read reco rd ca lcul ate ou tp ut va lu es format repo rt repo rt va lu es reco rd asse mbl y reco rd co mmand co mmand i nva li d co mmand sta tus error msg robo t co ntro l send co ntro l va lu e sta rt /sto p co mbi ned sta tus raw se tti ng fixtu re setti ng

  

Transaction Mapping Principles

isolate the incoming flow path define each of the action paths by looking for the "spokes of the wheel" assess the flow on each action path define the dispatch and control structure

map each action path flow individually

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

Transaction Mapping

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  data flow model a b t d e f g h i j k l m n

Mapping

  b a x1

t

x2 d e f

x3

g h x3.1 i j k x4 l m n

Isolate Flow Paths

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  read co mmand prod uce error msg va li da te co mmand de te rmi ne type read fixtu re sta tus de te rmi ne setti ng format setti ng read reco rd ca lcul ate ou tp ut va lu es format repo rt repo rt va lu es reco rd asse mbl y reco rd co mmand co mmand i nva li d co mmand sta tus error msg robo t co ntro l send co ntro l va lu e sta rt /sto p co mbi ned sta tus raw se tti ng fixtu re settin g

Map the Flow Model

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  process operator commands command input controller read command validate command produce error message determine type fixture status controller report generation controller send control value each of the action paths must be expanded further

Refining the Structure Chart

  These courseware materials are to be used in conjunction with Software Engineering: A Practitioner’s Approach, 6/e and are provided

  process operator commands command input controller read command validate command produce error message determine type send control value read fixture status determine setting format setting read record calculate output values format report fixture status controller report generation controller