Need help to execute the example ruby on rails

10 views
Skip to first unread message

velusamy

unread,
Jun 29, 2010, 5:59:24 AM6/29/10
to Liverpie Support
Dear All,
I have installed the liverpie and created the application in
rails. I have changed the necessary IP and port details in
liverpie.yml. But I have got the following error in development log
while testing the example application.

ActionController::UnknownAction (No action responded to say_welcome):

Where I made mistake? Please help me...

Regards,
Velusamy.

alexand...@gmail.com

unread,
Jun 29, 2010, 6:16:56 AM6/29/10
to Liverpie Support
Hi Velusamy,

You need to have a method called say_welcome in the controller that
responds to Liverpie. Please make sure that you do.

Alex

velusamy Krishnan

unread,
Jun 29, 2010, 6:32:21 AM6/29/10
to liverpie...@googlegroups.com
Dear Alex,
    I have found the problem in rails application that say_welcome method has been defined under 'private' access specifiers. But it called without object. So I have defined under the public access modifiers and tested. It worked fine.
   Thanks for you help...

Regards,
Velusamy

--
You received this message because you are subscribed to the Google Groups "Liverpie Support" group.
To post to this group, send email to liverpie...@googlegroups.com.
To unsubscribe from this group, send email to liverpie-suppo...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/liverpie-support?hl=en.


alexand...@gmail.com

unread,
Jun 29, 2010, 6:35:55 AM6/29/10
to Liverpie Support
Hi Velusamy,

There is a reason why that method was private. The reason is that any
state machine should have only one public method (well, in my case, 2
if you also count the reset method. Well, 3 if you also count and use
the DTMF signaller.)

So that public method should be the one that changes the state of the
application and calls, in turns, private methods like say_welcome. In
my Rails example, that method is called state_machine. That's the one
that Liverpie should be calling.

Alex

On Jun 29, 1:32 pm, velusamy Krishnan <velu.techni...@gmail.com>
wrote:
> Dear Alex,
>     I have found the problem in rails application that say_welcome method
> has been defined under 'private' access specifiers. But it called without
> object. So I have defined under the public access modifiers and tested. It
> worked fine.
>    Thanks for you help...
>
> Regards,
> Velusamy
>
> On Tue, Jun 29, 2010 at 3:46 PM, a...@indigenious.ro <
>
> alexandru.d...@gmail.com> wrote:
> > Hi Velusamy,
>
> > You need to have a method called say_welcome in the controller that
> > responds to Liverpie. Please make sure that you do.
>
> >  Alex
>
> > On Jun 29, 12:59 pm, velusamy <velu.techni...@gmail.com> wrote:
> > > Dear All,
> > >       I have installed the liverpie and created the application in
> > > rails. I have changed the necessary IP and port details in
> > > liverpie.yml. But I have got the following error in development log
> > > while testing the example application.
>
> > > ActionController::UnknownAction (No action responded to say_welcome):
>
> > >       Where I made mistake? Please help me...
>
> > > Regards,
> > > Velusamy.
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Liverpie Support" group.
> > To post to this group, send email to liverpie...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > liverpie-suppo...@googlegroups.com<liverpie-support%2Bunsu...@googlegroups.com>
> > .

velusamy Krishnan

unread,
Jun 30, 2010, 3:19:47 AM6/30/10
to liverpie...@googlegroups.com
Dear Alex,
    I have problem after commenting private in that rails application, that is welcome message played in the loop. If I used the private method. Then It said the following error in development log.

          ActionController::UnknownAction (No action responded to say_welcome):
   I couldn't fix this problem. Please help me...

Regards,
Velusamy.

To unsubscribe from this group, send email to liverpie-suppo...@googlegroups.com.

Alex Deva

unread,
Jun 30, 2010, 3:26:21 AM6/30/10
to liverpie...@googlegroups.com
Hi there,

Could you please paste the content of your liverpie configuration file here? Alternatively you can write me directly at al...@indigenious.ro but maybe this is useful for other people as well.

  Alex

velusamy Krishnan

unread,
Jun 30, 2010, 3:35:36 AM6/30/10
to liverpie...@googlegroups.com
Dear Alex,
     The following things in the liverpie.yml file.
---
configuration:
  # bind_ip, bind_port - where to start the local server. In Freeswitch, this must reflect in your dialplan:
  # <action application="socket" data="ENTER_LIVERPIE_IP_HERE:ENTER_LIVERPIE_PORT_HERE async full />"
  bind_ip: 0.0.0.0
  bind_port: 8084
  #
  # Configure each separate IVR application below. The id of the application needs to be sent from Freeswitch as a channel variable like so:
  # <action application="set" data="liverpie_webapp_id=my_webapp />"
webapps:
  my_webapp:
    # webapp_ip, webapp_port - where your webapp is
    ip: 192.168.1.222
    port: 8010
    # the URI to call the state machine:
    state_machine_uri: '/ivr/say_welcome'
    # the URI to reset the state machine:
    reset_uri: '/ivr/reset'
    # the URI to call when a DTMF pops up (optional):
    dtmf_uri: '/ivr/dtmf'
  conference:
    ip: 192.168.1.222
    port: 8010
    state_machine_uri: '/ivr/state_machine'
    reset_uri: '/ivr/reset'
    dtmf_uri: '/ivr/dtmf'

Thanks,
Velusamy.

Alex Deva

unread,
Jun 30, 2010, 3:39:51 AM6/30/10
to liverpie...@googlegroups.com
Hi Velusamy,

There's your problem right there. As you can see in the "my_webapp" section, the state_machine_url points to /ivr/say_welcome. That means that this URL will be called everytime Freeswitch has something to pass to your application; and as a result, all you'll ever hear is the welcome message.

To correctly use the state machine application, you should call the state machine method: '/ivr/state_machine' just like in the second example in the configuration.

In my Rails example, that method will then, in turn, call each private method as the state of the application changes.

If you have another implementation of state machines that you're more familiar with, you can very well try to use that.

In fact, if you do use another state machine implementation, I'd appreciate some sample code to post to the Liverpie website to your credit.

velusamy Krishnan

unread,
Jun 30, 2010, 3:49:03 AM6/30/10
to liverpie...@googlegroups.com
Dear Alex,
      Thank you very much. I have corrected configurations. Currently I am not familiar with rails applications. Definitely  I will  post some example after I experimented some new things in liverpie.

Thanks,
Velusamy.
Reply all
Reply to author
Forward
0 new messages