This is an automated email from the ASF dual-hosted git repository. kezhenxu94 pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/skywalking.git
The following commit(s) were added to refs/heads/master by this push: new edd8305 Check http protocol in Python agent as well (#4805) edd8305 is described below commit edd8305fa289cb9d1d9cdbe66920f0fc9e5257d3 Author: kezhenxu94 <kezhenx...@apache.org> AuthorDate: Sat May 23 16:05:13 2020 +0800 Check http protocol in Python agent as well (#4805) --- test/e2e/e2e-test/docker/python/Dockerfile.python | 2 +- test/e2e/e2e-test/docker/python/consumer.py | 2 ++ test/e2e/e2e-test/docker/python/provider.py | 7 ++++--- test/e2e/e2e-test/src/test/resources/expected/python/topo.yml | 9 --------- 4 files changed, 7 insertions(+), 13 deletions(-) diff --git a/test/e2e/e2e-test/docker/python/Dockerfile.python b/test/e2e/e2e-test/docker/python/Dockerfile.python index 9db46fb..6a0e4f9 100644 --- a/test/e2e/e2e-test/docker/python/Dockerfile.python +++ b/test/e2e/e2e-test/docker/python/Dockerfile.python @@ -15,7 +15,7 @@ FROM python:3.7 -ENV COMMIT_HASH=445d64c162555a3ff92b98e8ccec3cdc1a66876d +ENV COMMIT_HASH=1bfced8e967fb4a74f9ac2eabe3a9d01efab3d94 WORKDIR /app diff --git a/test/e2e/e2e-test/docker/python/consumer.py b/test/e2e/e2e-test/docker/python/consumer.py index a4cf711..67a7be4 100644 --- a/test/e2e/e2e-test/docker/python/consumer.py +++ b/test/e2e/e2e-test/docker/python/consumer.py @@ -23,6 +23,8 @@ from skywalking import agent, config if __name__ == '__main__': config.service_name = 'consumer' config.logging_level = 'DEBUG' + config.protocol = 'http' + config.collector_address = 'http://oap:12800' agent.start() import socketserver diff --git a/test/e2e/e2e-test/docker/python/provider.py b/test/e2e/e2e-test/docker/python/provider.py index 87561ee..16d2fd5 100644 --- a/test/e2e/e2e-test/docker/python/provider.py +++ b/test/e2e/e2e-test/docker/python/provider.py @@ -15,6 +15,8 @@ # limitations under the License. # +import time + from urllib import request from skywalking import agent, config @@ -30,12 +32,11 @@ if __name__ == '__main__': class SimpleHTTPRequestHandler(BaseHTTPRequestHandler): def do_POST(self): + time.sleep(0.5) self.send_response(200) self.send_header('Content-Type', 'application/json') self.end_headers() - req = request.Request('https://github.com/kezhenxu94') - with request.urlopen(req): - self.wfile.write('{"name": "whatever"}'.encode('ascii')) + self.wfile.write('{"name": "whatever"}'.encode('ascii')) PORT = 9091 Handler = SimpleHTTPRequestHandler diff --git a/test/e2e/e2e-test/src/test/resources/expected/python/topo.yml b/test/e2e/e2e-test/src/test/resources/expected/python/topo.yml index 56ebcb6..efdea72 100644 --- a/test/e2e/e2e-test/src/test/resources/expected/python/topo.yml +++ b/test/e2e/e2e-test/src/test/resources/expected/python/topo.yml @@ -30,10 +30,6 @@ nodes: name: Your_ApplicationName type: Tomcat isReal: true - - id: not null - name: github.com - type: Unknown - isReal: false calls: - id: not null source: ${User[0]} @@ -52,8 +48,3 @@ calls: - CLIENT - SERVER target: ${provider[0]} - - id: not null - source: ${provider[0]} - detectPoints: - - CLIENT - target: ${github.com[0]}