pike.git / lib / modules / Sql.pmod / pgsql.pike

version» Context lines:

pike.git/lib/modules/Sql.pmod/pgsql.pike:174:   //! Specifies the database to connect to. Not specifying this is   //! only supported if the PostgreSQL backend has a default database   //! configured. If you do not want to connect to any live database,   //! you can use @expr{"template1"@}.   //!   //! @param options   //! Currently supports at least the following:   //! @mapping   //! @member int "reconnect"   //! Set it to zero to disable automatic reconnects upon losing - //! the connection to the database + //! the connection to the database. Not setting it, or setting + //! it to one, will cause one timed reconnect to take place. + //! Setting it to -1 will cause the system to try and reconnect + //! indefinitely   //! @member int "use_ssl"   //! If the database supports and allows SSL connections, the session   //! will be SSL encrypted, if not, the connection will fallback   //! to plain unencrypted   //! @member int "force_ssl"   //! If the database supports and allows SSL connections, the session   //! will be SSL encrypted, if not, the connection will abort   //! @member int "text_query"   //! Send queries to and retrieve results from the database using text   //! instead of the, generally more efficient, default native binary method.
pike.git/lib/modules/Sql.pmod/pgsql.pike:597:    return MARKSTART+query+MARKEND;    return MARKSTART+(k>1?query[..k-2]:"")+MARKERROR+query[k-1..]+MARKEND;   }      private void phasedreconnect()   { if(!connectionclosed)    { connectionclosed=1;    if(!reconnect(1))    { sleep(RECONNECTDELAY);    if(!reconnect(1)) -  { sleep(RECONNECTBACKOFF); -  reconnect(1); +  { do sleep(RECONNECTBACKOFF); +  while(!reconnect(1) && options->reconnect==-1);    }    }    }   }      final int _decodemsg(void|state waitforstate)   {   #ifdef DEBUG    { array line;   #ifdef DEBUGMORE