

技术领域technical field
本发明涉及媒体流存储测试技术领域,具体提供一种流媒体直存系统的高并发测试方法。The invention relates to the technical field of media stream storage testing, and in particular provides a high concurrency testing method of a streaming media direct storage system.
背景技术Background technique
目前流媒体直存系统性能测试方案中,都存在着不同程度的缺陷,有待进一步的改进:At present, the performance test scheme of streaming media direct storage system has defects of varying degrees, which need to be further improved:
(1)对于流媒体直存系统的高性能测试,如果采用实际的媒体流设备,需求量太大,成本较高;如果在现有的实际系统环境下测试,则影响系统稳定性及用户体验效果,均可行性较低;(1) For the high-performance test of the streaming media direct storage system, if the actual media streaming equipment is used, the demand is too large and the cost is high; if the test is performed in the existing actual system environment, it will affect the system stability and user experience. The effect is low in feasibility;
(2)简易的媒体流模拟方法,难以满足高连接数、大数据量、高性能流媒体直存系统的测试,同时无法稳定提供并发服务;(2) The simple media stream simulation method is difficult to meet the test of high connection number, large data volume, and high-performance streaming media direct storage system, and at the same time, it cannot provide concurrent services stably;
(3)通用性及可扩展性差,操作繁琐、测试流程不可控等因素也是流媒体直存系统性能测试的阻碍。(3) Poor versatility and scalability, cumbersome operations, uncontrollable test procedures and other factors are also obstacles to the performance testing of streaming media direct storage systems.
发明内容SUMMARY OF THE INVENTION
本发明的技术任务是针对上述存在的问题,提供一种能够满足高连接数、大数据量、高性能流媒体直存系统的测试需求,并具有较强的可扩展性和通用性的流媒体直存系统的高并发测试方法。The technical task of the present invention is to address the above-mentioned problems, and to provide a streaming media that can meet the testing requirements of a high number of connections, a large amount of data, and a high-performance streaming media direct storage system, and has strong scalability and versatility. A high-concurrency testing method for direct storage systems.
为实现上述目的,本发明提供了如下技术方案:For achieving the above object, the present invention provides the following technical solutions:
一种流媒体直存系统的高并发测试方法,该方法采用流媒体分发技术和异步架构技术构建流媒体放大器组,将单路视频转换为多路视频流,运用媒体存储服务开启流存储,将大量的视频流保存到本地,从而实现模拟大数目设备的视频流输出。A high-concurrency testing method for a streaming media direct storage system, the method adopts streaming media distribution technology and asynchronous architecture technology to construct a streaming media amplifier group, converts a single-channel video into a multi-channel video stream, uses a media storage service to open stream storage, and A large number of video streams are saved locally, so as to simulate the video stream output of a large number of devices.
该流媒体直存系统的高并发测试方法基于流媒体分发技术及异步架构技术构建流媒体放大器,实现以较低成本模拟千台设备对外部系统提供媒体流的方法,能够满足高连接数、大数据量、高性能流媒体直存系统的测试,具有较强的可扩展性和通用。The high concurrency testing method of the streaming media direct storage system builds a streaming media amplifier based on streaming media distribution technology and asynchronous architecture technology, and realizes the method of simulating thousands of devices to provide media streams to external systems at a low cost, which can meet the requirements of high connection number, large The test of data volume and high-performance streaming media direct storage system has strong scalability and generality.
作为优选,该流媒体直存系统的高并发测试方法具体包括以下步骤:Preferably, the high concurrency testing method of the streaming media direct storage system specifically includes the following steps:
S1、媒体转发服务通过Live555拉取视频流,构建流媒体放大器组;S1. The media forwarding service pulls the video stream through Live555 to build a streaming media amplifier group;
S2、媒体存储服务通过流媒体放大器组拉取大数目视频流;S2, the media storage service pulls a large number of video streams through the streaming media amplifier group;
S3、媒体存储服务开启流存储保存视频流到本地。S3. The media storage service enables streaming storage to save the video stream locally.
作为优选,该流媒体直存系统的高并发测试方法还包括以下步骤:Preferably, the high concurrency testing method of the streaming media direct storage system further comprises the following steps:
S4、采集性能数据,优化程序。S4. Collect performance data and optimize the program.
作为优选,步骤S1包括以下流程:Preferably, step S1 includes the following processes:
1)定义媒体转发服务和媒体存储服务的接口地址,及开关、路数全局变量;1) Define the interface addresses of the media forwarding service and the media storage service, as well as the global variables of switches and paths;
2)读取本地视频文件,通过Live555拉取视频文件为小数量视频流;2) Read the local video file, and pull the video file into a small number of video streams through Live555;
3)通过流媒体分发技术,实现从Live555中拉取的视频流分发为大数量的视频流,完成流媒体放大器的构建;3) Through the streaming media distribution technology, the video stream pulled from Live555 can be distributed into a large number of video streams, and the construction of the streaming media amplifier is completed;
4)将多个流媒体放大器构建成流媒体放大器组。4) Constructing a plurality of streaming media amplifiers into a streaming media amplifier group.
作为优选,读取本地视频文件,通过Live555拉取视频文件为小数量视频时,根据入参选择相应视频码流、视频输入输出路数,向媒体转发服务发送相应的JSON数据包,以通过Live555拉取视频流。Preferably, read the local video file, and pull the video file into a small amount of video through Live555, select the corresponding video stream and the number of video input and output channels according to the input parameters, and send the corresponding JSON data packet to the media forwarding service to pass Live555. Pull the video stream.
作为优选,步骤S2中,媒体存储服务通过流媒体放大器组接口,拉取通过流媒体分发技术所得的大数量视频流,将各个视频流输入流媒体存储服务通道,开启流媒体存储服务。Preferably, in step S2, the media storage service pulls a large number of video streams obtained through the streaming media distribution technology through the streaming media amplifier group interface, inputs each video stream into the streaming media storage service channel, and starts the streaming media storage service.
作为优选,步骤S3中,将媒体存储服务通过流媒体放大器组拉流所得的大数目的视频流保存到本地存储盘上,从而模拟各路视频为设备所产生的视频流,以数千路视频同时保存,所产生的高并发数据量作为测试数据。Preferably, in step S3, save the large number of video streams obtained by the media storage service through the streaming media amplifier group to the local storage disk, thereby simulating various video streams as the video streams generated by the device, and using thousands of video streams At the same time, the resulting high concurrent data volume is used as test data.
作为优选,步骤S4中,对视频保存的CPU、内存及I/O吞吐量进行采集,检测流媒体直存系统面对高并发时的效果,并根据相应数据进行程序优化,再经过性能数据采集,循环操作。Preferably, in step S4, the CPU, memory and I/O throughput of video storage are collected, the effect of the streaming media direct storage system in the face of high concurrency is detected, and the program is optimized according to the corresponding data, and then the performance data is collected. , loop operation.
本发明中用的传输协议包括RTSP流媒体传输协议、HTTP协议和NFS协议。Live555服务器通过RTSP流媒体传输协议将视频文件传入媒体转发服务,完成流媒体分发,将视频分成多路视频流。媒体转发服务通过RTSP流媒体传输协议传入媒体存储服务,并通过NFS协议存入本地存储盘中,即可完成对视频流的保存。The transmission protocol used in the present invention includes RTSP streaming media transmission protocol, HTTP protocol and NFS protocol. The Live555 server transmits the video file to the media forwarding service through the RTSP streaming media transmission protocol, completes the streaming media distribution, and divides the video into multiple video streams. The media forwarding service is transmitted to the media storage service through the RTSP streaming media transmission protocol, and stored in the local storage disk through the NFS protocol, so as to complete the preservation of the video stream.
与现有技术相比,本发明的流媒体直存系统的高并发测试方法具有以下突出的有益效果:Compared with the prior art, the high concurrency testing method of the streaming media direct storage system of the present invention has the following outstanding beneficial effects:
(1)节约成本,模拟高并发场景。通过流媒体放大器以及媒体转发服务、媒体存储服务拉流,以较低成本模拟数千台设备所产生视频流的场景,对视频进行存储,模拟了高并发直存的大数量视频流,从而对程序进行测试,即可测出程序面对高并发场景的健壮性;(1) Save costs and simulate high concurrency scenarios. Streaming through streaming media amplifiers, media forwarding services, and media storage services can simulate the scene of video streams generated by thousands of devices at a low cost, store videos, and simulate a large number of video streams with high concurrency and direct storage. The program is tested to measure the robustness of the program in the face of high concurrency scenarios;
(2)调用API,测试流程可控。调用多个已经封装好的API,通过改变调用顺序,以控程序的执行顺序,实现流程可控;(2) Call the API, and the test process is controllable. Call multiple APIs that have been encapsulated, and control the execution order of the program by changing the calling sequence, so that the process can be controlled;
(3)基于http协议的远程原生调用控制流程方法,简易高效。通过post方法提交相应json包到live555服务器以拉取视频流的方法,只需搭建live555服务以及通过调用MSS、MTS、流媒体分发和异步架构等相关技术即可完成自定义的高并发场景模拟;(3) The remote native call control process method based on the http protocol is simple and efficient. The method of submitting the corresponding json package to the live555 server through the post method to pull the video stream, only need to build the live555 service and complete the customized high-concurrency scenario simulation by calling MSS, MTS, streaming media distribution and asynchronous architecture and other related technologies;
(4)利用多个流媒体放大器稳定数据流量。构建流媒体放大器组,避免视频流数据峰值同步,保证数据输入时流量变化的稳定性,使数据流量更稳定,具有良好的推广应用价值。(4) Use multiple streaming media amplifiers to stabilize data flow. Build a streaming media amplifier group to avoid peak synchronization of video stream data, ensure the stability of traffic changes when data is input, make data traffic more stable, and have good promotion and application value.
附图说明Description of drawings
图1是本发明所述流媒体直存系统的高并发测试方法的流程图;Fig. 1 is the flow chart of the high concurrency testing method of the streaming media direct storage system of the present invention;
图2是本发明所述流媒体直存系统的高并发测试方法中构建流媒体放大器示意图;2 is a schematic diagram of building a streaming media amplifier in the high concurrency testing method of the streaming media direct storage system of the present invention;
图3是本发明所述流媒体直存系统的高并发测试方法中构建流媒体放大器组示意图。FIG. 3 is a schematic diagram of constructing a streaming media amplifier group in the high concurrency testing method of the streaming media direct storage system according to the present invention.
具体实施方式Detailed ways
下面将结合附图和实施例,对本发明的流媒体直存系统的高并发测试方法作进一步详细说明。The high concurrency testing method of the streaming media direct storage system of the present invention will be further described in detail below with reference to the accompanying drawings and embodiments.
实施例Example
本发明的流媒体直存系统的高并发测试方法,采用流媒体分发技术和异步架构技术构建流媒体放大器组,将单路视频转换为多路视频流,运用媒体存储服务开启流存储,将大量的视频流保存到本地,从而模拟大数目设备的视频流输出。The high concurrency testing method of the streaming media direct storage system of the present invention adopts the streaming media distribution technology and the asynchronous architecture technology to construct a streaming media amplifier group, converts a single-channel video into a multi-channel video stream, uses the media storage service to open the stream storage, and converts a large number of The video stream is saved locally, thereby simulating the video stream output of a large number of devices.
如图1所示,该流媒体直存系统的高并发测试方法具体包括以下步骤:As shown in Figure 1, the high concurrency testing method of the streaming media direct storage system specifically includes the following steps:
S1、媒体转发服务通过Live555拉取视频流,构建流媒体放大器组。S1. The media forwarding service pulls the video stream through Live555 to build a streaming media amplifier group.
如图2和图3所示,该步骤包括以下流程:As shown in Figure 2 and Figure 3, this step includes the following processes:
1)定义媒体转发服务和媒体存储服务的接口地址,及开关、路数全局变量。1) Define the interface addresses of the media forwarding service and the media storage service, as well as the global variables of switches and paths.
2)读取本地视频文件,通过Live555拉取视频文件为小数量视频流。2) Read the local video file, and pull the video file into a small number of video streams through Live555.
读取本地视频文件,通过Live555拉取视频文件为小数量视频时,根据入参选择相应视频码流、视频输入输出路数,向媒体转发服务发送相应的JSON数据包,以通过Live555拉取视频流。Read the local video file, and pull the video file through Live555 as a small amount of video, select the corresponding video stream and the number of video input and output channels according to the input parameters, and send the corresponding JSON data package to the media forwarding service to pull the video through Live555. flow.
3)通过流媒体分发技术,实现从Live555中拉取的视频流分发为大数量的视频流,完成流媒体放大器组的构建。3) Through the streaming media distribution technology, the video streams pulled from Live555 are distributed into a large number of video streams, and the construction of the streaming media amplifier group is completed.
4)将多个流媒体放大器构建成流媒体放大器组。4) Constructing a plurality of streaming media amplifiers into a streaming media amplifier group.
S2、媒体存储服务通过流媒体存储服务拉取大数目视频流。S2. The media storage service pulls a large number of video streams through the streaming media storage service.
媒体存储服务通过流媒体放大器组接口,拉取通过流媒体分发技术所得的大数量视频流,将各个视频流放入媒体存储服务通道,开启流媒体存储服务。The media storage service pulls a large number of video streams obtained through the streaming media distribution technology through the streaming media amplifier group interface, puts each video stream into the media storage service channel, and starts the streaming media storage service.
S3、流媒体存储服务开启流存储保存视频流到本地。S3. The streaming media storage service enables streaming storage to save the video stream locally.
媒体存储服务通过流媒体放大器组拉流所得的大数目的视频流保存到本地存储盘上,从而模拟各路视频为设备所产生的视频流,以数千路视频同时保存,所产生的高并发数据量作为测试数据。The media storage service saves a large number of video streams obtained by pulling the stream through the streaming media amplifier group to the local storage disk, thereby simulating the video streams generated by the device for each channel of video, and saving thousands of videos at the same time, resulting in high concurrency. The amount of data is used as test data.
S4、采集性能数据,优化程序。S4. Collect performance data and optimize the program.
对视频保存的CPU、内存及I/O吞吐量进行采集,检测流媒体直存系统面对高并发时的效果,并根据相应数据进行程序优化,再经过性能数据采集,循环操作。Collects the CPU, memory and I/O throughput of video storage, detects the effect of the streaming media direct storage system in the face of high concurrency, and optimizes the program according to the corresponding data, and then collects performance data and operates in a loop.
该流媒体直存系统的高并发测试方法基于流媒体分发技术及异步架构技术构建流媒体放大器,实现以较低成本模拟千台设备对外部系统提供媒体流的方法,能够满足高连接数、大数据量、高性能流媒体直存系统的测试,具有较强的可扩展性和通用性。The high concurrency testing method of the streaming media direct storage system builds a streaming media amplifier based on streaming media distribution technology and asynchronous architecture technology, and realizes the method of simulating thousands of devices to provide media streams to external systems at a low cost, which can meet the requirements of high connection number, large The test of data volume and high-performance streaming media direct storage system has strong scalability and versatility.
以上所述的实施例,只是本发明较优选的具体实施方式,本领域的技术人员在本发明技术方案范围内进行的通常变化和替换都应包含在本发明的保护范围内。The above-mentioned embodiments are only preferred specific embodiments of the present invention, and the usual changes and substitutions made by those skilled in the art within the scope of the technical solutions of the present invention should be included in the protection scope of the present invention.
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201910940903.0ACN110635969B (en) | 2019-09-30 | 2019-09-30 | High concurrency test method for streaming media direct memory system |
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201910940903.0ACN110635969B (en) | 2019-09-30 | 2019-09-30 | High concurrency test method for streaming media direct memory system |
| Publication Number | Publication Date |
|---|---|
| CN110635969Atrue CN110635969A (en) | 2019-12-31 |
| CN110635969B CN110635969B (en) | 2022-09-13 |
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN201910940903.0AActiveCN110635969B (en) | 2019-09-30 | 2019-09-30 | High concurrency test method for streaming media direct memory system |
| Country | Link |
|---|---|
| CN (1) | CN110635969B (en) |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN112153410A (en)* | 2020-09-30 | 2020-12-29 | 郑州信大捷安信息技术股份有限公司 | High-concurrency testing method and system for streaming media service |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2001055913A1 (en)* | 2000-01-28 | 2001-08-02 | Williams Communications, Llc | Method of utilizing a single uniform resource locator for resources with multiple formats |
| WO2001056266A2 (en)* | 2000-01-28 | 2001-08-02 | Ibeam Broadcasting Corporation | Method and apparatus for encoder-based distribution of live video and other streaming content |
| WO2001055912A1 (en)* | 2000-01-28 | 2001-08-02 | Ibeam Broadcasting Corporation | Method and apparatus for client-side authentication and stream selection in a content distribution system |
| WO2003058518A2 (en)* | 2002-01-07 | 2003-07-17 | Stephen James Crampton | Method and apparatus for an avatar user interface system |
| US7657644B1 (en)* | 2002-05-10 | 2010-02-02 | Netapp, Inc. | Methods and apparatus for streaming media multicast |
| US20120282974A1 (en)* | 2011-05-03 | 2012-11-08 | Green Robert M | Mobile device controller application for any security system |
| CN103000228A (en)* | 2011-09-08 | 2013-03-27 | 上海宝信软件股份有限公司 | Storage device test method and system |
| CN105872856A (en)* | 2016-03-21 | 2016-08-17 | 乐视云计算有限公司 | Method and system for distributing stream media files |
| CN107395456A (en)* | 2017-07-18 | 2017-11-24 | 郑州云海信息技术有限公司 | Distributed file system stream directly deposits method of testing and platform |
| WO2018059076A1 (en)* | 2016-09-27 | 2018-04-05 | 华为技术有限公司 | Memory recovery method and apparatus |
| US10200428B1 (en)* | 2016-03-30 | 2019-02-05 | Amazon Technologies, Inc. | Unicast routing of a media stream to subscribers |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2001055913A1 (en)* | 2000-01-28 | 2001-08-02 | Williams Communications, Llc | Method of utilizing a single uniform resource locator for resources with multiple formats |
| WO2001056266A2 (en)* | 2000-01-28 | 2001-08-02 | Ibeam Broadcasting Corporation | Method and apparatus for encoder-based distribution of live video and other streaming content |
| WO2001055912A1 (en)* | 2000-01-28 | 2001-08-02 | Ibeam Broadcasting Corporation | Method and apparatus for client-side authentication and stream selection in a content distribution system |
| WO2003058518A2 (en)* | 2002-01-07 | 2003-07-17 | Stephen James Crampton | Method and apparatus for an avatar user interface system |
| US7657644B1 (en)* | 2002-05-10 | 2010-02-02 | Netapp, Inc. | Methods and apparatus for streaming media multicast |
| US20120282974A1 (en)* | 2011-05-03 | 2012-11-08 | Green Robert M | Mobile device controller application for any security system |
| CN103000228A (en)* | 2011-09-08 | 2013-03-27 | 上海宝信软件股份有限公司 | Storage device test method and system |
| CN105872856A (en)* | 2016-03-21 | 2016-08-17 | 乐视云计算有限公司 | Method and system for distributing stream media files |
| US10200428B1 (en)* | 2016-03-30 | 2019-02-05 | Amazon Technologies, Inc. | Unicast routing of a media stream to subscribers |
| WO2018059076A1 (en)* | 2016-09-27 | 2018-04-05 | 华为技术有限公司 | Memory recovery method and apparatus |
| CN107395456A (en)* | 2017-07-18 | 2017-11-24 | 郑州云海信息技术有限公司 | Distributed file system stream directly deposits method of testing and platform |
| Title |
|---|
| YUNPENG CHAI等: "Efficient Data Migration to Conserve Energy in Streaming Media Storage Systems", 《IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS ( VOLUME: 23, ISSUE: 11, NOV. 2012)》* |
| 万川龙等: "基于P2P网络的视频点播系统设计", 《计算机技术与发展》* |
| 付媛媛: "一种IPTV系统的整体结构设计", 《甘肃科技》* |
| 耿红燕: "流媒体网络中数据质量测试与分析", 《万方硕士论文数据库》* |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN112153410A (en)* | 2020-09-30 | 2020-12-29 | 郑州信大捷安信息技术股份有限公司 | High-concurrency testing method and system for streaming media service |
| CN112153410B (en)* | 2020-09-30 | 2022-02-22 | 郑州信大捷安信息技术股份有限公司 | High-concurrency testing method and system for streaming media service |
| Publication number | Publication date |
|---|---|
| CN110635969B (en) | 2022-09-13 |
| Publication | Publication Date | Title |
|---|---|---|
| CN111723558B (en) | Document display method, device, electronic device and storage medium | |
| WO2021082584A1 (en) | Message exchange method and apparatus, readable medium, and electronic device | |
| CN109299013A (en) | A kind of automatic test approach and device | |
| CN110662017B (en) | A kind of video playback quality detection method and device | |
| CN106021095A (en) | A push mechanism-based Android application automated testing method | |
| CN105306900A (en) | Intelligent scheduling high definition integrated networking video monitoring system based on cloud computing | |
| CN115866331B (en) | Video frame extraction analysis method, device, equipment and storage medium | |
| WO2020248649A1 (en) | Audio and video data synchronous playback method, apparatus and system, electronic device and medium | |
| CN103684925A (en) | Performance test method based on simulation terminal | |
| WO2021042936A1 (en) | Video data processing method, apparatus, electronic device and computer-readable medium | |
| CN111355927B (en) | Monitoring equipment determining method, device, equipment and storage medium based on visual networking | |
| CN110635969B (en) | High concurrency test method for streaming media direct memory system | |
| CN106506483B (en) | ONVIF-based video source group synchronous playback method and device | |
| CN109495776B (en) | Audio sending and playing method and intelligent terminal | |
| CN102647621B (en) | Video synchronous playback device and method | |
| CN103929607A (en) | Communication method based on screen recording, and application client-side | |
| CN112057832B (en) | Live-action riding training system based on mobile streaming media technology | |
| CN111885351B (en) | Screen display method and device, terminal equipment and storage medium | |
| CN114244821A (en) | Data processing method, apparatus, device, electronic device and storage medium | |
| CN113691799A (en) | Live stream interaction control method and corresponding device, equipment and medium | |
| CN109831335B (en) | Data monitoring method, monitoring terminal, storage medium and data monitoring system | |
| CN117955959A (en) | Collaborative transmission method, device, equipment and storage medium for multimedia content | |
| JP2023031248A (en) | Edge computing network, data transmission method, apparatus, device, and storage medium | |
| CN104185042B (en) | A kind of TV guide method of calibration and system | |
| CN105337778A (en) | Internet of Things event-driven service management system |
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| TA01 | Transfer of patent application right | Effective date of registration:20220824 Address after:271000 Langchao science and Technology Park, 527 Dongyue street, Tai'an City, Shandong Province Applicant after:INSPUR SOFTWARE Co.,Ltd. Address before:250100 Ji'nan hi tech Zone No. 2877, Shandong Province Applicant before:INSPUR GROUP Co.,Ltd. | |
| TA01 | Transfer of patent application right | ||
| GR01 | Patent grant | ||
| GR01 | Patent grant |