Author Topic: Setup Wizard - AsteriskRealtime PostgreSQL  (Read 5542 times)

bauair

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
    • View Profile
Setup Wizard - AsteriskRealtime PostgreSQL
« on: September 15, 2010, 16:04:15 »
Hi Everyone,
I've got PostgreSQL on my Asterisk host and i'm trying to get the configuration from my DB with the Setup Wizard and the AsteriskRealtime mode.

I installed the JDBC Version for PostgreSQL and changed the configuration.properties   

default.autoconf.realtimedrv=org.postgresql.Driver
default.autoconf.realtimeuri=jdbc:postgresql://192.168.0.6/asterisk?zeroDateTimeBehavior=convertToNull&jdbcCompliantTruncation=false&user=test&password=testpw

My queuemetrics host connects succesfully to the asterisk host, but i get an exception

Code: [Select]
Errore DB: org.postgresql.util.PSQLException:Fetch size must be a value greater to or equal to 0.
I write a java application to test it. it works fine
   
     
Code: [Select]
Statement st = connection.createStatement();
st.setFetchSize(10);
ResultSet rs = st.executeQuery("SELECT * FROM ast_phone");
        while (rs.next()) {
       System.out.println("   a row was returned.   ");
         }
       rs.close();

but if i  change st.setFetchSize(-1)
     
 
Code: [Select]
Statement st = connection.createStatement();
st.setFetchSize(-1);
ResultSet rs = st.executeQuery("SELECT * FROM ast_phone");
        while (rs.next()) {
       System.out.println("   a row was returned.   ");
         }
       rs.close();

i've got exatly the exeption.

My questions are now:
can i fix it?
how can i fix it?
is that an error of my postgresql configuration?
is it possible to connect to a postgresql asterisk host with queuemetrics?

Thank you and regards,
Bauair

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Setup Wizard - AsteriskRealtime PostgreSQL
« Reply #1 on: September 16, 2010, 09:45:55 »
We do not support Postgres as a back-end, so I fear there would be many a case where QM fails.
You should be using a MySQL instance for the back-end.

 

bauair

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
    • View Profile
Re: Setup Wizard - AsteriskRealtime PostgreSQL
« Reply #2 on: September 17, 2010, 16:11:42 »
Thank you for fast anwser.
I've got another Question, is it possible to configure queuemetrics with the manager interface with an external asterisk server?
where can i change the options for the "Single Mashine AMI"  to connect on the AMI?

Greets Bauair
« Last Edit: September 17, 2010, 16:15:12 by bauair »

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Setup Wizard - AsteriskRealtime PostgreSQL
« Reply #3 on: September 21, 2010, 10:06:42 »
Yes absolutely - see:

Code: [Select]
callfile.dir=tcp:login:passw@10.10.3.27

Thanks

bauair

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
    • View Profile
Re: Setup Wizard - AsteriskRealtime PostgreSQL
« Reply #4 on: September 22, 2010, 15:44:19 »
Thank you again,
it works well but only for the queues, is that possible to configure the agents like the queues?

Greetings
BauAir

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Setup Wizard - AsteriskRealtime PostgreSQL
« Reply #5 on: September 23, 2010, 10:47:11 »
? Not sure I understand? You mean auto-config?

bauair

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
    • View Profile
Re: Setup Wizard - AsteriskRealtime PostgreSQL
« Reply #6 on: September 24, 2010, 09:03:55 »
Yes,
if i choose "Single Mashine" at the AutoConfig, queuemetrics generate the queues from my asterisk host, but only the queues. is it possible that QM configure the agents too?
Greets Bauair

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Setup Wizard - AsteriskRealtime PostgreSQL
« Reply #7 on: September 27, 2010, 09:35:12 »
It should understand the agents as well - how do you set them up? because if you set up using e.g. ADDMEMBER there is no way for QM to guess who could they be.