Comments (6)
np!
the example you gave looks almost valid,
first just in case, don't forget shebang at the beginning,
second -- there are no assignments and no direct list accessors,
please try running the following:
include_resource(tsv_resource, "resource_data.tsv", tsv)
pool(size = 5,
worker_type = dummy_worker):
print(sprintf("Client creds are ~p", round_robin(resource(tsv_resource))))
or
include_resource(tsv_resource, "resource_data.tsv", tsv)
pool(size = 5,
worker_type = dummy_worker):
print(sprintf("Client creds are ~p", choose(resource(tsv_resource))))
please let me know if you have questions
from vmq_mzbench.
That's a good question! I'v never loaded clientid/username/password combos from resource files like that. Did you scan the examples from MZBench a little? https://github.com/mzbench/mzbench/tree/master/examples.bdl
Maybe there's a hint there.
Pinging @parsifal-47 hi... :) maybe you have an idea on this? (looking for a way to loop through a resource file)
from vmq_mzbench.
that is correct,
you may access various resource rows to get credentials for your users,
you may use loop iterator for that if you have equal number of iterations to users or you may use randomized access.
https://github.com/mzbench/mzbench/blob/master/doc/scenarios/spec.md#iterator
https://github.com/mzbench/mzbench/blob/master/doc/scenarios/spec.md#random_number
The only problem if you have big number of these (for example 10^6), you may start to suffer from List access O(N)
complexity.
from vmq_mzbench.
Thank parsifal-47 and sorry I am newbie with erlang and MZBench.
Would you help me to show a grammar to get a value from list by order like below?
include_resource(tsv_resource, "resource_data.tsv", tsv)
pool(size = 5,
worker_type = dummy_worker):
tempRow = round_robin(resource(tsv_resource)) #BDL grammar error
print(sprintf("Client ~p, ID is ~p, password is ~p", tempRow[1], tempRow[2], tempRow[3])) #BDL grammar error
from vmq_mzbench.
There are no assignments and no direct list accessors
So it's impossible to extract all value from each index of the list?
Or may be we can put info into a list of client like "clientInfoList", and set it to vmq_mzbench?
@ioolkos Could it be like below?
make_install(git = "https://github.com/erlio/vmq_mzbench.git",
branch = "master")
include_resource(tsv_resource, "resource_data.tsv", tsv)
pool(size = 100,
worker_type = mqtt_worker,
worker_start = poisson(10 rps)):
connect([t(host, "test-mqtt"),
t(port,1883),
t(clientInfoList, round_robin(resource(tsv_resource))),
t(clean_session,true),
t(keepalive_interval,60),
t(proto_version,4), t(reconnect_timeout,4)
])
set_signal(connect1, 1)
wait_signal(connect1, 100)
wait(4 sec)
loop(time = 10 sec, rate = 1 rps):
publish("test/broadcast", "THIS IS A TEST", 0)
disconnect()
from vmq_mzbench.
your listing looks valid,
yes restructuring or structure conversions supposed to happen inside worker operations
from vmq_mzbench.
Related Issues (20)
- How to run with user/pass HOT 2
- why I got this error with Mzbench loadtest VerneMQ on my mac HOT 3
- Not getting any data from mqtt.message.consumed.total HOT 12
- mqtt.message.consumed.total is very low compared to published messages HOT 5
- Dynamic deadlock detected for 1_to_1 scenario HOT 2
- vmq_mzbench workers crashed with message "no function clause matching gen_emqtt:handle_frame(waiting_for_connack....)" HOT 7
- Plugin doesn't compile HOT 11
- Not able to start MZBENCH server HOT 3
- mzbench not connecting to the host specify in the scenario HOT 11
- Subscriber never receiving message Fan out HOT 9
- Could not compile on OSX HOT 1
- Syntax error on fan_out.bdl scenario HOT 1
- Cannot Start Server HOT 7
- Unable to use mqtt_worker HOT 2
- problem with loading client cert
- Not able to run scenarios on mzbench tool HOT 7
- Connections limit to 28k CCUs
- MQTT live messaging scenario HOT 4
- Receiving worker down crash errors : (Reason : no function clause matching rand:mk_alg(exsss) ) HOT 9
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 vmq_mzbench.