(Microsoft PowerPoint - newPresentation [modalit\340 ...

651 views

Published on

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
651
On SlideShare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
5
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

(Microsoft PowerPoint - newPresentation [modalit\340 ...

  1. 1. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study tesi di laurea Developing Google Android Mobile Clients for Web Services: a Case Study Anno Accademico 2007/2008 relatore Ch.mo prof. Stefano Russo correlatore Ing. Marcello Cinque candidato Vito Daniele Cuccaro Matr. 885/83
  2. 2. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study Main issue Is the new Google Android platform mature for developing mobile clients for Web Services? Goal of the Thesis Evaluating the Android platform through a case study (porting of a J2ME client for accessing Wireless Sensor Networks). Contributions Pros and Cons of Android for WS mobile clients. Fitting and Testing of the KSOAP solution for WS on Android. Proposal of a new Android-specific design pattern (AVA) for Android- translating the popular MVC pattern.
  3. 3. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study Operational Model Background: Web Services The most common implementation of SOA Key benefits: Accessible by anyone, anywhere and from any device B2B and EAI support Dynamic location and invocation of services Core Standards Interoperability among XML and ebXML heterogeneous applications WSDL and UDDI Standard protocols and SOAP, SOAP, the de facto standard data exchange format for invoking Web Services
  4. 4. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study Background: Background: The Google Android Mobile Platform A software stack for mobile devices including OS, middleware and key applications Key features: Software Stack Developed within OHA Open source under Apache license Laying on a Linux 2.6 Kernel Applications written in Java Has its own APIs (as well as some of Java) Uses its own VM (Dalvik)
  5. 5. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study Developing an Android Application Application Lifecycle Main components: Toolbox: Activity Eclipse (or Service NetBeans) NetBeans) plugin Broadcast Receiver Full- Full-featured SDK Content Provider with Debug Monitor Device Emulator Other key concepts: Online Doc and Intent Support Intent Filter Notification Manifest XML- XML-defined GUI R.java
  6. 6. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study Android and Web Services: state of the art No native solutions available yet (SOAP APIs for WS invocation) KSOAP Main Developers’ proposals A popular open-source open- “Homemade” solution: mobile- mobile-oriented HTTP connection + SOAP implementation manual XML parsing (SAX) Basically a client library for invoking web services Tested on Java-based Java- kXML- kXML-RPC (lightweight solution) devices Now in version 2 KSOAP (1 is deprecated)
  7. 7. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study Case Study: the ICAAS framework for accessing WSN Software architecture for accessing Wireless Sensor Networks developed at Mobilab within the REMOAM project (by CINI and Strago s.r.l.) s.r.l.) The Architecture Non standard implementation of the OGC Sensor Web Enablement specifications Key features: Interoperable & Configurable Extensible Requests optimization (Caching and Filtering) ROA and SOA access
  8. 8. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study ICAAS Web Services ICAASMobile: a J2ME test client for SOA access: SOA access to ICAAS through WS Real Time monitoring of WSN Notification Service Session management Observation Service Tested with a WSN simulator Collection Service Alert Service Planning Service Technology note: Apache Axis (a Java-based SOAP Java- implementation) used for WS deployment
  9. 9. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study Case Study: Porting ICAASMobile from J2ME to Android A typical porting process Assessing Migration Feasibility 1. All functions of the original client are achievable on Android (doubts were raised about invoking Web Services) Understanding Initial Application 2. Reverse Engineering of ICAASMobile to get SRS and software architecture Deciding Target Development Tools 3. Eclipse with Android SDK plugin Validating Original Design Plan 4. Decision to keep the same architecture and code base Deciding about Porting Strategies 5. ++ approach: add one function at a time and make it work before going on
  10. 10. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study Invoking Web Services in Android: the KSOAP2 solution Advantages: Disadvantages: Reliable (tested on other Introduces overhead on mobile platforms) constrained devices Easy to use Some effort is needed to Facilitates porting (the port a client from KSOAP1 original application uses to KSOAP2 KSOAP1) Motivations for the choice: Implementation Reusing the original business Stub restructuring needed logic as much as possible The thread responsible for Relying on a widely tested solution WS invocation (through the stub) can be reused
  11. 11. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study Porting the MVC Pattern to Android: the AVA solution Model-View- Model-View-Controller Adapter-View- Adapter-View-Activity Separating GUI from Business Main issues: Logic and Data Access Android Views are not Java- Java- coded but xml-defined xml- Who is the Controller? Who is the Model? Answers Activity builds View from xml Activity acts as Controller Adapter plays Model’s role Contribution: a reusable design pattern for Android
  12. 12. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study DroidICAASMobile: a Conceptual Model KSOAP- KSOAP-based AVA- AVA-based GUI change dataset WS invocation change dataset creates Adapter Thread notifyDataSetChanged creates response creates user inputs View Activity Stub update response uses setContentView invokes builds Layout.xml Web user inputs --------- KSOAP Services -------
  13. 13. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study DroidICAASMobile: example of use
  14. 14. Facoltà di Ingegneria Corso di Studi in Ingegneria Informatica Developing Google Android Mobile Clients for Web Services: A Case Study Critical Considerations about the Android Experience Average learning curve (probably slightly steeper than J2ME) Advantages over other mobile platforms: xml-defined GUIs, xml- open philosophy and full portability (at least in principle) Conclusions The KSOAP solution for invoking WS is working on Android Porting from J2ME is possible reusing most of the code The AVA pattern is a good option for designing Android GUIs Future Works Improvement of the developed client (under both functional and graphic aspect) and testing on real Android devices Testing of other solutions for Web Services (e.g. kXML-RPC) kXML-

×