Kill specific terminal using shell/bash

Hello elite shell/bash specialists,

I have done plenty of STFW and some RTFM, but I cannot find a clear solution to my challenge

Goal:
My goal is to have a script(of any language, preferably shell/bash/anything that can run things on unix), which will kill specific unix terminal windows for me. Killing just the process itself does not satisfy my case requirements and nor does killing terminal on process end. Also running everything in one terminal is not the case.

Background:
I am working on a massive scale db-plugin tester. It spawns 2 new terminals per each db - one for db and one for app(app needs db specific settings) it's tested against. There is 35 dbs in the collection and therefore I am in danger of having 70 terminals hanging on my screen. The spawned terminals cannot automatically shutdown on process end - in case an error occurs and debugging will need to take place(those terminals contain vital logs). After my tester is done with one db and everything ends happily, it should proceed to the next db. It would be very useful if it could dispose of all the terminals that are no longer needed when it proceeds to the next db. In fact, I believe it is vital to be able to do it.

Details:
The command I use to spawn each new process looks like this:

gnome-terminal -x bash -c "sh app.sh; exec $SHELL"

Note there is plenty of shell commands before and after each spawn, i.e. init and cleanup operations

Any sort of clues is much appreciated. Also feel free to suggest any change in my design/code that could make my goal more realistic.

Thank you

@Update

Problem Solved!

Okay I finally have it figured out.

To all those with the same problem, look at

gnome-terminal --disable-factory

It spawns killable gnome-terminals with unique PIDs