tarantool / tarantool/tarantool
Add action_timing to _trigger space
Nobody has claimed this yet.
- Dominant language
- Lua
- Stars
- 3.7k
- Forks
- 419
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 88
Description
This is due to a suggestion from Konstantin Osipov:
"
- a feature request to extend _trigger system space with trigger
timing - this should take a bit longer, yet we need to do it in
2.2.
"
The context was a mention of a column in information_schema.triggers
named ACTION_TIMING, which can be 'BEFORE' or 'AFTER' or 'INSTEAD OF'.
So add a field in the _trigger space containing one of those
values, depending on the way that CREATE TRIGGER was done.
I hope this feature request isn't due to a misunderstanding.
I mentioned that information_schema.triggers.ACTION_TIMING
can be hard to find by looking at the _trigger space.
But it is only one of several bits of information.
Therefore I suggested I would like a list of tokens.
That is, if I could say:
gimme_tokens([[box.execute([[create trigger before /* before */ After/before/INSERT ON t
FOR EACH ROW BEGIN DELETE FROM before; end;]])
then I could find ACTION_TIMING (which = 'AFTER' in this example),
and EVENT_MANIPULATION (= 'INSERT'), and EVENT_OBJECT_TABLE (= 'T').
For simulating information_schema, action_timing is not good enough.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the _trigger space and the CREATE TRIGGER handling described in the issue, then compare the available metadata with information_schema.triggers.ACTION_TIMING. Done means the _trigger space exposes whether each trigger was created as BEFORE, AFTER, or INSTEAD OF.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- lua
- Domain
- database
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100