Detailed Description
In order to make the technical problems, technical solutions and advantageous effects to be solved by the present invention more clearly apparent, the present invention is further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
Referring to fig. 1, fig. 1 is a schematic flow chart of a fiber optic network management method according to an embodiment of the present invention. The method comprises the following steps:
s101: acquiring first attribute information of the optical network node, and generating identification information of the optical network node according to the first attribute information of the optical network node.
In this embodiment, the identification information of the optical network node is used to instruct an optical network administrator to obtain the first attribute information of the optical network node according to the received identification information of the optical network node. The first attribute information includes, but is not limited to, a fiber type, a fiber operator, a fiber plugging state, a geographic location (expressed in longitude and latitude coordinates) of a fiber network node, a fiber service life, and the like.
S102: and acquiring second attribute information of the optical fiber network node, and determining the corresponding relation between the second attribute information of the optical fiber network node and the identification information of the optical fiber network node according to the corresponding relation between the first attribute information and the second attribute information of the optical fiber network node.
In this embodiment, the identification information of the optical network node represents the first attribute information of the optical network node, so that the corresponding relationship between the second attribute information of the optical network node and the identification information of the optical network node can be determined according to the corresponding relationship between the first attribute information and the second attribute information of the optical network node.
The second attribute information is port configuration information of the optical fiber network node stored by the optical fiber management server.
S103: and adding the second attribute information of each optical fiber network node and the identification information of the optical fiber network node corresponding to the second attribute information of the optical fiber network node to a preset relational mapping model to obtain a relational mapping network, and managing the optical fiber network based on the relational mapping network.
In this embodiment, the predetermined relational mapping model is a queue including a plurality of node pairs. The number of the node pairs in the preset relational mapping model is far larger than the number of the optical fiber network nodes stored by the current optical fiber management server.
In this embodiment, the process of establishing the relationship mapping network may be: firstly, all the node pairs in the preset relational mapping model are set to be in an idle state, and the second attribute information of each optical network node and the identification information of the optical network node corresponding to the second attribute information of the optical network node are added to the idle node pairs of the preset relational mapping model in a circulating mode until all the optical network nodes are recorded.
In this embodiment, the first identification information is information stored in the electronic tag.
As can be seen from the foregoing description, in one aspect, in the embodiment of the present invention, the first attribute information of the optical network node is recorded by using the first identification information, where the first identification information occupies a smaller amount of memory (reduces the storage amount of the electronic tag) relative to the first attribute information, so that the hardware cost of the electronic tag is effectively reduced; on the other hand, the optical fiber network is managed through the relational mapping network, when the network connection changes, only the corresponding relation between the second attribute information and the identification information of the optical fiber network nodes in the relational mapping network needs to be modified, and the first attribute information, the second attribute information and the content of the identification information of the optical fiber network nodes do not need to be modified (the first identification information does not need to be modified, namely the electronic tags do not need to be frequently replaced), so that the workload of optical fiber network managers can be effectively reduced, and the labor cost is reduced.
Referring to fig. 1 and fig. 2 together, fig. 2 is a schematic flow chart of a fiber network management method according to another embodiment of the present application. On the basis of the above embodiment, the optical network management includes adding an optical network node, and the adding process of the optical network node may be:
s201: the method comprises the steps of obtaining attribute information of an optical network node to be added, wherein the attribute information of the optical network node to be added comprises first attribute information and second attribute information of the optical network node to be added.
S202: and generating identification information of the optical network node to be added according to the first attribute information of the optical network node to be added.
S203: and extracting the idle node pairs in the idle node queue of the relational mapping network, and adding the second attribute information of the optical network nodes to be added and the identification information of the optical network nodes to be added to the idle node pairs.
In this embodiment, if a new optical network node needs to be added, the first attribute information and the second attribute information of the optical network node to be added may be directly set, the identification information of the optical network node to be added is generated according to the first attribute information of the optical network node to be added, finally, the idle node pair is taken out from the head of the idle node queue of the relational mapping network, and the second attribute information of the optical network node to be added and the identification information of the optical network node to be added are added to the extracted idle node pair.
Referring to fig. 1 and fig. 3 together, fig. 3 is a schematic flow chart of a fiber network management method according to another embodiment of the present application. The optical network management includes deletion of optical network nodes, and the deletion process of the optical network nodes may be:
s301: and setting the node where the second attribute information of the optical network node to be deleted and the identification information of the optical network node to be deleted are located in an idle state.
S302: the node pairs placed in the idle state are added to an idle node pair column of the relational mapping network.
In this embodiment, if the optical network node needs to be deleted, the second attribute information and the identification information of the optical network node to be deleted, which are stored by the node pair where the optical network node is located, may be directly removed, the node pair after the second attribute information and the identification information of the optical network node to be deleted are removed is set in an idle state, and finally, the node pair set in the idle state is added to the queue tail of the idle node pair column of the relational mapping network.
Please refer to fig. 1 and fig. 4 together, and fig. 4 is a flowchart illustrating a fiber network management method according to another embodiment of the present application. The optical network management comprises the modification of the optical network nodes, and the modification process of the optical network nodes can be as follows:
s401: and acquiring the modified second attribute information of the optical network node to be modified.
S402: and replacing the second attribute information before modification of the optical fiber network node to be modified based on the modified second attribute information of the optical fiber network node to be modified.
In this embodiment, if the optical network node needs to be modified, only the second attribute information of the new optical network node to be modified needs to be used to replace the old second attribute information in the node pair of the optical network node.
Please refer to fig. 1 and 5 together, and fig. 5 is a flowchart illustrating a fiber network management method according to another embodiment of the present application. The optical fiber network management includes switching of optical fiber network nodes, the optical fiber network nodes to be switched include a first network node and a second network node, and the switching process of the optical fiber network nodes may be:
s501: and extracting the idle node pairs in the relation mapping network idle node queue, and adding the second attribute information of the first network node and the identification information of the first network node to the idle node pairs.
S502: second attribute information of the second network node and identification information of the first network node are added to the first node pair.
S503: adding the second attribute information of the first network node and the identification information of the second network node to the second node pair.
S504: the free node pairs are added to a free node pair column of the relational mapping network.
The first node pair is a node pair in which the second attribute information of the first network node and the identification information of the first network node are located, and the second node pair is a node pair in which the second attribute information of the second network node and the identification information of the second network node are located.
In this embodiment, if the optical network nodes need to be exchanged, the second attribute information of the two optical network nodes to be exchanged may be directly exchanged, and specifically, a new idle node pair may be used as a buffer to implement the exchange of the second attribute information in the two optical network nodes.
Fig. 6 is a block diagram of an optical fiber network management apparatus according to an embodiment of the present invention, which corresponds to the optical fiber network management method according to the foregoing embodiment. For convenience of explanation, only portions related to the embodiments of the present invention are shown. Referring to fig. 6, the apparatus includes: the system comprises an identification information generation module 100, a corresponding relation determination module 200 and a network management module 300.
The identification information generating module 100 is configured to obtain first attribute information of an optical network node, and generate identification information of the optical network node according to the first attribute information of the optical network node.
The corresponding relationship determining module 200 is configured to obtain second attribute information of the optical network node, and determine a corresponding relationship between the second attribute information of the optical network node and the identification information of the optical network node according to a corresponding relationship between the first attribute information of the optical network node and the second attribute information.
The network management module 300 is configured to add the second attribute information of each optical network node and the identification information of the optical network node corresponding to the second attribute information of the optical network node to a preset relational mapping model to obtain a relational mapping network, and manage the optical network based on the relational mapping network.
Referring to fig. 6, in another embodiment of the present invention, the network management module 300 includes a node adding unit 310, and the node adding unit 310 may include:
the first information obtaining device 311 is configured to obtain attribute information of an optical network node to be added, where the attribute information of the optical network node to be added includes first attribute information and second attribute information of the optical network node to be added.
The first identifier generating device 312 is configured to generate identifier information of the optical network node to be added according to the first attribute information of the optical network node to be added.
And the node adding device 313 is configured to extract an idle node pair in the relation mapping network idle node queue, and add the second attribute information of the optical network node to be added and the identification information of the optical network node to be added to the idle node pair.
Referring to fig. 6, in a further embodiment of the present invention, the network management module 300 includes a node deletion unit 320, and the node deletion unit 320 may include:
and the state modifying device 321 is configured to set, as an idle state, a node where the second attribute information of the optical network node to be deleted and the identification information of the optical network node to be deleted are located.
A first queue adding device 322, configured to add the node pairs set in the idle state to an idle node pair column of the relational mapping network.
Referring to fig. 6, in a further embodiment of the present invention, the network management module 300 includes a node modification unit 330, and the node modification unit 330 may include:
the second information obtaining device 331 is configured to obtain modified second attribute information of the optical network node to be modified.
The information replacing device 332 is configured to replace the second attribute information before modification of the optical network node to be modified based on the modified second attribute information of the optical network node to be modified.
Referring to fig. 6, in another embodiment of the present invention, the network management module 300 includes a node switching unit 340, and the node switching unit 340 may include:
the first information exchanging device 341 is configured to extract an idle node pair in the relation mapping network idle node queue, and add the second attribute information of the first network node and the identification information of the first network node to the idle node pair.
Second information exchanging means 342 for adding second attribute information of the second network node and identification information of the first network node to the first node pair.
Third information exchanging means 343 for adding the second attribute information of the first network node and the identification information of the second network node to the second node pair.
Second queue adding means 344 for adding an idle node pair to an idle node pair column of the relational mapping network.
The first node pair is a node pair in which the second attribute information of the first network node and the identification information of the first network node are located, and the second node pair is a node pair in which the second attribute information of the second network node and the identification information of the second network node are located.
Referring to fig. 7, fig. 7 is a schematic block diagram of a terminal device according to an embodiment of the present invention. The terminal 700 in the present embodiment shown in fig. 7 may include: one or more processors 701, one or more input devices 702, one or more output devices 703, and one or more memories 704. The processor 701, the input device 702, the output device 703 and the memory 704 are in communication with each other via a communication bus 705. The memory 704 is used to store computer programs, which include program instructions. The processor 701 is configured to execute program instructions stored by the memory 704. The processor 701 is configured to call a program instruction to perform the following functions of operating each module/unit in each device embodiment, for example, the functions of the modules 100 to 300 shown in fig. 6.
It should be understood that, in the embodiment of the present invention, the Processor 701 may be a Central Processing Unit (CPU), and the Processor may also be other general processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components, etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The input device 702 may include a touch pad, a fingerprint sensor (for collecting fingerprint information of a user and direction information of the fingerprint), a microphone, etc., and the output device 703 may include a display (LCD, etc.), a speaker, etc.
The memory 704 may include both read-only memory and random-access memory, and provides instructions and data to the processor 701. A portion of the memory 704 may also include non-volatile random access memory. For example, the memory 704 may also store device type information.
In a specific implementation, the processor 701, the input device 702, and the output device 703 described in this embodiment of the present invention may execute the implementation manners described in the first embodiment and the second embodiment of the optical network management method provided in this embodiment of the present invention, and may also execute the implementation manner of the terminal described in this embodiment of the present invention, which is not described herein again.
In another embodiment of the present invention, a computer-readable storage medium is provided, in which a computer program is stored, where the computer program includes program instructions, and the program instructions, when executed by a processor, implement all or part of the processes in the method of the above embodiments, and may also be implemented by a computer program instructing associated hardware, and the computer program may be stored in a computer-readable storage medium, and the computer program, when executed by a processor, may implement the steps of the above methods embodiments. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer readable medium may include: any entity or device capable of carrying computer program code, recording medium, U.S. disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution media, and the like. It should be noted that the computer readable medium may include any suitable increase or decrease as required by legislation and patent practice in the jurisdiction, for example, in some jurisdictions, computer readable media may not include electrical carrier signals and telecommunications signals in accordance with legislation and patent practice.
The computer readable storage medium may be an internal storage unit of the terminal of any of the foregoing embodiments, for example, a hard disk or a memory of the terminal. The computer readable storage medium may also be an external storage device of the terminal, such as a plug-in hard disk provided on the terminal, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like. Further, the computer-readable storage medium may also include both an internal storage unit and an external storage device of the terminal. The computer-readable storage medium is used for storing a computer program and other programs and data required by the terminal. The computer-readable storage medium may also be used to temporarily store data that has been output or is to be output.
Those of ordinary skill in the art will appreciate that the elements and algorithm steps of the examples described in connection with the embodiments disclosed herein may be embodied in electronic hardware, computer software, or combinations of both, and that the components and steps of the examples have been described in a functional general in the foregoing description for the purpose of illustrating clearly the interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of the terminal and the unit described above may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed terminal and method can be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, a division of a unit is merely a logical division, and an actual implementation may have another division, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may also be an electric, mechanical or other form of connection.
Units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment of the present invention.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
While the invention has been described with reference to specific embodiments, it will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the invention as defined by the appended claims. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.