Comments (3)
I'm not sure what you mean @komikoni. Can you write your give your full locustfile and what you are trying to achieve?
from invokust.
Thank you for your reply. (I'm sorry. It was a strange English sentence.)
I want to save the performance measurement results in a database And I want to see the results graphically at any time.
And I want to run them serverless.
As a result of searching, with invokest locust-influxdb-listener was found.
Later, I also found the Amazon Managed Service for Grafana (Preview).
However, influxdb has a Cloud service, but the version is different and it does not work, so I rewrote it for Amazon Timestream
I made a locust-timestream-listener.
But it didn't work with invokest.(It worked with normal locust)
I thought that the reason was that add_listener did not work in invokest, so I asked the question.
sample locustfile
from locust import between, events, tag, task, HttpUser
import sys,os
sys.path.append('##localpath##/locust-timestream-listener/') #TODO pip regist
from locust_timestream_listener import TimestreamListener, TimestreamSettings
@events.init.add_listener
def on_locust_init(environment, **_kwargs):
print('on_locust_init')
"""
Hook event that enables starting an timestream connection
"""
# this settings matches the given docker-compose file
timestreamSettings = TimestreamSettings(
database = 'locust-result-1'
)
# start listerner with the given configuration
TimestreamListener(env=environment, timestreamSettings=timestreamSettings)
class TestWebUser(HttpUser):
wait_time = between(1,5)
@tag('home_page')
@task(1)
def home_page(self):
with self.client.get("/", catch_response=True) as response:
if response.status_code != 200:
response.failure("Got wrong response")
@tag('connectors')
@task(1)
def workfront_connector(self):
with self.client.get("/connectors/workfront", catch_response=True) as response:
if 'Do More Work, Faster' not in response.text:
response.failure("Expected test was not displayed")
def on_start(self):
print('New user was spawned')
from invokust.
I made a locust-timestream-listener.
Nice 👍
2 things to try:
- If you replace everything in
on_locust_init
with aprint
statement, do you see it in the logs? - Does it work when you run this locally in python, like shown in the readme?
from invokust.
Related Issues (20)
- Error invoking lambda following quickstart HOT 3
- Semantic versioning HOT 2
- version 0.75 missing for Pypi HOT 3
- AWS deployment fails HOT 8
- Handle environment variables with `LambdaLoadTest` on Locust HOT 4
- Ability to deploy Lambda through AWS-CDK instead of using local script HOT 1
- Locust exception ImportError("cannot import name 'User'",) HOT 6
- Unable to use invokust. locust version == 1.3.0, locustio==0.13.5, invokust==0.73 HOT 6
- gevent error when attempting to invoke lambda HOT 3
- No results when using LambdaLoadTest HOT 2
- segmentation fault (core dumped) HOT 4
- Can you output CSV or HTML reports?
- AWS Lambda deployment with function layer
- Negative execution time
- Use invokust with odoo HOT 3
- no option to save the load test report HOT 1
- Logging Configuration HOT 3
- LoadTestShape HOT 3
- AttributeError: 'StatsError' object has no attribute 'to_dict' HOT 1
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.
from invokust.