I have to integrate an existing javabased Framework (whith different components which communicate via SOAP) in my Android. Every Component needs to receive and send SOAP-Messages, needs to act as a Server.
Is it true that Android OS < 2.0 does not support Server functionalities? What would be the min. Version?
Which framework can i use? I only found a few kSOAP examples for the client side, but none for servers.
Thanks for every hint, link, idea... help:)
Fabi
You best bet would be to run e.g. jetty as a server on Android but I would seriously reconsider your architecture. Why do the devices need to act as server? Are they being contacted in a pull way by another device or server?
yeah you're right... reconsidering the architecture would be best. But i can't change the existing framework which comnponents i have to use.(yes, a pull way communication is implemented)
Thanks for your help. But i just decided to use the framework by implementing a polling-service. A lot of extra work... but it will do it:)
fabi
Related
I am looking to create a simple service to learn calling a service from android.
What I want to do is an app to call a system over the web provide some parameters and the system respond. Very simple (hopefully)
But I want to build both ends.. not just the android end.
What tools would the community recommend that are industry standard and hopefully easily accessible.
I am hoping TomCat can do the hosting, but don't know if this should be a JSP or EE application.
Can anyone point me to an email of setting this up, again with both sides.
Hopefully Tomcat is a decent enough server to be both easy to setup and robust enough if enough calls are made to it.
Once that is done then I only need to do the android portion with Ksoap or anything else that is recommended.
Thanks in advance and I hope this is not too general a question.
I recommend using Apache CXF for a server. It does pretty much everything that you need in a web service. It does have a client part, but so far, I have implemented web services on Android myself, rather than using libraries. But that was a while ago, maybe today libs are better customized for Android.
I have an android app, and I would like to allow my users to chat with each other.
Searching google, I found a tutorial on android socket programming, but it looks quite complicated and requires me to take care of the server side too.
Is there an easier solution that doesn't require me to basically write it all myself?
I would suggest using one of the free SDK like Scringo (www.scringo.com).
It is very easy to add - basically all you need is to call
Scringo.init(this);
at the end of your Activity's onCreate() method.
No need for server side programming at all.
Here's a screenshot of Scringo in action:
i would suggest using a WebView and using a node.js / now.js chat!
It's very simple to setup!
Another viable solution is to check xmpp protocol and asmack library . I gave it a try a while ago and managed to make it work with gtalk. You can also setup an xmpp server by yourself using their openfire server.
Still better than reinvent the wheel.
HeyHo,
which opportunities do I have to implement a client-server architecture for an android application. I simply want to transmit results from my database server to my application. I was researching on the internet and found different solutions but I ain't sure which one fits the best and is the simplest one:
- XML-RPC
- RESTlet
- REST + JSON
Maybe there is even a more simple way to do this and I haven't considered it yet.
Thanks for your helpful answers in advance
Cheers
Ei.Schinken
AFAIK, Rest+JSon is best option and simple to do and there are lot of references available for help.
Depends on yout server architecture, for example We have here a Mysql database with PHPmyadmin, so I'm using Json with PHP, and works fine for me.
I'm going to develope an application based on web services (axis2) and android (clients).
I'm now planning the logic architecture for my system and I supose that it should be like a SOA architecture. I have seen that a SOA architecture is based on layers.
So, this would be a "correct" logic architecture for my application? (with some changes of course)
http://geeks.ms/cfs-filesystemfile.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/unai/DDD_5F00_NLAYER_5F00_ARCHITECTURE_5F00_SMALL_5F00_6ADA95E1.png
Android code (activities) would be on Presentation Layer?
EDIT
April 2014
Now, 3 years later with some more experience... REST is the best :)
Warning, it may that this answer is not at all an answer to you question but anyway, here is my thoughts.
I'm definitely not a SOA specialist but since SOA can be implemented with REST, it should not have any consequences on a SOA architecture. Android is REST-ready (see that Google IO 2010 session on REST) and there is only little SOAP support on android (afaik, but I may be wrong).
At some point, you'll have to evaluate the feasibility of the interop. between your Axis WS-* with any existing android SOAP support (the well-known ksoap2 project for example). The result could be not without impact on your architecture design.
The point here is: if you do use Rampart to use WS-Security, for example, on top of Axis2, it seems to me there are little chances that ksoap may interact at all (technically) with your service provider. On the one hand, if the service is simple and can be bound with ksoap2, great, go on. On the other hand, if you would use a not so simple security or authentication scheme, it could just be a nightmare to get the things done with the simple SOAP support on android. In the latest case and as the REST approach seems to be the preferred philosophy on android, you may be confronted to the decision to have a REST proxy dedicated to android between your Axis2 business WS and the android client-side application.
In the hope it may be of any help.
Perhaps you could even try SOAP. Android supports SOAP web services and provides ksoap2 libraries which you can use for sending request and getting response from your server easily.
For starters just check this out. Now, the latest version of ksoap also supports passing of Object Arrays.
For more information of ksoap2, I suggest to read this
Cheers
All the best
I want to build a server that communicates with an android phone
based on a request/response model
At first i thought i will use Httpservlets and communicate with the android
by Http messages. but i need to be able to access a pretty big object with every
request so i guess i cant really transfer the object to the servlet.
so i know this is a pretty newbish question but iv'e been searching for days
what kind of java EE tech should i use(i thought of EJB but as i understand they cant communicate with android)?
Thanks in advance
I think the right question is how to implement service layer for your android application:
Basically there are two options REST based web services and SOAP. Android's support for SOAP is inadequate and I personally prefer REST over soap any day. If you have decided to go with REST, your options in Java are Jersey, RESTlets or Spring Rest services. I will prefer Jersey, but you can also look in to Spring ( although not strictly complaint with the JSR).
(note: look in "SO" for comparison on various rest based frameworks in Java)