CN112528334B - Data acquisition method and device based on blockchain network and computer equipment - Google Patents

Data acquisition method and device based on blockchain network and computer equipment Download PDF

Info

Publication number
CN112528334B
CN112528334B CN202011487796.XA CN202011487796A CN112528334B CN 112528334 B CN112528334 B CN 112528334B CN 202011487796 A CN202011487796 A CN 202011487796A CN 112528334 B CN112528334 B CN 112528334B
Authority
CN
China
Prior art keywords
data
performance data
dimension
report
acquisition
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011487796.XA
Other languages
Chinese (zh)
Other versions
CN112528334A (en
Inventor
张丽莎
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hainan Boying Electronic Sports Co ltd
Shenzhen Lian Intellectual Property Service Center
Original Assignee
Hainan Boying Electronic Sports Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hainan Boying Electronic Sports Co ltd filed Critical Hainan Boying Electronic Sports Co ltd
Priority to CN202011487796.XA priority Critical patent/CN112528334B/en
Publication of CN112528334A publication Critical patent/CN112528334A/en
Application granted granted Critical
Publication of CN112528334B publication Critical patent/CN112528334B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/62Protecting access to data via a platform, e.g. using keys or access control rules
    • G06F21/6218Protecting access to data via a platform, e.g. using keys or access control rules to a system of files or objects, e.g. local or distributed file system or database
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/30Authentication, i.e. establishing the identity or authorisation of security principals
    • G06F21/44Program or device authentication
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Computing Systems (AREA)
  • Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • General Health & Medical Sciences (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention provides a data acquisition method, a device and computer equipment based on a blockchain network, wherein the method comprises the following steps: a first block chain link point records the data information and the instruction record into the block chain network; transmitting a data acquisition message to a corresponding second blockchain node in the blockchain network according to the data information; receiving parameter data acquired in real time; responding to the instruction according to the parameter data to generate a corresponding performance data report; and sending the performance data report to the terminal. The invention has the beneficial effects that: corresponding parameter data is acquired through the blockchain network, and a corresponding performance data report is generated according to the acquired parameter data, so that the corresponding performance data report is automatically generated, the workload of accounting personnel is reduced, and the confidentiality of data is improved.

Description

Data acquisition method and device based on blockchain network and computer equipment
Technical Field
The present invention relates to the field of blockchain, and in particular, to a method and apparatus for acquiring data based on a blockchain network, and a computer device.
Background
At present, when a JMeter script (a java-based pressure testing tool) acquires parameter data, a corresponding performance data report cannot be directly generated, verification can only be manually performed, and because the performance data report needs data generation of multiple dimensions, all data are required to be sent to corresponding verification personnel for calculation, on one hand, the workload of the verification personnel is increased, and on the other hand, the safety of the data cannot be guaranteed.
Disclosure of Invention
The invention mainly aims to provide a data acquisition method, a data acquisition device and computer equipment based on a blockchain network, and aims to solve the problem that the safety of data cannot be guaranteed.
The invention provides a data acquisition method based on a block chain network, which comprises the following steps:
the method comprises the steps that a first block chain link point receiving terminal is used for obtaining an obtaining instruction of performance data, wherein the first block chain node is a node in a pre-constructed block chain network, and the obtaining instruction comprises authority information of the terminal for obtaining the performance data;
judging whether the authority information meets preset acquisition authorities or not;
if the acquisition permission is met, analyzing data information used for representing an address where performance data are located in the acquisition instruction, and recording the data information and the acquisition instruction into the blockchain network;
sending a performance data acquisition request to a second blockchain node in the blockchain network according to the address represented by the data information;
and receiving the parameter data based on the performance data acquired by the JMeter in real time and sent by each second blockchain node, generating a performance data report, and sending the performance data report to the terminal.
Further, after the step of receiving the parameter data based on the performance data obtained by JMeter in real time and sent by each second blockchain node and generating a performance data report, the method further includes:
acquiring a conference file uploaded by the terminal;
identifying a data form in the conference file through a semantic identification technology, and acquiring performance data required by the data form;
and acquiring the performance data required by the data table from the performance data report, and importing the performance data into the data table.
Further, the step of receiving the parameter data based on the performance data obtained by JMeter in real time and sent by each second blockchain node and generating a performance data report includes:
detecting whether abnormal data exists in the performance data report;
if abnormal data exist, acquiring position information of the abnormal data;
transmitting the location information and the abnormal data to the second blockchain node;
and receiving the generation reason of the abnormal data sent by the second blockchain node and marking the generation reason in the performance data report.
Further, the step of detecting whether abnormal data exists in the performance data report includes:
acquiring data of the same dimension in the performance data report;
calculating the difference value between each dimension data and other dimension data in the data of the same dimension, and establishing a difference value set for each dimension data according to the difference value;
according to the formulaCalculating the density of each difference set, wherein ρ c (O) represents the density of each difference set, N (O) represents the difference set, P represents one of the other dimensional data, O represents the dimensional data, d c (O, P) represents the difference value between other dimension data P and dimension data O, and c is a preset constant;
according to the formulaCalculating an outlier of the set of differences; wherein LOF c (O) represents an outlier of the dimension data, N represents all dimension data in the same dimension, ρ c (P) represents the density of the difference set corresponding to the dimension data P;
judging whether the abnormal value is larger than a preset abnormal value or not;
if the dimension data is larger than the preset abnormal value, judging that the dimension data corresponding to the abnormal value is abnormal data.
Further, the step of generating the performance data report includes:
acquiring the subject information of the performance data required to be acquired in the acquisition instruction;
extracting initial data corresponding to the subject information from the parameter data;
acquiring a preset processing mode for processing each initial data in the subject information, and processing the initial data according to a corresponding preset processing mode to obtain target data;
and importing the target data into an initial data table to obtain the performance data report.
Further, before the step of the first block link point receiving terminal for acquiring the performance data acquisition instruction, the method includes:
creating a blockchain class by using a Go language, giving specific parameters to the blockchain class, thereby obtaining an created blockchain node, and setting a hash value in the created block;
generating sub-blockchain nodes by adopting a preset blockchain node generation technology based on the created blockchain nodes so as to build the blockchain network; the sub-block chain nodes record hash values of adjacent previous block chain nodes, and the first block chain node and each second block chain node are respectively one sub-block chain node.
Further, after the step of sending the performance data report to the terminal, the method includes:
acquiring a reference performance data report closest to the time of the performance data report from a database storing the performance data report;
comparing each dimension of the performance data report with the reference performance data report;
according to the formulaCalculating a difference value between the reference performance data report and the performance data report; wherein X represents the reference performance data report, Y represents the performance data report, and X i A value representing the ith dimension of the reference performance data report, y i And (3) representing the numerical value of the ith dimension of the performance data report, wherein n represents the number of dimensions, and f (X, Y) represents the difference value.
The invention also provides a data acquisition device based on the block chain network, which comprises:
the system comprises an instruction acquisition module, a performance data acquisition module and a performance data processing module, wherein the instruction acquisition module is used for acquiring an acquisition instruction of performance data, the first blockchain node is a node in a blockchain network constructed in advance, and the acquisition instruction comprises authority information of the terminal for acquiring the performance data;
the permission acquisition verification module is used for judging whether the permission information meets preset permission acquisition;
the data information analysis module is used for analyzing the data information used for representing the address where the performance data is located in the acquisition instruction if the acquisition permission is met, and recording the data information and the acquisition instruction into the blockchain network;
a data acquisition message sending module, configured to send a performance data acquisition request to a second blockchain node in the blockchain network according to the address indicated by the data information;
and the receiving module is used for receiving the parameter data based on the performance data acquired by the JMeter in real time and sent by each second blockchain node, generating a performance data report, and sending the performance data report to the terminal.
The invention also provides a computer device comprising a memory storing a computer program and a processor implementing the steps of any of the methods described above when the processor executes the computer program.
The invention also provides a computer readable storage medium having stored thereon a computer program which when executed by a processor performs the steps of the method of any of the preceding claims.
The invention has the beneficial effects that: and verifying the authority of the terminal through the blockchain network, acquiring corresponding parameter data after the verification is passed, and generating a corresponding performance data report according to the acquired parameter data, thereby realizing automatic generation of the corresponding performance data report, reducing the workload of accounting personnel and improving the confidentiality of the data. In addition, according to the corresponding instruction of the parameter data response, the corresponding performance data report is automatically generated and sent to the terminal, so that the performance data report is automatically generated, and the manual calculation amount is reduced.
Drawings
FIG. 1 is a flow chart of a data acquisition method based on a blockchain network according to an embodiment of the invention;
FIG. 2 is a schematic block diagram of a block chain network based data acquisition device according to an embodiment of the present invention;
fig. 3 is a block diagram schematically illustrating a structure of a computer device according to an embodiment of the present application.
The achievement of the objects, functional features and advantages of the present invention will be further described with reference to the accompanying drawings, in conjunction with the embodiments.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are only some, but not all embodiments of the invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
It should be noted that, in the embodiments of the present invention, all directional indicators (such as up, down, left, right, front, and back) are merely used to explain the relative positional relationship, movement conditions, and the like between the components in a specific posture (as shown in the drawings), if the specific posture is changed, the directional indicators correspondingly change, and the connection may be a direct connection or an indirect connection.
The term "and/or" is herein merely an association relation describing an associated object, meaning that there may be three relations, e.g., a and B, may represent: a exists alone, A and B exist together, and B exists alone.
Furthermore, descriptions such as those referred to as "first," "second," and the like, are provided for descriptive purposes only and are not to be construed as indicating or implying a relative importance or implying an order of magnitude of the indicated technical features in the present disclosure. Thus, a feature defining "a first" or "a second" may explicitly or implicitly include at least one such feature. In addition, the technical solutions of the embodiments may be combined with each other, but it is necessary to base that the technical solutions can be realized by those skilled in the art, and when the technical solutions are contradictory or cannot be realized, the combination of the technical solutions should be considered to be absent and not within the scope of protection claimed in the present invention.
Referring to fig. 1, the invention provides a data acquisition method based on a blockchain network, which comprises the following steps:
s1: the method comprises the steps that a first block chain link point receiving terminal is used for obtaining an obtaining instruction of performance data, wherein the first block chain node is a node in a pre-constructed block chain network, and the obtaining instruction comprises authority information of the terminal for obtaining the performance data;
s2: judging whether the authority information meets preset acquisition authorities or not;
s3: if the acquisition permission is met, analyzing data information used for representing an address where performance data are located in the acquisition instruction, and recording the data information and the acquisition instruction into the blockchain network;
s4: sending a performance data acquisition request to a second blockchain node in the blockchain network according to the address represented by the data information;
s5: and receiving the parameter data based on the performance data acquired by the JMeter in real time and sent by each second blockchain node, generating a performance data report, and sending the performance data report to the terminal.
In the step S1, the first blockchain node receives an acquiring instruction for acquiring performance data from the terminal, where the acquiring instruction should include information for acquiring corresponding parameter data, for example, the acquiring instruction includes a stability performance data report of the software to be acquired, and then the acquiring instruction should acquire a plurality of parameter data related to stability.
As described in step S2, it is determined whether the permission information satisfies a preset acquisition permission. The acquiring instruction contains information containing corresponding parameter data to be acquired, each network node can judge whether the acquiring authority is met or not according to the required parameter data, if the parameter data corresponding to the performance data does not exist in the data of a certain blockchain node, the first blockchain node does not have the right to acquire the parameter data of the blockchain node, and each second blockchain node only sends the corresponding parameter data to the first blockchain node, and the parameter data irrelevant to the performance data does not need to be sent to the first blockchain node, so that the confidentiality of other parameter data of each node is improved. In some embodiments, all the data may be sent to the first blockchain node for storage, so that after the first blockchain node receives a message that the terminal obtains the performance data, the first blockchain node may obtain the corresponding performance data more quickly.
And if the acquisition permission is met, analyzing data information used for representing the address where the performance data is located in the acquisition instruction, and recording the data information and the acquisition instruction into the blockchain network. When the acquisition right is met, the second blockchain node is connected with the corresponding platform, so that a plurality of parameter data can be acquired, in order to improve the confidentiality of the data, the corresponding parameter data in the data information is only required to be sent to the first blockchain node, namely, the acquisition instruction is firstly analyzed to acquire the corresponding data information to be acquired, and in order to facilitate the data recording and sending, the data information and the acquisition instruction can be recorded in the blockchain network.
And as described in the step S4, sending a performance data acquisition request to a second blockchain node in the blockchain network according to the address indicated by the data information. The parameter data to be acquired is compiled into corresponding data acquisition information and is sent to a corresponding second block chain node, and the second block chain node analyzes the parameter data to be acquired contained in the data acquisition information after receiving the corresponding data acquisition information. It should be appreciated that the parameter data that may be acquired by the different second blockchain nodes is also different, and that the different parameter data should be acquired at the corresponding second blockchain node, and that the content in the data acquisition message sent to the different second blockchain nodes may also be different. In some embodiments, the content in the data acquisition messages sent to different second blockchain nodes may also be the same, that is, the acquisition modes of all the parameter data in the data information are included, and each second blockchain node only needs to feed back the parameter data that can be acquired by itself.
As described in the above step S5, the second blockchain node acquires corresponding parameter data in real time based on the JFER. The JMeter is a Java-based stress testing tool developed by the Apache organization for stress testing software. The corresponding parameter data can be obtained through the JMeter, wherein the parameter data can be the performance parameter of the software, and the obtained parameter data can be the performance parameter of the current software operation or the performance parameter in a time period and can be set according to the requirement. After the second block chain nodes acquire the corresponding parameter data, the parameter data are sent to the first block chain nodes, namely the first block chain nodes receive the parameter data acquired by the second block chain nodes in real time based on the jmeters, and corresponding performance data reports are generated according to the acquired parameter data response acquisition instructions. That is, the parameter data acquired by each second blockchain node generally includes multiple dimensions, and the first blockchain node only needs a part of parameter data, so that the corresponding parameter data is screened out according to the acquired parameter data and according to the content in the acquisition instruction, and a performance data report is correspondingly generated and sent to the terminal.
In one embodiment, after the step S5 of receiving the parameter data of the performance data sent by each second blockchain node and obtained in real time based on JMeter and generating a performance data report, the method further includes:
s601: acquiring a conference file uploaded by the terminal;
s602: identifying a data form in the conference file through a semantic identification technology, and acquiring performance data required by the data form;
s603: and acquiring the performance data required by the data table from the performance data report, and importing the performance data into the data table.
As described in the above steps S601-S603, automatic entry of data in the conference file is achieved. Firstly, acquiring a conference file uploaded by a terminal, identifying the conference file through OCR semantics, identifying form parameters in the conference file, for example, the form parameters are parameters of stability of each device, acquiring performance data required by a data form after semantic identification, filling corresponding data in a performance data report form into corresponding positions in the conference file, specifically, acquiring the data form in the conference file, detecting head lifting of the form, and filling data content in the performance data report form into the data form, thereby completing automatic input of the data in the conference file.
In one embodiment, the step S5 of receiving the parameter data of the performance data sent by each second blockchain node and acquired in real time based on JMeter and generating a performance data report includes:
s501: detecting whether abnormal data exists in the performance data report;
s502: if abnormal data exist, acquiring position information forming the abnormal data;
s503: transmitting the location information and the abnormal data to the second blockchain node;
s504: and receiving the generation reason of the abnormal data sent by the second blockchain node and marking the generation reason in the performance data report.
As described in the above steps S501-S504, the marking of the abnormal data is realized, so that the abnormal data can be analyzed later, and the processing speed of the abnormal situation can be increased. Specifically, whether abnormal data exists in the performance data report may be detected first, the detection method may be that an average value of each dimension is calculated, then dimension data differing from the average value by more than a preset value is marked as abnormal data, then position information of the abnormal data is sent to a second blockchain node, and a generation reason of the abnormal data is acquired by the second blockchain node at a corresponding position according to the position information of the abnormal data, wherein the generation reason may be analyzed through big data, that is, after statistics is performed on each abnormal data and the generated reason in advance, a corresponding relation between each abnormal data and the generation reason is established, and the corresponding relation may be that one abnormal data corresponds to a plurality of generation reasons. And then marking the corresponding generation reasons at the set positions of the performance data report. Therefore, the marking of the abnormal data is realized, and the problem can be processed conveniently.
In one embodiment, the step S501 of detecting whether abnormal data exists in the performance data report includes:
s5011: acquiring data of the same dimension in the performance data report;
s5012: calculating the difference value between each dimension data and other dimension data in the data of the same dimension, and establishing a difference value set for each dimension data according to the difference value;
s5013: according to the formulaCalculating the density of each difference set, wherein ρ c (O) represents the density of each difference set, N (O) represents the difference set, P represents one of the other dimensional data, O represents the dimensional data, d c (O, P) represents the difference value between other dimension data P and dimension data O, and c is a preset constant;
s5014: according to the formulaCalculating an outlier of the set of differences; wherein LOF c (O) represents an outlier of the dimension data, N represents all dimension data in the same dimension, ρ c (P) represents the density of the difference set corresponding to the dimension data P;
s5015: judging whether the abnormal value is larger than a preset abnormal value or not;
s5016: if the dimension data is larger than the preset abnormal value, judging that the dimension data corresponding to the abnormal value is abnormal data.
As described in the above steps S7011-S7016, detection of abnormal data is achieved, specifically, detection of each data of each dimension is performed, where the difference between each dimension data and other dimension data in the same dimension may be calculated first, so as to reflect the phase difference between each dimension data and other dimension data. The density of the difference value set of the dimension data can be obtained according to a formula, the density can also be considered as the density corresponding to the dimension data, then the abnormal value in the difference value set is calculated according to the formula, whether the dimension data is abnormal or not is judged according to the abnormal value, the judging method can be that a preset abnormal value is set, the obtained abnormal value is compared with the preset abnormal value, if the obtained abnormal value is larger than the preset abnormal value, the dimension data is considered to be abnormal, and if the preset abnormal value is not reached, the dimension data is considered to be normal.
In one embodiment, the step S7 of generating a performance data report includes:
s711: acquiring the subject information of the performance data required to be acquired in the acquisition instruction;
s712: extracting initial data corresponding to the subject information from the parameter data;
s713: acquiring a preset processing mode for processing each initial data in the subject information, and processing the initial data according to a corresponding preset processing mode to obtain target data;
s714: and importing the target data into an initial data table to obtain the performance data report.
As described in steps S711-S714 above, the generation of the performance data report is accomplished. Specifically, the acquiring instruction includes each piece of theme information, that is, data information to be acquired, and then acquires initial data in parameter data according to the theme information, and since the initial data cannot meet the needs in most cases, further processing needs to be performed on the initial data, that is, corresponding preset processing modes are required, of course, different processing modes are required for different initial data, average values are required for some initial data, sum needs to be calculated for some initial data, probability that abnormal values need to be counted for some initial data, and the like, the initial data can be acquired according to the corresponding theme information, finally target data corresponding to the theme information is obtained, and the target data is imported into a table to obtain a final performance data report. Therefore, the technical effects of automatically obtaining corresponding target data according to the obtained initial data and further generating the performance data report are achieved, and the workload of accounting staff is greatly reduced.
In one embodiment, before the step S1 of receiving the acquiring instruction of the terminal to acquire the performance data, the first blockchain node includes:
s001: creating a blockchain class by using a Go language, giving specific parameters to the blockchain class, thereby obtaining an created blockchain node, and setting a hash value in the created block;
s002: generating sub-blockchain nodes by adopting a preset blockchain node generation technology based on the created blockchain nodes so as to build the blockchain network; the sub-block chain nodes record hash values of adjacent previous block chain nodes, and the first block chain node and each second block chain node are respectively one sub-block chain node.
Building a blockchain network is achieved as described in steps S401-S403 above. The language in which the blockchain class is created may be any feasible language, such as JAVA, C++, go, etc., with the Go language being preferred for this embodiment to optimize the blockchain class. The method comprises the steps of defining a blockchain, instantiating the blockchain, namely determining specific parameters of the blockchain, so as to obtain a first blockchain node (an originating blockchain node), and taking the first blockchain node as a generation basis of other sub-blockchain nodes. Since the originating blockchain node is the first blockchain node, there is virtually no previous block, and therefore the hash value of the originating blockchain node needs to be set. The preset consensus mechanism can be any consensus mechanism, such as a workload proof mechanism, a rights proof mechanism, a Bayesian fault tolerance mechanism, etc. The preset block generation technology is, for example, setting a block head and a block body; a hash value of a previous block in the block header, a hash value of a local block and a timestamp; the data prepared in advance is stored in the block body so that the block head and the block body constitute one block.
In one embodiment, after the step S8 of sending the performance data report to the terminal, the method includes:
s901: acquiring a reference performance data report of the performance data report;
s902: comparing each dimension of the performance data report with the reference performance data report;
s903: according to the formulaCalculating a difference value between the reference performance data report and the performance data report; wherein X represents the reference performance data report, Y represents the performance data report, and X i A value representing the ith dimension of the reference performance data report, y i And (3) representing the numerical value of the ith dimension of the performance data report, wherein n represents the number of dimensions, and f (X, Y) represents the difference value.
As described in the above steps S901-S903, the analysis of the performance data report is implemented, that is, the reference performance data report of the performance data report is obtained, in the process of detecting the software, multiple detection and analysis are required to be performed on the software, and each function of the software is continuously optimized, so that the current performance data report needs to be compared with the reference or the previous parts, in this embodiment, the reference performance data report is compared, that is, the obtained performance data report is compared with the reference performance data report in each dimension, the difference value is calculated according to the formula, the data analysis is performed on the performance data report and the reference report according to the difference value, when the difference value is too large, the change condition of the software is illustrated to be large, and when the difference value is small, the change condition of the software is illustrated to be small.
The invention has the beneficial effects that: and verifying the authority of the terminal through the blockchain network, acquiring corresponding parameter data after the verification is passed, and generating a corresponding performance data report according to the acquired parameter data, thereby realizing automatic generation of the corresponding performance data report, reducing the workload of accounting personnel and improving the confidentiality of data.
Referring to fig. 2, the present invention further provides a data acquisition device based on a blockchain network, including:
the instruction acquisition module 10 is used for receiving an acquisition instruction of a terminal for acquiring performance data, wherein the first blockchain node is a node in a blockchain network constructed in advance, and the acquisition instruction comprises authority information of the terminal for acquiring the performance data;
the acquisition permission verification module 20 is configured to determine whether the permission information meets a preset acquisition permission;
the data information analysis module 30 is configured to analyze data information, which is used for representing an address where the performance data is located, in the acquisition instruction if the acquisition permission is satisfied, and record the data information and the acquisition instruction into the blockchain network;
a data acquisition message sending module 40, configured to send a performance data acquisition request to a second blockchain node in the blockchain network according to the address indicated by the data information;
and the receiving module 50 is used for receiving the parameter data based on the performance data acquired by the JMeter in real time and sent by each second blockchain node, generating a performance data report, and sending the performance data report to the terminal.
In one embodiment, the blockchain network-based data acquisition device further includes:
the conference file acquisition module is used for acquiring conference files uploaded by the terminal;
the data form identification module is used for identifying the data form in the conference file through a semantic identification technology and acquiring performance data required by the data form;
and the content filling module is used for acquiring the performance data required by the data table from the performance data report and importing the performance data into the data table.
In one embodiment, the receiving module 50 includes:
the abnormal data detection sub-module is used for detecting whether abnormal data exists in the performance data report;
the position information acquisition sub-module is used for acquiring position information forming the abnormal data if the abnormal data exist;
a generation cause acquisition sub-module for transmitting the location information and the abnormal data to the second blockchain node;
and the remarking sub-module is used for receiving the generation reason of the abnormal data sent by the second blockchain node and marking the generation reason in the performance data report.
In one embodiment, the abnormal data detection sub-module includes:
the acquisition unit acquires data of the same dimension in the performance data report;
the difference value calculation unit is used for calculating the difference value between each dimension data and other dimension data in the data of the same dimension, and establishing a difference value set for each dimension data according to the difference value;
a density calculating unit for calculating a density according to the formulaCalculating the density of each difference set, wherein ρ c (O) represents the density of each difference set, N (O) represents the difference set, P represents one of the other dimensional data, O represents the dimensional data, d c (O, P) represents the difference value between other dimension data P and dimension data O, and c is a preset constant;
an outlier calculating unit for calculating an outlier according to the formulaCalculating an outlier of the set of differences; wherein LOF c (O) represents an outlier of the dimension data, N represents all dimension data in the same dimension, ρ c (P) represents the density of the difference set corresponding to the dimension data P;
the dimension data judging unit is used for judging whether the abnormal value is larger than a preset abnormal value or not;
and the judging unit is used for judging that the dimension data corresponding to the abnormal value is abnormal data if the dimension data is larger than the preset abnormal value.
In one embodiment, the receiving module 50 includes:
the theme information acquisition sub-module is used for acquiring theme information of the performance data required to be acquired in the acquisition instruction;
an initial data acquisition sub-module, configured to extract initial data corresponding to the subject information from the parameter data;
the theme information processing sub-module is used for acquiring a preset processing mode for processing each initial data in the theme information, and processing the initial data according to a corresponding preset processing mode to obtain target data;
and the target data importing sub-module is used for importing the target data into an initial data table to obtain the performance data report.
In one embodiment, the blockchain network-based data acquisition device further includes:
the giving module is used for creating a blockchain class by using a Go language, giving specific parameters of the blockchain class so as to obtain an created blockchain node, and setting a hash value in the created block;
the building module is used for generating sub-blockchain nodes by adopting a preset blockchain node generation technology based on the generated blockchain nodes so as to build the blockchain network; the sub-block chain nodes record hash values of adjacent previous block chain nodes, and the first block chain node and each second block chain node are respectively one sub-block chain node.
In one embodiment, the blockchain network-based data acquisition device further includes:
the reference performance data report acquisition module is used for acquiring a reference performance data report closest to the performance data report time in a database storing the performance data report;
the dimension comparison module is used for comparing each dimension of the performance data report and the reference performance data report;
the difference value calculation module is used for calculating the difference value according to the formulaCalculating a difference value between the reference performance data report and the performance data report; wherein X represents the reference performance data report, Y represents the performance data report, and X i A value representing the ith dimension of the reference performance data report, y i And (3) representing the numerical value of the ith dimension of the performance data report, wherein n represents the number of dimensions, and f (X, Y) represents the difference value.
Referring to fig. 3, a computer device is further provided in the embodiment of the present application, where the computer device may be a server, and the internal structure of the computer device may be as shown in fig. 3. The computer device includes a processor, a memory, a network interface, and a database connected by a system bus. Wherein the computer is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The database of the computer device is used for storing various parameter data and the like. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program, when executed by a processor, may implement the blockchain network-based data acquisition method of any of the embodiments described above.
Those skilled in the art will appreciate that the architecture shown in fig. 3 is merely a block diagram of a portion of the architecture in connection with the present application and is not intended to limit the computer device to which the present application is applied.
The embodiment of the application further provides a computer readable storage medium, on which a computer program is stored, where the computer program can implement the data acquisition method based on the blockchain network according to any of the above embodiments when executed by a processor.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by hardware associated with a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium provided herein and used in embodiments may include non-volatile and/or volatile memory. The nonvolatile memory can include Read Only Memory (ROM), programmable ROM (PROM), electrically Programmable ROM (EPROM), electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual speed data rate SDRAM (SSRSDRAM), enhanced SDRAM (ESDRAM), synchronous Link DRAM (SLDRAM), memory bus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), among others.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, apparatus, article, or method that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, apparatus, article, or method. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, apparatus, article or method that comprises the element.
The above description is only of the preferred embodiments of the present invention and is not intended to limit the present invention, but various modifications and variations can be made to the present invention by those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention should be included in the scope of the claims of the present invention.

Claims (7)

1. A blockchain network-based data acquisition method, comprising:
the method comprises the steps that a first block chain link point receiving terminal is used for obtaining an obtaining instruction of performance data, wherein the first block chain node is a node in a pre-constructed block chain network, and the obtaining instruction comprises authority information of the terminal for obtaining the performance data;
judging whether the authority information meets preset acquisition authorities or not;
if the acquisition permission is met, analyzing data information used for representing an address where performance data are located in the acquisition instruction, and recording the data information and the acquisition instruction into the blockchain network;
sending a performance data acquisition request to a second blockchain node in the blockchain network according to the address represented by the data information;
acquiring data of the same dimension in the performance data report;
calculating the difference value between each dimension data and other dimension data in the data of the same dimension, and establishing a difference value set for each dimension data according to the difference value;
according to the formulaCalculating the density of each difference set, wherein ρ c (O) represents the density of each difference set, N (O) represents the difference set, P represents one of the other dimensional data, O represents the dimensional data, d c (O, P) represents the difference value between other dimension data P and dimension data O, and c is a preset constant;
according to the formulaCalculating an outlier of the set of differences; wherein LOF c (O) represents an outlier of the dimension data, N represents all dimension data in the same dimension, ρ c (P) represents the density of the difference set corresponding to the dimension data P;
judging whether the abnormal value is larger than a preset abnormal value or not;
if the dimension data is larger than the preset abnormal value, judging that the dimension data corresponding to the abnormal value is abnormal data;
if abnormal data exist, acquiring position information of the abnormal data;
transmitting the location information and the abnormal data to the second blockchain node;
and receiving the generation reason of the abnormal data sent by the second blockchain node, marking the generation reason in the performance data report, and sending the performance data report to the terminal.
2. The blockchain network-based data acquisition method of claim 1, further comprising, after the step of receiving the parameter data of the performance data sent by each of the second blockchain nodes and acquired in real time based on jmeters and generating a performance data report:
acquiring a conference file uploaded by the terminal;
identifying a data form in the conference file through a semantic identification technology, and acquiring performance data required by the data form;
and acquiring the performance data required by the data table from the performance data report, and importing the performance data into the data table.
3. The blockchain network-based data acquisition method of claim 1, wherein before the step of the first blockchain point receiving terminal for acquiring the acquisition instruction of the performance data, the method includes:
creating a blockchain class by using a Go language, giving specific parameters to the blockchain class, thereby obtaining an created blockchain node, and setting a hash value in the created block;
generating sub-blockchain nodes by adopting a preset blockchain node generation technology based on the created blockchain nodes so as to build the blockchain network; the sub-block chain nodes record hash values of adjacent previous block chain nodes, and the first block chain node and each second block chain node are respectively one sub-block chain node.
4. The blockchain network-based data acquisition method of claim 1, wherein after the step of transmitting the performance data report to the terminal, comprising:
acquiring a reference performance data report closest to the time of the performance data report from a database storing the performance data report;
comparing each dimension of the performance data report with the reference performance data report;
according to the formulaCalculating a difference value between the reference performance data report and the performance data report; wherein X represents the reference performance data report, Y represents the performance data report, and X i A value representing the ith dimension of the reference performance data report, y i And (3) representing the numerical value of the ith dimension of the performance data report, wherein n represents the number of dimensions, and f (X, Y) represents the difference value.
5. A blockchain network-based data acquisition device, comprising:
the system comprises an instruction acquisition module, a performance data acquisition module and a performance data processing module, wherein the instruction acquisition module is used for acquiring an acquisition instruction of performance data, a first blockchain node is a node in a blockchain network constructed in advance, and the acquisition instruction comprises authority information of a terminal for acquiring the performance data;
the permission acquisition verification module is used for judging whether the permission information meets preset permission acquisition;
the data information analysis module is used for analyzing the data information used for representing the address where the performance data is located in the acquisition instruction if the acquisition permission is met, and recording the data information and the acquisition instruction into the blockchain network;
a data acquisition message sending module, configured to send a performance data acquisition request to a second blockchain node in the blockchain network according to the address indicated by the data information;
the receiving module is used for acquiring the data with the same dimension in the performance data report;
calculating the difference value between each dimension data and other dimension data in the data of the same dimension, and establishing a difference value set for each dimension data according to the difference value;
according to the formulaCalculating the density of each difference set, wherein ρ c (O) represents the density of each difference set, N (O) represents the difference set, P represents one of the other dimensional data, O represents the dimensional data, d c (O, P) represents the difference value between other dimension data P and dimension data O, and c is a preset constant;
according to the formulaCalculating an outlier of the set of differences; wherein LOF c (O) represents an outlier of the dimension data, N represents all dimension data in the same dimension, ρ c (P) represents the density of the difference set corresponding to the dimension data P;
judging whether the abnormal value is larger than a preset abnormal value or not;
if the dimension data is larger than the preset abnormal value, judging that the dimension data corresponding to the abnormal value is abnormal data;
if abnormal data exist, acquiring position information of the abnormal data;
transmitting the location information and the abnormal data to the second blockchain node;
and receiving the generation reason of the abnormal data sent by the second blockchain node, marking the generation reason in the performance data report, and sending the performance data report to the terminal.
6. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any of claims 1 to 4 when the computer program is executed.
7. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 4.
CN202011487796.XA 2020-12-16 2020-12-16 Data acquisition method and device based on blockchain network and computer equipment Active CN112528334B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011487796.XA CN112528334B (en) 2020-12-16 2020-12-16 Data acquisition method and device based on blockchain network and computer equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011487796.XA CN112528334B (en) 2020-12-16 2020-12-16 Data acquisition method and device based on blockchain network and computer equipment

Publications (2)

Publication Number Publication Date
CN112528334A CN112528334A (en) 2021-03-19
CN112528334B true CN112528334B (en) 2024-01-23

Family

ID=75000689

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011487796.XA Active CN112528334B (en) 2020-12-16 2020-12-16 Data acquisition method and device based on blockchain network and computer equipment

Country Status (1)

Country Link
CN (1) CN112528334B (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20190012969A (en) * 2017-07-31 2019-02-11 서강대학교산학협력단 Data access management system based on blockchain and method thereof
CN109918926A (en) * 2019-02-28 2019-06-21 浪潮软件股份有限公司 Data staging classification method for authenticating, node and block catenary system based on block chain
WO2019157810A1 (en) * 2018-02-13 2019-08-22 华为技术有限公司 Data transmission method and device and network node
CN110334536A (en) * 2019-05-30 2019-10-15 深圳壹账通智能科技有限公司 Data save method, device and computer equipment based on block chain
WO2019205849A1 (en) * 2018-04-28 2019-10-31 腾讯科技(深圳)有限公司 Authentication method and apparatus for blockchain access, and storage medium and electronic apparatus
KR20200105312A (en) * 2019-02-28 2020-09-07 주식회사 케이티 Method and system for sharing data
CN112015964A (en) * 2020-08-22 2020-12-01 王红建 Business data processing method based on block chain and digital finance and big data platform

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20190012969A (en) * 2017-07-31 2019-02-11 서강대학교산학협력단 Data access management system based on blockchain and method thereof
WO2019157810A1 (en) * 2018-02-13 2019-08-22 华为技术有限公司 Data transmission method and device and network node
WO2019205849A1 (en) * 2018-04-28 2019-10-31 腾讯科技(深圳)有限公司 Authentication method and apparatus for blockchain access, and storage medium and electronic apparatus
CN109918926A (en) * 2019-02-28 2019-06-21 浪潮软件股份有限公司 Data staging classification method for authenticating, node and block catenary system based on block chain
KR20200105312A (en) * 2019-02-28 2020-09-07 주식회사 케이티 Method and system for sharing data
CN110334536A (en) * 2019-05-30 2019-10-15 深圳壹账通智能科技有限公司 Data save method, device and computer equipment based on block chain
CN112015964A (en) * 2020-08-22 2020-12-01 王红建 Business data processing method based on block chain and digital finance and big data platform

Also Published As

Publication number Publication date
CN112528334A (en) 2021-03-19

Similar Documents

Publication Publication Date Title
CN109446068B (en) Interface test method, device, computer equipment and storage medium
CN110399293B (en) System test method, device, computer equipment and storage medium
CN110399925B (en) Account risk identification method, device and storage medium
CN110798502B (en) Grayscale publishing method and device based on micro-service framework and computer equipment
CN111314306A (en) Interface access method and device, electronic equipment and storage medium
CN107085549B (en) Method and device for generating fault information
CN111641658A (en) Request intercepting method, device, equipment and readable storage medium
CN110688659A (en) Method and system for dynamically detecting horizontal override based on IAST test tool
CN108256322B (en) Security testing method and device, computer equipment and storage medium
CN109936624B (en) Adaptation method and device for HTTP request message header and computer equipment
CN110046155B (en) Method, device and equipment for updating feature database and determining data features
CN109324956B (en) System testing method, apparatus and computer readable storage medium
CN109344046B (en) Data processing method, device, medium and electronic equipment
CN113918526A (en) Log processing method and device, computer equipment and storage medium
CN113742250B (en) Automatic interface testing method and device
CN105074670B (en) Daily record output control equipment, method and computer readable recording medium storing program for performing
CN113126955A (en) Random data generation method and device, intelligent terminal and storage medium
CN112632330A (en) Method and device for routing inspection of ATM equipment, computer equipment and storage medium
CN112528334B (en) Data acquisition method and device based on blockchain network and computer equipment
CN110321529B (en) Frame text display method and device, computer equipment and storage medium
CN110941543A (en) Log processing method and device, computer equipment and storage medium
CN116185785A (en) Early warning method and device for file abnormal change
CN116166533A (en) Interface testing method, device, terminal equipment and storage medium
CN113435517B (en) Abnormal data point output method, device, computer equipment and storage medium
CN111814145B (en) Request verification method and device based on log acquisition and computer equipment

Legal Events

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
TA01 Transfer of patent application right

Effective date of registration: 20231228

Address after: Room 102, No. 17 Science and Technology Avenue, Hong Kong Macao Industrial Zone, Xiuying District, Haikou City, Hainan Province, 570100

Applicant after: Hainan Boying Electronic Sports Co.,Ltd.

Address before: 518000 Room 202, block B, aerospace micromotor building, No.7, Langshan No.2 Road, Xili street, Nanshan District, Shenzhen City, Guangdong Province

Applicant before: Shenzhen LIAN intellectual property service center

Effective date of registration: 20231228

Address after: 518000 Room 202, block B, aerospace micromotor building, No.7, Langshan No.2 Road, Xili street, Nanshan District, Shenzhen City, Guangdong Province

Applicant after: Shenzhen LIAN intellectual property service center

Address before: 518000 Room 201, building A, No. 1, Qian Wan Road, Qianhai Shenzhen Hong Kong cooperation zone, Shenzhen, Guangdong (Shenzhen Qianhai business secretary Co., Ltd.)

Applicant before: PING AN PUHUI ENTERPRISE MANAGEMENT Co.,Ltd.

GR01 Patent grant
GR01 Patent grant