PageRenderTime 122ms CodeModel.GetById 60ms app.highlight 1ms RepoModel.GetById 60ms app.codeStats 0ms

/benchmarks/scenarii/templates/connect_and_push.erb

http://github.com/AF83/ucengine
ERB | 26 lines | 21 code | 5 blank | 0 comment | 0 complexity | 9fdea25a71d496ecb5bdc43fe02dd8fd MD5 | raw file
 1<setdynvars sourcetype="file" fileid="users" delimiter=";" order="iter">
 2  <var name="meeting" />
 3  <var name="username" />
 4  <var name="password" />
 5</setdynvars>
 6
 7  <!-- Authenticate -->
 8  <request subst="true">
 9    <dyn_variable name="sid" jsonpath="result.sid" />
10    <dyn_variable name="uid" jsonpath="result.uid" />
11    <http url='/api/0.6/presence' contents='name=%%_username%%&amp;auth=password&amp;credential=%%_password%%' method='POST' />
12  </request>
13
14  <!-- Main Loop -->
15  <for from="1" to="5000" incr="1" var="counter">
16
17    <!-- POST an event -->
18    <transaction name="post_event">
19      <request subst="true">
20        <http url='/api/0.6/event/%%_meeting%%' contents='type=test&amp;uid=%%_uid%%&amp;sid=%%_sid%%' method='POST' />
21      </request>
22    </transaction>
23
24    <thinktime random='true' value='<%= level %>'/>
25  </for>
26