Thursday, 2014-09-11

*** sandywalsh has quit IRC01:31
*** tkuhlman has quit IRC04:00
*** krtaylor has joined #openstack-monasca04:11
*** kuhlmant has joined #openstack-monasca04:21
*** sandywalsh has joined #openstack-monasca12:56
openstackgerritlitong01 proposed a change to stackforge/monasca-api: initial python implementation  https://review.openstack.org/12078813:45
*** tongli has joined #openstack-monasca14:08
*** dschroeder has joined #openstack-monasca14:56
*** garyh has joined #openstack-monasca15:01
*** cindyo has joined #openstack-monasca15:01
*** rbak has joined #openstack-monasca15:10
openstackgerritDeklan Dieterly proposed a change to stackforge/monasca-api: Refactor serie name decoder  https://review.openstack.org/12081215:24
openstackgerritDeklan Dieterly proposed a change to stackforge/monasca-api: Refactor serie name decoder  https://review.openstack.org/12081215:57
*** rhochmuth has joined #openstack-monasca15:58
openstackgerritA change was merged to stackforge/monasca-ui: Pass threshold to drilldown script in grafana  https://review.openstack.org/12026816:30
cindyo@tongli I’m trying to run your code that hasn’t been checked in - I think it is older than the review code.  Is this the right syntax to use for gunicorn?  I get a connection error.16:51
cindyoDEBUG (http:113) curl -i -X POST -H 'X-Auth-User: mini-mon' -H 'X-Auth-Token: 2f490a76cef9431ea1a747b2a8011278' -H 'X-Auth-Key: password' -H 'Accept: application/json' -H 'User-Agent: python-monascaclient' -H 'Content-Type: application/json' -d '{"timestamp": 1410454025.554345, "name": "tong1", "value": 1.2}' http://localhost:9090/v2.0/metrics16:51
cindyoINFO (connectionpool:180) Starting new HTTP connection (1): localhost16:51
cindyoTraceback (most recent call last):16:51
cindyo  File "/Library/Frameworks/Python.framework/Versions/2.7/bin/monasca", line 10, in <module>16:51
cindyo    sys.exit(main())16:51
cindyo  File "/Users/cindy/stackforge/python-monascaclient/monascaclient/shell.py", line 426, in main16:51
cindyo    MonascaShell().main(args)16:52
cindyo  File "/Users/cindy/stackforge/python-monascaclient/monascaclient/shell.py", line 381, in main16:52
cindyo    args.func(client, args)16:52
cindyo  File "/Users/cindy/stackforge/python-monascaclient/monascaclient/v2_0/shell.py", line 61, in do_metric_create16:52
cindyo    mc.metrics.create(**fields)16:52
cindyo  File "/Users/cindy/stackforge/python-monascaclient/monascaclient/v2_0/metrics.py", line 45, in create16:52
cindyo    headers=newheaders)16:52
cindyo  File "/Users/cindy/stackforge/python-monascaclient/monascaclient/common/http.py", line 232, in json_request16:52
cindyo    resp = self._http_request(url, method, **kwargs)16:52
cindyo  File "/Users/cindy/stackforge/python-monascaclient/monascaclient/common/http.py", line 171, in _http_request16:52
cindyo    **kwargs)16:52
cindyo  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests/api.py", line 44, in request16:52
cindyo    return session.request(method=method, url=url, **kwargs)16:52
cindyo  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests/sessions.py", line 456, in request16:52
cindyo    resp = self.send(prep, **send_kwargs)16:52
cindyo  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests/sessions.py", line 559, in send16:52
cindyo    r = adapter.send(request, **kwargs)16:52
cindyo  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests/adapters.py", line 375, in send16:52
cindyo    raise ConnectionError(e, request=request)16:52
cindyorequests.exceptions.ConnectionError: HTTPConnectionPool(host='localhost', port=9090): Max retries exceeded with url: /v2.0/metrics (Caused by <class 'socket.error'>: [Errno 61] Connection refused)16:52
cindyolooks like gunicorn is not starting with the command that you recommend, it exits right away without an error17:16
openstackgerritRob Raymond proposed a change to stackforge/monasca-ui: Change detail panel to take over screen  https://review.openstack.org/12085317:40
*** openstackgerrit has quit IRC17:46
*** openstackgerrit has joined #openstack-monasca17:47
*** mikedillion has joined #openstack-monasca18:27
*** mikedillion has quit IRC18:30
tongli@cindyo, sorry, did not see your message.19:01
tongliare you still trying it or you have moved on?19:02
cindyotongli: I wasn’t able to get the gunicorn to startup correctly.   using your code and readme from here: https://github.com/litong01/python-monasca-api19:06
tonglipossibly errors might be, you are using a mismatch falcon.19:06
tongliprobably use the latest code from the monasca-api repository?19:07
tonglithat code requires falcon 0.1.8, I think that the latest is 0.1.9 which I have made changes in the latest code.19:07
cindyoI don’t think that code is merged yet into monasca-api, I’ll wait for that, I think Roland is reviewing, but I was hoping to test and see that I can start it up19:09
*** rhochmuth has quit IRC19:18
cindyotongli: i can fetch your changes with git!  I’ll try the latest19:24
tongli@cindyo, even if it is not merged, you can still get it and run it.19:25
cindyoyep just got it19:25
*** rhochmuth has joined #openstack-monasca19:31
rhochmuthI was running the python monasca-api. Currently, the message format that is used for publishing metrics to the Kafka queue doesn't match what we've done for the java api.19:32
rhochmuthSo, none of the messages are processed by the rest of the MOnasca pipeline19:32
rhochmuthThe python api just publishes the JSON request body to Kafka as is. FOr example,19:33
rhochmuth{19:33
rhochmuth  "name": "name1",19:33
rhochmuth  "dimensions": {19:33
rhochmuth    "key1": "value1",19:33
rhochmuth    "key2": "value2"19:33
rhochmuth  },19:33
rhochmuth  "timestamp": 1405647317,19:33
rhochmuth  "value": 1.019:33
rhochmuth}19:33
rhochmuthWhat is expected right now is the following:19:33
rhochmuth"metric":{"name":"cpu.system_perc","dimensions":{"service":"monitoring","hostname":"mini-mon"},"timestamp":1410459127,"value":2.56},"meta":{"tenantId":"3c1f6223f44d42c0b88623e75ed3c996","region":"useast"},"creation_time":1410459131}19:33
rhochmuthOne of the bigger design issues is that I was expecting to see the major resources, such as metrics, measurements, statistics, alarms and notification-methods to be in separate class files, simlar to what we've done in the Java implementation.19:36
rhochmuthFor example, the code for processing POST metrics is in …/monasca/dispatcher/kafka_queue.py. THis seems like a pretty strange place to be putting that.19:37
rhochmuthWe should have a class MetricsResource that accepts the KafkaDispatcher in the constructor.19:42
cindyotongli: ^^19:44
cindyorhochmuth: to track this you better put it in the review comments19:44
cindyoi agree on the desire for separate resource classes19:45
cindyoand passing the kafka dispatcher into them19:45
rhochmuthagree.19:46
rhochmuthI imagine that there could be a base class called DIspatcher so that other dispatchers could be easily substituted, such as RabbitMQ19:46
cindyotongli: ugh a stevedore problem multiple drivers found. RuntimeError: Multiple 'monasca.dispatcher' drivers found: monasca.dispatcher.kafka_queue:KafkaDispatcher,monasca.dispatcher.kafka_queue:KafkaDispatcher20:00
cindyothis worked, the old one had the same driver name: sudo pip uninstall monasca-api-server20:13
cindyotongli: the kafka driver wasn’t working for me, so I did a sudo pip uninstall monasca-api and then another sudo python setup.py install.  Now I have the multiple driver error again.  How do you cleanup stevedore drivers?20:42
*** tongli has quit IRC21:12
openstackgerritDeklan Dieterly proposed a change to stackforge/monasca-api: Refactor serie name decoder  https://review.openstack.org/12081222:32
*** openstackgerrit has quit IRC22:38
*** openstackgerrit_ has joined #openstack-monasca22:38
*** openstackgerrit_ is now known as openstackgerrit22:40
openstackgerritDeklan Dieterly proposed a change to stackforge/monasca-api: Refactor serie name decoder  https://review.openstack.org/12081222:47
*** rhochmuth has quit IRC22:48
openstackgerritA change was merged to stackforge/monasca-api: Refactor serie name decoder  https://review.openstack.org/12081222:55
*** dschroeder has quit IRC23:05
*** rbak has quit IRC23:06

Generated by irclog2html.py 2.14.0 by Marius Gedminas - find it at mg.pov.lt!