Jan Willamowius wrote:
> Thats pretty much what I roughly had in mind.
>
> But now for extra credit: ;-)
> Right now you only return the preferred gateway IP. You should modify
> your SQL to return the other gateway IPs in the next rows so the call
> will failover to those when the preferred gateway isn't available.
Isn't it doing that already?
mysql> select * from routes;
+-------------+--------+-------+-------------+--------+---------+
| gatewayip | prefix | route | destination | called | calling |
+-------------+--------+-------+-------------+--------+---------+
| 10.244.22.5 | NULL | NULL | NULL | NULL | 21 |
| 10.244.22.5 | NULL | NULL | NULL | NULL | 22 |
| 10.244.2.5 | NULL | NULL | NULL | NULL | 31 |
| 10.244.22.5 | NULL | NULL | NULL | NULL | 31 |
+-------------+--------+-------+-------------+--------+---------+
4 rows in set (0.00 sec)
mysql> select gatewayip from routes where calling="31";
+-------------+
| gatewayip |
+-------------+
| 10.244.2.5 |
| 10.244.22.5 |
+-------------+
2 rows in set (0.00 sec)
And then in the log I see:
2009/10/08 10:42:23.809 5 gksql.cxx(388) SqlPolicy
Executing query: SELECT gatewayip from routes where c
alling=left('310339',2)
2009/10/08 10:42:23.809 5 Routing.cxx(1654) SqlPolicy
Query result : 10.244.2.5
2009/10/08 10:42:23.809 5 Routing.cxx(1674) SqlPolicy
Result cont'd: 10.244.22.5
If I read the docs correctly, wouldn't it automatically try 10.244.22.5 if
10.244.2.5 isn't available?
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________________
Posting: mailto:[email protected]
Archive:
http://sourceforge.net/mailarchive/forum.php?forum_name=openh323gk-users
Unsubscribe: http://lists.sourceforge.net/lists/listinfo/openh323gk-users
Homepage: http://www.gnugk.org/