clkao / plv8js-migrated

Automatically exported from code.google.com/p/plv8js
Other
0 stars 0 forks source link

Protect Postgres from malformed PLV8 javascript - Feature request #103

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
We are looking to use PLV8 as a neat way to give web developers access to the 
back end system and workflow which is all coded in Postgres stored procedures. 
Javascript is ideal as we do not need to retrain them in other languages.

One feature request would be the ability to wrap a PLV8 function and prevent 
the database suffering in the instance of rogue javascript code for example:-

while (a > 0)  {
 a++;
}

Which will run forever.

Using statement_timeout at the client level does not work for us as it would 
affect all functions some of which are  allowed to run for a long time. Could 
this be done at the PLV8 level?

Original issue reported on code.google.com by Dave.Bar...@gmail.com on 15 Sep 2014 at 3:41