Asterisk - The Open Source Telephony Project GIT-master-77d630f
serializer_shutdown_group.h
Go to the documentation of this file.
1/*
2 * Asterisk -- An open source telephony toolkit.
3 *
4 * Copyright (C) 2012-2013, Digium, Inc.
5 *
6 * Mark Michelson <mmmichelson@digium.com>
7 *
8 * See http://www.asterisk.org for more information about
9 * the Asterisk project. Please do not directly contact
10 * any of the maintainers of this project for assistance;
11 * the project provides a web site, mailing lists and IRC
12 * channels for your use.
13 *
14 * This program is free software, distributed under the terms of
15 * the GNU General Public License Version 2. See the LICENSE file
16 * at the top of the source tree.
17 */
18
19
20#ifndef _ASTERISK_SERIALIZER_SHUTDOWN_GROUP_H
21#define _ASTERISK_SERIALIZER_SHUTDOWN_GROUP_H
22
24
25/*!
26 * \brief Create a serializer group shutdown control object.
27 * \since 13.5.0
28 *
29 * \return ao2 object to control shutdown of a serializer group.
30 */
32
33/*!
34 * \brief Wait for the serializers in the group to shutdown with timeout.
35 * \since 13.5.0
36 *
37 * \param shutdown_group Group shutdown controller. (Returns 0 immediately if NULL)
38 * \param timeout Number of seconds to wait for the serializers in the group to shutdown.
39 * Zero if the timeout is disabled.
40 *
41 * \return Number of serializers that did not get shutdown within the timeout.
42 */
44
45/*!
46 * \brief Increment the number of serializer members in the group.
47 * \since 23.1.0
48 * \since 22.7.0
49 * \since 20.17.0
50 *
51 * \param shutdown_group Group shutdown controller.
52 */
54
55 /*!
56 * \brief Decrement the number of serializer members in the group.
57 * \since 23.1.0
58 * \since 22.7.0
59 * \since 20.17.0
60 *
61 * \param shutdown_group Group shutdown controller.
62 */
64
65#endif /* ASTERISK_SERIALIZER_SHUTDOWN_GROUP_H */
static struct ast_serializer_shutdown_group * shutdown_group
Shutdown group for options serializers.
void ast_serializer_shutdown_group_dec(struct ast_serializer_shutdown_group *shutdown_group)
Decrement the number of serializer members in the group.
void ast_serializer_shutdown_group_inc(struct ast_serializer_shutdown_group *shutdown_group)
Increment the number of serializer members in the group.
int ast_serializer_shutdown_group_join(struct ast_serializer_shutdown_group *shutdown_group, int timeout)
Wait for the serializers in the group to shutdown with timeout.
struct ast_serializer_shutdown_group * ast_serializer_shutdown_group_alloc(void)
Create a serializer group shutdown control object.