user2738779
user2738779

Reputation: 11

Chat application in android without a server

Is it possible to create a chat application in android between two systems without implementing a server as a middle ware? I have created an application , and I want to make the chat possible between two different emulators on two different systems , I need some help guys ...!!!

Upvotes: 0

Views: 5148

Answers (3)

ashish0072
ashish0072

Reputation: 11

I guess there is a solution which may work.

You can use http://programminglife.io/android-http-server-with-nanohttpd/

NanoHttpd and if both mobile phone are in same network and they can ping each other there is a possibility that you can easily create an app which help to create the chat app peer to peer mobile.

Upvotes: 1

Marc Van Daele
Marc Van Daele

Reputation: 2734

XMPP is often used for Chat. It is typically used with a server but there also exists an extension XEP-0174 Serverless Messaging supporting chat without an intermediate server. I don't know whether there are Android libraries supporting this though.

An alternative could be to

  • use eg SSDP (or Bonjour(mDNS + DNS-SD)) for discovery of devices
  • write your own protocol on top of it

Upvotes: 1

cesztoszule
cesztoszule

Reputation: 306

Yes it is possible thats how I made my Phd project. When my application is started it asks the user to chose if it will be a "server" or client. And on the second phone it choses the other. But there is nothing in the middle of the communication.

Upvotes: 1

Related Questions