• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

tarantool / tarantool / 8686452751
88%

Build:
DEFAULT BRANCH: master
Ran 15 Apr 2024 09:22AM UTC
Jobs 1
Files 513
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

15 Apr 2024 09:07AM UTC coverage: 87.051% (+0.02%) from 87.028%
8686452751

push

github

sergepetrenko
trigger: introduce persistent triggers

After this patch, functions with non-empty option `trigger` will be
inserted into the trigger registry. The option specifies event names in
which the function will be inserted as a trigger.

When a function is created, it is set as a trigger without any checks -
it can replace an existing one. When it is deleted, it can delete a
trigger it hasn't set - for example, it can happen when user manually
replaces a persistent trigger. So, it is recommended to have different
names (or even separate namespaces) for persistent and usual triggers.

Note that both persistent and non-persistent funcs can be used as
triggers. Also, when the triggers are called, access rights are
not checked.

Closes #8663

@TarantoolBot document
Title: Document `trigger` option of `box.schema.func.create`.

The new option `trigger` allows to create persistent triggers. The
option can be a string or an array of strings - name (or names) of the
event in which the trigger will be set.

Each function created with `box.schema.func.create` has its own tuple
in system space `_func`. When the tuple with non-empty field `trigger`
is inserted, the function is set to the events listed by this option
in the event registry, function name is used as a trigger name. When
such tuple is deleted from `_func`, the triggers are deleted.

When a function is created, it is set as a trigger without any checks -
it can replace an existing one. When it is deleted, it can delete a
trigger it hasn't set - for example, it can happen when user manually
replaces a persistent trigger. So, it is recommended to have different
names (or even separate namespaces) for persistent and usual triggers.

When a function is called as a trigger, access rights are ignored, so,
actually, every user that can trigger the event has access to your
function, but only as a trigger.

Since the space `_func` is not temporary, after Tarantool is restarted,
the persistent triggers will be set. Al... (continued)

67308 of 119785 branches covered (56.19%)

28 of 29 new or added lines in 1 file covered. (96.55%)

526 existing lines in 21 files now uncovered.

100028 of 114907 relevant lines covered (87.05%)

2442256.56 hits per line

Jobs
ID Job ID Ran Files Coverage
1 8686452751.1 15 Apr 2024 09:22AM UTC 0
87.05
GitHub Action Run
Source Files on build 8686452751
Detailed source file information is not available for this build.
  • Back to Repo
  • 4c81aba8 on github
  • Prev Build on master (#8663639615)
  • Next Build on master (#8688598910)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc