parent
49c9e6efa8
commit
84be32f5dc
|
|
@ -55,9 +55,13 @@ Example for how to create a trace using [RabbitMQ HTTP API](http://www.rabbitmq.
|
|||
curl -i -u guest:guest -H "content-type:application/json" -XPUT \
|
||||
http://localhost:15672/api/traces/%2f/my-trace \
|
||||
-d'{"format":"text","pattern":"#", "max_payload_bytes":1000,
|
||||
"consumer_username":"guest", "consumer_password":"guest"}'
|
||||
"tracer_connection_username":"guest", "tracer_connection_password":"guest"}'
|
||||
```
|
||||
|
||||
`consumer_username` and `consumer_password` are optionals, defaults to the configured values in the app.
|
||||
`max_payload_bytes` is optional (omit it to prevent payload truncation),
|
||||
format and pattern are mandatory.
|
||||
The format and pattern fields are mandatory.
|
||||
|
||||
`tracer_connection_username` and `tracer_connection_password` control what credentials the tracing
|
||||
connection will use. Both are optional and default to the configured
|
||||
plugin values.
|
||||
|
||||
`max_payload_bytes` is optional (omit it to prevent payload truncation).
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
<th>Payload limit</th>
|
||||
<th>Rate</th>
|
||||
<th>Queued</th>
|
||||
<th>Consumer username</th>
|
||||
<th>Tracer connection username</th>
|
||||
<th></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
|
@ -58,7 +58,7 @@
|
|||
<div class="status-red"><acronym title="The trace failed to start - check the server logs for details.">FAILED</acronym></div>
|
||||
</td>
|
||||
<% } %>
|
||||
<td><%= fmt_string(trace.consumer_username) %></td>
|
||||
<td><%= fmt_string(trace.tracer_connection_username) %></td>
|
||||
<td>
|
||||
<form action="#/traces/node/<%= node.name %>" method="delete">
|
||||
<input type="hidden" name="vhost" value="<%= fmt_string(trace.vhost) %>"/>
|
||||
|
|
@ -145,12 +145,12 @@
|
|||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><label>Consumer username:</label></th>
|
||||
<td><input type="text" name="consumer_username"/></td>
|
||||
<td><label>Consumer password:</label></td>
|
||||
<th><label>Tracer connection username:</label></th>
|
||||
<td><input type="text" name="tracer_connection_username"/></td>
|
||||
<td><label>Tracer connection password:</label></td>
|
||||
<td>
|
||||
<div id="password-div">
|
||||
<input type="password" name="consumer_password"/>
|
||||
<input type="password" name="tracer_connection_password"/>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
|||
|
|
@ -50,9 +50,9 @@ init(Args) ->
|
|||
process_flag(trap_exit, true),
|
||||
Name = pget(name, Args),
|
||||
VHost = pget(vhost, Args),
|
||||
Username = pget(consumer_username, Args,
|
||||
Username = pget(tracer_connection_username, Args,
|
||||
rabbit_misc:get_env(rabbitmq_tracing, username, ?DEFAULT_USERNAME)),
|
||||
Password = pget(consumer_password, Args,
|
||||
Password = pget(tracer_connection_password, Args,
|
||||
rabbit_misc:get_env(rabbitmq_tracing, password, ?DEFAULT_PASSWORD)),
|
||||
Username = rabbit_tracing_util:coerce_env_value(username, Username),
|
||||
Password = rabbit_tracing_util:coerce_env_value(password, Password),
|
||||
|
|
|
|||
|
|
@ -116,8 +116,8 @@ vhost_tracing(VHost, Table) ->
|
|||
|
||||
augment(Trace) ->
|
||||
Pid = pget(pid, Trace),
|
||||
Trace1 = lists:keydelete(consumer_password, 1,
|
||||
lists:keydelete(<<"consumer_password">>, 1,
|
||||
Trace1 = lists:keydelete(tracer_connection_password, 1,
|
||||
lists:keydelete(<<"tracer_connection_password">>, 1,
|
||||
lists:keydelete(pid, 1, Trace))),
|
||||
case Pid of
|
||||
undefined -> Trace1;
|
||||
|
|
|
|||
Loading…
Reference in New Issue