CN116301970A - Smooth upgrading method for door face abstract device and JSON serialization/deserialization - Google Patents

Smooth upgrading method for door face abstract device and JSON serialization/deserialization Download PDF

Info

Publication number
CN116301970A
CN116301970A CN202310106214.6A CN202310106214A CN116301970A CN 116301970 A CN116301970 A CN 116301970A CN 202310106214 A CN202310106214 A CN 202310106214A CN 116301970 A CN116301970 A CN 116301970A
Authority
CN
China
Prior art keywords
json
deserialization
serialization
processing
library
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.)
Pending
Application number
CN202310106214.6A
Other languages
Chinese (zh)
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 VRV Software Corp Ltd
Original Assignee
Beijing VRV Software Corp 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 VRV Software Corp Ltd filed Critical Beijing VRV Software Corp Ltd
Priority to CN202310106214.6A priority Critical patent/CN116301970A/en
Publication of CN116301970A publication Critical patent/CN116301970A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/40Transformation of program code
    • G06F8/41Compilation
    • G06F8/42Syntactic analysis
    • G06F8/427Parsing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Stored Programmes (AREA)

Abstract

The application discloses a door face abstract device and a JSON serialization/deserialization smooth upgrading method, wherein the door face abstract device comprises the following steps: the device comprises a docking module, an identification module and a processing module; the docking module is used for providing an interface matched with the JSON serialization/deserialization; the identification module is used for acquiring an engine processing strategy; the processing module is used for obtaining an initialization analysis library according to an engine processing strategy, obtaining a processing instruction according to an interface, and carrying out JSON serialization/deserialization based on the processing instruction and the initialization analysis library; the device allows the jsonjar which is actually needed to be freely inserted in the deployment process; the plug-and-play effect is achieved by the mode that the device is independently divided into a class library; meanwhile, the JSON analysis library is switched at any time according to project requirements, the problems that the JSON analysis library is complicated and complicated to upgrade and easy to generate loopholes and the like caused by technical architecture upgrading in production projects can be effectively solved, and the method is convenient and efficient.

Description

Smooth upgrading method for door face abstract device and JSON serialization/deserialization
Technical Field
The disclosure relates to the technical field of computer software, in particular to a door face abstract device and a JSON serialization/deserialization smooth upgrading method.
Background
At present, part of customer sites have scenes that old projects need to be upgraded due to the development of business, a system needs to be upgraded to the latest version, and the latest version system needs to be upgraded correspondingly due to the upgrading of a technical framework; under the condition, all relevant operations of the system JSON need a large amount of reconstruction, the risk is very large, the system JSON is very tedious and easy to generate loopholes, each subsystem has the scene, the workload is huge, and the upgrading period is long.
Disclosure of Invention
In view of the above, the application provides a door face abstract device and a JSON serialization/deserialization smooth upgrading method, which can effectively solve the problems of complex and complicated JSON analysis library upgrading, easiness in loopholes and the like caused by technical architecture upgrading in production projects.
In a first aspect, an embodiment of the present disclosure provides a door face abstraction device, specifically including:
the docking module is used for providing an interface matched with the JSON serialization/anti-serialization;
the identification module is in signal connection with the docking module and is used for acquiring an engine processing strategy;
the processing module is in signal connection with the docking module and the identification module;
the processing module is used for obtaining an initialization parsing library according to the engine processing strategy, obtaining processing instructions through the docking module, and initializing YY+221401P based on the processing instructions
The parsing library performs JSON serialization/deserialization.
Optionally, the identification module includes:
a first unit for calling a JSON serialization/deserialization recognition function through the docking module;
the second unit is used for carrying out JSON analysis library set detection according to the set detection sequence to obtain a target JSON analysis library;
and the third unit is used for obtaining the engine processing strategy according to the target JSON analysis library.
Optionally, the JSON parsing library set includes Jackson parsing library, fastsson parsing library, gson parsing library and JSON-lib parsing library.
Optionally, the setting detection sequence is: jackson, fastJSON, gson, JSON-lib.
Optionally, the engine processing policy is any one of a first policy, a second policy, a third policy or a fourth policy; the first policy, the second policy, the third policy, and the fourth policy are associated with the Jackson parse library, the FastJSON parse library, the Gson parse library, and the JSON-lib parse library, respectively.
Optionally, the processing module includes:
the initialization unit is connected with the identification module and used for initializing a JSON analysis library corresponding to the engine processing strategy to obtain the initialization analysis library;
the instruction acquisition unit is connected with the docking module and is used for acquiring a processing instruction based on an interface;
and the execution unit is used for sending the processing instruction to the initialization analysis library to perform JSON serialization/deserialization operation.
In a second aspect, an embodiment of the present disclosure further provides a smooth upgrade method for JSON serialization/deserialization, including the following steps:
creating a door face abstract model;
introducing a shop front abstract model and a bottom JSON analysis library on which the shop front abstract model depends into a preset program;
performing a serialization/deserialization upgrade operation;
the door face abstract model is a jar packet packaged by any one of the door face abstract devices.
Optionally, the performing the serialization/deserialization upgrade operation includes:
if the attribute of the processing instruction is NULL or NULL, not performing JSON serialization/anti-serialization;
if the processing instruction is an instruction of an empty object type, normally processing and feeding back null;
for a data item modified by a transient in the processing instruction, the data item does not participate in JSON serialization/deserialization;
if the date type attribute of the processing instruction is not consistent with the preset date attribute, modifying the date type attribute to be a specified date format;
if the time zone type attribute in the processing instruction is not consistent with the preset time zone attribute, modifying the time zone type attribute into a designated time zone format.
Optionally, the performing the anti-serialization upgrade operation further includes:
and if the attribute of the processing instruction is unknown, outputting an alarm signal based on an abnormal matching result with a preset attribute.
In a third aspect, an embodiment of the present disclosure further provides an electronic device, which adopts the following technical scheme:
the electronic device includes:
at least one processor; the method comprises the steps of,
a memory communicatively coupled to the at least one processor; wherein, the liquid crystal display device comprises a liquid crystal display device,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform any of the above JSON serialization/deserialization smooth upgrade methods.
In a fourth aspect, the disclosed embodiments also provide a computer readable storage medium storing computer instructions for causing a computer to perform any of the above JSON serialization/deserialization smooth upgrade methods.
The JSON serialization/deserialization smooth upgrading method provided by the embodiment of the disclosure is a unified universal tool which does not need to care about a JSON analysis library, can realize convenient and smooth upgrading of old projects, and can realize the aim of upgrading the multi-scene requirement of the JSON analysis library due to safety consideration, and when upgrading, the JSON analysis library does not need to carry out great improvement on all operations related to JSON in a system, thereby greatly shortening the upgrading period and realizing rapid and efficient convenient and smooth upgrading.
According to the scheme disclosed by the application, no practical implementation of the JSON framework exists, JSON format data are generated and analyzed through the use of the portal abstract model, and only the portal abstract model is required to be called for use, and whether the use of jackson or fastjson is required to be adopted by the bottom layer is not required to be judged.
The portal abstraction model in the application allows the json jar which is actually needed to be freely inserted in deployment. The JSON analysis library is decoupled from the service by independently forming the general facade model into a class library, so that the plug-and-play effect is achieved; meanwhile, the aim that the JSON analysis library is switched at any time according to project requirements and is convenient to upgrade and replace is achieved, so that other services can be thoroughly decoupled from the JSON analysis library according to the realization when the same requirements exist in the project in the future.
The foregoing description is only an overview of the disclosed technology, and may be implemented in accordance with the disclosure of the present disclosure, so that the above-mentioned and other objects, features and advantages of the present disclosure can be more clearly understood, and the following detailed description of the preferred embodiments is given with reference to the accompanying drawings.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the drawings that are needed in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present disclosure, and other drawings may be obtained according to these drawings without inventive effort to a person of ordinary skill in the art.
Fig. 1 is a flow chart of a JSON serialization/deserialization smooth upgrade method provided by an embodiment of the present disclosure.
Fig. 2 is a schematic diagram of a door face abstract device according to an embodiment of the disclosure.
Fig. 3 is a schematic diagram of a configuration of an identification module according to an embodiment of the disclosure.
Fig. 4 is a schematic diagram of a configuration of a processing module according to an embodiment of the disclosure.
Fig. 5 is a schematic block diagram of an electronic device according to an embodiment of the present disclosure.
Detailed Description
Embodiments of the present disclosure are described in detail below with reference to the accompanying drawings.
It should be appreciated that the following specific embodiments of the disclosure are described in order to provide a better understanding of the present disclosure, and that other advantages and effects will be apparent to those skilled in the art from the present disclosure. It will be apparent that the described embodiments are merely some, but not all embodiments of the present disclosure. The disclosure may be embodied or practiced in other different specific embodiments, and details within the subject specification may be modified or changed from various points of view and applications without departing from the spirit of the disclosure. It should be noted that the following embodiments and features in the embodiments may be combined with each other without conflict. All other embodiments, which can be made by one of ordinary skill in the art without inventive effort, based on the embodiments in this disclosure are intended to be within the scope of this disclosure.
It is noted that various aspects of the embodiments are described below within the scope of the following claims. It should be apparent that the aspects described herein may be embodied in a wide variety of forms and that any specific structure and/or function described herein is merely illustrative. Based on the present disclosure, one skilled in the art will appreciate that one aspect described herein may be implemented independently of any other aspect, and that two or more of these aspects may be combined in various ways. For example, an apparatus may be implemented and/or a method practiced using any number of the aspects set forth herein. In addition, such apparatus may be implemented and/or such methods practiced using other structure and/or functionality in addition to one or more of the aspects set forth herein.
It should also be noted that the illustrations provided in the following embodiments merely illustrate the basic concepts of the disclosure by way of illustration, and only the components related to the disclosure are shown in the drawings and are not drawn according to the number, shape and size of the components in actual implementation, and the form, number and proportion of the components in actual implementation may be arbitrarily changed, and the layout of the components may be more complicated.
In addition, in the following description, specific details are provided in order to provide a thorough understanding of the examples. However, it will be understood by those skilled in the art that the aspects may be practiced without these specific details.
Referring to fig. 1, an embodiment of the present disclosure provides a smooth upgrade method of JSON serialization/deserialization, which specifically includes the following steps:
s100, a door face abstract model is created, wherein the door face abstract model is a door face abstract device packaged into a jar packet, and the jar packet is embedded into a service A (namely a preset program) in a concrete embodiment.
S200, introducing a portal abstract model and a bottom JSON analysis library on which the portal abstract model depends into a preset program.
Specifically, a service embedded in the model is deployed to a Linux server: setting Java environment variable according to the corresponding jdk in Linux server; uploading the jar of the service to the Linux server designated directory.
Further, the introduction mode comprises:
a) For common Java items, a lib directory is newly built under the item directory, a face abstract model jar package is copied to the folder, and then all the dependencies under the lib directory are imported into the classpath.
b) For Maven project, directly adding the dependent coordinates of the portal abstract model jar in the pon.xml under the project.
c) For Gradle projects, directly adding the dependent coordinates of the door face abstract model jar in the build. Gradle under the project.
S300, carrying out serialization/deserialization upgrading operation.
In actual use, the service is started through a java-jarxxx.jar command, so that automatic upgrading operation is realized.
According to the scheme disclosed by the application, no practical implementation of the JSON framework exists, JSON format data are generated and analyzed through the use of the portal abstract model, and only the portal abstract model is required to be called for use, and whether the use of jackson or fastjson is required to be adopted by the bottom layer is not required to be judged.
The portal abstraction model in the application allows the json jar which is actually needed to be freely inserted in deployment. The JSON analysis library is decoupled from the service by independently forming the general facade model into a class library, so that the plug-and-play effect is achieved; meanwhile, the aim that the JSON analysis library is switched at any time according to project requirements and is convenient to upgrade and replace is achieved, so that other services can be thoroughly decoupled from the JSON analysis library according to the realization when the same requirements exist in the project in the future.
Referring to fig. 2, the facade abstraction device includes a docking module, an identification module, and a processing module, wherein the identification module is in signal connection or communication connection with the docking module, and the processing module is in signal connection or communication connection with the docking module, the identification module.
The docking module is used for providing an interface matched with JSON serialization/deserialization, and aims to dynamically identify available mainstream JSON parsing libraries.
The identification module is used for acquiring the engine processing strategy and further used for identifying the engine processing strategy by the docking interface.
The processing module is used for obtaining an initialization analysis library according to an engine processing strategy, obtaining a processing instruction according to an interface, and performing JSON serialization/deserialization on the basis of the processing instruction and the initialization analysis library.
In the processing module, initializing a JSON analysis library corresponding to an engine processing strategy through connection with the identification module to obtain an initialized analysis library; acquiring a processing instruction based on an interface through connection with the docking module; then, sending the processing instruction to an initialization analysis library to perform JSON serialization/deserialization operation; the method comprises the steps of firstly obtaining an initialization analysis library according to an engine processing strategy, obtaining a processing instruction according to an interface, and then carrying out JSON serialization/deserialization smooth upgrading on the initialization analysis library according to the processing instruction.
Specifically, referring to fig. 3, the identification module includes a first unit, a second unit, and a third unit; the first unit is used for interfacing the interface to call the JSON serialization/deserialization recognition function.
In the embodiment, a polymorphic mechanism is adopted to carry out the butt joint of interfaces; and adopting a delegation mechanism to call the identification function.
The second unit is used for carrying out JSON analysis library set detection according to the set detection sequence to obtain a target JSON analysis library; in this embodiment, a reflection mechanism is used to obtain a target JSON parsing library.
The JSON analysis library set comprises a Jackson analysis library, a FastJSON analysis library, a Gson analysis library and a JSON-lib analysis library.
The detection sequence is set as follows: jackson > FastJSON > Gson > JSON-lib, namely, for a JSON analysis library set, judging by taking a set detection sequence as a standard, judging whether the JSON analysis library is an abnormal analysis library, whether the JSON analysis library is a target analysis library or not, and whether the JSON serialization/deserialization operation can be met.
The third unit is used for obtaining the engine processing strategy according to the target JSON analysis library; in an embodiment, the engine processes the SPI mechanism adopted by the method for obtaining the strategy.
The engine processing strategy is any one of a first strategy, a second strategy, a third strategy or a fourth strategy; and the first strategy, the second strategy, the third strategy and the fourth strategy are respectively and correspondingly arranged with a Jackson analysis library, a FastJSON analysis library, a Gson analysis library and a JSON-lib analysis library.
Further, referring to fig. 4, the processing module includes an initializing unit, an instruction acquiring unit, and an executing unit, where the initializing unit is in communication with or signal connected to the identifying module, and the instruction acquiring unit is in communication with or signal connected to the docking module.
The initialization unit is used for initializing the JSON analysis library corresponding to the engine processing strategy to obtain an initialization analysis library. The instruction acquisition unit acquires a processing instruction based on the interface; the execution unit is used for sending the processing instruction to the initialization analysis library, and performing JSON serialization/deserialization operation through the initialization analysis library, so that the JSON serialization/deserialization smooth upgrading is realized, and the requirement of the project non-perception upgrading JSON analysis library is met.
The process of performing JSON serialization smooth upgrade (i.e., the process of initializing the parsing library) specifically includes the following aspects:
1) If the attribute of the processing instruction is NULL or the attribute is default, the JSON deserialization is not executed.
2) If the processing instruction is an empty object type instruction, the exception is not thrown, normal processing is performed, and null is fed back.
3) For data items modified by the transient in the processing instruction, JSON deserialization is not participated, namely, the attribute of the modification of the transient is ignored.
4) If the date type attribute of the processing instruction is not consistent with the preset date attribute, modifying the processing instruction into a specified date format, namely modifying the date format after modification serialization.
5) If the time zone type attribute in the processing instruction is not consistent with the preset time zone attribute, modifying the time zone type attribute to be the designated time zone format, namely processing different time zone offset formats.
The process of performing JSON deserialization smooth upgrade (i.e., the process of initializing the parsing library) specifically includes the following aspects:
1) If the property of the processing instruction is NULL or NULL, JSON deserialization is not performed.
2) If the attribute of the processing instruction is unknown, based on an abnormal matching result with a preset attribute, an alarm signal is output, specifically, when deserialization is performed, an operation that the unknown attribute is encountered and error cannot be reported is performed, namely, the self-contained judgment of an analysis library is initialized, when the unknown attribute is encountered during deserialization, the alarm is performed according to the feedback identification or not, if the feedback identification is false, the alarm is performed, and if the feedback identification is wire, the alarm is not performed.
3) If the processing instruction is an empty object type instruction, the exception is not thrown, normal processing is performed, and null is fed back.
4) For data items modified by the transient in the processing instruction, JSON deserialization is not participated, namely, the attribute of the modification of the transient is ignored.
5) If the date type attribute of the processing instruction is not consistent with the preset date attribute, modifying the processing instruction into a specified date format, namely modifying the date format after reverse serialization.
6) If the time zone type attribute in the processing instruction is not consistent with the preset time zone attribute, modifying the time zone type attribute to be the designated time zone format, namely processing different time zone offset formats.
It should be noted that, when JSON data is transmitted through a network, two types exist, one is a JSON object type and the other is a JSON string type, and two types of conversion involve knowledge of JSON serialization and deserialization.
JSON serialization is a process of processing JSON objects into JSON strings to facilitate the transmission of data. JSON serialization can be achieved in two ways, one is to call a stringy () function built in a JSON object, and one is to customize a toJSON () function for the object. And (3) performing JSON deserialization, namely converting the JSON character string into a JSON object, wherein the obtained result is used for performing logic processing in JavaScript. There are two implementations of JSON deserialization, one using the parameter () function built in the JSON object and one using the eval () function.
An electronic device according to an embodiment of the present disclosure includes a memory and a processor. The memory is for storing non-transitory computer readable instructions. In particular, the memory may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and/or non-volatile memory. The volatile memory may include, for example, random Access Memory (RAM) and/or cache memory (cache), and the like. The non-volatile memory may include, for example, read Only Memory (ROM), hard disk, flash memory, and the like.
The processor may be a Central Processing Unit (CPU) or other form of processing unit having data processing and/or instruction execution capabilities, and may control other components in the electronic device to perform the desired functions. In one embodiment of the present disclosure, the processor is configured to execute the computer readable instructions stored in the memory to cause the electronic device to perform all or part of the foregoing steps of the JSON serialization/deserialization smooth upgrade method of the various embodiments of the present disclosure.
It should be understood by those skilled in the art that, in order to solve the technical problem of how to obtain a good user experience effect, the present embodiment may also include well-known structures such as a communication bus, an interface, and the like, and these well-known structures are also included in the protection scope of the present disclosure.
Fig. 5 is a schematic structural diagram of an electronic device according to an embodiment of the disclosure. A schematic diagram of an electronic device suitable for use in implementing embodiments of the present disclosure is shown. The electronic device shown in fig. 5 is merely an example and should not be construed to limit the functionality and scope of use of the disclosed embodiments.
As shown in fig. 5, the electronic device may include a processing means (e.g., a central processing unit, a graphic processor, etc.) that may perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM) or a program loaded from a storage means into a Random Access Memory (RAM). In the RAM, various programs and data required for the operation of the electronic device are also stored. The processing device, ROM and RAM are connected to each other via a bus. An input/output (I/O) interface is also connected to the bus.
In general, the following devices may be connected to the I/O interface: input means including, for example, sensors or visual information gathering devices; output devices including, for example, display screens and the like; storage devices including, for example, magnetic tape, hard disk, etc.; a communication device. The communication means may allow the electronic device to communicate wirelessly or by wire with other devices, such as edge computing devices, to exchange data. While fig. 5 shows an electronic device having various means, it is to be understood that not all of the illustrated means are required to be implemented or provided. More or fewer devices may be implemented or provided instead.
In particular, according to embodiments of the present disclosure, the processes described above with reference to flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a non-transitory computer readable medium, the computer program comprising program code for performing the method shown in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network via a communication device, or installed from a storage device, or installed from ROM. All or part of the steps of the JSON serialization/deserialization smooth upgrade method of an embodiment of the present disclosure are performed when the computer program is executed by a processing device.
The detailed description of the present embodiment may refer to the corresponding description in the foregoing embodiments, and will not be repeated herein.
A computer-readable storage medium according to an embodiment of the present disclosure has stored thereon non-transitory computer-readable instructions. When executed by a processor, perform all or part of the steps of the JSON serialization/deserialization smooth upgrade method of the various embodiments of the present disclosure described previously.
The computer-readable storage medium described above includes, but is not limited to: optical storage media (e.g., CD-ROM and DVD), magneto-optical storage media (e.g., MO), magnetic storage media (e.g., magnetic tape or removable hard disk), media with built-in rewritable non-volatile memory (e.g., memory card), and media with built-in ROM (e.g., ROM cartridge).
The detailed description of the present embodiment may refer to the corresponding description in the foregoing embodiments, and will not be repeated herein.
The basic principles of the present disclosure have been described above in connection with specific embodiments, however, it should be noted that the advantages, benefits, effects, etc. mentioned in the present disclosure are merely examples and not limiting, and these advantages, benefits, effects, etc. are not to be considered as necessarily possessed by the various embodiments of the present disclosure. Furthermore, the specific details disclosed herein are for purposes of illustration and understanding only, and are not intended to be limiting, since the disclosure is not necessarily limited to practice with the specific details described.
In this disclosure, relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions, and the block diagrams of devices, apparatuses, devices, systems involved in this disclosure are merely illustrative examples and are not intended to require or implicate that connections, arrangements, configurations must be made in the manner shown in the block diagrams. As will be appreciated by one of skill in the art, the devices, apparatuses, devices, systems may be connected, arranged, configured in any manner. Words such as "including," "comprising," "having," and the like are words of openness and mean "including but not limited to," and are used interchangeably therewith. The terms "or" and "as used herein refer to and are used interchangeably with the term" and/or "unless the context clearly indicates otherwise. The term "such as" as used herein refers to, and is used interchangeably with, the phrase "such as, but not limited to.
In addition, as used herein, the use of "or" in the recitation of items beginning with "at least one" indicates a separate recitation, such that recitation of "at least one of A, B or C" for example means a or B or C, or AB or AC or BC, or ABC (i.e., a and B and C). Furthermore, the term "exemplary" does not mean that the described example is preferred or better than other examples.
It is also noted that in the systems and methods of the present disclosure, components or steps may be disassembled and/or assembled. Such decomposition and/or recombination should be considered equivalent to the present disclosure.
Various changes, substitutions, and alterations are possible to the techniques described herein without departing from the teachings of the techniques defined by the appended claims. Furthermore, the scope of the claims of the present disclosure is not limited to the particular aspects of the process, machine, manufacture, composition of matter, means, methods and acts described above. The processes, machines, manufacture, compositions of matter, means, methods, or acts, presently existing or later to be developed that perform substantially the same function or achieve substantially the same result as the corresponding aspects described herein may be utilized. Accordingly, the appended claims are intended to include within their scope such processes, machines, manufacture, compositions of matter, means, methods, or acts.
The previous description of the disclosed aspects is provided to enable any person skilled in the art to make or use the present disclosure. Various modifications to these aspects will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other aspects without departing from the scope of the disclosure. Thus, the present disclosure is not intended to be limited to the aspects shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
The foregoing description has been presented for purposes of illustration and description. Furthermore, this description is not intended to limit the embodiments of the disclosure to the form disclosed herein. Although a number of example aspects and embodiments have been discussed above, a person of ordinary skill in the art will recognize certain variations, modifications, alterations, additions, and subcombinations thereof.

Claims (10)

1. A door facing abstraction device, comprising:
the docking module is used for providing an interface matched with the JSON serialization/anti-serialization;
the identification module is in signal connection with the docking module and is used for acquiring an engine processing strategy;
the processing module is in signal connection with the docking module and the identification module;
the processing module is used for obtaining an initialization analysis library according to the engine processing strategy, obtaining a processing instruction through the docking module, and performing JSON serialization/deserialization on the basis of the processing instruction and the initialization analysis library.
2. The facade abstraction device according to claim 1, wherein the identification module comprises:
a first unit for calling a JSON serialization/deserialization recognition function through the docking module;
the second unit is used for carrying out JSON analysis library set detection according to the set detection sequence to obtain a target JSON analysis library;
and the third unit is used for obtaining the engine processing strategy according to the target JSON analysis library.
3. The facade abstracting apparatus according to claim 2, wherein the set of JSON parsing libraries includes Jackson parsing libraries, fastJSON parsing libraries, gson parsing libraries, and JSON-lib parsing libraries;
the set detection sequence is as follows: jackson, fastJSON, gson, JSON-lib.
4. The facade abstraction device according to claim 3, wherein the engine processing policy is any one of a first policy, a second policy, a third policy, or a fourth policy;
the first policy, the second policy, the third policy, and the fourth policy are associated with the Jackson parse library, the FastJSON parse library, the Gson parse library, and the JSON-lib parse library, respectively.
5. The facade abstraction device according to claim 1, wherein the processing module comprises:
the initialization unit is connected with the identification module and is used for initializing a JSON analysis library corresponding to the engine processing strategy to obtain the initialization analysis library;
the instruction acquisition unit is connected with the docking module and acquires a processing instruction based on an interface;
and the execution unit is used for sending the processing instruction to the initialization analysis library to perform JSON serialization/deserialization operation.
6. A smooth upgrade method of JSON serialization/deserialization, comprising:
creating a door face abstract model;
introducing a shop front abstract model and a bottom JSON analysis library on which the shop front abstract model depends into a preset program;
performing a serialization/deserialization upgrade operation;
the door face abstract model is a jar packet packaged by the door face abstract device according to any one of claims 1 to 5.
7. The smooth upgrade method of JSON serialization/deserialization according to claim 6, wherein the upgrade operation to perform serialization/deserialization comprises:
if the attribute of the processing instruction is NULL or NULL, not performing JSON serialization/anti-serialization;
if the processing instruction is an instruction of an empty object type, normally processing and feeding back null;
for a data item modified by a transient in the processing instruction, the data item does not participate in JSON serialization/deserialization;
if the date type attribute of the processing instruction is not consistent with the preset date attribute, modifying the date type attribute to be a specified date format;
if the time zone type attribute in the processing instruction is not consistent with the preset time zone attribute, modifying the time zone type attribute into a designated time zone format.
8. The JSON serialization/deserialization smooth upgrade method of claim 7, wherein the performing the deserialization upgrade operation further comprises:
and if the attribute of the processing instruction is unknown, outputting an alarm signal based on an abnormal matching result with a preset attribute.
9. An electronic device, the electronic device comprising:
at least one processor; the method comprises the steps of,
a memory communicatively coupled to the at least one processor; wherein, the liquid crystal display device comprises a liquid crystal display device,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the JSON serialization/deserialization smooth upgrade method of claim 8.
10. A computer readable storage medium storing computer instructions for causing a computer to perform the JSON serialization/deserialization smooth upgrade method of any one of claims 6-8.
CN202310106214.6A 2023-02-13 2023-02-13 Smooth upgrading method for door face abstract device and JSON serialization/deserialization Pending CN116301970A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310106214.6A CN116301970A (en) 2023-02-13 2023-02-13 Smooth upgrading method for door face abstract device and JSON serialization/deserialization

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310106214.6A CN116301970A (en) 2023-02-13 2023-02-13 Smooth upgrading method for door face abstract device and JSON serialization/deserialization

Publications (1)

Publication Number Publication Date
CN116301970A true CN116301970A (en) 2023-06-23

Family

ID=86791487

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310106214.6A Pending CN116301970A (en) 2023-02-13 2023-02-13 Smooth upgrading method for door face abstract device and JSON serialization/deserialization

Country Status (1)

Country Link
CN (1) CN116301970A (en)

Similar Documents

Publication Publication Date Title
US7681138B2 (en) Use of a reusable control software whose user interface and communication connection are established via an external description-based configuration at run time
US8418132B2 (en) Application description language
US7051316B2 (en) Distributed computing component system with diagrammatic graphical representation of code with separate delineated display area by type
US7886035B2 (en) Profile service based deployment configuration
US8327341B2 (en) Integrating aspect oriented programming into the application server
US20030200532A1 (en) System and method for sharing reusable code base
EP3047372B1 (en) Computer-aided development of native mobile application code
US8479150B2 (en) Compositional modeling of integrated systems using event-based legacy applications
KR20020035567A (en) Object property meta model emulator for legacy data structures
US20210208854A1 (en) System and method for enhancing component based development models with auto-wiring
CN105022630A (en) Component management system and component management method
US20120005647A1 (en) Automated discovery of programmatic resources
CN107463406A (en) Issue the method and electronic equipment of Mobile solution
CN114461182A (en) Method and device for pipeline construction, electronic equipment and computer readable storage medium
CN115291946A (en) Hongmong system transplanting method, device, electronic equipment and readable medium
CN114661375A (en) Application integration method and device
US9009699B2 (en) Providing a POJO-based microcontainer for an application server
CN114217789A (en) Function component expansion method, device, equipment, storage medium and program product
CN108287720B (en) Software compiling method, device, equipment and storage medium
CN114048415A (en) Form generation method and device, electronic equipment and computer readable storage medium
US9250885B2 (en) Image forming apparatus operating based on framework capable of sharing function among a plurality of bundles and method of installing bundle in image forming apparatus
TWI467481B (en) Method, system, and computer program product for hierarchical program source management
CN116301970A (en) Smooth upgrading method for door face abstract device and JSON serialization/deserialization
Guojie Professional Java native interfaces with SWT/JFace
US20060101436A1 (en) Hosting environment abstraction model for content

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