3194 Web Services Access from MIDP Devices - PowerPoint PPT Presentation

1 / 40
About This Presentation
Title:

3194 Web Services Access from MIDP Devices

Description:

3194. Web Services Access from MIDP Devices. Ken Sipe. Chief Instructor / TO. Code Mentor ... Learn details necessary in order to consume a web service from a ... – PowerPoint PPT presentation

Number of Views:83
Avg rating:3.0/5.0
Slides: 41
Provided by: kennethg9
Category:
Tags: midp | access | devices | services | sipe | web

less

Transcript and Presenter's Notes

Title: 3194 Web Services Access from MIDP Devices


1
3194Web Services Access from MIDP Devices
  • Ken Sipe
  • Chief Instructor / TO
  • Code Mentor

2
Overall Presentation Goal
Learn details necessary in order to consume a web
service from a wireless MIDP device. Understand
the current issues with the technology.
3
Speakers Qualifications
  • Sun Certified Java 2 Architect.
  • Instructor for Visibroker for Java
  • Rational OOAD Rose
  • Frequently speaks on the subject of distributed
    computing programming, including CORBA and EJB
    architecture.

4
WARNING!!!
  • Letter of the Law
  • Presentation has greatly change from what was
    advertised in the brochure
  • Spirit of the Law
  • Presentation provides the new and future
    approach to accomplish the goals of the session.

5
Presentation Agenda
  • MIDP
  • MIDP Connectivity
  • MIDP XML
  • Web Services
  • WSA
  • Demo

6
Whats not Covered
  • MIDP GUI Development
  • Security
  • Communication Topology
  • kSOAP
  • http//webservices.xml.com/pub/a/ws/2003/08/19/kso
    ap.html

7
MIDP
8
What is MIDP
  • MIDP Mobile Information Device Profile
  • A specification of a set of APIs for the Java
    platform used for writing portable applications
    on mobile devices.
  • Cell Phones
  • Pagers
  • PDAs

9
MIDP Architecture
10
Wireless Device Characteristics
  • Small displays
  • Limited keyboard
  • Limited memory
  • Slow processors
  • Limited battery life
  • Low bandwidth connectivity

11
Benefits of J2ME
  • Rich GUI
  • Multiple target support

12
J2ME Limitations
  • No RMI
  • No finalization
  • No reflection
  • Lacking XML parsers
  • Issue with size of parsers
  • Intermittent Communication

13
MIDP Connectivity
14
Connection Framework
15
HttpConnection
  • HttpConnection defines the necessary methods and
    constants for HTTP connection.
  • Connector.open("http//borland.com/webapp")

16
HTTP Get
  • Where c is a HTTPConection
  • c.setRequestMethod(HttpConnection.GET)

17
HTTP Post
  • Where c is a HTTPConection
  • c.setRequestMethod(HttpConnection.POST)

18
MIDP 2.0
  • HTTPS
  • The only addition to MIDP 2.0 for connectivity
    was the requirement to support HTTPS.

19
MIDP XML
20
J2ME XML Options
  • KXML
  • Kxml.org
  • SAX / DOM
  • NanoXML
  • Nanoxml.sourceforge.net/kvm.html
  • DOM

21
J2ME Web Service options of the past
  • HTTP Connectivity using kXML or nanoXML
  • Connectivity to Web Proxy for Web Service
    Consumption
  • kSOAP
  • - connectivity to SOAP proxy
  • - direct connectivity to the service

22
Web Services / SOAP
23
What are Web Services?
  • XML - Extensible Markup Language
  • SOAP - Simple Object Access Protocol
  • WSDL - Web Services Definition Language
  • UDDI - Universal Description, Discovery and
    Integration

Alphabet Soap
24
Governing Bodies
  • W3C World Wide Web Consortium
  • OASIS Organization for the Advancement of
    Structured Information Standards
  • WS-I Web Services Interoperability Organization

25
Web Services
26
SOAP Payload Structure
  • The body can be formatted either
  • RPC or
  • Document
  • Its parameters are formatted either
  • Encoded or
  • Literal

27
RPC Centric
  • Web services transmit objects as XML
  • Typically used with Encoded body.

28
Document Centric
  • Web services transmit XML documents. Applications
    on either end create and parse XML documents
  • Typically used with literal body.

29
Java / RPC vs. Doc
  • JAX-RPC is an RPC centric approach
  • JAXM is document centric
  • SAAJ is low-level document centric by default
  • Document centric is best when you are really
    dealing with documents newsfeeds for example
  • Doesnt make sense to change XML to objects back
    to XML again
  • Usually, you want to deal with objects, not XML
  • However
  • Business tends to think in documents (P.O.,
    Invoice)
  • Documents are more naturally coarse grained

30
WS Challenges
  • The building blocks are their, however almost
    immediately several camps chose different
    directions.
  • The Java / Axiss approach RPC
  • MS / .Nets Approach Document

31
WS-I Basic Profile
  • Provides Compatibility
  • Requires
  • HTTP binding for SOAP
  • HTTP posts
  • WSDL 1.1
  • Requires rpc/literal or document/literal

32
J2ME meets Web Services
33
The new TLA -- WSA
  • JSR 172 J2ME Web Services API (WSA)
  • Extends the J2ME platform to support web services
    through two features
  • Remote Service Invocation
  • XML parsing

34
WSA
  • Requires Conformance to WS-I Basic Profile.
  • Supports SOAP 1.1

35
WSA Doesnt Support
  • No SOAP Message Attachments
  • No Message Handlers
  • No libraries for service end points
  • No UDDI

36
WSA Architecture
37
WSA Libraries
  • Subset of JAXP
  • The JAXP is limited to SAX 2.0.  It supports
    UTF-8 and UTF-16, DTD and XML namespaces.  It
    doesnt support DOM, or XLST
  • Subset of JAX-RPC
  • Subset of RMI
  • There are 3 remote Exceptions necessary to
    satisfy the JAX-RPC dependencies.

38
J2ME WSA Demo
39
Questions?
40
Thank You
  • 3194
  • Web Services Access from MIDP Devices
  • Please fill out the speaker evaluation
  • You can contact me further at kensipe_at_codementor
    .net
Write a Comment
User Comments (0)
About PowerShow.com