You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by GitBox <gi...@apache.org> on 2020/08/17 09:00:41 UTC
[GitHub] [skywalking] tmacjx edited a comment on issue #5263: Python agent supports uwsgi
tmacjx edited a comment on issue #5263:
URL: https://github.com/apache/skywalking/issues/5263#issuecomment-674755440
```
from gevent import monkey
monkey.patch_all()
from skywalking import config, agent
config.service_name = 'consumer'
config.logging_level = 'DEBUG'
config.disable_plugins = 'sw_tornado'
config.init(collector='192.168.1.241:11800', service='app')
agent.start()
import requests
from flask import Flask, jsonify
app = Flask(__name__)
@app.route("/users", methods=["POST", "GET"])
def view():
requests.post("http://baidu.com")
return jsonify({"test": "hello world"})
```
thanks,you guys advice.
I think most import reason is sky-walking not support gevent mode.
When I comment gevent monkey patch_all, log show well, server start with port and report log well.
But when I use gevent mode, the server not start normal.
![a](https://user-images.githubusercontent.com/11555807/90377651-dde42500-e0aa-11ea-8745-f7464a30f78e.jpg)
![b](https://user-images.githubusercontent.com/11555807/90377660-e0df1580-e0aa-11ea-8c11-b87b14522247.jpg)
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org