← Volver al índice de módulos

janssonrpcc

This module provides access to JSON-RPC 2.0 services (operating over TCP/Netstrings) in accordance with http://www.jsonrpc.org/specification. It uses JANSSON library for JSON document management.
🛠️ Utilidades y Varios Kamailio 6.1 10 parámetros 4 funciones

Descripción general

This module provides access to JSON-RPC 2.0 services (operating over TCP/Netstrings) in accordance with http://www.jsonrpc.org/specification. It uses JANSSON library for JSON document management. It uses t_suspend() and t_continue() from the TM module for asynchronous processing. Note that after invoking an asynchronous operation, the processing will continue later, in another application process. Therefore, do not rely on variables stored in private memory, use shared memory if you want to get values after the processing is resumed (e.g., $shv(...) or htable $sht(...)).

Documentación oficial: https://www.kamailio.org/docs/modules/stable/modules/janssonrpcc.html
Código fuente: https://github.com/kamailio/kamailio/tree/master/src/modules/janssonrpcc

Parámetros de configuración

ParámetroTipoDescripción
min_srv_ttl integer 3.2. result_pv (string) 3.3. server (string) 3.4. retry_codes (string) 3.5. keep_alive (integer)
result_pv string 3.3. server (string) 3.4. retry_codes (string) 3.5. keep_alive (integer)
server string 3.4. retry_codes (string) 3.5. keep_alive (integer)
retry_codes string 3.5. keep_alive (integer)
keep_alive integer 3.1. min_srv_ttl (integer)
min_srv_ttl integer The minimum acceptable TTL in seconds for SRV DNS entries. This means that TTLs from the DNS will be ignored if they are lower than this value. It cannot be set lower than 1 second.
result_pv string The PV spec where to store the result of a call to janssonrpc_request(). It can be any writable PV.
server string The server providing the remote jsonrpc service. Format can be "conn=example;addr=localhost;port=9999;priority=10;weight=20" or "conn=bar;srv=_sip._tcp.example.net".
retry_codes string A comma delimited list of error codes or error code ranges to automatically schedule a request retry if received.
keep_alive integer number of seconds to send a tcp keep-alive to the server connection

Funciones exportadas

janssonrpc_notification(conn, method, parameters)

4.2. janssonrpc_request(conn, method, params[, options]])

janssonrpc_request(conn, method, params[, options]])

4.1. janssonrpc_notification(conn, method, parameters)

janssonrpc_notification(conn, method, parameters)

* conn - name for a collection of servers (required) * method - jsonrpc method (required) * params - jsonrpc request params (required) Use $null or empty string to not send any parameters in the jsonrpc notification.

janssonrpc_request(conn, method, params[, options]])

The conn, method, params, and options can be a static string or a dynamic string value with config variables.

Autores y contribuidores

Joe Hillenbrand <joe@flowroute.com>Matthew Williams <matthew@flowroute.com>

Copyright © 2013 Flowroute LLC (flowroute.com)

Módulos relacionados

auth_web3 auth_xkeys avp avpops benchmark blst call_control call_obj