invalid cidr crahses pooled connection

Поиск
Список
Период
Сортировка
Искать

invalid cidr crahses pooled connection

От:
Mir Shafiqul Islam <mislam@corp.earthlink.net>
Дата:
Environment: JBoss 2.4.4 with tomcat
Connection to postgres established at jboss startup time via regular 
connection pooling.
Accessing db from ejb

I am facing a problem with a pooled connection to postgres being 
dropped. This happens when the user is trying to execute a query with 
and invalid CIDR address. I am pasting a similar query and error I am 
seeing jboss side.

[INFO,Default] Debug SELECT ip from ip_space where ip 
 >>='192.168.1.0/8'::cidr
[INFO,Default] SQLException: ERROR:  invalid CIDR value '192.168.1.0/8': 
has bits set to right of mask
[INFO,Default] SQLState:         null
[INFO,Default] VendorError:    0

After this nothing can be done with the same connection object. And 
since this is actually a pooled object once it is closed the ejb is 
pretty much useless until jboss is restarted. This happens only in the 
SQLException involving invalid cidr.

FAQ