apimonitor's People
apimonitor's Issues
Subscription Class is throwing error with the AES.new()
Subscription is throwing an error inside the app :
Exception in thread Thread-5:
Traceback (most recent call last):
File "/usr/lib64/python2.7/threading.py", line 804, in __bootstrap_inner
self.run()
File "/usr/lib64/python2.7/threading.py", line 757, in run
self.__target(*self.__args, **self.__kwargs)
File "/usr/local/lib/python2.7/site-packages/pubnub-3.8.3-py2.7.egg/pubnub.py", line 2554, in run
'callback'], data)
File "/usr/local/lib/python2.7/site-packages/pubnub-3.8.3-py2.7.egg/pubnub.py", line 2524, in _invoke
func(get_data_for_user(data))
File "/usr/local/lib/python2.7/site-packages/pubnub-3.8.3-py2.7.egg/pubnub.py", line 2339, in sub_callback
chobj['name'].split('-pnpres')[0])
File "/usr/local/lib/python2.7/site-packages/pubnub-3.8.3-py2.7.egg/pubnub.py", line 2127, in _invoke
func(get_data_for_user(msg), channel)
File "/home/ec2-user/APIMonitor/ringcentral/subscription/subscription.py", line 155, in callback
self._notify(message)
File "/home/ec2-user/APIMonitor/ringcentral/subscription/subscription.py", line 174, in _notify
message = self._decrypt(message)
File "/home/ec2-user/APIMonitor/ringcentral/subscription/subscription.py", line 188, in _decrypt
obj2 = AES.new(key)
TypeError: new() takes at least 2 arguments (1 given)
Current version on the Instance
- Python - 2.7
- Pubnub 3.8.3-py2.7
The issue seems to be with the _decrypt(self, message)
method within the subscription. Please take a look at Line 188
Use a configurable schedule to run different APIs within the monitor
Monitor should read the schedule from a config file (add a schedule section), it should not be hard-coded in the monitor.
Steps:
startup and initialize
Read schedule from config
run schedule
cleanup
Schedule config should contain which APIs to run, with what frequency, how many times total to run (or indefinitely until interrupted, or until certain datetime), what inputs to pass into each API etc.
For example see https://pymotw.com/2/sched/
Use rotating logs for ease of use
Log time taken for each request, from the time request is submitted by monitoring app, till time the response is received by same app.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.