CN104572087A - Adaptation mode method and system for business logic implementation - Google Patents
Adaptation mode method and system for business logic implementation Download PDFInfo
- Publication number
- CN104572087A CN104572087A CN201410822623.7A CN201410822623A CN104572087A CN 104572087 A CN104572087 A CN 104572087A CN 201410822623 A CN201410822623 A CN 201410822623A CN 104572087 A CN104572087 A CN 104572087A
- Authority
- CN
- China
- Prior art keywords
- logic
- service
- service logic
- business
- interface
- 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
Links
Landscapes
- Debugging And Monitoring (AREA)
Abstract
The invention relates to an adaptation mode method and an adaptation mode system for business logic implementation, which are especially applied to the situation that the difficulty in business logic interface development is reduced, so that a developer concentrates on the core part of the business logic. The adaptation mode method comprises the following steps of (S2) executing pre-business operation of a business logic adapter; (S3) loading a business logic component by the business logic adapter; (S5) executing business logic processing on input list parameters of an execution object by the business logic adapter; (S7) executing post-business operation. The adaptation mode method and the adaptation mode system for the business logic implementation have the beneficial effects that the development workload of the developer can be reduced, and the developer pays more attention on the development of core business logic; the business logic adapter can be configured, so that richer management and monitoring functions are provided for the business logic operations, and the developer do not need to perform more development, compiling and testing work.
Description
Technical field
The present invention relates to technical field of data processing, more particularly, relate to a kind of difficulty reducing service logic interface exploitation, the adapt mode method and system that the service logic making the energy of developer concentrate on the situation of the core of service logic realizes.
Background technology
In traditional software three-tier architecture, requirement for the realization of software operation logic interfacing is a lot, not only require that service logic interface considers diversified input parameter list, and also will consider the needs of execution time, log recording, operation note (database preservation) etc. when the exploitation of logic interfacing inside.How to reduce the difficulty of business logic development interface, reduce the cost of software development, become the required problem solved of software factory.
Common service logic Interface realization, not only there are dissimilar input parameter list, internal logic, Output rusults, and inside must realize the bookkeeping of execution time statistics, operation log recording, operation note (being saved in database) equivalent type, as shown in Figure 1.
Multiple service logic Interface realization is there is in software systems, the input parameter list of each service logic interface is not necessarily identical, the internal logic (1-n) realized is also different, Output rusults is not identical yet, but service logic interface internal exists identical process, the duration that such as record interface operates, record interface Operation Log, record operation note are to database management process.
The major defect of existing service logic Interface realization has following 2 points:
1: service logic inside realizes loaded down with trivial details.Developer not only needs to realize different internal logics, also must realize the management process of record interface duration, record Operation Log, record operation note at each service logic interface internal, cause the task of developer heavy.
2: more difficult expansion management function.If need the statistics increasing an average interface duration in inside realizes, just need developer in the realization of each service logic, increase corresponding management process, cause all code revisions, compiling, test, more difficult expansion management function.
Summary of the invention
Technical matters to be solved by this invention is, comparatively loaded down with trivial details for existing service logic inside exploitation, management function expands the situation of comparatively difficulty, provides the adapt mode method and system that a kind of service logic realizes.
The technical scheme that the present invention solves the problems of the technologies described above is as follows: a kind of adapt mode method that service logic realizes, and comprising:
S1, service logic adapter receive the execution object of service logic interface, perform step S2 when described execution object is legal;
S2, described service logic adapter perform front service operation;
S3, described service logic adapter are by the interface name loaded with traffic logic module of described execution object;
S4, described service logic adapter call the internal logic of the business logic components corresponding with the interface name of service logic interface;
S5, described service logic adapter combination internal logic perform business logic processing to the parameter of the input list of described execution object;
Service logic result after execution outputs among the results list of service logic interface by S6, described service logic adapter;
S7, described service logic adapter perform rearmounted business operation.
In the adapt mode method that service logic of the present invention realizes, the execution object of described service logic interface comprises: interface name, input list and the results list; Described interface name is the title of internal logic, and described input list comprises at least one parameter, and described the results list comprises at least one result.
In the adapt mode method that service logic of the present invention realizes, described step S1 also comprises: when the execution object of described service logic adapter reception service logic interface is illegal, stops receiving performing object to service logic interface, and stops process.
In the adapt mode method that service logic of the present invention realizes, described front service is operating as record interface and calls the start time.
In the adapt mode method that service logic of the present invention realizes, described rearmounted business operation comprises record traffic logic interfacing duration, record Operation Log and record operation.
In the adapt mode method that service logic of the present invention realizes, described front service operation and rearmounted business operation can increase at least one operation, strengthen the management to service logic.
The adapt mode system that service logic realizes, comprising: front service operational module, business logic processing module and rearmounted service operation module;
Described front service operational module, for managing the record of front service operation;
Described business logic processing module, for the internal logic in conjunction with business logic components, the parameter inputting list in the execution object to described service logic interface carries out business logic processing, and among the results list result being stored into described execution object.
Described rearmounted business operation device, for managing the record of rearmounted business operation.
In the adapt mode system that service logic of the present invention realizes, described business logic processing module comprises: service logic selector switch and business logic components;
Described service logic selector switch, for according to the interface name performing object, selects the internal logic of business logic components corresponding thereto.
Described business logic components, for storing at least one internal logic;
Described service logic selector switch is connected with described business logic components.
In the adapt mode system that service logic of the present invention realizes, described business logic processing module is connected with described service logic interface.
In the adapt mode system that service logic of the present invention realizes, described front service operational module, business logic processing module are connected successively with rearmounted service operation module.
Implement the adapt mode method and system that service logic of the present invention realizes, there is following beneficial effect: developer can be made to reduce development amount, by the exploitation of input core business logic larger for energy; Service logic adapter can realize configurationization, for business logical operation provides abundanter management and supervision function, and does not need that developer more develops, compile and test work.
Accompanying drawing explanation
Fig. 1 is the structural representation of the service logic interface of prior art;
Fig. 2 is the process flow diagram of the preferred embodiment of the adapt mode method that service logic of the present invention realizes;
Fig. 3 is the configuration schematic diagram of the front service operation of the preferred embodiment of the adapt mode method that service logic of the present invention realizes;
Fig. 4 is the configuration schematic diagram of the rearmounted business operation of the preferred embodiment of the adapt mode method that service logic of the present invention realizes;
Fig. 5 is the adapt mode system architecture schematic diagram that service logic of the present invention realizes;
Fig. 6 is the expanded structure schematic diagram of the service logic adapter management function of the adapt mode system that service logic of the present invention realizes.
Embodiment
In order to make object of the present invention, technical scheme and advantage clearly understand, below in conjunction with drawings and Examples, the present invention is further elaborated.Should be appreciated that specific embodiment described herein only in order to explain the present invention, be not intended to limit the present invention.
As shown in Figure 2, in the process flow diagram of the preferred embodiment of the adapt mode method realized in service logic of the present invention, the adapt mode method that described service logic realizes starts from step S0: proceed to step S1 after step S0, service logic adapter receives the execution object of service logic interface, performs step S2 when described execution object is legal; Subsequently, to next step S2, described service logic adapter performs front service operation; Subsequently, to next step S3, described service logic adapter is by the interface name loaded with traffic logic module of described execution object; Subsequently, to next step S4, described service logic adapter calls the internal logic of the business logic components corresponding with the interface name of service logic interface; Subsequently, to next step S5, described service logic adapter combination internal logic performs business logic processing to the parameter of the input list of described execution object; Subsequently, to next step S6, the service logic result after execution outputs among the results list of service logic interface by described service logic adapter; Subsequently, to next step S7, described service logic adapter performs rearmounted business operation; Last the method ends at step S8.
Further, the execution object of described service logic interface comprises: interface name, input list and the results list; Described interface name is the title of internal logic, and described input list comprises at least one parameter, and described the results list comprises at least one result.
Further, described step S1 also comprises: when the execution object of described service logic adapter reception service logic interface is illegal, stops receiving performing object to service logic interface, and stops process.
Further, described front service is operating as record interface and calls the start time.
Further, described rearmounted business operation comprises record traffic logic interfacing duration, record Operation Log and record operation.
Further, the operation of described front service and rearmounted business operation can increase at least one operation, strengthen the management to service logic.
The beneficial effect of the adapt mode method that service logic of the present invention realizes: developer can be made to reduce development amount, by the exploitation of input core business logic larger for energy.
As shown in Figure 3, in the configuration schematic diagram of the front service operation of the preferred embodiment of the adapt mode method realized in service logic of the present invention, configure the operation of described front service to comprise: the configuration record interface interchange start time, the quantity etc. of the parameter of configuration record input list, the configuration of described front service operation can comprise at least one configuration information.
Described record interface calls the start time, for wanting to calculate with the end time, is convenient to the time of statistics process;
The quantity of the parameter of described record input list, for compared with the input results quantity of the results list, judges the progress of process;
The operation of configuration front service, is convenient to the record managing the operation of described front service.
As shown in Figure 4, in the configuration schematic diagram of the rearmounted business operation of the preferred embodiment of the adapt mode method realized in service logic of the present invention, configure described rearmounted business operation to comprise: configuration record interface duration, configuration record Operation Log, configuration record operates, the average durations of configuration record interface etc., the configuration of described rearmounted business operation can comprise at least one configuration information.
Described record interface duration, for the short time consumption of record the process;
Described record Operation Log, for recording the operation steps in whole process, is convenient to later stage inquiry;
The average duration of described record interface, for the statistics that is often averaged to the execution of service logic, is convenient to the statistics of software systems to business operation.
Configure rearmounted business operation, for recording the bookkeeping of whole process.
As shown in Figure 5, at the structural representation of the adapt mode system that service logic of the present invention realizes, comprising: front service operational module, business logic processing module and rearmounted service operation module;
Described front service operational module, for managing the record of front service operation;
Described business logic processing module, for the internal logic in conjunction with business logic components, the parameter inputting list in the execution object to described service logic interface carries out business logic processing, and among the results list result being stored into described execution object.
Described rearmounted business operation device, for managing the record of rearmounted business operation.
Further, described business logic processing module also comprises: service logic selector switch and business logic components;
Described service logic selector switch, for according to the interface name performing object, selects the internal logic of business logic components corresponding thereto.
Described business logic components, for storing at least one internal logic;
Described service logic selector switch is connected with described business logic components.
Further, described business logic processing module is connected with described service logic interface.
Described service logic interface, for the execution object of transport service logic; Input list during data input under fetch interface title, and receive the results list after business logic processing.
Further, described front service operational module, business logic processing module are connected successively with rearmounted service operation module.
The adapt mode system that service logic of the present invention realizes, can make developer reduce development amount, by the exploitation of input core business logic larger for energy; Service logic adapter can realize configurationization, need not more develop, compile and test work.
As shown in Figure 6, the expanded structure schematic diagram of the service logic adapter management function of the adapt mode system that service logic of the present invention realizes, namely comprises the expansion to front service operation or rearmounted business operation.
Described service logic adapter can increase preposition or rearmounted business operation, carries out abundanter management to service logic.As the rearmounted business operation of the average duration of record interface of dotted line frame in figure, for the statistics that is often averaged to the execution of service logic, be convenient to the statistics of software systems to business operation.
Described service logic adapter only increases preposition or rearmounted business operation, does not need to modify, greatly reduce the workload of developer to internal logic.Simultaneously by increasing the preposition or rearmounted business operation of adapter, more convenient system manager management and supervision can be carried out to system.
Compared with prior art, the adapt mode method and system that service logic of the present invention realizes can make developer reduce development amount, by the exploitation of input core business logic larger for energy; Service logic adapter can realize configurationization, for business logical operation provides abundanter management and supervision function, and does not need that developer more develops, compile and test work.
The foregoing is only embodiments of the invention; not thereby the scope of the claims of the present invention is limited; every equivalent structure transformation utilizing instructions of the present invention and accompanying drawing content to do, or be directly or indirectly used in other relevant technical fields, be all in like manner included in scope of patent protection of the present invention.
Claims (10)
1. an adapt mode method for service logic realization, is characterized in that, comprising:
S1, service logic adapter receive the execution object of service logic interface, perform step S2 when described execution object is legal;
S2, described service logic adapter perform front service operation;
S3, described service logic adapter are by the interface name loaded with traffic logic module of described execution object;
S4, described service logic adapter call the internal logic of the business logic components corresponding with the interface name of service logic interface;
S5, described service logic adapter combination internal logic perform business logic processing to the parameter of the input list of described execution object;
Service logic result after execution outputs among the results list of service logic interface by S6, described service logic adapter;
S7, described service logic adapter perform rearmounted business operation.
2. the adapt mode method of service logic realization according to claim 1, it is characterized in that, the execution object of described service logic interface comprises: interface name, input list and the results list; Described interface name is the title of internal logic, and described input list comprises at least one parameter, and described the results list comprises at least one result.
3. the adapt mode method of service logic realization according to claim 1 and 2, it is characterized in that, described step S1 also comprises: when the execution object of described service logic adapter reception service logic interface is illegal, stops receiving performing object to service logic interface, and stops process.
4. the adapt mode method of service logic realization according to claim 1, it is characterized in that, described front service is operating as record interface and calls the start time.
5. the adapt mode method of service logic realization according to claim 1, is characterized in that, described rearmounted business operation comprises record traffic logic interfacing duration, record Operation Log and record operation.
6. the adapt mode method that realizes of service logic according to claim 1, is characterized in that, described front service operation and rearmounted business operation can increase at least one operation, strengthen the management to service logic.
7. an adapt mode system for service logic realization, is characterized in that, comprising: front service operational module, business logic processing module and rearmounted service operation module;
Described front service operational module, for managing the record of front service operation;
Described business logic processing module, for the internal logic in conjunction with business logic components, the parameter inputting list in the execution object to described service logic interface carries out business logic processing, and among the results list result being stored into described execution object.
Described rearmounted business operation device, for managing the record of rearmounted business operation.
8. the adapt mode system of service logic realization according to claim 7, it is characterized in that, described business logic processing module comprises: service logic selector switch and business logic components;
Described service logic selector switch, for according to the interface name performing object, selects the internal logic of business logic components corresponding thereto.
Described business logic components, for storing at least one internal logic;
Described service logic selector switch is connected with described business logic components.
9. the adapt mode system of service logic realization according to claim 7, it is characterized in that, described business logic processing module is connected with described service logic interface.
10. the system of the adapt mode of service logic realization according to claim 7, it is characterized in that, described front service operational module, business logic processing module are connected successively with rearmounted service operation module.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410822623.7A CN104572087A (en) | 2014-12-25 | 2014-12-25 | Adaptation mode method and system for business logic implementation |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410822623.7A CN104572087A (en) | 2014-12-25 | 2014-12-25 | Adaptation mode method and system for business logic implementation |
Publications (1)
Publication Number | Publication Date |
---|---|
CN104572087A true CN104572087A (en) | 2015-04-29 |
Family
ID=53088253
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410822623.7A Pending CN104572087A (en) | 2014-12-25 | 2014-12-25 | Adaptation mode method and system for business logic implementation |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104572087A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105589695A (en) * | 2015-12-23 | 2016-05-18 | 深圳市丽海弘金科技有限公司 | Business function calling method and system |
CN110611674A (en) * | 2019-09-20 | 2019-12-24 | 北京三快在线科技有限公司 | Protocol interaction method, system and storage medium between different computer systems |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103279358A (en) * | 2013-06-08 | 2013-09-04 | 北京首钢自动化信息技术有限公司 | Interpreted dynamic business component construction method for industrial applications |
CN103677825A (en) * | 2013-12-10 | 2014-03-26 | 国家电网公司 | Multithreading universal data processing frame and establish method thereof based on Java |
CN104123135A (en) * | 2014-07-04 | 2014-10-29 | 北京思特奇信息技术股份有限公司 | Method and device for unifying background interfaces |
CN104156300A (en) * | 2013-05-14 | 2014-11-19 | 利德科技发展有限公司 | Log management system and log management method |
-
2014
- 2014-12-25 CN CN201410822623.7A patent/CN104572087A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104156300A (en) * | 2013-05-14 | 2014-11-19 | 利德科技发展有限公司 | Log management system and log management method |
CN103279358A (en) * | 2013-06-08 | 2013-09-04 | 北京首钢自动化信息技术有限公司 | Interpreted dynamic business component construction method for industrial applications |
CN103677825A (en) * | 2013-12-10 | 2014-03-26 | 国家电网公司 | Multithreading universal data processing frame and establish method thereof based on Java |
CN104123135A (en) * | 2014-07-04 | 2014-10-29 | 北京思特奇信息技术股份有限公司 | Method and device for unifying background interfaces |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105589695A (en) * | 2015-12-23 | 2016-05-18 | 深圳市丽海弘金科技有限公司 | Business function calling method and system |
CN110611674A (en) * | 2019-09-20 | 2019-12-24 | 北京三快在线科技有限公司 | Protocol interaction method, system and storage medium between different computer systems |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106156186B (en) | Data model management device, server and data processing method | |
US8572437B2 (en) | Multi-platform test automation enhancement | |
CN106708718B (en) | Service framework interface test method and device | |
CN110377520B (en) | Transaction scenario testing method and device, electronic equipment and readable storage medium | |
CN100511156C (en) | Apparatus for compulsively terminating thread blocked on input/output operation and method for the same | |
CN107480327B (en) | Simulation verification method and device and electronic equipment | |
CN105022691A (en) | Highly automatic software testing method based on UML diagram | |
CN110225078B (en) | Application service updating method, system and terminal equipment | |
CN105204917B (en) | The method and device of loading configuration file in application program launching | |
CN109815141B (en) | Test method and device | |
CN103885873A (en) | Automated integration testing method | |
CN104778118A (en) | Improvement method for automatic testing technology | |
CN103186463B (en) | Determine the method and system of the test specification of software | |
CN116166525A (en) | Method and device for generating test script | |
CN114117973A (en) | Logic synthesis method, device and storage medium | |
CN104572087A (en) | Adaptation mode method and system for business logic implementation | |
CN105550103A (en) | Custom test script based automated testing method | |
CN102521132A (en) | Automated testing method and automated testing system for real-time output logs | |
CN110209565A (en) | A kind of metadata schema adjustment method and its device | |
CN102591714B (en) | Process calling method, system and application server | |
CN100576182C (en) | The real-time monitoring system of computer documents and method | |
CN105868957A (en) | Continuous integration method and device | |
CN112130849B (en) | Code automatic generation method and device | |
CN111104161B (en) | Automatic approval execution method for database sql script | |
CN108512688A (en) | Network node configuration method and terminal |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20150429 |
|
RJ01 | Rejection of invention patent application after publication |