Module: kamailio
Branch: master
Commit: 03356132aef31a35b94bd47b4146cbce3e1c4ce9
URL: https://github.com/kamailio/kamailio/commit/03356132aef31a35b94bd47b4146cbc…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2022-11-29T09:33:24+01:00
app_python3: Makefile - extend python3-config lookup
---
Modified: src/modules/app_python3/Makefile
---
Diff: https://github.com/kamailio/kamailio/commit/03356132aef31a35b94bd47b4146cbc…
Patch: https://github.com/kamailio/kamailio/commit/03356132aef31a35b94bd47b4146cbc…
---
diff --git a/src/modules/app_python3/Makefile b/src/modules/app_python3/Makefile
index b3c1e8760b..c357ebc09e 100644
--- a/src/modules/app_python3/Makefile
+++ b/src/modules/app_python3/Makefile
@@ -1,4 +1,4 @@
-#
+#
# WARNING: do not run this directly, it should be run by the main Makefile
include ../../Makefile.defs
@@ -6,21 +6,34 @@ auto_gen=
NAME=app_python3.so
# If you have multiple Python versions installed make sure to modify the
-# the following to point to the correct instance. Module has been tested
-# to work with 2.6 and 2.5. Python 2.4 has been only confirmed to compile,
-# but no testing has been done with that.
-PYTHON3?=python3
+# the following to point to the correct instance.
+PYTHON3?=$(shell which python3)
+ifeq ($(PYTHON3),)
+PYTHON3=python
+endif
+
+PYTHON3CONFIG=$(shell which ${PYTHON3}-config)
+ifeq ($(PYTHON3CONFIG),)
+python_version_full := $(wordlist 2,4,$(subst ., ,$(shell ${PYTHON3} --version 2>&1)))
+python_version_major := $(word 1,${python_version_full})
+python_version_minor := $(word 2,${python_version_full})
+PYTHON3 = python${python_version_major}.${python_version_minor}
+PYTHON3CONFIG=$(shell which ${PYTHON3}-config)
+ifeq ($(PYTHON3CONFIG),)
+PYTHON3CONFIG=${PYTHON3}-config
+endif
+endif
LIBS=${shell \
- tmp_py3_libs=$$(${PYTHON3}-config --ldflags --embed 2>/dev/null) || \
- tmp_py3_libs=$$(${PYTHON3}-config --ldflags); \
+ tmp_py3_libs=$$(${PYTHON3CONFIG} --ldflags --embed 2>/dev/null) || \
+ tmp_py3_libs=$$(${PYTHON3CONFIG} --ldflags); \
echo $$tmp_py3_libs}
ifeq ($(OS), freebsd)
LIBS+=-pthread
endif
-DEFS+=${shell ${PYTHON3}-config --includes}
+DEFS+=${shell ${PYTHON3CONFIG} --includes}
include ../../Makefile.modules
Hello!
We needed some commands in rtpengine module to be asynchronous that is offer, answer and delete. I needed help for this.
Firstly, I went through the evapi module to understand how asynchronous commands were implemented by suspending request/responses and then by continuing. But I couldn't see anywhere where the suspended commands were being continued.
Thank you.
Hey!
I've raised a PR<https://github.com/kamailio/kamailio/pull/3286> against the master. It has passed all the build checks successfully. I'm looking forward to someone's code review.
Thank you.
________________________________
From: Henning Westerholt <hw(a)gilawa.com>
Sent: Monday, November 28, 2022 3:09:20 PM
To: Aditya Gupta <aditya.gupta(a)alumni.iiit.ac.in>; Kamailio (SER) - Development Mailing List <sr-dev(a)lists.kamailio.org>
Subject: RE: Make some commands in kamailio rtpengine module asynchronous
Hello,
as mentioned, there are people using rtpengine with larger installations (like some racks of rtpengine).
But we are of course always open for improvements of our code base. ??
If there are some changes that are needed in rtpengine daemon code as well, it probably needs to be raised in their issue tracker later on. But for this topic, they need to comment on that.
Regarding pull-requests for Kamailio, they should be done against development (master) branch in github. After creating the PR somebody of our developer team will have a look and review it. Usually there are some comments or adaptions necessary before merging the code into your repository.
Looking forward to your PR,
Henning
--
Henning Westerholt – https://skalatan.de/blog/
Kamailio services – https://gilawa.com<https://gilawa.com/>
From: Aditya Gupta <aditya.gupta(a)alumni.iiit.ac.in>
Sent: Monday, November 28, 2022 10:15 AM
To: Henning Westerholt <hw(a)gilawa.com>; Kamailio (SER) - Development Mailing List <sr-dev(a)lists.kamailio.org>
Subject: Re: Make some commands in kamailio rtpengine module asynchronous
We have 2 rtpengines in production and thousands of calls coming in. Few of them get timed out because they don't get processed in time by rtpengine. Simply by making 3 commands; offer, answer and delete. It can help us a lot with this.
I think I've understood what needs to be done and, in a day, or two I'll raise a PR with the changes for rtpengine module.
After that I guess there are some changes that needs to be done in sipwise/rtpengine media servers which seems complicated at this point.
I'm hoping for your support in improving my PR for now. Against which branch should I raise my PR??
Thank you
________________________________
From: Henning Westerholt <hw(a)gilawa.com<mailto:hw@gilawa.com>>
Sent: Monday, November 28, 2022 1:47:00 PM
To: Kamailio (SER) - Development Mailing List <sr-dev(a)lists.kamailio.org<mailto:sr-dev@lists.kamailio.org>>
Cc: Aditya Gupta <aditya.gupta(a)alumni.iiit.ac.in<mailto:aditya.gupta@alumni.iiit.ac.in>>
Subject: RE: Make some commands in kamailio rtpengine module asynchronous
Hello,
what is the motivation behind this? Are you seeing performance issues in a production environment that could not solved e.g., by adding some more rtpengine resources?
Regarding implementation, you could also have a look for example at the http_async_client module, which might be a bit more easy to understand regarding the async implementation in Kamailio.
Cheers,
Henning
--
Henning Westerholt – https://skalatan.de/blog/
Kamailio services – https://gilawa.com<https://gilawa.com/>
From: sr-dev <sr-dev-bounces(a)lists.kamailio.org<mailto:sr-dev-bounces@lists.kamailio.org>> On Behalf Of Aditya Gupta
Sent: Thursday, November 24, 2022 2:47 PM
To: sr-dev(a)lists.kamailio.org<mailto:sr-dev@lists.kamailio.org>
Subject: [sr-dev] Make some commands in kamailio rtpengine module asynchronous
Hello!
We needed some commands in rtpengine module to be asynchronous that is offer, answer and delete. I needed help for this.
Firstly, I went through the evapi module to understand how asynchronous commands were implemented by suspending request/responses and then by continuing. But I couldn't see anywhere where the suspended commands were being continued.
Thank you.
The accounting module seems to inserts random data into reason header fields, see attached screenshot.
This was observed after an upgrade to Kamailio 5.5.4 from an 5.4.9. I did a quick review of the changes between both branches, and the commit c5f6ff37f61f99e0 seems to be touching this functionality.
It might be some missing initialization for the locally generated replies reason phrase.
![grafik](https://user-images.githubusercontent.com/6481937/204288275-9e937539-c242-43fa-babd-f098a3542940.png)
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3287
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/3287(a)github.com>