Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Info

Example - Using APL function closePooledConnections

Code Block
languagetext
themeEclipse
persistent int profileUsageCnt; 
      .... 
      if ( profileUsageCnt > 100 ) { 
         closePooledConnections("sybase_iq.mydb"); 
         profileUsageCnt = 0; 
      }

...

Info

Example - Setting the maximum number of connections for Sybase IQ

Code Block
languagetextthemeEclipse
For Helm deployed ECs, in values.yaml add at:
systemProperties:
  - config.properties.sybase.iq.pool.maxlimit=20

For ECs deployed in Desktop Online, add:
EC Deployment, Execution Context, Configure EC: System Properties: Add -> 
config.properties.sybase.iq.pool.maxlimit=20 

Deploy the EC again either in Desktop Online or with:
$ kubectl delete pod <ec-pod> -n <namespace>

By default there is no timeout value defined for the socket tied to a database connection. This means that a running query could get stuck, in case the database suddenly becomes unreachable. To specify a timeout valueThere are two properties available for handling timeout of socket connections and socket threads:

sybase.jdbc.socketread.timeout with default value 180000 (3 minutes in milliseconds)

sybase.jdbc.socketconnect.timeout  with default value 30000 (30 seconds in milliseconds)

To specify other timeout values, in milliseconds, set the Execution Context property properties in the relevant <pico>.conf file.

Info

Example - Setting the timeout for a socket tied to a Sybase IQ connection

Code Block
$ mzsh topo set topo://container:<container>/pico:<pico name>/val:config.properties.sybase.jdbc.socketread

...

.timeout 600000 
$ mzsh topo set topo://container:<container>/pico:<pico name>/val:config.properties.sybase.jdbc.socketconnect.timeout 20000 
Info

Example - Setting the timeout for a socket tied to a Sybase IQ connection

Code Block
languagetextthemeEclipse
For Helm deployed ECs, in values.yaml add at:
systemProperties:
  - config.properties.sybase.jdbc.socketread.timeout=600000 
  - config.properties.sybase.jdbc.socketconnect.timeout=20000

For ECs deployed in Desktop Online, add in:
EC Deployment, Execution Context, Configure EC: System Properties: Add ->
config.properties.sybase.jdbc.socketread.timeout=600000 
config.properties.sybase.jdbc.socketconnect.timeout=20000

Deploy the EC again either in Desktop Online or with:
$ kubectl delete pod <ec-pod> -n <namespace

...