当前位置:网站首页>mod_ WSGI + pymssql path SQL server seat
mod_ WSGI + pymssql path SQL server seat
2022-07-06 19:50:00 【Full stack programmer webmaster】
Hello everyone , I meet you again , I'm the king of the whole stack .
by pymssql access SQL Server moment , directly python Implementation without problems . by mod_wsgi and Apache When deployed . All requests are found hang Then query the database .
adopt google Found the answer , thank google, Please refer to :https://code.google.com/p/modwsgi/wiki/ApplicationIssues#Python_Simplified_GIL_State_API
Briefly ,mod_wsgi For each virtual host and app mount point Create a sub interpreter.python There is a famous GIL, Through C extension Visit GIL State when , There is only the first sub interpreter To work properly , Suppose you use the possible sub interpreter May cause deadlock or crash, because pymssql It's a C extension So there will be this problem , The solution is . Add configuration items :
WSGIApplicationGroup %{GLOBAL}
Force this app Use the first one sub interpreter, bring GIL Normal work . After finishing ,mod_wsgi everything ok.
Copyright notice : This article is an original blog article , Blog , Without consent , Shall not be reproduced .
Publisher : Full stack programmer stack length , Reprint please indicate the source :https://javaforall.cn/117139.html Link to the original text :https://javaforall.cn
边栏推荐
- 121. The best time to buy and sell stocks
- 力扣101题:对称二叉树
- [infrastructure] deployment and configuration of Flink / Flink CDC (MySQL / es)
- 学习探索-函数防抖
- Transformer model (pytorch code explanation)
- Vmware虚拟机无法打开内核设备“\\.\Global\vmx86“的解决方法
- 社招面试心得,2022最新Android高频精选面试题分享
- Alibaba data source Druid visual monitoring configuration
- 2022年6月语音合成(TTS)和语音识别(ASR)论文月报
- redisson bug分析
猜你喜欢
MySQL information schema learning (I) -- general table
Classic 100 questions of algorithm interview, the latest career planning of Android programmers
深入浅出,面试突击版
腾讯T4架构师,android面试基础
Analysis of rainwater connection
系统性详解Redis操作Hash类型数据(带源码分析及测试结果)
企业精益管理体系介绍
如何自定义动漫头像?这6个免费精品在线卡通头像生成器,看一眼就怦然心动!
Introduction to enterprise lean management system
Microservice architecture debate between radical technologists vs Project conservatives
随机推荐
方法关键字Deprecated,ExternalProcName,Final,ForceGenerate
【翻译】供应链安全项目in-toto移至CNCF孵化器
redisson bug分析
Cesium 点击绘制圆形(动态绘制圆形)
【计算情与思】扫地僧、打字员、信息恐慌与奥本海默
腾讯字节等大厂面试真题汇总,网易架构师深入讲解Android开发
Web开发小妙招:巧用ThreadLocal规避层层传值
Example of shutter text component
句号压缩过滤器
学习探索-函数防抖
部门树递归实现
Social recruitment interview experience, 2022 latest Android high-frequency selected interview questions sharing
beegfs高可用模式探讨
CF960G - Bandit Blues(第一类斯特林数+OGF)
Application of clock wheel in RPC
Introduction to enterprise lean management system
ZABBIX proxy server and ZABBIX SNMP monitoring
腾讯字节阿里小米京东大厂Offer拿到手软,老师讲的真棒
From spark csc. csr_ Matrix generate adjacency matrix
HDU 1026 search pruning problem within the labyrinth of Ignatius and the prince I