CN112541718B - Material processing method and device - Google Patents

Material processing method and device Download PDF

Info

Publication number
CN112541718B
CN112541718B CN201910895303.7A CN201910895303A CN112541718B CN 112541718 B CN112541718 B CN 112541718B CN 201910895303 A CN201910895303 A CN 201910895303A CN 112541718 B CN112541718 B CN 112541718B
Authority
CN
China
Prior art keywords
information
message queue
auditing
module
queried
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
CN201910895303.7A
Other languages
Chinese (zh)
Other versions
CN112541718A (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.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and Technology 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 Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN201910895303.7A priority Critical patent/CN112541718B/en
Publication of CN112541718A publication Critical patent/CN112541718A/en
Application granted granted Critical
Publication of CN112541718B publication Critical patent/CN112541718B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/08Logistics, e.g. warehousing, loading or distribution; Inventory or stock management
    • G06Q10/087Inventory or stock management, e.g. order filling, procurement or balancing against orders
    • G06Q10/0875Itemisation or classification of parts, supplies or services, e.g. bill of materials
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/546Message passing systems or structures, e.g. queues
    • 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
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/30Computing systems specially adapted for manufacturing

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Economics (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • Tourism & Hospitality (AREA)
  • Marketing (AREA)
  • Operations Research (AREA)
  • Quality & Reliability (AREA)
  • Strategic Management (AREA)
  • Human Resources & Organizations (AREA)
  • Entrepreneurship & Innovation (AREA)
  • General Business, Economics & Management (AREA)
  • Finance (AREA)
  • Accounting & Taxation (AREA)
  • Development Economics (AREA)
  • General Engineering & Computer Science (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The application discloses a material processing method and a device, which have the specific implementation scheme that material attribute information and position information of materials are obtained from a message queue; constructing an information storage table based on the material attribute information and the position information; wherein, the material attribute information comprises a plurality of identity information of the material; generating a first main key of the material by using at least one identity information; the first primary key is stored in the database in association with the information storage table. The application adopts the technical means that the identity information of the materials is used for generating the first main key and storing the first main key and the information storage table in the database in a correlated way, so that the generated first main key can be used as the identification of the materials, and the technical effects of quickly searching the information storage table of the materials from the database by using the first main key and quickly searching the information of the required materials by using the information storage table are achieved.

Description

Material processing method and device
Technical Field
The present application relates to the field of data processing technologies, and in particular, to a method and an apparatus for processing materials.
Background
In the current material auditing process, all auditing states of the materials are printed to a local file system through a log for recording. However, due to the large amount of audits of some materials, such as advertising materials. Even if the audit state of all materials in each stage is recorded through the logs, the information of the materials to be queried is difficult to quickly query and locate from a plurality of logs.
Disclosure of Invention
The embodiment of the application provides a material processing method and a material processing device, which are used for solving one or more technical problems in the prior art.
In a first aspect, an embodiment of the present application provides a material processing method, including:
acquiring material attribute information and position information of materials from a message queue;
constructing an information storage table based on the material attribute information and the position information; wherein, the material attribute information comprises a plurality of identity information of the material;
generating a first main key of the material by using at least one identity information;
the first primary key is stored in the database in association with the information storage table.
In the embodiment, the first main key is generated by adopting the identity information of the material, so that the generated first main key can be used as the unique identifier of the material, and the associated information storage table can be quickly and accurately searched from the database through the first main key. And the information storage table is constructed based on the material attribute information and the position information, but not the whole information of the material, so that the processing performance of the data is not affected.
In one embodiment, acquiring material attribute information and position information of a material from a message queue includes:
And acquiring material attribute information and position information of the material in the corresponding message queue from at least one of the input message queue, the output message queue, the audit message queue and the audit abnormal message queue.
According to the method and the device, the material attribute information and the position information of the material in the corresponding message queue are obtained, so that the material attribute information and the position information in the corresponding message queue can be utilized to search the related material information of the material in different stages. The material information includes any information related to the material.
In one embodiment, the material handling method further comprises:
subscribing at least one of an input message queue, an output message queue, an audit message queue and an audit exception message queue;
the input message queue is used for storing the material information input into the checking unit, the output message queue is used for storing the material checking information output by the checking unit, the checking message queue is used for storing the material checking information for performing secondary checking on the material checking information output by the checking unit, and the checking abnormal message queue is used for storing abnormal material information checked by the checking unit.
According to the method and the device, through subscribing different message queues, the related material information of the materials in different stages can be obtained from each message queue quickly and accurately.
In one embodiment, using at least one identity information, a first primary key of a material is generated comprising:
converting at least one identity information into a character string format to obtain a first character string;
and carrying out the binary conversion on the first character string to generate a first main key.
According to the embodiment, the identity information is converted in a binary system mode, so that the length of the first primary key character string can be compressed, and the storage space of a database is saved.
In one embodiment, the material handling method further comprises:
acquiring at least one target identity information from a plurality of identity information of a material to be queried;
generating a second main key of the material to be queried by utilizing the target identity information;
searching a first main key corresponding to the second main key from a database;
and acquiring an information storage table of the material to be queried from the database according to the first main key corresponding to the second main key.
The second main key of the embodiment is generated by utilizing the target identity information of the material to be queried, so that the first main key generated by the identity information can be searched through the second main key, and the information storage table of the material to be queried associated with the first main key is obtained according to the first main key.
In one embodiment, the material handling method further comprises:
Acquiring material attribute information and position information of the material to be queried according to an information storage table of the material to be queried;
and acquiring the information of the material to be queried from the target message queue according to the material attribute information and the position information of the material to be queried.
According to the embodiment, the message queue to be queried can be determined according to the material attribute information in the information storage table, and all information related to the material to be queried can be accurately obtained from the corresponding message queue according to the position information.
In one embodiment, generating a second primary key of the material to be queried using the target identity information includes:
converting the target identity information into a character string format to obtain a second character string;
and carrying out the binary conversion on the second character string to generate a second main key.
According to the embodiment, the second character string converted from the target identity information is subjected to the binary conversion, so that the generated second main key can be kept in a uniform format with the first main key, and the corresponding first main key can be found according to the second main key.
In a second aspect, an embodiment of the present application provides a material handling apparatus, including:
the first acquisition module is used for acquiring material attribute information and position information of the material from the message queue;
The construction module is used for constructing an information storage table based on the material attribute information and the position information; wherein, the material attribute information comprises a plurality of identity information of the material;
the first generation module is used for generating a first main key of the material by utilizing at least one identity information;
and the storage module is used for storing the first primary key in the database in association with the information storage table.
In one embodiment, the first acquisition module includes:
and the acquisition sub-module is used for acquiring material attribute information and position information of the material in the corresponding message queue from at least one of the input message queue, the output message queue, the audit message queue and the audit abnormal message queue.
In one embodiment, the material handling apparatus further comprises:
the subscription module is used for subscribing at least one of an input message queue, an output message queue, an audit message queue and an audit abnormal message queue;
the input message queue is used for storing the material information input into the checking unit, the output message queue is used for storing the material checking information output by the checking unit, the checking message queue is used for storing the material checking information for performing secondary checking on the material checking information output by the checking unit, and the checking abnormal message queue is used for storing abnormal material information checked by the checking unit.
In one embodiment, the first generation module includes:
the first conversion sub-module is used for converting at least one identity information into a character string format to obtain a first character string;
and the first generation sub-module is used for carrying out the binary conversion on the first character string to generate a first primary key.
In one embodiment, the material handling apparatus further comprises:
the second acquisition module is used for acquiring at least one target identity information from a plurality of identity information of the material to be inquired;
the second generation module is used for generating a second main key of the material to be queried by utilizing the target identity information;
the searching module is used for searching a first main key corresponding to the second main key from the database;
and the third acquisition module is used for acquiring the information storage table of the material to be queried from the database according to the first main key corresponding to the second main key.
In one embodiment, the material handling apparatus further comprises:
the fourth acquisition module is used for acquiring material attribute information and position information of the material to be inquired according to the information storage table;
and a fifth acquisition module, configured to acquire information of the material to be queried from the target message queue according to the material attribute information and the position information of the material to be queried.
In one embodiment, the second generation module includes:
the second conversion sub-module is used for converting the target identity information into a character string format to obtain a second character string;
and the second generation sub-module is used for carrying out the binary conversion on the second character string to generate a second main key.
In a third aspect, an embodiment of the present application provides an electronic device, where functions of the electronic device may be implemented by hardware, or may be implemented by executing corresponding software by hardware. The hardware or software includes one or more modules corresponding to the functions described above.
In one possible design, the electronic device includes a processor and a memory in a structure thereof, the memory storing a program for supporting the electronic device to execute the above material processing method, and the processor is configured to execute the program stored in the memory. The electronic device may also include a communication interface for communicating with other devices or communication networks.
In a fourth aspect, embodiments of the present application provide a non-transitory computer readable storage medium storing computer instructions for storing electronic equipment and computer software instructions for use by the electronic equipment, including programs for performing the above-described material handling.
In a fifth aspect, a computer program product is provided, comprising a computer program which, when executed by a processor, implements a method as described above.
One embodiment of the above application has the following advantages or benefits: the application adopts the technical means that the identity information of the materials is used for generating the first main key and storing the first main key and the information storage table in the database in a correlated way, so that the generated first main key can be used as the identification of the materials, the technical effects that the information storage table of the materials is quickly searched from the database by using the first main key and the information of the required materials is quickly searched by using the information storage table are achieved, and the technical problem that the information of the materials cannot be quickly obtained is solved.
Other effects of the above alternative will be described below in connection with specific embodiments.
Drawings
The drawings are included to provide a better understanding of the present application and are not to be construed as limiting the application. Wherein:
FIG. 1 is a schematic flow chart of a material handling method according to a first embodiment of the application;
FIG. 2 is a schematic flow chart of another material handling method according to a first embodiment of the application;
FIG. 3 is a flow chart of another material handling method according to a first embodiment of the present application;
FIG. 4 is an application example diagram of a material processing method according to a first embodiment of the present application;
FIG. 5 is an application example diagram of a material processing method according to a first embodiment of the present application;
FIG. 6 is an application example diagram of a material processing method according to a first embodiment of the present application;
fig. 7 is a schematic flow chart of step S300 of the material processing method according to the first embodiment of the present application;
FIG. 8 is a flow chart of another material handling method according to the first embodiment of the present application;
FIG. 9 is a flow chart of another material handling method according to the first embodiment of the application;
fig. 10 is a flow chart of step S700 of the material processing method according to the first embodiment of the present application;
FIG. 11 is a schematic view of a material handling apparatus according to a second embodiment of the present application;
FIG. 12 is a schematic view of a first acquisition module of a material handling apparatus according to a second embodiment of the present application;
FIG. 13 is a schematic view of another material handling apparatus according to a second embodiment of the present application;
FIG. 14 is a schematic view of a first generation module of a material handling apparatus according to a second embodiment of the present application;
FIG. 15 is a schematic view of another material handling apparatus according to a second embodiment of the present application;
FIG. 16 is a schematic view of another material handling apparatus according to a second embodiment of the present application;
FIG. 17 is a schematic view of a second generation module of a material handling apparatus according to a second embodiment of the present application;
fig. 18 is a block diagram of an electronic device for implementing a material handling method of an embodiment of the present application.
Detailed Description
Exemplary embodiments of the present application will now be described with reference to the accompanying drawings, in which various details of the embodiments of the present application are included to facilitate understanding, and are to be considered merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the application. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
According to a first embodiment of the present application, there is provided a material handling method, as shown in fig. 1, comprising:
s100: and acquiring material attribute information and position information of the material from the message queue.
A message queue is understood to be a container that stores information data during material handling. A message queue may store information data for a plurality of items.
The material may include advertising material, film material, news material, etc. The material attribute information may include a plurality of information associated with the material. For example, the item attribute information may include a plurality of identity information (id) associated with the item, version information of the item, content information of the item, name information of the item, and the like. The location information of the material may include a applet index, a message id, a sequence id, etc. The position of the material in the message queue can be accurately acquired through the applet index, the message id and the sequence id.
S200: and constructing an information storage table based on the material attribute information and the position information. The material attribute information comprises a plurality of identity information of materials.
The plurality of identity information for the item may include any identity information associated with the item obtained from the message queue. For example, the identity information may include a product (vendor) id, a user (user) id, a version (version of material) id, and the like of the material.
In one example, to ensure that the generated first primary key can be used as a unique identifier representing the item, a plurality of selected identity information may be used to generate the first primary key of the item. The number of identity information needed specifically can be selected and adjusted according to the type of the material.
S300: a first primary key (row key) of the material is generated using the at least one identity information. The first primary key may be a string of characters of a certain length.
S400: the first primary key is stored in the database in association with the information storage table. The first primary key is used for indexing and distinguishing an information storage table of each material. The information storage table of the corresponding materials can be indexed through all character strings or part of character strings of the first main key.
In this embodiment, the first primary key of the material is generated through the identity information, so that the generated first primary key can be used as the identifier of the material. In this embodiment, the first primary key is stored in the database in association with the information storage table, so that the information storage table can be quickly obtained from the database through the first primary key. And the information storage table stores material attribute information and position information, but not all the information of materials, so that the data processing performance is not affected. And the information of all materials can be obtained by rapidly indexing the information of the material attribute and the position information to the corresponding message queue.
In one embodiment, as shown in fig. 2, acquiring material attribute information and position information of a material from a message queue includes:
S110: and acquiring material attribute information and position information of the material in the corresponding message queue from at least one of the input message queue, the output message queue, the audit message queue and the audit abnormal message queue.
According to the embodiment, by acquiring the material attribute information and the position information of the material in the corresponding message queue, all the information of the material in different stages can be searched by utilizing the material attribute information and the position information in the corresponding message queue.
In one embodiment, as shown in fig. 3, the material handling method further comprises:
s500: at least one of the input message queue, the output message queue, the audit message queue, and the audit exception message queue is subscribed.
The input message queue is used for storing the material information input into the checking unit, the output message queue is used for storing the material checking information output by the checking unit, the checking message queue is used for storing the material checking information for performing secondary checking on the material checking information output by the checking unit, and the checking abnormal message queue is used for storing abnormal material information checked by the checking unit.
According to the method and the device for subscribing the message queue, the material information related to the material can be rapidly and accurately obtained from the message queue.
In one example, the material information stored by the input message queue may include: material attribute information, position information, and the like. The material audit information stored by the output message queue may include: material attribute information, position information, material audit information generated by machine audit of materials, and the like. The material audit information stored in the audit message queue may include: material attribute information, position information, material audit information generated by manually conducting secondary audit on machine audit results, and the like. Auditing the abnormal material information stored by the abnormal message queue may include: material attribute information, position information, specific abnormality cause information and the like of abnormal materials.
In one example, the material audit process, as shown in FIG. 4, includes material input, material audit, and material write-back (i.e., material output) processes. The material input process may include a process of inputting material into an audit unit. The material auditing process may include a process in which the material auditing unit audits the material. The material review process may include a process in which the auditing unit outputs material audit information.
In one example, a material handling method includes:
and synchronously subscribing the input message queue, the output message queue, the audit message queue and the audit abnormal message queue.
And respectively acquiring material attribute information and position information of all the auditing materials in the input message queue, the output message queue, the auditing message queue and the auditing abnormal message queue.
And packaging the material attribute information and the position information of all the auditing materials in each message queue (an input message queue, an output message queue, an auditing message queue and an auditing abnormal message queue) into a protocol buffer form, and sending the protocol buffer form to a downstream server module for processing.
After the parser module obtains the data of the upstream subscription, deserializing the already serialized pb (protobuf). And positioning and tracking a class of target materials needing tracking (trace). And extracting the material information of each material in the target material, acquiring the identity information and the position information in each message queue, packaging the material information into a new protobuf format only recording key information, and transmitting the new protobuf format to a downstream trace-exporter module for processing.
the trace-exporter module is mainly responsible for material information warehousing operation, and because each material in a class of target materials sent upstream is subscribed from different message queues, information of the same material from different message queues needs to be aggregated. And constructing an information storage table of the material according to a plurality of identity information of the same material from different message queues and material attribute information and position information of the different message queues.
In one example, as shown in fig. 5, the constructed information storage table includes at least five columns of information. The method comprises the steps of material id information, information of an input message queue, information of an output message queue, information of an audit message queue and information of an audit abnormal message queue. Wherein, the id information of the material may include: multiple identity information of the material or all identity information of the material. The information of the input message queue may include: the method comprises the steps of enabling a plurality of identity information of materials in an input message queue, material attribute information of the materials in the input message queue and position information of the materials in the input message queue. The information of the output message queue may include: the multiple identity information of the material in the output message queue, the material attribute information of the material in the output message queue, the position information of the material in the output message queue, and the additional information of the material (text, picture, rejected text, rejected image in the material). Auditing information of a message queue may include: the method comprises the steps of checking a plurality of identity information of materials manually checked from a machine, checking material attribute information of the materials in a checking message queue and position information of the materials in the checking message queue. Auditing the information of the exception message queue may include: the method comprises the steps of enabling a plurality of identity information of abnormal materials, material attribute information of the abnormal materials, position information of the materials in an audit abnormal message queue and specific abnormal information of the abnormal materials to be displayed. Since the number of abnormal materials is generally small, recording specific abnormal information into the information storage table hardly has any influence on the information processing performance.
In one example, during the material auditing process, if the material is abnormal, the abnormal material is directly recorded into an auditing abnormal message queue, but not recorded into an output message queue or an auditing message queue.
In one example, as shown in FIG. 6, the information in the audit exception message queue is typically recorded machine audit occurring material exception information. The machine audit module specifically includes a first audit module (e.g., a parser module), a second audit module (e.g., a pair audit module), and a third audit module (e.g., a LP (landing page) audit module, a floor page audit module). After the material processing fails, the three modules can carry out the back-plugging processing on the failed material, and the result is that the material can be blocked in the machine for auditing, so that an auditing result can not be obtained. And extracting the blocking information of each module to obtain the information of the material in the checking abnormal message queue. The extracted back-plug information is ultimately generated into an information storage table and stored in a database.
In one embodiment, as shown in fig. 7, generating a first primary key of a material using at least one identity information, includes:
s310: and converting at least one identity information into a character string format to obtain a first character string.
S320: and carrying out the binary conversion on the first character string to generate a first main key.
According to the embodiment, the identity information is converted in a binary system mode, so that the length of the first primary key character string can be compressed, and the storage space of a database is saved.
In one example, although different materials may have identical types of identity information, even identical content identity information, if multiple identity information of the same material are combined, it may not happen that identical information exists after the combination. Therefore, the identity information of the materials are respectively converted into character string formats, and the character strings are spliced according to a preset sequence to form a first character string. A unique first string of the material may be obtained and a unique first primary key generated.
In one example, when the material is advertising material, generating the plurality of identity information utilized by the first primary key may include: product id, user id, idea id, mc id, unit id, plan id, version id.
In one example, the plurality of identity information of the material is a digital id, each digital id is converted into a decimal string format and spliced together to form a first string of the material. The first character string is then converted to the characters 32-126 in the ASCII code (American Standard Code for Information Interchange ), thereby enabling the decimal number to be converted to a printable character of 94, thereby effectively shortening the length of the character string of the first primary key.
In one embodiment, as shown in fig. 8, the material handling method further includes:
s600: at least one target identity information is obtained from a plurality of identity information of the material to be queried.
S700: and generating a second main key of the material to be queried by using the target identity information.
S800: and searching a first main key corresponding to the second main key from the database.
S900: and acquiring an information storage table of the material to be queried from the database according to the first main key corresponding to the second main key.
The second main key of the embodiment is generated by utilizing the target identity information of the material to be queried, so that the first main key generated by the identity information can be searched through the second main key, and the information storage table of the material to be queried associated with the first main key is obtained according to the first main key.
In one example, finding a first primary key corresponding to a second primary key from a database may be understood as: the database comprises a first main key which is identical with the second main key, or the database comprises the first main key which contains all information of the second main key.
In one embodiment, as shown in fig. 9, the material handling method further includes:
s1000: and acquiring material attribute information and position information of the material to be queried according to the information storage table of the material to be queried.
S1100: and acquiring the information of the material to be queried from the target message queue according to the material attribute information and the position information of the material to be queried.
According to the embodiment, the message queue to be queried can be determined according to the material attribute information in the information storage table, and all information related to the material to be queried can be accurately obtained from the corresponding message queue according to the position information.
In one embodiment, as shown in fig. 10, generating a second primary key of the material to be queried using the target identity information includes:
s710: and converting the target identity information into a character string format to obtain a second character string.
S720: and carrying out the binary conversion on the second character string to generate a second main key.
According to the embodiment, the second character string converted from the target identity information is subjected to the binary conversion, so that the generated second main key can be kept in a uniform format with the first main key, and the corresponding first main key can be found according to the second main key.
In one example, the target identity information of the material to be queried utilized may include the same type of identity information utilized in generating the first primary key of the material. Thereby ensuring that the second primary key generated using the target identity information can be indexed from the database to the corresponding first primary key.
In one example, the number of target identity information utilized to form the second primary key may be less than the number of identity information that forms the first primary key. So that the second primary key formed contains only a portion of the character string in the first primary key. The uniquely corresponding first primary key can also typically be found from the database by this partial character conversion. For example, when the identity information utilized to construct the first primary key includes a product id, a user id, an idea id, an mc id, a unit id, a plan id, and a version id. The identity information utilized to construct the second primary key may include only a product id, a user id, and an idea id.
In another example, the number of target identity information utilized to form the second primary key may be equal to the number of identity information that form the first primary key. So that the character string of the formed second primary key coincides with the character string in the first primary key. Therefore, the unique corresponding first main key can be found from the database rapidly and accurately through the character string of the second main key. For example, when the identity information utilized to construct the first primary key includes a product id, a user id, an idea id, an mc id, a unit id, a plan id, and a version id. The identity information utilized to construct the second primary key may also include a product id, a user id, an idea id, an mc id, a unit id, a plan id, and a version id.
According to a second embodiment of the present application, there is provided a material handling apparatus, as shown in fig. 11, the material handling apparatus 1000 including:
the first acquiring module 10 is configured to acquire material attribute information and location information of a material from the message queue.
A construction module 20, configured to construct an information storage table based on the material attribute information and the location information; the material attribute information comprises a plurality of identity information of materials.
The first generating module 30 is configured to generate a first primary key of the material using at least one identity information.
A storage module 40 for storing the first primary key in association with the information storage table in the database.
In one embodiment, as shown in fig. 12, the first acquisition module 10 includes:
and the obtaining sub-module 11 is configured to obtain material attribute information and position information of the material in the corresponding message queue from at least one of the input message queue, the output message queue, the audit message queue and the audit exception message queue.
In one embodiment, as shown in fig. 13, the material handling apparatus 1000 further includes:
a subscription module 50 for subscribing to at least one of the input message queue, the output message queue, the audit message queue, and the audit exception message queue.
The input message queue is used for storing the material information input into the checking unit, the output message queue is used for storing the material checking information output by the checking unit, the checking message queue is used for storing the material checking information for performing secondary checking on the material checking information output by the checking unit, and the checking abnormal message queue is used for storing abnormal material information checked by the checking unit.
In one embodiment, as shown in fig. 14, the first generation module 30 includes:
the first conversion sub-module 31 is configured to convert at least one identity information into a character string format, so as to obtain a first character string.
The first generation sub-module 32 is configured to perform a binary conversion on the first character string to generate a first primary key.
In one embodiment, as shown in fig. 15, the material handling apparatus 1000 further includes:
the second obtaining module 60 is configured to obtain at least one target identity information from a plurality of identity information of the material to be queried.
The second generating module 70 is configured to generate a second primary key of the material to be queried using the target identity information.
The searching module 80 is configured to search the database for the first primary key corresponding to the second primary key.
And the third obtaining module 90 is configured to obtain, from the database, an information storage table of the material to be queried according to the first primary key corresponding to the second primary key.
In one embodiment, as shown in fig. 16, the material handling apparatus 1000 further includes:
a fourth obtaining module 100, configured to obtain material attribute information and position information of a material to be queried according to the information storage table;
and a fifth obtaining module 110, configured to obtain information of the material to be queried from the target message queue according to the material attribute information and the position information of the material to be queried.
In one embodiment, as shown in fig. 17, the second generating module 70 includes:
the second conversion sub-module 71 is configured to convert the target identity information into a character string format, so as to obtain a second character string.
The second generation sub-module 72 is configured to perform a binary conversion on the second character string to generate a second primary key.
According to embodiments of the present application, the present application also provides an electronic device, a readable storage medium and a computer program product.
As shown in fig. 18, is a block diagram of an electronic device of a method of material handling according to an embodiment of the application. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular telephones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the applications described and/or claimed herein.
As shown in fig. 18, the electronic device includes: one or more processors 901, memory 902, and interfaces for connecting the components, including high-speed interfaces and low-speed interfaces. The various components are interconnected using different buses and may be mounted on a common motherboard or in other manners as desired. The processor may process instructions executing within the electronic device, including instructions stored in or on memory to display graphical information of a graphical user interface (Graphical User Interface, GUI) on an external input/output device, such as a display device coupled to the interface. In other embodiments, multiple processors and/or multiple buses may be used, if desired, along with multiple memories and multiple memories. Also, multiple electronic devices may be connected, each providing a portion of the necessary operations (e.g., as a server array, a set of blade servers, or a multiprocessor system). One processor 901 is illustrated in fig. 18.
Memory 902 is a non-transitory computer readable storage medium provided by the present application. Wherein the memory stores instructions executable by the at least one processor to cause the at least one processor to perform the method of material handling provided by the present application. The non-transitory computer readable storage medium of the present application stores computer instructions for causing a computer to perform the method of material handling provided by the present application.
The memory 902 is used as a non-transitory computer readable storage medium for storing non-transitory software programs, non-transitory computer-executable programs, and modules, such as program instructions/modules (e.g., the first acquisition module 10, the construction module 20, the first generation module 30, and the storage module 40 of fig. 11) corresponding to the method of processing materials in the embodiments of the present application. The processor 901 executes various functional applications of the server and data processing, i.e., a method of realizing the material processing in the above-described method embodiments, by running non-transitory software programs, instructions, and modules stored in the memory 902.
The memory 902 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, at least one application program required for a function; the storage data area may store data created from the use of the electronic device for material handling, etc. In addition, the memory 902 may include high-speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory 902 optionally includes memory remotely located relative to processor 901, which may be connected to the materials handling electronics via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The electronic device of the method of material handling may further comprise: an input device 903 and an output device 904. The processor 901, memory 902, input devices 903, and output devices 904 may be connected by a bus or other means, for example in fig. 18.
The input device 903 may receive input numeric or character information and generate key signal inputs related to user settings and function control of the electronic device for material handling, such as a touch screen, keypad, mouse, trackpad, touchpad, pointer stick, one or more mouse buttons, trackball, joystick, and the like. The output means 904 may include a display device, auxiliary lighting means (e.g., LEDs), tactile feedback means (e.g., vibration motors), and the like. The display device may include, but is not limited to, a liquid crystal display (Liquid Crystal Display, LCD), a light emitting diode (Light Emitting Diode, LED) display, and a plasma display. In some implementations, the display device may be a touch screen.
Various implementations of the systems and techniques described here can be implemented in digital electronic circuitry, integrated circuitry, application specific integrated circuits (Application Specific Integrated Circuits, ASIC), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs, the one or more computer programs may be executed and/or interpreted on a programmable system including at least one programmable processor, which may be a special purpose or general-purpose programmable processor, that may receive data and instructions from, and transmit data and instructions to, a storage system, at least one input device, and at least one output device.
These computing programs (also referred to as programs, software applications, or code) include machine instructions for a programmable processor, and may be implemented in a high-level procedural and/or object-oriented programming language, and/or in assembly/machine language. As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, apparatus, and/or device (e.g., magnetic discs, optical disks, memory, programmable logic devices (programmable logic device, PLDs)) used to provide machine instructions and/or data to a programmable processor, including a machine-readable medium that receives machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal used to provide machine instructions and/or data to a programmable processor.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., CRT (Cathode Ray Tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and pointing device (e.g., a mouse or trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic input, speech input, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a background component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such background, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local area network (Local Area Network, LAN), wide area network (Wide Area Network, WAN) and the internet.
The computer system may include a client and a server. The client and server are typically remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other.
According to the method and the device for generating the first main key of the material, the first main key of the material is generated through the identity information, so that the generated first main key can be used as the unique identifier of the material. In this embodiment, the first primary key is stored in the database in association with the information storage table, so that the information storage table can be quickly obtained from the database through the first primary key. And the information storage table stores material attribute information and position information, but not all the information of materials, so that the data processing performance is not affected. And the system can also rapidly index to a corresponding message queue through the material attribute information and the position information to acquire all necessary state information of the material, break through the traditional log record mode, stand on the periphery of the system to acquire the auditing material, and reversely push the auditing state.
According to the embodiment, the unique first main key corresponding to the material can be obtained by splicing the identity information, so that the information storage table corresponding to the material can be quickly and accurately obtained from the database according to the first main key. And the first character string forming the first main key is subjected to the binary conversion, so that the compression of the character string length of the first main key can be realized, and the storage space of a database is saved.
According to the technical scheme of the embodiment of the application, the technical means of constructing the behavior track in the space-time coordinate system by utilizing the position information and the time information and calculating the similarity of the two behavior tracks based on the minimum editing distance are adopted, so that the technical problem of ignoring time factors when constructing and analyzing the behavior track in the two-dimensional plane coordinate system is solved, and the technical effect of obtaining the similarity of the behavior track of the target object more accurately is achieved.
It should be appreciated that various forms of the flows shown above may be used to reorder, add, or delete steps. For example, the steps described in the present application may be performed in parallel, sequentially, or in a different order, provided that the desired results of the disclosed embodiments are achieved, and are not limited herein.
The above embodiments do not limit the scope of the present application. It will be apparent to those skilled in the art that various modifications, combinations, sub-combinations and alternatives are possible, depending on design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present application should be included in the scope of the present application.

Claims (14)

1. A method of processing a material, comprising:
acquiring material attribute information and position information of materials from a message queue;
constructing an information storage table based on the material attribute information and the position information; wherein the material attribute information comprises a plurality of identity information of the material;
generating a first main key of the material by using at least one piece of identity information;
storing the first primary key in a database in association with the information storage table;
generating a first primary key of the material by using at least one identity information, including:
converting at least one identity information into a character string format to obtain a first character string;
and carrying out binary conversion on the first character string to generate the first primary key.
2. The method of claim 1, wherein obtaining material attribute information and location information for the material from the message queue comprises:
and acquiring material attribute information and position information of the material in the corresponding message queue from at least one of the input message queue, the output message queue, the audit message queue and the audit abnormal message queue.
3. The method as recited in claim 2, further comprising:
Subscribing at least one of the input message queue, the output message queue, the audit message queue and the audit exception message queue;
the input message queue is used for storing material information input into the auditing unit, the output message queue is used for storing material auditing information output by the auditing unit, the auditing message queue is used for storing material auditing information for conducting secondary auditing on the material auditing information output by the auditing unit, and the auditing abnormal message queue is used for storing abnormal material information audited by the auditing unit.
4. The method as recited in claim 1, further comprising:
acquiring at least one target identity information from a plurality of identity information of a material to be queried;
generating a second main key of the material to be queried by using the target identity information;
searching a first main key corresponding to the second main key from the database;
and acquiring the information storage table of the material to be queried from the database according to the first main key corresponding to the second main key.
5. The method as recited in claim 4, further comprising:
Acquiring material attribute information and position information of the material to be queried according to the information storage table of the material to be queried;
and acquiring the information of the material to be queried from a target message queue according to the material attribute information and the position information of the material to be queried.
6. The method of claim 4, wherein generating the second primary key for the material to be queried using the target identity information comprises:
converting the target identity information into a character string format to obtain a second character string;
and carrying out binary conversion on the second character string to generate the second primary key.
7. A material handling apparatus, comprising:
the first acquisition module is used for acquiring material attribute information and position information of the material from the message queue;
the construction module is used for constructing an information storage table based on the material attribute information and the position information; wherein the material attribute information comprises a plurality of identity information of the material;
the first generation module is used for generating a first main key of the material by utilizing at least one piece of identity information;
the storage module is used for storing the first primary key and the information storage table in a database in an associated mode;
The first generation module includes:
the first conversion sub-module is used for converting at least one piece of identity information into a character string format to obtain a first character string;
and the first generation sub-module is used for carrying out the binary conversion on the first character string to generate the first primary key.
8. The apparatus of claim 7, wherein the first acquisition module comprises:
and the acquisition sub-module is used for acquiring the material attribute information and the position information of the material in the corresponding message queue from at least one of the input message queue, the output message queue, the audit message queue and the audit abnormal message queue.
9. The apparatus as recited in claim 8, further comprising:
the subscription module is used for subscribing at least one of the input message queue, the output message queue, the audit message queue and the audit abnormal message queue;
the input message queue is used for storing material information input into the auditing unit, the output message queue is used for storing material auditing information output by the auditing unit, the auditing message queue is used for storing material auditing information for conducting secondary auditing on the material auditing information output by the auditing unit, and the auditing abnormal message queue is used for storing abnormal material information audited by the auditing unit.
10. The apparatus as recited in claim 7, further comprising:
the second acquisition module is used for acquiring at least one target identity information from a plurality of identity information of the material to be inquired;
the second generation module is used for generating a second main key of the material to be queried by utilizing the target identity information;
the searching module is used for searching a first main key corresponding to the second main key from the database;
and the third acquisition module is used for acquiring the information storage table of the material to be queried from the database according to the first main key corresponding to the second main key.
11. The apparatus as recited in claim 10, further comprising:
the fourth acquisition module is used for acquiring the material attribute information and the position information of the material to be inquired according to the information storage table;
and a fifth acquisition module, configured to acquire information of the material to be queried from a target message queue according to the material attribute information and the position information of the material to be queried.
12. The apparatus of claim 10, wherein the second generating module comprises:
the second conversion sub-module is used for converting the target identity information into a character string format to obtain a second character string;
And the second generation sub-module is used for carrying out the binary conversion on the second character string to generate the second primary key.
13. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-6.
14. A non-transitory computer readable storage medium storing computer instructions for causing the computer to perform the method of any one of claims 1-6.
CN201910895303.7A 2019-09-20 2019-09-20 Material processing method and device Active CN112541718B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910895303.7A CN112541718B (en) 2019-09-20 2019-09-20 Material processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910895303.7A CN112541718B (en) 2019-09-20 2019-09-20 Material processing method and device

Publications (2)

Publication Number Publication Date
CN112541718A CN112541718A (en) 2021-03-23
CN112541718B true CN112541718B (en) 2023-09-01

Family

ID=75012651

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910895303.7A Active CN112541718B (en) 2019-09-20 2019-09-20 Material processing method and device

Country Status (1)

Country Link
CN (1) CN112541718B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113947349A (en) * 2021-09-28 2022-01-18 安徽云星空信息科技有限公司 Material data processing method and system

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105069665A (en) * 2015-09-06 2015-11-18 北京京东尚科信息技术有限公司 Sorting and display method and apparatus of multi-channel off-site advertisement report data
CN107783975A (en) * 2016-08-24 2018-03-09 北京京东尚科信息技术有限公司 The method and apparatus of distributed data base synchronization process
CN109376204A (en) * 2018-11-27 2019-02-22 五八有限公司 Message configuring method, message acquisition method, device, equipment and storage medium

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2011133812A1 (en) * 2010-04-22 2011-10-27 Kirk Lanciani Data mining system
US8595267B2 (en) * 2011-06-27 2013-11-26 Amazon Technologies, Inc. System and method for implementing a scalable data storage service

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105069665A (en) * 2015-09-06 2015-11-18 北京京东尚科信息技术有限公司 Sorting and display method and apparatus of multi-channel off-site advertisement report data
CN107783975A (en) * 2016-08-24 2018-03-09 北京京东尚科信息技术有限公司 The method and apparatus of distributed data base synchronization process
CN109376204A (en) * 2018-11-27 2019-02-22 五八有限公司 Message configuring method, message acquisition method, device, equipment and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
长庆油田物料管理库存优化系统的分析与设计;杨艳梅;朱养鹏;;科技视界(36);全文 *

Also Published As

Publication number Publication date
CN112541718A (en) 2021-03-23

Similar Documents

Publication Publication Date Title
CN110633292B (en) Query method, device, medium, equipment and system for heterogeneous database
US11899710B2 (en) Image recognition method, electronic device and storage medium
CN111177231A (en) Report generation method and report generation device
EP3968185A1 (en) Method and apparatus for pushing information, device and storage medium
US20210201168A1 (en) Method and Apparatus for Outputting Information, Device and Storage Medium
US10175954B2 (en) Method of processing big data, including arranging icons in a workflow GUI by a user, checking process availability and syntax, converting the workflow into execution code, monitoring the workflow, and displaying associated information
CN112486820B (en) Method, apparatus, device and storage medium for testing code
CN111639027B (en) Test method and device and electronic equipment
CN112541359B (en) Document content identification method, device, electronic equipment and medium
CN112506479B (en) Page editing method, device, equipment and storage medium
CN112491617B (en) Link tracking method, device, electronic equipment and medium
CN110633281A (en) Method and device for processing multi-type data sources
CN112328658B (en) User profile data processing method, device, equipment and storage medium
US11442930B2 (en) Method, apparatus, device and storage medium for data aggregation
CN112115113A (en) Data storage system, method, device, equipment and storage medium
CN111475164A (en) Component dependency relationship detection method and device and electronic equipment
CN112395333A (en) Method and device for checking data exception, electronic equipment and storage medium
CN112541718B (en) Material processing method and device
CN111026916B (en) Text description conversion method and device, electronic equipment and storage medium
CN111985760A (en) Data content evaluation method and device, electronic equipment and storage medium
US20220147700A1 (en) Method and apparatus for annotating data
US20220198301A1 (en) Method and apparatus for update processing of question answering system
CN114661747A (en) Index calculation method and device, storage medium and computer equipment
CN108153834B (en) Method and device for querying data by commercial intelligent application and electronic equipment
CN112948328A (en) Retrieval method, device, equipment and medium of log data

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
GR01 Patent grant
GR01 Patent grant