home
/
code
/
beam_stats.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add reductions delta.
[beam_stats.git]
/
src
/
beam_stats_consumer_csv.erl
diff --git
a/src/beam_stats_consumer_csv.erl
b/src/beam_stats_consumer_csv.erl
index
c9d2785
..
6b27106
100644
(file)
--- a/
src/beam_stats_consumer_csv.erl
+++ b/
src/beam_stats_consumer_csv.erl
@@
-101,9
+101,9
@@
beam_stats_to_bin(#beam_stats
) ->
<<TimestampBin/binary>> = timestamp_to_bin(Timestamp),
<<NodeIDBin/binary>> = node_id_to_bin(NodeID),
) ->
<<TimestampBin/binary>> = timestamp_to_bin(Timestamp),
<<NodeIDBin/binary>> = node_id_to_bin(NodeID),
-
PairToBin = make_pair_to_bin(NodeIDBin, TimestampBin
),
+
MemoryPairToBin = make_pair_to_bin(NodeIDBin, TimestampBin, <<"memory">>
),
MemoryBinPairs = lists:map(fun atom_int_to_bin_bin/1, Memory),
MemoryBinPairs = lists:map(fun atom_int_to_bin_bin/1, Memory),
- MemoryBins = lists:map(PairToBin, MemoryBinPairs),
+ MemoryBins = lists:map(
Memory
PairToBin, MemoryBinPairs),
AllBins =
[ MemoryBins
],
AllBins =
[ MemoryBins
],
@@
-131,14
+131,16
@@
timestamp_to_float({ComponentMega, ComponentWhole, ComponentMicro}) ->
TotalMicroSeconds = (TotalWholeSeconds * OneMillion) + ComponentMicro,
TotalMicroSeconds / OneMillion.
TotalMicroSeconds = (TotalWholeSeconds * OneMillion) + ComponentMicro,
TotalMicroSeconds / OneMillion.
--spec make_pair_to_bin(binary(), binary()) ->
+-spec make_pair_to_bin(binary(), binary()
, binary()
) ->
fun(({binary(), binary()}) -> binary()).
fun(({binary(), binary()}) -> binary()).
-make_pair_to_bin(<<NodeID/binary>>, <<TimestampBin/binary>>) ->
+make_pair_to_bin(<<NodeID/binary>>, <<TimestampBin/binary>>
, <<Type/binary>>
) ->
fun ({<<K/binary>>, <<V/binary>>}) ->
<< TimestampBin/binary
, "|"
, NodeID/binary
, "|"
fun ({<<K/binary>>, <<V/binary>>}) ->
<< TimestampBin/binary
, "|"
, NodeID/binary
, "|"
+ , Type/binary
+ , "|"
, K/binary
, "|"
, V/binary
, K/binary
, "|"
, V/binary
This page took
0.028095 seconds
and
4
git commands to generate.