Unable to terminate process started from PLV8 function - Mailing list pgsql-general

From Mukesh Chhatani
Subject Unable to terminate process started from PLV8 function
Date
Msg-id CACnmOYJ4RNMWCafGgv=6C9oE+bpMZxMHAADFKoRmoBiA_Rr3rg@mail.gmail.com
Whole thread Raw
List pgsql-general
Hello Team,

We are trying to use PLV8 function to calculate the histograms and while testing the function
we found that with some of the data, function was going into the infinite loop.

We tried to kill the session using pg_terminate_backend(pid) but process could not get killed,
we terminated the process using kill pid still no luck , then we tried , kill -9 PID and it terminated postmaster also and restarted the database.

Below is the sample function to reproduce the infinite loop

CREATE FUNCTION test_infinite () returns void as $$  while (true) {(new Date).toISOString(); } $$ LANGUAGE plv8 IMMUTABLE STRICT;;

Please let me know if someone has ever noticed this or is this the expected behavior with PLV8 extension or do I have to report the issue to PLV8 or V8 groups.

Thanks for your help in advance.

Regards,
Mukesh

pgsql-general by date:

Previous
From: Łukasz Jarych
Date:
Subject: Using GIT to caught delta between database versions
Next
From: Adrian Klaver
Date:
Subject: Re: Using GIT to caught delta between database versions