mirror of
https://github.com/langhuihui/monibuca.git
synced 2025-10-13 02:03:46 +08:00
增加集群概览显示
This commit is contained in:
@@ -1 +1 @@
|
||||
#app,body,html{height:100%}#app{font-family:Avenir,Helvetica,Arial,sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-align:center;color:#184c18;position:relative}#app>div:first-child{position:absolute;top:10px;left:30px;font-size:x-large}.content{padding-top:60px}.feature-title[data-v-54efad41]{color:#eb5e46;font-weight:700;font-size:larger}p[data-v-54efad41]{margin:30px;font-size:20px}img[data-v-54efad41]{margin:20px}.root[data-v-e34eab40]{background:#d3d3d3}.root>img[data-v-e34eab40]{width:300px;margin:30px}.records[data-v-4eee1624]{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;padding:0 15px}.records>[data-v-4eee1624]{width:200px}.log-container{overflow-y:auto;max-height:500px}@-webkit-keyframes recording-data-v-7f7c92c8{0%{opacity:.2}50%{opacity:1}to{opacity:.2}}@keyframes recording-data-v-7f7c92c8{0%{opacity:.2}50%{opacity:1}to{opacity:.2}}.recording[data-v-7f7c92c8]{-webkit-animation:recording-data-v-7f7c92c8 1s infinite;animation:recording-data-v-7f7c92c8 1s infinite}.layout[data-v-7f7c92c8]{padding-bottom:30px;display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap}.room[data-v-7f7c92c8]{width:250px;margin:10px;text-align:left}.empty[data-v-7f7c92c8]{color:#eb5e46;width:100%;min-height:500px;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.empty[data-v-7f7c92c8],.status[data-v-7f7c92c8]{display:-webkit-box;display:-ms-flexbox;display:flex}.status[data-v-7f7c92c8]{position:fixed;left:5px;bottom:10px}.status>div[data-v-7f7c92c8]{margin:0 5px}
|
||||
#app,body,html{height:100%}#app{font-family:Avenir,Helvetica,Arial,sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-align:center;color:#184c18;position:relative}#app>div:first-child{position:absolute;top:10px;left:30px;font-size:x-large}.content{padding-top:60px}.feature-title[data-v-54efad41]{color:#eb5e46;font-weight:700;font-size:larger}p[data-v-54efad41]{margin:30px;font-size:20px}img[data-v-54efad41]{margin:20px}.root[data-v-e34eab40]{background:#d3d3d3}.root>img[data-v-e34eab40]{width:300px;margin:30px}.records[data-v-4eee1624]{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;padding:0 15px}.records>[data-v-4eee1624]{width:200px}.log-container{overflow-y:auto;max-height:500px}@-webkit-keyframes recording-data-v-f6113870{0%{opacity:.2}50%{opacity:1}to{opacity:.2}}@keyframes recording-data-v-f6113870{0%{opacity:.2}50%{opacity:1}to{opacity:.2}}.recording[data-v-f6113870]{-webkit-animation:recording-data-v-f6113870 1s infinite;animation:recording-data-v-f6113870 1s infinite}.layout[data-v-f6113870]{padding-bottom:30px;display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap}.room[data-v-f6113870]{width:250px;margin:10px;text-align:left}.empty[data-v-f6113870]{color:#eb5e46;width:100%;min-height:500px;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.empty[data-v-f6113870],.status[data-v-f6113870]{display:-webkit-box;display:-ms-flexbox;display:flex}.status[data-v-f6113870]{position:fixed;left:5px;bottom:10px}.status>div[data-v-f6113870]{margin:0 5px}
|
2
dashboard/dist/index.html
vendored
2
dashboard/dist/index.html
vendored
@@ -1 +1 @@
|
||||
<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1"><link rel=icon href=/favicon.ico><title>Monibuca</title><script src=jessibuca/ajax.js></script><script src=jessibuca/renderer.js></script><link href=/css/app.d549056a.css rel=preload as=style><link href=/css/chunk-vendors.22ebf426.css rel=preload as=style><link href=/js/app.d6cffcca.js rel=preload as=script><link href=/js/chunk-vendors.ae8ac63d.js rel=preload as=script><link href=/css/chunk-vendors.22ebf426.css rel=stylesheet><link href=/css/app.d549056a.css rel=stylesheet></head><body><noscript><strong>We're sorry but dashboard doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app></div><script src=/js/chunk-vendors.ae8ac63d.js></script><script src=/js/app.d6cffcca.js></script></body></html>
|
||||
<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1"><link rel=icon href=/favicon.ico><title>Monibuca</title><script src=jessibuca/ajax.js></script><script src=jessibuca/renderer.js></script><link href=/css/app.ea4656d8.css rel=preload as=style><link href=/css/chunk-vendors.22ebf426.css rel=preload as=style><link href=/js/app.af5e5ef3.js rel=preload as=script><link href=/js/chunk-vendors.ebc28a73.js rel=preload as=script><link href=/css/chunk-vendors.22ebf426.css rel=stylesheet><link href=/css/app.ea4656d8.css rel=stylesheet></head><body><noscript><strong>We're sorry but dashboard doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app></div><script src=/js/chunk-vendors.ebc28a73.js></script><script src=/js/app.af5e5ef3.js></script></body></html>
|
2
dashboard/dist/js/app.af5e5ef3.js
vendored
Normal file
2
dashboard/dist/js/app.af5e5ef3.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dashboard/dist/js/app.af5e5ef3.js.map
vendored
Normal file
1
dashboard/dist/js/app.af5e5ef3.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
2
dashboard/dist/js/app.d6cffcca.js
vendored
2
dashboard/dist/js/app.d6cffcca.js
vendored
File diff suppressed because one or more lines are too long
1
dashboard/dist/js/app.d6cffcca.js.map
vendored
1
dashboard/dist/js/app.d6cffcca.js.map
vendored
File diff suppressed because one or more lines are too long
44
dashboard/dist/js/chunk-vendors.ae8ac63d.js
vendored
44
dashboard/dist/js/chunk-vendors.ae8ac63d.js
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
52
dashboard/dist/js/chunk-vendors.ebc28a73.js
vendored
Normal file
52
dashboard/dist/js/chunk-vendors.ebc28a73.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dashboard/dist/js/chunk-vendors.ebc28a73.js.map
vendored
Normal file
1
dashboard/dist/js/chunk-vendors.ebc28a73.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
360
dashboard/package-lock.json
generated
360
dashboard/package-lock.json
generated
@@ -123,6 +123,44 @@
|
||||
"tslib": "1.10.0"
|
||||
}
|
||||
},
|
||||
"@antv/g6": {
|
||||
"version": "3.2.9",
|
||||
"resolved": "https://registry.npm.taobao.org/@antv/g6/download/@antv/g6-3.2.9.tgz",
|
||||
"integrity": "sha1-V4k4YKrE3iZUTz1dSoG4jWXVK9k=",
|
||||
"requires": {
|
||||
"@antv/g": "3.4.7",
|
||||
"@antv/hierarchy": "0.6.1",
|
||||
"@antv/util": "1.3.1",
|
||||
"d3": "5.15.0",
|
||||
"d3-force": "2.0.1",
|
||||
"d3-sankey": "0.12.3",
|
||||
"dagre": "0.8.5",
|
||||
"numeric": "1.2.6",
|
||||
"numericjs": "1.2.6"
|
||||
},
|
||||
"dependencies": {
|
||||
"@antv/g": {
|
||||
"version": "3.4.7",
|
||||
"resolved": "https://registry.npm.taobao.org/@antv/g/download/@antv/g-3.4.7.tgz",
|
||||
"integrity": "sha1-1CCM07f4XVEvp19l0YXIoFoYHuU=",
|
||||
"requires": {
|
||||
"@antv/gl-matrix": "2.7.1",
|
||||
"@antv/util": "1.3.1",
|
||||
"d3-ease": "1.0.6",
|
||||
"d3-interpolate": "1.1.6",
|
||||
"d3-timer": "1.0.10"
|
||||
}
|
||||
},
|
||||
"@antv/util": {
|
||||
"version": "1.3.1",
|
||||
"resolved": "https://registry.npm.taobao.org/@antv/util/download/@antv/util-1.3.1.tgz?cache=0&sync_timestamp=1572438102677&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2F%40antv%2Futil%2Fdownload%2F%40antv%2Futil-1.3.1.tgz",
|
||||
"integrity": "sha1-MKNLIB/5Em7A1YxyyBZqnD5kTM0=",
|
||||
"requires": {
|
||||
"@antv/gl-matrix": "2.7.1"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"@antv/gl-matrix": {
|
||||
"version": "2.7.1",
|
||||
"resolved": "https://registry.npm.taobao.org/@antv/gl-matrix/download/@antv/gl-matrix-2.7.1.tgz",
|
||||
@@ -141,6 +179,24 @@
|
||||
"tslib": "1.10.0"
|
||||
}
|
||||
},
|
||||
"@antv/hierarchy": {
|
||||
"version": "0.6.1",
|
||||
"resolved": "https://registry.npm.taobao.org/@antv/hierarchy/download/@antv/hierarchy-0.6.1.tgz",
|
||||
"integrity": "sha1-2oH6FUTNTj/17D+WAfv4FC9h7yw=",
|
||||
"requires": {
|
||||
"@antv/util": "1.3.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"@antv/util": {
|
||||
"version": "1.3.1",
|
||||
"resolved": "https://registry.npm.taobao.org/@antv/util/download/@antv/util-1.3.1.tgz?cache=0&sync_timestamp=1572438102677&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2F%40antv%2Futil%2Fdownload%2F%40antv%2Futil-1.3.1.tgz",
|
||||
"integrity": "sha1-MKNLIB/5Em7A1YxyyBZqnD5kTM0=",
|
||||
"requires": {
|
||||
"@antv/gl-matrix": "2.7.1"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"@antv/matrix-util": {
|
||||
"version": "2.0.4",
|
||||
"resolved": "https://registry.npm.taobao.org/@antv/matrix-util/download/@antv/matrix-util-2.0.4.tgz",
|
||||
@@ -4409,8 +4465,7 @@
|
||||
"commander": {
|
||||
"version": "2.20.3",
|
||||
"resolved": "https://registry.npm.taobao.org/commander/download/commander-2.20.3.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcommander%2Fdownload%2Fcommander-2.20.3.tgz",
|
||||
"integrity": "sha1-/UhehMA+tIgcIHIrpIA16FMa6zM=",
|
||||
"dev": true
|
||||
"integrity": "sha1-/UhehMA+tIgcIHIrpIA16FMa6zM="
|
||||
},
|
||||
"common-tags": {
|
||||
"version": "1.8.0",
|
||||
@@ -5130,16 +5185,171 @@
|
||||
"type": "1.2.0"
|
||||
}
|
||||
},
|
||||
"d3": {
|
||||
"version": "5.15.0",
|
||||
"resolved": "https://registry.npm.taobao.org/d3/download/d3-5.15.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fd3%2Fdownload%2Fd3-5.15.0.tgz",
|
||||
"integrity": "sha1-/9RJWOajy4pZqEQpxFQpuLylZ3o=",
|
||||
"requires": {
|
||||
"d3-array": "1.2.4",
|
||||
"d3-axis": "1.0.12",
|
||||
"d3-brush": "1.1.5",
|
||||
"d3-chord": "1.0.6",
|
||||
"d3-collection": "1.0.7",
|
||||
"d3-color": "1.4.0",
|
||||
"d3-contour": "1.3.2",
|
||||
"d3-dispatch": "1.0.6",
|
||||
"d3-drag": "1.2.5",
|
||||
"d3-dsv": "1.2.0",
|
||||
"d3-ease": "1.0.6",
|
||||
"d3-fetch": "1.1.2",
|
||||
"d3-force": "1.2.1",
|
||||
"d3-format": "1.4.3",
|
||||
"d3-geo": "1.11.9",
|
||||
"d3-hierarchy": "1.1.9",
|
||||
"d3-interpolate": "1.1.6",
|
||||
"d3-path": "1.0.9",
|
||||
"d3-polygon": "1.0.6",
|
||||
"d3-quadtree": "1.0.7",
|
||||
"d3-random": "1.1.2",
|
||||
"d3-scale": "2.2.2",
|
||||
"d3-scale-chromatic": "1.5.0",
|
||||
"d3-selection": "1.4.1",
|
||||
"d3-shape": "1.3.7",
|
||||
"d3-time": "1.1.0",
|
||||
"d3-time-format": "2.2.3",
|
||||
"d3-timer": "1.0.10",
|
||||
"d3-transition": "1.3.2",
|
||||
"d3-voronoi": "1.1.4",
|
||||
"d3-zoom": "1.8.3"
|
||||
},
|
||||
"dependencies": {
|
||||
"d3-force": {
|
||||
"version": "1.2.1",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-force/download/d3-force-1.2.1.tgz",
|
||||
"integrity": "sha1-/Sml0f8YHJ5/BmnkvXK9sOkU7As=",
|
||||
"requires": {
|
||||
"d3-collection": "1.0.7",
|
||||
"d3-dispatch": "1.0.6",
|
||||
"d3-quadtree": "1.0.7",
|
||||
"d3-timer": "1.0.10"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"d3-array": {
|
||||
"version": "1.2.4",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-array/download/d3-array-1.2.4.tgz",
|
||||
"integrity": "sha1-Y1zk1e6nWfb2BYY9vPww7cc39x8="
|
||||
},
|
||||
"d3-axis": {
|
||||
"version": "1.0.12",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-axis/download/d3-axis-1.0.12.tgz",
|
||||
"integrity": "sha1-zfILohDPu0N5WvM3Vohvs2ONqsk="
|
||||
},
|
||||
"d3-brush": {
|
||||
"version": "1.1.5",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-brush/download/d3-brush-1.1.5.tgz",
|
||||
"integrity": "sha1-BmuOhNF7GSmGAwRGyXwPun4brNw=",
|
||||
"requires": {
|
||||
"d3-dispatch": "1.0.6",
|
||||
"d3-drag": "1.2.5",
|
||||
"d3-interpolate": "1.1.6",
|
||||
"d3-selection": "1.4.1",
|
||||
"d3-transition": "1.3.2"
|
||||
}
|
||||
},
|
||||
"d3-chord": {
|
||||
"version": "1.0.6",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-chord/download/d3-chord-1.0.6.tgz?cache=0&sync_timestamp=1575418695102&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fd3-chord%2Fdownload%2Fd3-chord-1.0.6.tgz",
|
||||
"integrity": "sha1-MJFX4/LbLHUvAoD+3TXyBnzLsV8=",
|
||||
"requires": {
|
||||
"d3-array": "1.2.4",
|
||||
"d3-path": "1.0.9"
|
||||
}
|
||||
},
|
||||
"d3-collection": {
|
||||
"version": "1.0.7",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-collection/download/d3-collection-1.0.7.tgz",
|
||||
"integrity": "sha1-NJvSqpl32wcQkcExRNXk8WtbMQ4="
|
||||
},
|
||||
"d3-color": {
|
||||
"version": "1.4.0",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-color/download/d3-color-1.4.0.tgz",
|
||||
"integrity": "sha1-icRamV7Xc7EzFPBkYN8m1gug7K8="
|
||||
},
|
||||
"d3-contour": {
|
||||
"version": "1.3.2",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-contour/download/d3-contour-1.3.2.tgz",
|
||||
"integrity": "sha1-ZSqs1QDSJkyzQjzuENtp9vWb6tM=",
|
||||
"requires": {
|
||||
"d3-array": "1.2.4"
|
||||
}
|
||||
},
|
||||
"d3-dispatch": {
|
||||
"version": "1.0.6",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-dispatch/download/d3-dispatch-1.0.6.tgz",
|
||||
"integrity": "sha1-ANN7zuTdjNl3Kd2JOgrCnKq6XVg="
|
||||
},
|
||||
"d3-drag": {
|
||||
"version": "1.2.5",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-drag/download/d3-drag-1.2.5.tgz",
|
||||
"integrity": "sha1-JTf0UazTnTFAZne33HfIL32Yj3A=",
|
||||
"requires": {
|
||||
"d3-dispatch": "1.0.6",
|
||||
"d3-selection": "1.4.1"
|
||||
}
|
||||
},
|
||||
"d3-dsv": {
|
||||
"version": "1.2.0",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-dsv/download/d3-dsv-1.2.0.tgz?cache=0&sync_timestamp=1573934576301&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fd3-dsv%2Fdownload%2Fd3-dsv-1.2.0.tgz",
|
||||
"integrity": "sha1-nV91w6X4q9YR900/WEew1DOLiFw=",
|
||||
"requires": {
|
||||
"commander": "2.20.3",
|
||||
"iconv-lite": "0.4.24",
|
||||
"rw": "1.3.3"
|
||||
}
|
||||
},
|
||||
"d3-ease": {
|
||||
"version": "1.0.6",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-ease/download/d3-ease-1.0.6.tgz",
|
||||
"integrity": "sha1-69ttoi36wKIiIvLU2gb2bEFqDsA="
|
||||
},
|
||||
"d3-fetch": {
|
||||
"version": "1.1.2",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-fetch/download/d3-fetch-1.1.2.tgz",
|
||||
"integrity": "sha1-lXyPvG1EgFmboZGxslGL+Gs+G+I=",
|
||||
"requires": {
|
||||
"d3-dsv": "1.2.0"
|
||||
}
|
||||
},
|
||||
"d3-force": {
|
||||
"version": "2.0.1",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-force/download/d3-force-2.0.1.tgz",
|
||||
"integrity": "sha1-MXUO7oxDU1MB1XEZW/loO+2lNOI=",
|
||||
"requires": {
|
||||
"d3-dispatch": "1.0.6",
|
||||
"d3-quadtree": "1.0.7",
|
||||
"d3-timer": "1.0.10"
|
||||
}
|
||||
},
|
||||
"d3-format": {
|
||||
"version": "1.4.3",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-format/download/d3-format-1.4.3.tgz",
|
||||
"integrity": "sha1-To603/P9y4kahInsbmmGAcQblvE="
|
||||
},
|
||||
"d3-geo": {
|
||||
"version": "1.11.9",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-geo/download/d3-geo-1.11.9.tgz",
|
||||
"integrity": "sha1-d+rtFLpi/CwK71XNKUOEnIZveuY=",
|
||||
"requires": {
|
||||
"d3-array": "1.2.4"
|
||||
}
|
||||
},
|
||||
"d3-hierarchy": {
|
||||
"version": "1.1.9",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-hierarchy/download/d3-hierarchy-1.1.9.tgz?cache=0&sync_timestamp=1574108571076&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fd3-hierarchy%2Fdownload%2Fd3-hierarchy-1.1.9.tgz",
|
||||
"integrity": "sha1-L2vuJMqupD+Nw3VF+gFihVlkeoM="
|
||||
},
|
||||
"d3-interpolate": {
|
||||
"version": "1.1.6",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-interpolate/download/d3-interpolate-1.1.6.tgz",
|
||||
@@ -5148,16 +5358,132 @@
|
||||
"d3-color": "1.4.0"
|
||||
}
|
||||
},
|
||||
"d3-path": {
|
||||
"version": "1.0.9",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-path/download/d3-path-1.0.9.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fd3-path%2Fdownload%2Fd3-path-1.0.9.tgz",
|
||||
"integrity": "sha1-SMBQux/owmJJOoyvVSTj6VkXAc8="
|
||||
},
|
||||
"d3-polygon": {
|
||||
"version": "1.0.6",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-polygon/download/d3-polygon-1.0.6.tgz",
|
||||
"integrity": "sha1-C/jLgYCm3BB/UY3feXXhKrv7044="
|
||||
},
|
||||
"d3-quadtree": {
|
||||
"version": "1.0.7",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-quadtree/download/d3-quadtree-1.0.7.tgz",
|
||||
"integrity": "sha1-youE33u1N2P+PC8kvUNRN/TlMTU="
|
||||
},
|
||||
"d3-random": {
|
||||
"version": "1.1.2",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-random/download/d3-random-1.1.2.tgz",
|
||||
"integrity": "sha1-KDO+fBJDYL+eLT/U8zhHz+bKspE="
|
||||
},
|
||||
"d3-regression": {
|
||||
"version": "1.3.4",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-regression/download/d3-regression-1.3.4.tgz",
|
||||
"integrity": "sha1-o0FLGr5aINRqII2V5WWkGL6aDiM="
|
||||
},
|
||||
"d3-sankey": {
|
||||
"version": "0.12.3",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-sankey/download/d3-sankey-0.12.3.tgz",
|
||||
"integrity": "sha1-s8JoYnvXLl2AM26N5qy/7J0V0B0=",
|
||||
"requires": {
|
||||
"d3-array": "1.2.4",
|
||||
"d3-shape": "1.3.7"
|
||||
}
|
||||
},
|
||||
"d3-scale": {
|
||||
"version": "2.2.2",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-scale/download/d3-scale-2.2.2.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fd3-scale%2Fdownload%2Fd3-scale-2.2.2.tgz",
|
||||
"integrity": "sha1-TogOCydFrKrd0+3iap6Qip4XuB8=",
|
||||
"requires": {
|
||||
"d3-array": "1.2.4",
|
||||
"d3-collection": "1.0.7",
|
||||
"d3-format": "1.4.3",
|
||||
"d3-interpolate": "1.1.6",
|
||||
"d3-time": "1.1.0",
|
||||
"d3-time-format": "2.2.3"
|
||||
}
|
||||
},
|
||||
"d3-scale-chromatic": {
|
||||
"version": "1.5.0",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-scale-chromatic/download/d3-scale-chromatic-1.5.0.tgz",
|
||||
"integrity": "sha1-VOMz/HghL0ObFGQftVgB3YETWpg=",
|
||||
"requires": {
|
||||
"d3-color": "1.4.0",
|
||||
"d3-interpolate": "1.1.6"
|
||||
}
|
||||
},
|
||||
"d3-selection": {
|
||||
"version": "1.4.1",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-selection/download/d3-selection-1.4.1.tgz",
|
||||
"integrity": "sha1-mO7bvghfvaW6+i+ePzovTX1iKpg="
|
||||
},
|
||||
"d3-shape": {
|
||||
"version": "1.3.7",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-shape/download/d3-shape-1.3.7.tgz",
|
||||
"integrity": "sha1-32OAG+B7yYa8VPY3ibT+UCmStdc=",
|
||||
"requires": {
|
||||
"d3-path": "1.0.9"
|
||||
}
|
||||
},
|
||||
"d3-time": {
|
||||
"version": "1.1.0",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-time/download/d3-time-1.1.0.tgz",
|
||||
"integrity": "sha1-seGdMH2unJALflsl/8XcwkmooPE="
|
||||
},
|
||||
"d3-time-format": {
|
||||
"version": "2.2.3",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-time-format/download/d3-time-format-2.2.3.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fd3-time-format%2Fdownload%2Fd3-time-format-2.2.3.tgz",
|
||||
"integrity": "sha1-DJoS7ig0KyA35eoc8LnrTddfKcs=",
|
||||
"requires": {
|
||||
"d3-time": "1.1.0"
|
||||
}
|
||||
},
|
||||
"d3-timer": {
|
||||
"version": "1.0.10",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-timer/download/d3-timer-1.0.10.tgz?cache=0&sync_timestamp=1573934576216&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fd3-timer%2Fdownload%2Fd3-timer-1.0.10.tgz",
|
||||
"integrity": "sha1-3+dripF0iDGxO22ceT/71QjdneU="
|
||||
},
|
||||
"d3-transition": {
|
||||
"version": "1.3.2",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-transition/download/d3-transition-1.3.2.tgz",
|
||||
"integrity": "sha1-qY7yFRvo2GAFQ0NMHKgBQK4js5g=",
|
||||
"requires": {
|
||||
"d3-color": "1.4.0",
|
||||
"d3-dispatch": "1.0.6",
|
||||
"d3-ease": "1.0.6",
|
||||
"d3-interpolate": "1.1.6",
|
||||
"d3-selection": "1.4.1",
|
||||
"d3-timer": "1.0.10"
|
||||
}
|
||||
},
|
||||
"d3-voronoi": {
|
||||
"version": "1.1.4",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-voronoi/download/d3-voronoi-1.1.4.tgz",
|
||||
"integrity": "sha1-3Tx412U9K7NZKErkeGRdlZRMgpc="
|
||||
},
|
||||
"d3-zoom": {
|
||||
"version": "1.8.3",
|
||||
"resolved": "https://registry.npm.taobao.org/d3-zoom/download/d3-zoom-1.8.3.tgz",
|
||||
"integrity": "sha1-tqPb5zjHdjEhzQW4p3lf/hf0/Ao=",
|
||||
"requires": {
|
||||
"d3-dispatch": "1.0.6",
|
||||
"d3-drag": "1.2.5",
|
||||
"d3-interpolate": "1.1.6",
|
||||
"d3-selection": "1.4.1",
|
||||
"d3-transition": "1.3.2"
|
||||
}
|
||||
},
|
||||
"dagre": {
|
||||
"version": "0.8.5",
|
||||
"resolved": "https://registry.npm.taobao.org/dagre/download/dagre-0.8.5.tgz",
|
||||
"integrity": "sha1-ujCwBV2sErbB/MJHgXRCd30Gr+4=",
|
||||
"requires": {
|
||||
"graphlib": "2.1.8",
|
||||
"lodash": "4.17.15"
|
||||
}
|
||||
},
|
||||
"dashdash": {
|
||||
"version": "1.14.1",
|
||||
"resolved": "https://registry.npm.taobao.org/dashdash/download/dashdash-1.14.1.tgz",
|
||||
@@ -7568,6 +7894,14 @@
|
||||
"integrity": "sha1-ShL/G2A3bvCYYsIJPt2Qgyi+hCM=",
|
||||
"dev": true
|
||||
},
|
||||
"graphlib": {
|
||||
"version": "2.1.8",
|
||||
"resolved": "https://registry.npm.taobao.org/graphlib/download/graphlib-2.1.8.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fgraphlib%2Fdownload%2Fgraphlib-2.1.8.tgz",
|
||||
"integrity": "sha1-V2HUFHN4cAhMkux7XbywWSydNdo=",
|
||||
"requires": {
|
||||
"lodash": "4.17.15"
|
||||
}
|
||||
},
|
||||
"gray-matter": {
|
||||
"version": "4.0.2",
|
||||
"resolved": "https://registry.npm.taobao.org/gray-matter/download/gray-matter-4.0.2.tgz",
|
||||
@@ -8023,7 +8357,6 @@
|
||||
"version": "0.4.24",
|
||||
"resolved": "https://registry.npm.taobao.org/iconv-lite/download/iconv-lite-0.4.24.tgz?cache=0&sync_timestamp=1579333981154&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Ficonv-lite%2Fdownload%2Ficonv-lite-0.4.24.tgz",
|
||||
"integrity": "sha1-ICK0sl+93CHS9SSXSkdKr+czkIs=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"safer-buffer": "2.1.2"
|
||||
}
|
||||
@@ -9306,8 +9639,7 @@
|
||||
"lodash": {
|
||||
"version": "4.17.15",
|
||||
"resolved": "https://registry.npm.taobao.org/lodash/download/lodash-4.17.15.tgz?cache=0&sync_timestamp=1563508077056&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Flodash%2Fdownload%2Flodash-4.17.15.tgz",
|
||||
"integrity": "sha1-tEf2ZwoEVbv+7dETku/zMOoJdUg=",
|
||||
"dev": true
|
||||
"integrity": "sha1-tEf2ZwoEVbv+7dETku/zMOoJdUg="
|
||||
},
|
||||
"lodash._reinterpolate": {
|
||||
"version": "3.0.0",
|
||||
@@ -10296,6 +10628,16 @@
|
||||
"integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=",
|
||||
"dev": true
|
||||
},
|
||||
"numeric": {
|
||||
"version": "1.2.6",
|
||||
"resolved": "https://registry.npm.taobao.org/numeric/download/numeric-1.2.6.tgz",
|
||||
"integrity": "sha1-dlsCvvl5iPz4gNTrPza4D6MTNao="
|
||||
},
|
||||
"numericjs": {
|
||||
"version": "1.2.6",
|
||||
"resolved": "https://registry.npm.taobao.org/numericjs/download/numericjs-1.2.6.tgz",
|
||||
"integrity": "sha1-wNryXEvLIuBDv4NEP5856LM2eYs="
|
||||
},
|
||||
"oauth-sign": {
|
||||
"version": "0.9.0",
|
||||
"resolved": "https://registry.npm.taobao.org/oauth-sign/download/oauth-sign-0.9.0.tgz",
|
||||
@@ -13155,6 +13497,11 @@
|
||||
"aproba": "1.2.0"
|
||||
}
|
||||
},
|
||||
"rw": {
|
||||
"version": "1.3.3",
|
||||
"resolved": "https://registry.npm.taobao.org/rw/download/rw-1.3.3.tgz",
|
||||
"integrity": "sha1-P4Yt+pGrdmsUiF700BEkv9oHT7Q="
|
||||
},
|
||||
"rxjs": {
|
||||
"version": "6.5.4",
|
||||
"resolved": "https://registry.npm.taobao.org/rxjs/download/rxjs-6.5.4.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Frxjs%2Fdownload%2Frxjs-6.5.4.tgz",
|
||||
@@ -13182,8 +13529,7 @@
|
||||
"safer-buffer": {
|
||||
"version": "2.1.2",
|
||||
"resolved": "https://registry.npm.taobao.org/safer-buffer/download/safer-buffer-2.1.2.tgz",
|
||||
"integrity": "sha1-RPoWGwGHuVSd2Eu5GAL5vYOFzWo=",
|
||||
"dev": true
|
||||
"integrity": "sha1-RPoWGwGHuVSd2Eu5GAL5vYOFzWo="
|
||||
},
|
||||
"sax": {
|
||||
"version": "1.2.4",
|
||||
|
@@ -11,6 +11,7 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@antv/g2plot": "^0.11.22",
|
||||
"@antv/g6": "^3.2.9",
|
||||
"core-js": "^3.4.4",
|
||||
"view-design": "^4.0.0",
|
||||
"vue": "^2.6.10",
|
||||
|
@@ -3,38 +3,30 @@
|
||||
<div>Monibuca</div>
|
||||
<Menu mode="horizontal" :active-name="selectedMenu" style="position: absolute;top: 0;right: 0;">
|
||||
<MenuItem name="home" to="/">首页</MenuItem>
|
||||
<MenuItem name="docs" to="/docs" target="_blank">
|
||||
文档
|
||||
</MenuItem>
|
||||
<MenuItem name="console" to="console">
|
||||
控制台
|
||||
</MenuItem>
|
||||
<MenuItem name="docs" to="/docs" target="_blank">文档</MenuItem>
|
||||
<MenuItem name="console" to="console">控制台</MenuItem>
|
||||
<Submenu name="plugins">
|
||||
<template slot="title">
|
||||
内置插件
|
||||
</template>
|
||||
<template slot="title">内置插件</template>
|
||||
<MenuGroup title="发布者/订阅者">
|
||||
<MenuItem name="cluster" to="/docs/plugins.html#cluster插件">集群</MenuItem>
|
||||
<MenuItem name="rtmp" to="/docs/plugins.html#rtmp插件">RTMP</MenuItem>
|
||||
<MenuItem name="cluster" target="_blank" to="/docs/plugins.html#cluster插件">集群</MenuItem>
|
||||
<MenuItem name="rtmp" target="_blank" to="/docs/plugins.html#rtmp插件">RTMP</MenuItem>
|
||||
</MenuGroup>
|
||||
<MenuGroup title="订阅者">
|
||||
<MenuItem name="jessica" to="/docs/plugins.html#jessica插件">Jessica</MenuItem>
|
||||
<MenuItem name="HDL" to="/docs/plugins.html#http-flv插件">Http-Flv</MenuItem>
|
||||
<MenuItem name="record" to="/docs/plugins.html#recordflv插件">录制Flv</MenuItem>
|
||||
<MenuItem name="jessica" target="_blank" to="/docs/plugins.html#jessica插件">Jessica</MenuItem>
|
||||
<MenuItem name="HDL" target="_blank" to="/docs/plugins.html#http-flv插件">Http-Flv</MenuItem>
|
||||
<MenuItem name="record" target="_blank" to="/docs/plugins.html#recordflv插件">录制Flv</MenuItem>
|
||||
</MenuGroup>
|
||||
<MenuGroup title="发布者">
|
||||
<MenuItem name="HLS" to="/docs/plugins.html#hls插件">HLS</MenuItem>
|
||||
<MenuItem name="TS" to="/docs/plugins.html#hls插件">TS</MenuItem>
|
||||
<MenuItem name="HLS" target="_blank" to="/docs/plugins.html#hls插件">HLS</MenuItem>
|
||||
<MenuItem name="TS" target="_blank" to="/docs/plugins.html#hls插件">TS</MenuItem>
|
||||
</MenuGroup>
|
||||
<MenuGroup title="钩子">
|
||||
<MenuItem name="Auth" to="/docs/plugins.html#校验插件">验证</MenuItem>
|
||||
<MenuItem name="Auth" target="_blank" to="/docs/plugins.html#校验插件">验证</MenuItem>
|
||||
<MenuItem name="QoS">QoS</MenuItem>
|
||||
<MenuItem name="gateway" to="/docs/plugins.html#网关插件">网关</MenuItem>
|
||||
<MenuItem name="gateway" target="_blank" to="/docs/plugins.html#网关插件">网关</MenuItem>
|
||||
</MenuGroup>
|
||||
</Submenu>
|
||||
<MenuItem name="4" to="about">
|
||||
支持
|
||||
</MenuItem>
|
||||
<MenuItem name="4" to="about">支持</MenuItem>
|
||||
</Menu>
|
||||
<router-view class="content"></router-view>
|
||||
<div>Copyright © 2019-2020 dexter 苏ICP备20001212号</div>
|
||||
@@ -42,39 +34,38 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
export default {
|
||||
name: 'app',
|
||||
data(){
|
||||
export default {
|
||||
name: "app",
|
||||
data() {
|
||||
return {
|
||||
selectedMenu:"home"
|
||||
}
|
||||
}
|
||||
selectedMenu: "home"
|
||||
};
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
body,html{
|
||||
body,
|
||||
html {
|
||||
height: 100%;
|
||||
}
|
||||
#app {
|
||||
font-family: 'Avenir', Helvetica, Arial, sans-serif;
|
||||
}
|
||||
#app {
|
||||
font-family: "Avenir", Helvetica, Arial, sans-serif;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
text-align: center;
|
||||
color: #184c18;
|
||||
position: relative;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#app > div:first-child {
|
||||
#app > div:first-child {
|
||||
position: absolute;
|
||||
top: 10px;
|
||||
left: 30px;
|
||||
font-size: x-large;
|
||||
}
|
||||
.content{
|
||||
}
|
||||
.content {
|
||||
padding-top: 60px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
97
dashboard/src/components/Cluster.vue
Normal file
97
dashboard/src/components/Cluster.vue
Normal file
@@ -0,0 +1,97 @@
|
||||
<template>
|
||||
<div id="mountNode"></div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { mapState } from "vuex";
|
||||
import G6 from "@antv/g6";
|
||||
var graph = null;
|
||||
export default {
|
||||
computed: {
|
||||
...mapState({
|
||||
data(state) {
|
||||
let summary = state.summary;
|
||||
// 点集
|
||||
let nodes = [];
|
||||
// 边集
|
||||
let edges = [];
|
||||
this.addServer(summary, nodes, edges);
|
||||
return {
|
||||
nodes,
|
||||
edges
|
||||
};
|
||||
}
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
addServer(node, nodes, edges) {
|
||||
let result = {
|
||||
id: node.Address,
|
||||
label: node.Address,
|
||||
description: `cpu:${node.CPUUsage >> 0}% mem:${node.Memory.Usage >>
|
||||
0}%`,
|
||||
shape: "modelRect",
|
||||
logoIcon: {
|
||||
show: false
|
||||
}
|
||||
};
|
||||
nodes.push(result);
|
||||
if (node.Rooms) {
|
||||
for (let i = 0; i < node.Rooms.length; i++) {
|
||||
let room = node.Rooms[i];
|
||||
let roomId = result.id + room.StreamPath;
|
||||
nodes.push({
|
||||
id: roomId,
|
||||
label: room.StreamPath,
|
||||
shape: "rect"
|
||||
});
|
||||
edges.push({ source: result.id, target: roomId });
|
||||
if (room.SubscriberInfo) {
|
||||
for (let j = 0; j < room.SubscriberInfo.length; j++) {
|
||||
let subId = roomId + room.SubscriberInfo[j].ID;
|
||||
nodes.push({
|
||||
id: subId,
|
||||
label: room.SubscriberInfo[j].ID
|
||||
});
|
||||
edges.push({ source: roomId, target: subId });
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (node.Children && node.Children.length > 0) {
|
||||
for (let i = 0; i < node.Children.length; i++) {
|
||||
let child = this.addServer(node.Children[i], nodes, edges);
|
||||
edges.push({
|
||||
source: result.id,
|
||||
target: child.id
|
||||
});
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
data(v) {
|
||||
if (graph) {
|
||||
graph.read(v); // 加载数据
|
||||
}
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
graph = new G6.Graph({
|
||||
renderer: "svg",
|
||||
container: "mountNode", // 指定挂载容器
|
||||
width: 800, // 图的宽度
|
||||
height: 500, // 图的高度
|
||||
layout: {
|
||||
type: "radial"
|
||||
},
|
||||
defaultNode: {}
|
||||
});
|
||||
graph.read(this.data); // 加载数据
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
62
dashboard/src/components/Subscribers.vue
Normal file
62
dashboard/src/components/Subscribers.vue
Normal file
@@ -0,0 +1,62 @@
|
||||
<template>
|
||||
<Modal v-bind="$attrs" draggable v-on="$listeners" title="查看订阅者">
|
||||
<Table :columns="subtableColumns" :data="data"></Table>
|
||||
</Modal>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
props: {
|
||||
data: Array
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
subtableColumns: [
|
||||
{
|
||||
title: "类型",
|
||||
key: "Type"
|
||||
},
|
||||
{
|
||||
title: "Name",
|
||||
key: "ID"
|
||||
},
|
||||
{
|
||||
title: "订阅时间",
|
||||
render(h, { row }) {
|
||||
return h("StartTime", {
|
||||
props: {
|
||||
value: row.SubscribeTime
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
{
|
||||
title: "丢帧",
|
||||
render(h, { row }) {
|
||||
return h(
|
||||
"span",
|
||||
row.TotalPacket ? row.TotalDrop + "/" + row.TotalPacket : ""
|
||||
);
|
||||
}
|
||||
},
|
||||
{
|
||||
title: "Buffer",
|
||||
render(h, { row }) {
|
||||
return h("Progress", {
|
||||
props: {
|
||||
percent: Math.floor((row.BufferLength * 99) / 1024),
|
||||
"text-inside": true,
|
||||
"stroke-width": 20,
|
||||
"stroke-color": ["#87d068", "#ff0000"]
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
@@ -38,6 +38,7 @@ export default new Vuex.Store({
|
||||
summaryES.onmessage = evt => {
|
||||
if (!evt.data) return
|
||||
let summary = JSON.parse(evt.data)
|
||||
summary.Address = location.hostname
|
||||
commit("update", { summary })
|
||||
}
|
||||
},
|
||||
|
@@ -15,10 +15,7 @@
|
||||
{{item.VideoInfo.SPSInfo.Width}}x{{item.VideoInfo.SPSInfo.Height}}
|
||||
</p>
|
||||
<ButtonGroup size="small">
|
||||
<Button
|
||||
@click="onShowDetail(item)"
|
||||
icon="ios-people"
|
||||
>{{item.SubscriberInfo?item.SubscriberInfo.length:0}}</Button>
|
||||
<Button @click="onShowDetail(item)" icon="ios-people">{{getSubscriberCount(item)}}</Button>
|
||||
<Button v-if="item.Type" @click="preview(item)" icon="md-eye"></Button>
|
||||
<Button
|
||||
@click="stopRecord(item)"
|
||||
@@ -34,7 +31,9 @@
|
||||
</div>
|
||||
</div>
|
||||
</TabPane>
|
||||
<TabPane label="集群总览" icon="ios-cloud"></TabPane>
|
||||
<TabPane label="集群总览" icon="ios-cloud">
|
||||
<Cluster />
|
||||
</TabPane>
|
||||
<TabPane label="录制的视频" icon="ios-folder" name="recordsPanel">
|
||||
<Records ref="recordsPanel" />
|
||||
</TabPane>
|
||||
@@ -56,6 +55,7 @@
|
||||
>磁盘使用:{{networkFormat(HardDisk.Used,"M")}} 占比:{{HardDisk.Usage.toFixed(2)}}%</Alert>
|
||||
</div>
|
||||
<Jessibuca ref="jessibuca" v-model="showPreview"></Jessibuca>
|
||||
<Subscribers :data="currentStream && currentStream.SubscriberInfo" v-model="showSubscribers" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -66,7 +66,8 @@ import StartTime from "../components/StartTime";
|
||||
import Records from "../components/Records";
|
||||
import Logs from "../components/Logs";
|
||||
import Config from "../components/Config";
|
||||
|
||||
import Subscribers from "../components/Subscribers";
|
||||
import Cluster from "../components/Cluster";
|
||||
const uintInc = {
|
||||
"": "K",
|
||||
K: "M",
|
||||
@@ -106,12 +107,16 @@ export default {
|
||||
StartTime,
|
||||
Records,
|
||||
Logs,
|
||||
Config
|
||||
Subscribers,
|
||||
Config,
|
||||
Cluster
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
showPreview: false,
|
||||
showSubscribers: false,
|
||||
currentTab: "",
|
||||
currentStream: [],
|
||||
typeMap: {
|
||||
FlvFile: "🎥",
|
||||
TS: "🎬",
|
||||
@@ -143,14 +148,21 @@ export default {
|
||||
totalInNetSpeed(state) {
|
||||
return (
|
||||
this.networkFormat(
|
||||
state.summary.NetWork.reduce((aac, c) => aac + c.ReceiveSpeed, 0)
|
||||
state.summary.NetWork
|
||||
? state.summary.NetWork.reduce(
|
||||
(aac, c) => aac + c.ReceiveSpeed,
|
||||
0
|
||||
)
|
||||
: 0
|
||||
) + "/S"
|
||||
);
|
||||
},
|
||||
totalOutNetSpeed(state) {
|
||||
return (
|
||||
this.networkFormat(
|
||||
state.summary.NetWork.reduce((aac, c) => aac + c.SentSpeed, 0)
|
||||
state.summary.NetWork
|
||||
? state.summary.NetWork.reduce((aac, c) => aac + c.SentSpeed, 0)
|
||||
: 0
|
||||
) + "/S"
|
||||
);
|
||||
}
|
||||
@@ -158,15 +170,24 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
...mapActions(["fetchSummary", "stopFetchSummary"]),
|
||||
getSubscriberCount(item) {
|
||||
if (
|
||||
this.currentStream &&
|
||||
this.currentStream.StreamPath == item.StreamPath
|
||||
) {
|
||||
this.currentStream = item;
|
||||
}
|
||||
return item.SubscriberInfo ? item.SubscriberInfo.length : 0;
|
||||
},
|
||||
preview(item) {
|
||||
this.$refs.jessibuca.play(
|
||||
"ws://" + location.hostname + ":8080/" + item.StreamPath
|
||||
);
|
||||
this.showPreview = true;
|
||||
},
|
||||
onShowDetail() {
|
||||
// this.showDetail = true
|
||||
// this.currentSub = item
|
||||
onShowDetail(item) {
|
||||
this.showSubscribers = true;
|
||||
this.currentStream = item;
|
||||
},
|
||||
networkFormat(value, unit = "") {
|
||||
if (value > 1024 && uintInc[unit]) {
|
||||
|
@@ -118,7 +118,7 @@ func (s *ServerSummary) collect() {
|
||||
s.NetWork[i].Name = n.Name
|
||||
s.NetWork[i].Receive = n.BytesRecv
|
||||
s.NetWork[i].Sent = n.BytesSent
|
||||
if s.lastNetWork != nil {
|
||||
if s.lastNetWork != nil && len(s.lastNetWork) > i {
|
||||
s.NetWork[i].ReceiveSpeed = n.BytesRecv - s.lastNetWork[i].Receive
|
||||
s.NetWork[i].SentSpeed = n.BytesSent - s.lastNetWork[i].Sent
|
||||
}
|
||||
|
@@ -4,14 +4,15 @@ import (
|
||||
"bytes"
|
||||
"compress/gzip"
|
||||
"context"
|
||||
. "github.com/langhuihui/monibuca/monica"
|
||||
"github.com/quangngotan95/go-m3u8/m3u8"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"log"
|
||||
"net/http"
|
||||
"path/filepath"
|
||||
"time"
|
||||
|
||||
. "github.com/langhuihui/monibuca/monica"
|
||||
"github.com/quangngotan95/go-m3u8/m3u8"
|
||||
)
|
||||
|
||||
type HLS struct {
|
||||
@@ -94,8 +95,8 @@ func (p *HLS) run(info *M3u8Info) {
|
||||
if len(tsItems) > 3 {
|
||||
tsItems = tsItems[len(tsItems)-3:]
|
||||
}
|
||||
info.M3u8Info = make([]TSCost, len(tsItems))
|
||||
for i, v := range tsItems {
|
||||
info.M3u8Info = nil
|
||||
for _, v := range tsItems {
|
||||
tsCost := TSCost{}
|
||||
tsUrl, _ := info.Req.URL.Parse(v.Segment)
|
||||
tsReq, _ := http.NewRequest("GET", tsUrl.String(), nil)
|
||||
@@ -122,7 +123,7 @@ func (p *HLS) run(info *M3u8Info) {
|
||||
} else if err != nil {
|
||||
log.Printf("%s reqTs:%v", p.StreamPath, err)
|
||||
}
|
||||
info.M3u8Info[i] = tsCost
|
||||
info.M3u8Info = append(info.M3u8Info, tsCost)
|
||||
}
|
||||
|
||||
time.Sleep(time.Second * time.Duration(playlist.Target) * 2)
|
||||
|
Reference in New Issue
Block a user