November 11th

September 20, 2008

Web Service dengan SOAP - WSDL

Filed under: Opinion

Di hari libur ini, aku pengen menuliskan sedikit tentang konseptual dari web service (asline judul skripsiku sih :D ). Seperti kita ketahui, sudah banyak situs2 terkenal yang menggunakan teknologi web service. seperti : Google dengan API-nya, Amazon dengan Amazon Web Service-nya, dll. (He..He..He..Rada serius dikit).

Apa web service itu?
A Web service is a software system designed to support interoperable machine-to-machine interaction over a network. It has an interface described in a machine-processable format (specifically WSDL). Other systems interact with the Web service in a manner prescribed by its description using SOAP-messages, typically conveyed using HTTP with an XML serialization in conjunction with other Web-related standards. (detailnya : disini, akakakakaa….).

Dari definisi diatas, terdapat kata kunci “interaction” dimana memiliki maksud bahwa web service dapat meng-komunikasi berbagai software dari berbagai mesin maupun platform yang berbeda. Untuk dapat menjalankan fungsi tersebut, sebuah web service memerlukan agen. Agen adalah potongan software atau hardware yang mengirim dan menerima pesan (message). Agen tersebut dapat ditulis dengan berbagai bahasa pemrograman.

Web service ini didasarkan kepada protokol SOAP, WSDL, dan NuSOAP sebagai SOAP ekstension untuk PHP. Dengan ketiga tool ini, akan diperoleh suatu web service opensource yang dapat digabungkan dengan software opensource lain untuk membangun aplikasi berbasis web yang lengkap.

Ok…Kita pilah satu - persatu nih, biar sedikit tampak jelas :D .

SOAP (Simple Object Access Protocol)
SOAP adalah Lightweight XML-based protocol untuk mempertukarkan struktur informasi antar aplikasi terdistribusi melalui protokol-protokol native semacam HTTP.

Apa yang dilakukan SOAP?

  1. menentukan format XML,
  2. Cara data diproses,
  3. Menentukan aturan untuk mengenkode, untuk standar dan tipe data yang didefinisikan oleh aplikasi,
  4. Konvensi yang merepresentasikan remote procedure call, dan response.

Tiga bagian yang menyusun protokol SOAP,

  1. paket/amplop yang menggambarkan konten pesan dan bagaimana cara untuk menggunakannya,
  2. Sekumpulan aturan untuk serialisasi pertukaran data antar aplikasi,
  3. Prosedur yang merepresentasikan remote procedure call, yaitu, cara query dan respon ditampilkan,

WSDL (Web Service Definition Language)
WSDL adalah format XML untuk mendeskripsikan layanan network sebagai sekumpulan endpoint yang beroperasi pada pesan yang berisi informasi berorientasi dokumen, dan informasi berorientasi prosedur. WSDL diperluas supaya dapat menggambarkan endpoint serta pesannya dengan mengabaikan format pesan, protokol jaringan yang digunakan untuk berkomunikasi.

Arsitektur Web Service
Langkah yang dilakukan untuk mendefinisikan web service :

  1. Pemanggilan web browser yang membuat call procedure pada file WSDL dan klien layanan SOAP (SOAP Service Client),
  2. klien SOAP Service mengambil method dan parameter untuk membangun kontainer XML; kontainer ini dikirim melalui HTTP sebagai SOAP request,
  3. server SOAP Service menerima SOAP request; Soap_parser_class mengubah XML container dan menentukan method yang dipanggil serta parameter-parameter method ini,
  4. method kemudian dieksekusi pada server serta mengirimkan output,
  5. hasil/output kemudian dibungkus sebagai XML dan server mengirimkan XML result container sebagai respon untuk request POST oleh Soap_transport_http_class.
  6. client mengubah XML response container dan mengirimkan hasil ke aplikasi yang memanggilnya.
  7. aplikasi kemudian memproses hasil.

Seperti itulah sekilas tentang web service dengan SOAP dan WSDL. Mohon maap klo masih banyak kurangnya (sik newbie). Semoga bermanfaat..

September 12, 2008

XML is…

Filed under: Opinion

The Extensible Markup Language (XML) is a simple, platform-independent standard for describing data within a structured format. XML is not a language but instead a metalanguage that allows you to create markup languages. In layman’s terms, it allows data to be tagged using descriptive names so both humans and computer applications can understand the meaning of different pieces of data.

For example, reading the following structure, it is easy to understand what this data means :
<state>
<name>Maine</name>
<capitol>Augusta</capitol>
<animal>Moose</animal>
<bird>Chickadee</bird>
<tree>White Pine</tree>
</state>

The state capitol of Maine is Augusta. The state animal is the moose, the state bird is the chickadee, and the state tree is the white pine. Although no officially named standard markup language was used for this example, it is still a well-formed XML document. XML offers the freedom of defining your own language to describe your data as needed.

With these new languages, the number of applications (ranging from document publishing applications to distributed applications) and the number of people and businesses adopting XML continue to grow. One of the most visible XML-based technologies today is the Web service technology, where Web-based applications are able to communicate in a standardized, platform-neutral way over the Internet. As you may have guessed, this is a big reason why XML and Web serviceshave become buzzwords. With almost 30 years of history leading up to its creation, XML may just be what the original pioneers behind generalized markup envisioned.

Ehm…Just a little things from me :D






















Firman Faizal Rahman
are_u_ichank@yahoo.com