<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"><base href="x-msg://13/"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>10 nov 2013 kl. 21:33 skrev Allen Zhang <<a href="mailto:Allen.Zhang@imgtec.com">Allen.Zhang@imgtec.com</a>>:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div lang="EN-NZ" link="blue" vlink="purple" style="font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div class="WordSection1" style="page: WordSection1; "><div style="margin: 0cm 0cm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; ">Hi all,<o:p></o:p></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><o:p> </o:p></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; ">This is a re-post. My email didn’t seem to get on the list last time.<o:p></o:p></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><o:p> </o:p></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; ">Is there a function I can use to test database connection from the routing script in the cfg file?<o:p></o:p></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; ">My dispatcher uses OPTIONS probing. When the destination receives the OPTIONS request, I’d like to detect the health status of the database connection before sending a reply back.<o:p></o:p></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; ">Note the OPTIONS request doesn’t have a user part in the RURI. Hence, is_subscriber() and alias_db_lookup() don’t work.<o:p></o:p></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><o:p> </o:p></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; ">Any suggestion?<o:p></o:p></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><o:p> </o:p></div></div></div></blockquote>I wrote such a function as an extension to the db API at some point. Your mail reminds me that I should find that code and commit it to trunk.</div><div>It was implemented in the generic API and in the MySQL driver.</div><div><br></div><div>/O</div></body></html>