CN102857355B - A kind of method and device of message adaptation - Google Patents
A kind of method and device of message adaptation Download PDFInfo
- Publication number
- CN102857355B CN102857355B CN201110175343.8A CN201110175343A CN102857355B CN 102857355 B CN102857355 B CN 102857355B CN 201110175343 A CN201110175343 A CN 201110175343A CN 102857355 B CN102857355 B CN 102857355B
- Authority
- CN
- China
- Prior art keywords
- message
- webmaster
- command code
- command
- code
- 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
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/08—Configuration management of networks or network elements
- H04L41/0803—Configuration setting
- H04L41/084—Configuration by using pre-existing information, e.g. using templates or copying from other elements
- H04L41/0843—Configuration by using pre-existing information, e.g. using templates or copying from other elements based on generic templates
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/02—Standardisation; Integration
- H04L41/0226—Mapping or translating multiple network management protocols
Abstract
Present invention is disclosed a kind of methods of message adaptation, including:The message issued according to webmaster obtains corresponding webmaster command code;According to the webmaster command code and preset command tree configuration file, corresponding command tree is generated;The command tree includes the corresponding multiple equipment command code of the webmaster command code;The corresponding parameter of device command code described in the device command code and preset parameter Map Profile is combined, device command row message is generated and is issued to equipment, business configuration is carried out for the equipment.The invention also provides corresponding devices.A kind of method and device of message adaptation proposed by the present invention efficiently solves the problems, such as transmitting sequence when webmaster message conversion equipment order line message while reducing processing size of code, ensureing interface extensible.
Description
Technical field
The present invention relates to the communications fields, are related specifically to a kind of method and device of message adaptation.
Background technology
Webmastering software is as a kind of equipment management tool with visualization interface, since its operation is intuitive, simple and direct, logical
Letter equipment management becomes more and more important with the effect in safeguarding, especially in the case where the equipment amount for needing to manage is bigger.It is same with this
When, issuing for various device commands is carried out using the mode of order line, since it is directly facing equipment, the granularity of order is more
Small, maintenance content is more intuitive, also very wide range by many professional persons, particularly before webmastering software exploitation just
The personage for getting used to order line operation uses.
The message of message and the equipment processing issued due to webmaster is all had differences in message granularity and format, and message is suitable
With just at an essential link for webmastering software and communication between devices.Existing technology mostly uses the side of hard coded
Formula is adapted to interface, calls different message processing modules according to different information order codes, but this method encodes work
Work amount is big, and autgmentability is small, and size of code can be on the increase with the increase of message, and size of code is unable to control.And since webmaster is soft
The message that part issues may correspond to the configuration of multiple equipment message, these order lines configure between message that there is certain
Sequencing relationship, the prior art can not solve to ensure the sequence between each name row message during message adaptation.
Invention content
The main object of the present invention is to provide a kind of method and device of message adaptation, is reducing processing size of code, is ensureing
While interface extensible, transmitting sequence when webmaster message conversion equipment order line message is efficiently solved the problems, such as.
The present invention proposes a kind of method of message adaptation, including:
The message issued according to webmaster obtains corresponding webmaster command code;
According to the webmaster command code and preset command tree configuration file, corresponding command tree is generated;
The command tree includes the corresponding multiple equipment command code of the webmaster command code;
The corresponding parameter of device command code described in the device command code and preset parameter Map Profile is combined,
It generates device command row message and is issued to equipment, business configuration is carried out for the equipment.
Preferably, device command code described in the unit equipment command code and preset parameter Map Profile corresponds to
Parameter include:
Select the corresponding one or more parameters of device command code as keyword in the parameter Map Profile;
The keyword is pressed into default rule composing environment variable, unique mark corresponds to the business pair of the command tree
As.
Preferably, after executing the corresponding command code of the acquisition webmaster message, further include:
It detects in preset command code registration file and whether there is the webmaster command code, when the command code registers file
In be not present the webmaster command code when, response webmaster error messages simultaneously terminate flow.
Preferably, the method further includes:
Receive the device command row message that the equipment is sent;
According to the parameter Map Profile, the corresponding webmaster message of the device command row message is built, and send
To webmaster.
Preferably, described according to parameter Map Profile, build the corresponding webmaster message of the device command row message
Including:
Identical business object is judged whether according to the environmental variance in the device command row message;
Identical business object is such as not present, then generates a new business object, for building corresponding webmaster message.
The present invention also proposes a kind of device of message adaptation, including:
Acquisition module, the message for being issued according to webmaster obtain corresponding webmaster command code;
Command tree module is generated, for according to the webmaster command code and preset command tree configuration file, generation pair
The command tree answered;The command tree includes the corresponding multiple equipment command code of the webmaster command code:
Parameter configuration module, for combining equipment described in the device command code and preset parameter Map Profile
The corresponding parameter of command code, generates device command row message and is issued to equipment, and business configuration is carried out for the equipment.
Preferably, the parameter configuration module includes:
Selecting unit, for selecting the corresponding one or more ginsengs of device command code in the parameter Map Profile
Number is used as keyword;
Unit is identified, for the keyword to be pressed default rule composing environment variable, unique mark corresponds to the life
Enable the business object of tree.
Preferably, described device further includes:
Detection module whether there is the webmaster command code, when described for detecting in preset command code registration file
Command code is registered there is no when the webmaster command code in file, and response webmaster error messages simultaneously terminate flow.
Preferably, described device further includes:
Receiving module, the device command row message sent for receiving the equipment;
Module is built, for according to the parameter Map Profile, building the corresponding net of the device command row message
Pipe message, and it is sent to webmaster.
Preferably, the structure module includes:
Judging unit, for judging whether identical business according to the environmental variance in the device command row message
Object;
Generation unit is corresponded to for as identical business object is not present, then generating a new business object for structure
Webmaster message.
A kind of method and device of message adaptation proposed by the present invention completes message by way of reading configuration file
Unified adaptation, reduces the code of processing, while enhancing the scalability of program, solves equipment and each equipment is ordered
The requirement of row message transmitting sequence, while the method by ensureing webmaster and device data consistency are enabled, webmastering software is realized
With two kinds of way to manages of device command row while the function of management equipment.
Description of the drawings
Fig. 1 is the flow diagram of one embodiment of method of message adaptation of the present invention;
Fig. 2 is the format for the message that webmaster of the present invention issues;
Fig. 3 is the format of present device order line message;
Fig. 4 be message adaptation of the present invention one embodiment of method in parameter configuration step flow diagram;
Fig. 5 is the flow diagram of the another embodiment of method of message adaptation of the present invention;
Fig. 6 is the flow diagram of another embodiment of method of message adaptation of the present invention;
Fig. 7 be message adaptation of the present invention another embodiment of method in construction step flow diagram;
Fig. 8 is the structural schematic diagram of one embodiment of device of message adaptation of the present invention;
Fig. 9 be message adaptation of the present invention one embodiment of device in parameter configuration module structural schematic diagram;
Figure 10 is the structural schematic diagram of the another embodiment of device of message adaptation of the present invention;
Figure 11 is the structural schematic diagram of another embodiment of device of message adaptation of the present invention;
Figure 12 be message adaptation of the present invention another embodiment of device in structure module structural schematic diagram.
The embodiments will be further described with reference to the accompanying drawings for the realization, the function and the advantages of the object of the present invention.
Specific implementation mode
It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, it is not intended to limit the present invention.
Referring to Fig.1, one embodiment of method of message adaptation of the present invention is proposed, including:
Step S10, the message issued according to webmaster obtains corresponding webmaster command code;
It is the format for the message that webmaster issues shown in Fig. 2, which includes a command code MngrCode and some marks
The parameter of business object attribute, the message are a kind of flat structures, and the sequence for issuing parameter is fixed.Fig. 3 is to set
The format of standby order line message, convenient for follow-up narration, the command code in device command row message is named as ApiCode herein,
Device command row message shown in Fig. 3 corresponds to the webmaster message of Fig. 2.As it can be seen that a webmaster message may correspond to multiple equipment
Order line message, and device command row message has certain precedence relationship when being handed down to equipment.As shown in figure 3, from a left side
To the right side, the sequence that equipment receives order is ApiCode1-ApiCode2/ApiCode3-ApiCode4/ApiCode5, wherein
ApiCode2, ApiCode3 sequence it is interchangeable, the sequence of ApiCode4, ApiCode5 are interchangeable, but ApiCode1 and
ApiCode2, ApiCode3 or ApiCode4, ApiCode5 sequence cannot then change, otherwise equipment reports an error, wherein each
ApiCode can include multiple parameters.
The present embodiment pre-sets configuration file, including command code registration file and parameter Map Profile.Order
The correspondence between the webmaster command code of webmaster message and the device command code of device command row message is saved in tree configuration file
Relationship, when reading the configuration file, the webmaster command code of each corresponding webmaster message generates corresponding device command code
Order tree construction, parameter Map Profile determine the parameter correspondence between webmaster message and order line message.
Step S11, according to the webmaster command code and preset command tree configuration file, corresponding command tree is generated;
The command tree includes the corresponding multiple equipment command code of the webmaster command code;
The message issued according to webmaster obtains corresponding webmaster command code, searches the command tree read on startup and matches
File is set, determines the command tree for needing to issue.Wherein, command tree configuration file can be as follows:
Table 1-2:
MngrCode | ApiCode | ParentCode |
0xD00D | 0 | 0 |
0xD00D | 0x10112 | 0 |
0xD00D | 0x10113 | 0x10112 |
Table 1-2 can also carry out field extension according to the actual needs.Wherein, ApiCode indicates device command code,
ParentCode indicates that father's order of previous row device command code, i.e. the device command code of previous row depend on the device command
Code needs to retransmit after the device command code is sent, and otherwise equipment reports an error, configuration failure.In table 1-2, webmaster order
Code 0xD00D corresponds to two device command code 0x10112,0x10113 of device command row message, and wherein 0x10112 is
The father of 0x10113 orders, that is, needs first to issue 0x10112 when being handed down to equipment, then issue 0x10113.
Step S12, it is right to combine device command code described in the device command code and preset parameter Map Profile
The parameter answered, generates device command row message and is issued to equipment, and business configuration is carried out for the equipment.
After finding command tree, the parameter field in webmaster message is mapped to by corresponding set according to parameter Map Profile
Then device command row message is sent to equipment, if set determining in the time by standby command code, constitution equipment order line message
Standby response success then returns to webmaster success, otherwise returns to webmaster failure.Wherein parameter Map Profile format can be as follows:
Table 1-3
MngrCode | MngrPara | MngrDT | ApiCode | ApiParaNo | ApiDT |
0xD00D | ucPwIndex | BYTE | 0x10112 | par_1 | WORD |
0xD00D | wAttr1 | WORD | 0x10113 | par_1 | WORD |
0xD00D | wAttr2 | WORD | 0x10113 | par_2 | WORD |
Table 1-3 can be also extended according to the actual needs, wherein and MngrPara indicates the parameter field of webmaster message,
MngrDT indicates that the type of webmaster message parameter, ApiParaNo indicate that the parameter number of API message, ApiDT indicate the class of the parameter
Type.Table 1-3 is by taking the configuration of pseudo-wire in PTN device (PW) as an example, the parameter type of pseudo-wire call number ucPwIndex in webmaster message
For BYTE (8 without character type), the corresponding command code with device command row message is 0x10112, and parameter number is 1, the class of parameter
Type is WORD (16 without character type).
The device command row message of structure is sent to equipment, if equipment is replied within a certain period of time, according to return
Response is determined successfully or unsuccessfully to webmaster, otherwise it is assumed that webmaster is overtime.
In the present embodiment, the unified adaptation of message is completed by way of reading configuration file, reduces the code of processing,
While enhancing the scalability of program, solve requirement of the equipment for each device command row message transmitting sequence.
With reference to Fig. 4, in one embodiment, step S12 may include:
Step S121, the corresponding one or more parameters of device command code are selected in the parameter Map Profile;
Step S122, one or more of parameters are pressed into default rule composing environment variable, unique mark corresponds to institute
State the business object of command tree.
An important step is how to determine being which business object configured when issuing device command row message in S12
Attribute, it is therefore desirable to increase a mark, i.e. environmental variance in the device command row message for being handed down to equipment.Still set with PTN
It, will be according to the PW ropes configured in 0x10112 when issuing device command row message to equipment for the configuration of standby middle pseudo-wire (PW)
Draw and be handed down to equipment as environmental variance, environmental variance can be defined as a character string, such as pw_1 here.
With reference to Fig. 5, the another embodiment of method of message adaptation of the present invention is proposed, in the above-described embodiments, executing step
After S10, further include:
Step S13, it detects in preset command code registration file and whether there is the webmaster command code, when the command code
It registers there is no when the webmaster command code in file, feedback webmaster error messages simultaneously terminate flow.
When receiving from the message that webmaster issues, webmaster command code MngrCode is got from the webmaster message.Root
The preset command code that the when of starting reads is searched according to the webmaster command code MngrCode of webmaster message and registers file, it is determined whether is needed
Handle the message.It includes all name codes to be treated i.e. webmaster command code and setting command code that command code, which registers file,
As command code register file in there are the command code if need to handle, otherwise directly feedback webmaster information order code mistake.
Wherein, command code registration file format can be as follows:
Table 1-1
CmdCode | MngrCode | ComeFrom | Module |
0xD00D | 0xD00D | MNGR | CONFIG |
0x10112 | 0xD00D | API | CONFIG |
0x10113 | 0xD00D | API | CONFIG |
Wherein CmdCode indicates command code to be treated, including webmaster command code and device command code, MngrCode tables
Show that webmaster command code, ComeFrom indicate which direction is command code come from, is also to come from equipment from webmaster, Module is then
Indicate message belongs to which module of equipment, table 1-1 can be also extended according to the actual needs.Find out from table 1-1,0xD00D
The webmaster command code of the configuration message of webmaster, corresponding device command row message there are two device command code 0x10112 and
0x10113。
With reference to Fig. 6, propose that another embodiment of method of message adaptation of the present invention further includes in the above-described embodiments:
Step S14, the device command row message that the equipment is sent is received;
Step S15, it according to the parameter Map Profile, builds the corresponding webmaster of the device command row message and disappears
Breath, and it is sent to webmaster.
After receiving device command row message, corresponding equipment name code ApiCode is obtained, is registered according to the command code of reading
File determines the need for handling the message.Such as table 1-1, for example, if the equipment of the device command row message reversely sended over
Command code is 0x10114, since it is not registered, is then not necessarily to processing.According to the pass of the environmental variance in device command row message
Key word searches whether to configure the business object of environmental variance mark, to determine to increase, change or delete the business pair newly
As.Wherein the generation of keyword includes two kinds of situations:
(1) as shown in table 1-3, command code is the API message of 0x10112, it includes PW indexes this critical field, then its
The keyword of business object can be by directly acquiring being worth to for parameter par_1 in API message.
(2) as shown in table 1-3, the API message that command code is 0x10113 does not include key field, then can be according to disappearing
Environmental variance in breath obtains the value of the keyword of business object, it is assumed that its environmental variance is pw_1, then keyword PW indexes
Value be 1.
It is generated according to keyword or after finding business object, according to parameter Map Profile by the ginseng in API message
Number corresponds each field to webmaster message, and the webmaster message is then sent to webmaster.
The present embodiment realizes webmastering software and device command row two while ensureing webmaster and device data consistency
The function of kind way to manage while management equipment.
With reference to Fig. 7, in the above-described embodiments, step S15 further comprises:
Step S151, identical business pair is judged whether according to the environmental variance in the device command row message
As;
Step S152, identical business object is such as not present, then generates a new business object, for building corresponding net
Pipe message.
The environmental variance of device command row message generates format must be with environmental variance generation side when webmaster issuing message
Formula is identical, therefore, when equipment sending device order line message is to webmaster, needs to be become according to the environment in device command row message
Amount judges whether identical business object, if it is not, generating a new business object, matches further according to parameter mapping
It sets in file and the parameter in device command row message is mapped in webmaster message, the corresponding webmaster of structure device command row message
Message.
With reference to Fig. 8, one embodiment of device of message adaptation of the present invention is proposed, including:
Acquisition module 10, the message for being issued according to webmaster obtain corresponding webmaster command code;
Command tree module 20 is generated, for according to the webmaster command code and preset command tree configuration file, generating
Corresponding command tree;The command tree includes the corresponding multiple equipment command code of the webmaster command code:
Parameter configuration module 30 is set for combining described in the device command code and preset parameter Map Profile
The corresponding parameter of standby command code, generates device command row message and is issued to equipment, and business configuration is carried out for the equipment.
It is the format for the message that webmaster issues shown in Fig. 2, which includes a command code MngrCode and some marks
The parameter of business object attribute, the message are a kind of flat structures, and the sequence for issuing parameter is fixed.Fig. 3 is to set
The format of standby order line message, corresponds to the webmaster message of Fig. 2.As it can be seen that a webmaster message may correspond to multiple equipment life
Row message is enabled, and device command row message has certain precedence relationship when being handed down to equipment.As shown in figure 3, from a left side to
The right side, the sequence that equipment receives order is ApiCode1-ApiCode2/ApiCode3-ApiCode4/ApiCode5, wherein
ApiCode2, ApiCode3 sequence it is interchangeable, the sequence of ApiCode4, ApiCode5 are interchangeable, but ApiCode1 and
ApiCode2, ApiCode3 or ApiCode4, ApiCode5 sequence cannot then change, otherwise equipment reports an error, wherein each
ApiCode can include multiple parameters.
The present embodiment pre-sets configuration file, including command tree configuration file and parameter Map Profile.Order
The correspondence between the webmaster command code of webmaster message and the device command code of device command row message is saved in tree configuration file
Relationship, when reading the configuration file, the webmaster command code of each corresponding webmaster message generates corresponding device command code
Order tree construction, parameter Map Profile determine the parameter correspondence between webmaster message and order line message.
The message issued according to webmaster, acquisition module 10 obtain corresponding webmaster command code, generate command tree module 20 and look into
The command tree configuration file read on startup is looked for, determines the command tree for needing to issue.Wherein, command tree configuration file can be with
As shown in table 1-2:
Table 1-2:
MngrCode | ApiCode | ParentCode |
0xD00D | 0 | 0 |
0xD00D | 0x10112 | 0 |
0xD00D | 0x10113 | 0x10112 |
Table 1-2 can be also extended according to the actual needs.Wherein, ApiCode indicates device command code, ParentCode
Indicate that father's order of previous row device command code, i.e. the device command code of previous row depend on the device command code, need at this
Device command code retransmits after sending, and otherwise equipment reports an error, configuration failure.In table 1-2, webmaster command code 0xD00D is corresponded to
In two device commands code 0x10112,0x10113 of device command row message, wherein 0x10112 is father's order of 0x10113,
It needs first to issue 0x10112 when being handed down to equipment, then issues 0x10113.
After finding command tree, parameter configuration module 30 is according to parameter Map Profile by the parameter field in webmaster message
It is mapped to corresponding device command code, then device command row message is sent to equipment by constitution equipment order line message, if
Determining that equipment response success then returns to webmaster success in the time, otherwise returns to webmaster failure.Wherein parameter Map Profile
Format can be as follows:
Table 1-3
MngrCode | MngrPara | MngrDT | ApiCode | ApiParaNo | ApiDT |
0xD00D | ucPwIndex | BYTE | 0x10112 | par_1 | WORD |
0xD00D | wAttr1 | WORD | 0x10113 | par_1 | WORD |
0xD00D | wAttr2 | WORD | 0x10113 | par_2 | WORD |
Table 1-3 can be also extended according to the actual needs, wherein and MngrPara indicates the parameter field of webmaster message,
MngrDT indicates that the type of webmaster message parameter, ApiParaNo indicate that the parameter number of API message, ApiDT indicate the class of the parameter
Type.Table 1-3 is by taking the configuration of pseudo-wire in PTN device (PW) as an example, the parameter type of pseudo-wire call number ucPwIndex in webmaster message
For BYTE (8 without character type), the corresponding command code with device command row message is 0x10112, and parameter number is 1, the class of parameter
Type is WORD (16 without character type).
The device command row message of structure is sent to equipment, if equipment is replied within a certain period of time, according to return
Response is determined successfully or unsuccessfully to webmaster, otherwise it is assumed that webmaster is overtime.
In the present embodiment, the unified adaptation of message is completed by way of reading configuration file, reduces the code of processing,
While enhancing the scalability of program, solve requirement of the equipment for each device command row message transmitting sequence.
With reference to Fig. 9, in one embodiment, parameter configuration module 30 includes:
Selecting unit 31, for selecting the corresponding one or more of device command code in the parameter Map Profile
Parameter is as keyword;
Unit 32 is identified, described in, by default rule composing environment variable, unique mark corresponds to by the keyword
The business object of command tree.
When issuing device command row message, it must be determined that it is to configure the attribute of which business object, therefore selecting unit
31 need to select the corresponding parameter of one or more device command codes as keyword, and mark unit 32 is constituted according to the keyword
Environmental variance, and increase in the device command row message for being handed down to equipment.Still it is configured to pseudo-wire in PTN device (PW)
Example, when issuing device command row message to equipment, is handed down to according to the PW indexes configured in 0x10112 as environmental variance
Equipment, here environmental variance can be defined as a character string, such as pw_1.
Referring to Fig.1 0, propose that the another embodiment of device of message adaptation of the present invention further includes in the above-described embodiments:
Detection module 40 whether there is the webmaster command code for detecting in preset command code registration file, work as institute
It states there is no when the webmaster command code in command code registration file, feedback webmaster error messages simultaneously terminate flow.
When receiving from the message that webmaster issues, webmaster command code MngrCode is got from the webmaster message.Root
The preset command code that the when of starting reads is searched according to the webmaster command code MngrCode of webmaster message and registers file, it is determined whether is needed
Handle the message.It includes all name codes to be treated i.e. webmaster command code and setting command code that command code, which registers file,
As command code register file in there are the command code if need to handle, otherwise directly feedback webmaster information order code mistake.
Wherein, command code registration file format can be as follows:
Table 1-1
CmdCode | MngrCode | ComeFrom | Module |
0xD00D | 0xD00D | MNGR | CONFIG |
0x10112 | 0xD00D | API | CONFIG |
0x10113 | 0xD00D | API | CONFIG |
Wherein CmdCode indicates command code to be treated, including webmaster command code and device command code, MngrCode tables
Show that webmaster command code, ComeFrom indicate which direction is command code come from, is also to come from equipment from webmaster, Module is then
Indicate message belongs to which module of equipment, table 1-1 can be also extended according to the actual needs.Find out from table 1-1,0xD00D
The webmaster command code of the configuration message of webmaster, corresponding device command row message there are two device command code 0x10112 and
0x10113。
Referring to Fig.1 1, propose that another embodiment of device of message adaptation of the present invention further includes in the above-described embodiments:
Receiving module 50, the device command row message sent for receiving the equipment;
Module 60 is built, for according to the parameter Map Profile, it is corresponding to build the device command row message
Webmaster message, and it is sent to webmaster.
After receiving module 50 receives device command row message, corresponding equipment name code ApiCode is obtained, according to reading
Command code registration file determines the need for handling the message.Such as table 1-1, for example, if the device command row reversely sended over
The device command code of message is 0x10114, since it is not registered, is then not necessarily to processing.According to the ring in device command row message
The keyword of border variable searches whether to configure the business object of environmental variance mark, to determine to increase newly, change or delete
Except the business object.Wherein the generation of keyword includes two kinds of situations:
(1) as shown in table 1-3, command code is the API message of 0x10112, it includes PW indexes this critical field, then its
The keyword of business object can be by directly acquiring being worth to for parameter par_1 in API message.
(2) as shown in table 1-3, the API message that command code is 0x10113 does not include key field, then can be according to disappearing
Environmental variance in breath obtains the value of the keyword of business object, it is assumed that its environmental variance is pw_1, then keyword PW indexes
Value be 1.
It is generated according to keyword or after finding business object, structure module 60 is according to parameter Map Profile by API
Parameter in message corresponds each field to webmaster message, and the webmaster message is then sent to webmaster.
The present embodiment realizes webmastering software and device command row two while ensureing webmaster and device data consistency
The function of kind way to manage while management equipment.
Referring to Fig.1 2, in the above-described embodiments, structure module 60 includes:
Judging unit 61, for judging whether identical industry according to the environmental variance in the device command row message
Business object;
Generation unit 62, for as identical business object is not present, then generating a new business object, for structure pair
The webmaster message answered.
The environmental variance of device command row message generates format must be with environmental variance generation side when webmaster issuing message
Formula is identical, and therefore, when equipment sending device order line message is to webmaster, judging unit 61 is needed according to device command row message
In environmental variance judge whether identical business object, if it is not, generation unit 62 generate a new business
Parameter in device command row message is mapped in webmaster message by object further according in parameter Map Profile, and structure is set
For the corresponding webmaster message of order line message.
The foregoing is merely the preferred embodiment of the present invention, are not intended to limit the scope of the invention, every utilization
Equivalent structure or equivalent flow shift made by description of the invention and accompanying drawing content is applied directly or indirectly in other correlations
Technical field, be included within the scope of the present invention.
Claims (8)
1. a kind of method of message adaptation, which is characterized in that including:
The message issued according to webmaster obtains corresponding webmaster command code;
According to the webmaster command code and preset command tree configuration file, corresponding command tree is generated;The command tree packet
Include the corresponding multiple equipment command code of the webmaster command code;There is the priority sent in the device command code;
The corresponding parameter of device command code described in the device command code and preset parameter Map Profile is combined, is generated
Device command row message is simultaneously issued to equipment according to the priority, and business configuration is carried out for the equipment;
The corresponding parameter of device command code includes described in the unit equipment command code and preset parameter Map Profile:
Select the corresponding one or more parameters of device command code as keyword in the parameter Map Profile;
The keyword is pressed into default rule composing environment variable, unique mark corresponds to the business object of the command tree;Its
In, when environmental variance is used in device command code including key field, become according to the environment in device command row message
Amount obtains the value of the keyword of business object.
2. the method as described in claim 1, which is characterized in that executing the corresponding webmaster command code of the acquisition webmaster message
Later, further include:
It detects in preset command code registration file and whether there is the webmaster command code, when the command code is registered in file not
There are when the webmaster command code, response webmaster error messages simultaneously terminate flow.
3. the method as described in claim 1, which is characterized in that further include:
Receive the device command row message that the equipment is sent;
According to the parameter Map Profile, the corresponding webmaster message of the device command row message is built, and be sent to net
Pipe.
4. method as claimed in claim 3, which is characterized in that it is described according to parameter Map Profile, build the equipment
The corresponding webmaster message of order line message, including:
Identical business object is judged whether according to the environmental variance in the device command row message;
Identical business object is such as not present, then generates a new business object, for building corresponding webmaster message.
5. a kind of device of message adaptation, which is characterized in that including:
Acquisition module, the message for being issued according to webmaster obtain corresponding webmaster command code;
Command tree module is generated, for according to the webmaster command code and preset command tree configuration file, generating corresponding
Command tree;The command tree includes the corresponding multiple equipment command code of the webmaster command code;There is hair in the device command code
The priority sent;
Parameter configuration module, for combining device command described in the device command code and preset parameter Map Profile
The corresponding parameter of code generates device command row message and is simultaneously issued to equipment according to the priority, for the equipment into industry
Business configuration;
The parameter configuration module includes:
Selecting unit, for selecting the corresponding one or more parameters of device command code to make in the parameter Map Profile
For keyword;
Unit is identified, for the keyword to be pressed default rule composing environment variable, unique mark corresponds to the command tree
Business object;Wherein, when environmental variance is used in device command code including key field, disappeared according to device command row
Environmental variance in breath obtains the value of the keyword of business object.
6. device as claimed in claim 5, which is characterized in that further include:
Detection module whether there is the webmaster command code, when the order for detecting in preset command code registration file
When the webmaster command code is not present in code registration file, response webmaster error messages simultaneously terminate flow.
7. device as claimed in claim 5, which is characterized in that further include:
Receiving module, the device command row message sent for receiving the equipment;
Module is built, for according to the parameter Map Profile, building the corresponding webmaster of the device command row message and disappearing
Breath, and it is sent to webmaster.
8. device as claimed in claim 7, which is characterized in that the structure module includes:
Judging unit, for judging whether identical business pair according to the environmental variance in the device command row message
As;
Generation unit, for as identical business object is not present, then generating a new business object, for building corresponding net
Pipe message.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201110175343.8A CN102857355B (en) | 2011-06-27 | 2011-06-27 | A kind of method and device of message adaptation |
PCT/CN2011/082734 WO2013000236A1 (en) | 2011-06-27 | 2011-11-23 | Method and device for message adaptation |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201110175343.8A CN102857355B (en) | 2011-06-27 | 2011-06-27 | A kind of method and device of message adaptation |
Publications (2)
Publication Number | Publication Date |
---|---|
CN102857355A CN102857355A (en) | 2013-01-02 |
CN102857355B true CN102857355B (en) | 2018-07-13 |
Family
ID=47403565
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201110175343.8A Active CN102857355B (en) | 2011-06-27 | 2011-06-27 | A kind of method and device of message adaptation |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN102857355B (en) |
WO (1) | WO2013000236A1 (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103532756B (en) * | 2013-10-15 | 2017-01-25 | 上海寰创通信科技股份有限公司 | Command line system and command line operation method based on webmaster system |
CN105704169A (en) * | 2014-11-24 | 2016-06-22 | 中兴通讯股份有限公司 | Method for maintaining data consistency, device and PTN transmission device |
CN112463144B (en) * | 2020-12-02 | 2022-11-11 | 苏州浪潮智能科技有限公司 | Distributed storage command line service method, system, terminal and storage medium |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1787459A (en) * | 2005-12-22 | 2006-06-14 | 杭州华为三康技术有限公司 | Method and system for transmitting order to lower levels |
Family Cites Families (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR100358156B1 (en) * | 1999-12-10 | 2002-10-25 | 주식회사 케이티 | Converting Method of Managing Operation from service management system to Switching Command in a Integrated Network |
US20030204612A1 (en) * | 2002-04-30 | 2003-10-30 | Mark Warren | System and method for facilitating device communication, management and control in a network |
CN100346606C (en) * | 2003-09-24 | 2007-10-31 | 华为技术有限公司 | Information analytical method for facility configuration |
CN1929396A (en) * | 2005-09-09 | 2007-03-14 | 中兴通讯股份有限公司 | Method for realizing data configuration of network element in network |
CN101110703B (en) * | 2007-06-28 | 2011-11-30 | 中兴通讯股份有限公司 | Made-to-order command line implementing method and system |
CN101515929B (en) * | 2009-03-24 | 2012-07-04 | 成都市华为赛门铁克科技有限公司 | Message format conversion method, network device and agent device |
CN101610173B (en) * | 2009-07-14 | 2012-09-05 | 中兴通讯股份有限公司 | Method and network management server for implementing data collocation on multi-network elements |
-
2011
- 2011-06-27 CN CN201110175343.8A patent/CN102857355B/en active Active
- 2011-11-23 WO PCT/CN2011/082734 patent/WO2013000236A1/en active Application Filing
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1787459A (en) * | 2005-12-22 | 2006-06-14 | 杭州华为三康技术有限公司 | Method and system for transmitting order to lower levels |
Also Published As
Publication number | Publication date |
---|---|
WO2013000236A1 (en) | 2013-01-03 |
CN102857355A (en) | 2013-01-02 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101217504B (en) | A method and communication system of communication contactors sharing | |
CN102185901B (en) | Client message conversion method | |
CN102111192B (en) | Bluetooth connection method and system | |
CN104883267A (en) | Network configuration accessing method and device thereof | |
CN111061678B (en) | Service data processing method, device, computer equipment and storage medium | |
CN102857355B (en) | A kind of method and device of message adaptation | |
CN107347062A (en) | A kind of method, electronic equipment and the readable storage medium storing program for executing of daily record data processing | |
CN104881337A (en) | Method for expanding novel functions of SCSI (small computer system interface) cases | |
CN104821957B (en) | A kind of implementation method of BFD state machines, apparatus and system | |
CN1783881B (en) | Mechanism for binding a structured data protocol to a protocol offering up byte streams | |
Kouzapas et al. | Session types for broadcasting | |
CN105590436A (en) | Point-to-point meter reading method | |
US20100136920A1 (en) | Method and system for optimizing measurement reporting mechanism in a layered protocol wireless network | |
US20080167050A1 (en) | Method and system for managing user preferences for one or more software applications runing on a mobile computing device | |
CN104993906B (en) | A kind of method and system of message transmission | |
CN107493251A (en) | A kind of method and terminal for logging in destination server | |
CN104573461A (en) | User's account generating method and device | |
CN102006180B (en) | Method and device for selecting endpoints during establishment of end-to-end service layer service | |
CN104994137B (en) | A kind of method of network readezvous point agency | |
CN110971716B (en) | Address configuration method, device, system and computer readable storage medium | |
CN110519288A (en) | Communication protocol configuration method, device and the configuration system of data converter | |
US10638288B2 (en) | Embedded device identification information in packetized communications | |
WO2019179392A1 (en) | Packet generation method and related device | |
TW201607270A (en) | Management system and management method | |
CN110928667B (en) | Task scheduling method and device, electronic equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |