Efficient SOAP processing in embedded systems - PowerPoint PPT Presentation

1 / 28
About This Presentation
Title:

Efficient SOAP processing in embedded systems

Description:

Efficient SOAP processing in embedded systems. Jan Janecek. Czech ... Realtek RTL8019 Ethernet. Nut/OS - multi-threading kernel. Nut/Net - TCP/IP stack ... – PowerPoint PPT presentation

Number of Views:36
Avg rating:3.0/5.0
Slides: 29
Provided by: janja7
Category:

less

Transcript and Presenter's Notes

Title: Efficient SOAP processing in embedded systems


1
Efficient SOAP processing in embedded systems
  • Jan Janecek

2
Outline (i.e. what I will be speaking about)
  • Component oriented
  • objects having clearly defined interfaces
  • Distributed
  • component communicating over a standardised
    network
  • architecture (e.g. TCP/IP, but not limited
    to)
  • Embedded
  • able to work even on cheap, small memory
    footprint systems
  • Not restricted to the Client-Server model
  • support for servers functionality is
    emphasized
  • Real-time able
  • providing reasonable real-time behaviour,
  • not restricted to a specific real-time kernel

3
Small embedded servers HW (an example
what we want to support as servers)
Egnite Software GmbH, BRD HW Server, CZ
Charon II / EtherNut
Atmel ATMega128 128 kB Flash EPROM 32 kB
SRAM Realtek RTL8019 Ethernet Nut/OS -
multi-threading kernel Nut/Net - TCP/IP
stack simple HTTP server
4
Component Software
  • Older systems
  • DCE, D/COM
  • Java RMI, EJB
  • CORBA
  • Drawbacks
  • complicated integration across platforms
  • complicated integration across vendors
  • programmer attention to internal mechanics
    assumed
  • (IDL, marshalling, data format)

5
SOAP (Web Services)
  • Requirements
  • - interoperability across platforms,
    vendors, languages
  • - readable/textual format of data
  • - wide spectrum of communication schemata
  • Standards
  • UDDI - Universal Description Discovery and
    Integration
  • DISCO - Discovery
  • WSDL - Web Service Description Language
  • SOAP - Simple Object Access Protocol
  • XML - eXtended Mark-up Language

6
Classical Web Service
interface logic
(lightweight) CLIENTs
(very) heavy SERVER
stub
interface logic
application logic
stub
interface logic
request
stub
stub
response
web server environment (ASP.NET/IIS,
Axis/Tomcat/Apache)
browser environment (IE, NS, ...)
7
SOAP Simple Object Access Protocol
data encoding
communication protocols
application protocol
application vocabulary
SOAP
SOAP
HTTP
XML Schema
TCP
XML Namespaces
IP
XML
Ethernet
Unicode
8
SOAP Simple Object Access Protocol
SOAP Request
lt?xml version"1.0" encoding"UTF-8"
standalone"no" ?gt ltSOAP-ENVEnvelope
SOAP-ENVencodingStyle"http//schemas.xmlsoap.org
/soap/encoding/" xmlnsSOAP-ENV"http//schema
s.xmlsoap.org/soap/envelope/"
xmlnsSOAP-ENC"http//schemas.xmlsoap.org/soap/en
coding/" xmlnsxsi"http//www.w3.org/1999/XML
Schema-instance" xmlnsxsd"http//www.w3.org/
1999/XMLSchema"gt ltSOAP-ENVBodygt
ltns1doubleAnInteger xmlnsns1"urnMySoapServices
"gt ltparam1 xsitype"xsdint"gt123lt/param
1gt lt/ns1doubleAnIntegergt
lt/SOAP-ENVBodygt lt/SOAP-ENVEnvelopegt
9
SOAP Simple Object Access Protocol
SOAP Response
lt?xml version"1.0" encoding"UTF-8" ?gt
ltSOAP-ENVEnvelope xmlnsSOAP-ENV"http//sche
mas.xmlsoap.org/soap/envelope/"
xmlnsxsi"http//www.w3.org/1999/XMLSchema-instan
ce" xmlnsxsd"http//www.w3.org/1999/XMLSchem
a"gt ltSOAP-ENVBodygt
ltns1doubleAnIntegerResponse
xmlnsns1"urnMySoapServices"
SOAP-ENVencodingStyle"http//schemas.xmlsoap.org
/soap/encoding/"gt ltreturn
xsitype"xsdint"gt246lt/returngt
lt/ns1doubleAnIntegerResponsegt
lt/SOAP-ENVBodygt lt/SOAP-ENVEnvelopegt
10
WSDL Web Service Description Language
  • lt?xml version1.0 encodingutf-8gt
  • ltdefinitionsgt
  • lttypesgt describes SOAP parameters types
  • lt\typesgt
  • ltmessagegt describes structure of SOAP
    messages
  • lt\messagegt
  • ltportTypegt defines method invocations
  • lt\portTypegt (binds requests and
    responses)
  • ltbindinggt defines encoding of SOAP
    messages
  • lt\bindinggt
  • ltservicegt defines binding to communication
    stack
  • lt\servicegt
  • lt\definitionsgt

11
WSDL Web Service Description Language
  • ltservice namehelloWorldPortgt
  • ltdocumentgt
  • textual service description
  • lt/documentgt
  • ltport namehelloWorldPort
    namehelloWorldSoap /gt
  • ltsoapaddress locationhttp//127.0.0.15
    555/ /gt
  • lt/portgt
  • lt\servicegt

12
Classical Web Service
  • Server
  • 1. server application logic in Java (or C,
    if you prefer)
  • 2. (compilation) and generating WSDL
    description
  • 2. deployment in a suitable web server (MS
    IIS, GNU Axis)
  • 3. registering WSDL description by UDDI
    service
  • (or a related html page)
  • Client
  • 1. getting WSDL description (WSDL2Java/Axis,
    WSDL/.Net)
  • 2. creating SOAP proxy
  • 3. client application logic in Java (or C )
  • 4. running the client in a suitable
    environment

13
Classical Web Service
lightweight CLIENT
application source (server)
(very) heavy SERVER
Java,C
Apache/Tomcat, IIS
src/bytecode/cli
wsdl
soap
Axis, ASP.NET
UDDI
wsdl
WSDL
14
Classical x Embedded Web Service
  • Challenge
  • use of SOAP communication for sensors /
    controllers
  • Classical service schema requirements /
    properties
  • heavyweight server support
  • slow SOAP parsing (generic DOM/SAX XML
    parser)
  • high flexibility
  • Small servers limitation / requirements
  • small memory footprint, restricted
    communication stack
  • limited number of statically deployed
    application
  • real-time abilities

15
Embedded Web Service
lightweight CLIENTs
lightweight SERVERs
interface logic
application logic
stub
stub
interface logic
application logic
request
stub
stub
response
web server environment (RT kernel, configurable
OS)
browser environment (IE, NS, ...)
16
Embedded Web Service
  • Server
  • 1. server application interface in Java (or
    C )
  • 2. generating WSDL description
  • 3. generating glue logic (C) from the WSDL
    description
  • 4. server application logic (C), compilation
  • 5. registering WSDL description by UDDI
    service
  • Client
  • - identical to the classical web service

17
Embedded Web Service
application interface (server)
(lightweight) CLIENT
Java, C
wsdl
lightweight SERVER
wsdl
soap
application logic
wsdl
UDDI
glue logic
C
TCP/HTTP/UDP
WSDL
glue logic (server)
C
18
XML Grammars
Tags - terminal symbols of XML grammar
Rules
19
XML Grammars
Nodes nonterminal symbols of XML grammar
Rules
20
XML Grammars
Basic WSDL / SOAP analyser structure
m
b
n
b
b
m
a
b
a
m
e
a
21
Current HW Support
Charon II / EtherNut
Egnite Software GmbH, BRD HW Server, CZ
Atmel ATMega128 128 kB Flash EPROM 32 kB
SRAM Realtek RTL8019 Ethernet Nut/OS -
multithreading kernel Nut/Net - TCP/IP
stack simple HTTP server
22
Example Multi-channel sensor - server code
Namespace Sensor_ns public class Sample
public int Channel public
long Value public long Time . . .
. . public class Sensor
System.Web.Services.WebService Sample
storage new SamplestSize . . . . .
WebMethod public void SetSample (Channel
val) . . . . .
Sensor
Initialize ()
GetSample ()
SetSample ()
GetAll ()
23
Example Multi-channel sensor - message
lt?xml version"1.0" encoding"utf-8"?gt ltsoapEnvel
ope attributes / namespace definitions gt
ltsoapBody attributes / namespace definitions
gt ltSetSamplegt ltvalgt
ltChannelgt 7 lt/Channelgt
ltValuegt 12 ltValuegt ltTimegt 1768
lt/Timegt lt/valgt lt/SetSamplegt
ltsoapBodygt ltsoapEnvelopegt
24
Example Multi-channel sensor - grammar
1 R r integer-value r 2 CH ch
channel-number ch 3 V v measure-value
v 4 T t time-stamp t 5 S s R
s 6 AS as R as 7 I i CR
i 8 G g g 9 P p S p 10 A a
a 11 R C V T 12 R S
a
as
a
as
25
Example Multi-channel sensor - grammar
SOAP automaton description
interface definition
data types definitions
application code
system support
TCP/IP
RT kernel
Ethernet
26
Example Multi-channel sensor - grammar
include mchs.h struct Sample
int Channel long Time
long Value . . . . .
mchs_g.h (type definitions, )
include mchs_g.h void Initialize(int Channel,
long Range) struct Sample GetSample() void
SetSample(struct Sample) struct Sample GetAll()

mchs.cpp (interface)
27
Thanks for your attention . . .Questions ?
  • janecek_at_cs.felk.cvut.cz

28
Some notes
  • Experience
  • CORBA - mOA (Object Adaptor) Atmel
  • Java RMI - effectiveness of RMI communication
  • SOAP - tiny SOAP servers (Microsoft
    Research)
  • Goals for the research
  • decreasing the SOAP link to
  • - unicast and connection-oriented TCP
  • binding SOAP communication to wireless
  • - Bluetooth, IEEE 802.11b/g, UWB (wireless
    USB)
Write a Comment
User Comments (0)
About PowerShow.com