[Freeswitch-dev] Freeswitch and Google PUSH (C2DM)

Nacho leucaruth at gmail.com
Sun Jul 10 18:12:36 MSD 2011


I just noticed short before you answered :).

I have been reading it and I found it very interesting, but I have found a
problem in Java.

The constructor for an Outbound connection requires the File Descriptor (an
Int parameter) of the listening socket to create the ESL object, but as far
as I know, Java doesn't allow to get the int value of a File Descriptor from
a Socket. This would be veary easy to achieve in C, but I have no found any
means to get this to work with Java in Linux (Windows is out of the
question).

I tried to see the source code of the ESL client to see how it uses the int
value, but as I suspected is C code wrapped with SWIG. I have thought about
other ways to work with it, like using the FileDescriptor class in java and
Reflection, but I have not found any way to get the desired int value, so
i'm stuck about what to do right now.

Any ideas? if the constructor requires the int value of the File Descriptor
means that there is a way to get it, doesn't it?

Regards,

Jose

2011/7/7 Kristian Kielhofner <kris at kriskinc.com>

> http://wiki.freeswitch.org/wiki/Event_Socket_Library
>
> On Thu, Jul 7, 2011 at 7:35 AM, Nacho <leucaruth at gmail.com> wrote:
> > Hi again
> > Im doing as Kristian suggested, at first is an easier solution that
> making a
> > module.
> > I created a plan that redirects calls to a local port where I will do the
> > testings with the server that will work with that call.
> > The call is parked and the connection is stablished as I can see with
> > netcat, so I was thinking about making a program with C or Java that will
> > become the custom server. The problem is that I don't find info about the
> > structure of the packages I'll receive from Freeswitch, how to deal with
> > them or even how can I send orders to freeswitch.
> > Any suggestions about where I could find some info about it would be
> kindly
> > appreciated.
> > Regards,
> > Jose.
> > 2011/7/6 Robert-iPhone <rhuddleston at gmail.com>
> >>
> >> I have interest too! Considering mwi / voicemail push for apple
> >>
> >> Sent from my iPhone
> >>
> >> On Jul 5, 2011, at 5:49 PM, Anthony Minessale
> >> <anthony.minessale at gmail.com> wrote:
> >>
> >> > it can be left out of FS code but still part of contrib if an external
> >> > solution is developed.
> >> >
> >> >
> >> > On Tue, Jul 5, 2011 at 1:20 PM, Kristian Kielhofner <
> kris at kriskinc.com>
> >> > wrote:
> >> >> Jose,
> >> >>
> >> >>  Whether it's C2DM or APNS (Apple) this functionality is best left
> >> >> out of FreeSWITCH.  FreeSWITCH has plenty of other existing means
> >> >> (XML_CURL, socket, etc) to drive dynamic call functionality and
> >> >> interact with other technologies.
> >> >>
> >> >>  How do you ask?  An imcoming call to FreeSWITCH could hit static
> >> >> dialplan and execute a socket connection to some other custom server.
> >> >> This server could tell FreeSWITCH to do something (play media,
> >> >> ringback, messages, whatever) while it sends a PUSH (via C2DM or
> APNS,
> >> >> for example).
> >> >>
> >> >>  One could implement such a socket program easily.  It can be
> >> >> extended and maintained separately as new push technologies become
> >> >> available.
> >> >>
> >> >> On Mon, Jul 4, 2011 at 7:48 AM, Nacho <leucaruth at gmail.com> wrote:
> >> >>> Hello all.
> >> >>> My name is Jose. This is my first post here. I joined the list
> because
> >> >>> I was
> >> >>> wondering about developing a feature for Freeswitch and I would like
> >> >>> to know
> >> >>> your opinion.
> >> >>> The idea is about making a non-persistent client for cell phones
> that
> >> >>> works
> >> >>> with PUSH technology (C2DM and Android for example). These clients
> >> >>> wouldn't
> >> >>> be connected to the Freeswitch server at first, but if there is an
> >> >>> incoming
> >> >>> call, the Freeswitch server would send a PUSH message to these
> >> >>> clients, the
> >> >>> client would process it and, if accepted by the user, the client
> would
> >> >>> awake, connect to Freeswitch and then receive the the call invite
> >> >>> message
> >> >>> and accept it automatically.
> >> >>> I don't know if this idea is plausible due to the real time
> >> >>> restrictions we
> >> >>> have to face in phone calls. If the delay introduced by C2DM
> delivery
> >> >>> is
> >> >>> high, the waiting time for the caller is probably something that he
> >> >>> isn't
> >> >>> willing to accept in order to get his call answered.
> >> >>> Another question is about the battery life time it would save
> because
> >> >>> the
> >> >>> application woulnd't need to be answering the "still alive" ACKS
> from
> >> >>> Freeswitch.
> >> >>> I'm new in freeswitch developing and still learning about it, but
> I'm
> >> >>> really
> >> >>> interested in this, so any help would be kindly appreciated.
> >> >>> --
> >> >>> Aquellos que hablan son esclavos de sus palabras y los que callan
> >> >>> dueños de
> >> >>> su silencio.
> >> >>>
> >> >>> _______________________________________________
> >> >>> Join us at ClueCon 2011, Aug 9-11, Chicago
> >> >>> http://www.cluecon.com 877-7-4ACLUE
> >> >>>
> >> >>> FreeSWITCH-dev mailing list
> >> >>> FreeSWITCH-dev at lists.freeswitch.org
> >> >>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev
> >> >>> UNSUBSCRIBE:
> http://lists.freeswitch.org/mailman/options/freeswitch-dev
> >> >>> http://www.freeswitch.org
> >> >>>
> >> >>>
> >> >>
> >> >>
> >> >>
> >> >> --
> >> >> Kristian Kielhofner
> >> >>
> >> >> _______________________________________________
> >> >> Join us at ClueCon 2011, Aug 9-11, Chicago
> >> >> http://www.cluecon.com 877-7-4ACLUE
> >> >>
> >> >> FreeSWITCH-dev mailing list
> >> >> FreeSWITCH-dev at lists.freeswitch.org
> >> >> http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev
> >> >> UNSUBSCRIBE:
> http://lists.freeswitch.org/mailman/options/freeswitch-dev
> >> >> http://www.freeswitch.org
> >> >>
> >> >
> >> >
> >> >
> >> > --
> >> > Anthony Minessale II
> >> >
> >> > FreeSWITCH http://www.freeswitch.org/
> >> > ClueCon http://www.cluecon.com/
> >> > Twitter: http://twitter.com/FreeSWITCH_wire
> >> >
> >> > AIM: anthm
> >> > MSN:anthony_minessale at hotmail.com
> >> > GTALK/JABBER/PAYPAL:anthony.minessale at gmail.com
> >> > IRC: irc.freenode.net #freeswitch
> >> >
> >> > FreeSWITCH Developer Conference
> >> > sip:888 at conference.freeswitch.org
> >> > googletalk:conf+888 at conference.freeswitch.org
> >> > pstn:+19193869900
> >> >
> >> > _______________________________________________
> >> > Join us at ClueCon 2011, Aug 9-11, Chicago
> >> > http://www.cluecon.com 877-7-4ACLUE
> >> >
> >> > FreeSWITCH-dev mailing list
> >> > FreeSWITCH-dev at lists.freeswitch.org
> >> > http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev
> >> > UNSUBSCRIBE:
> http://lists.freeswitch.org/mailman/options/freeswitch-dev
> >> > http://www.freeswitch.org
> >>
> >> _______________________________________________
> >> Join us at ClueCon 2011, Aug 9-11, Chicago
> >> http://www.cluecon.com 877-7-4ACLUE
> >>
> >> FreeSWITCH-dev mailing list
> >> FreeSWITCH-dev at lists.freeswitch.org
> >> http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev
> >> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev
> >> http://www.freeswitch.org
> >
> >
> >
> > --
> > Aquellos que hablan son esclavos de sus palabras y los que callan dueños
> de
> > su silencio.
> >
> > _______________________________________________
> > Join us at ClueCon 2011, Aug 9-11, Chicago
> > http://www.cluecon.com 877-7-4ACLUE
> >
> > FreeSWITCH-dev mailing list
> > FreeSWITCH-dev at lists.freeswitch.org
> > http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev
> > UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev
> > http://www.freeswitch.org
> >
> >
>
>
>
> --
> Kristian Kielhofner
>
> _______________________________________________
> Join us at ClueCon 2011, Aug 9-11, Chicago
> http://www.cluecon.com 877-7-4ACLUE
>
> FreeSWITCH-dev mailing list
> FreeSWITCH-dev at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev
> http://www.freeswitch.org
>



-- 
Aquellos que hablan son esclavos de sus palabras y los que callan dueños de
su silencio.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-dev/attachments/20110710/00ab1349/attachment-0001.html 


More information about the FreeSWITCH-dev mailing list