CN117240928A - Dynamic publishing method and device for website service, medium and equipment - Google Patents

Dynamic publishing method and device for website service, medium and equipment Download PDF

Info

Publication number
CN117240928A
CN117240928A CN202311490597.8A CN202311490597A CN117240928A CN 117240928 A CN117240928 A CN 117240928A CN 202311490597 A CN202311490597 A CN 202311490597A CN 117240928 A CN117240928 A CN 117240928A
Authority
CN
China
Prior art keywords
service
website
services
instance
dynamic
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
CN202311490597.8A
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.)
Inspur General Software Co Ltd
Original Assignee
Inspur General Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Inspur General Software Co Ltd filed Critical Inspur General Software Co Ltd
Priority to CN202311490597.8A priority Critical patent/CN117240928A/en
Publication of CN117240928A publication Critical patent/CN117240928A/en
Pending legal-status Critical Current

Links

Landscapes

  • Information Transfer Between Computers (AREA)

Abstract

The invention relates to the technical field of computer application, in particular to a method and a device for dynamically publishing website service, a medium and equipment. The method comprises the following steps: unified registration management is carried out on various services; setting standard template codes of website services, loading the standard template codes into a memory by adopting a dynamic loading technology, creating an instance, binding the instance with the services appointed by a user according to front-end operation of the user to obtain a service instance corresponding to the services, and publishing the service instance as the website services; when a request is received, determining a website service corresponding to the request according to the URL address of the request, and routing the request to the website service. The embodiment of the invention is convenient and quick, does not need strong specialization of users, and can greatly improve development experience and development efficiency.

Description

Dynamic publishing method and device for website service, medium and equipment
Technical Field
The present invention relates to the field of computer applications, and in particular, to a method, an apparatus, a medium, and a device for dynamically publishing a website service.
Background
The website is a remote call technology crossing programming languages and operating system platforms, requests various services published on a network through a unified mode and a message format, and is a web technology which is platform-independent and language-independent. Generally, when we need to develop a web site service, at least three techniques for understanding the association of web sites are needed: (1) XML: extensible markup language is a basic format in the process of data transmission and representation by using websites; (2) WSDL: the Web service description language defines the structure and the calling method of the service, which is the service instruction provided by the website service end, and illustrates the interface, the method, the parameters and the return value of the service end, and WSDL is successfully issued along with the service, and is automatically generated without additional writing; (3) SOAP: the simple object access protocol, a protocol specification for exchanging data, is a lightweight, simple, XML-based protocol designed to exchange structured and consolidated information over the WEB, a SOAP message is a generic XML document containing elements.
Although the above technology is mature in the industry and is widely known, the technology has a threshold for the beginners of the industry, so that under the development trend of adopting a zero-code low-code mode in general, the traditional website service development mode not only needs professional developers, but also has great defects in the aspect of adaptability to complex business scenes, and the goals of rapid development test and flexible deployment delivery are difficult to achieve. In addition, in the prior art, when a certain developed website service has business requirement change, code adaptation can be rewritten and verification can be modified and verified in a complicated way, and when all tests are correct, a restarting application is required to be deployed. Even if the business needs to be fine-tuned only a little, the above steps cannot be reduced by one step, so this is unacceptable for customers whose business is frequently varied. In addition, when the service interface is abnormal, the problem is difficult to be examined due to factors such as the professional performance of maintenance personnel and the timeliness of client demands. Therefore, the traditional website service is constrained by the development and deployment framework, and is often driven to stretch the whole body, and flexible adjustment is difficult to achieve for complex business scenes, so that the development efficiency and the development experience have larger defects.
Disclosure of Invention
Aiming at least one technical problem, the embodiment of the invention provides a method, a device, a medium and equipment for dynamically publishing website services.
According to a first aspect, the method for dynamically publishing the website service provided by the embodiment of the invention comprises the following steps:
unified registration management is carried out on various services;
setting standard template codes of website services, loading the standard template codes into a memory by adopting a dynamic loading technology, creating an instance, binding the instance with the services appointed by a user according to front-end operation of the user to obtain a service instance corresponding to the services, and publishing the service instance as the website services;
when a request is received, determining a website service corresponding to the request according to the URL address of the request, and routing the request to the website service.
According to a second aspect, the website service dynamic publishing device provided by the embodiment of the invention comprises:
the service registration module is used for carrying out unified registration management on a plurality of services;
the dynamic publishing module is used for setting standard template codes of website services, loading the standard template codes into a memory by adopting a dynamic loading technology, creating an instance, binding the instance with the services designated by the user according to front-end operation of the user to obtain a service instance corresponding to the services, and publishing the service instance as the website services;
and the dynamic routing module is used for determining the website service corresponding to the request according to the URL address of the request when the request is received, and routing the request to the website service.
According to a third aspect, embodiments of the present invention provide a computer-readable storage medium having stored thereon a computer program which, when executed in a computer, causes the computer to perform the method provided by the first aspect.
According to a fourth aspect, a computing device provided by an embodiment of the present invention includes a memory and a processor, where the memory stores executable code, and the processor implements the method provided by the first aspect when executing the executable code.
The website service dynamic release method, the device, the medium and the equipment provided by the embodiment of the invention firstly perform unified registration management on various services, then realize the dynamic release of the website service according to the operation of a user at the front end, and further perform routing according to the URL address when receiving the request. In the process, the logic code of the service is not required to be modified, so that the service is convenient and quick, the user is not required to have strong specialty, and the development experience and the development efficiency can be greatly improved. The user can quickly generate the required website service according to the scene requirement, and can flexibly adjust, for example, the participation and participation parameter form, the URL, the service authentication mode and the like, so that the flexibility of developing the website service scene by using zero codes is improved, and the development flow is simplified.
Drawings
FIG. 1 is a flowchart of a method for dynamically publishing web services according to an embodiment of the present invention;
fig. 2 is a schematic diagram of a registration manner of an interface according to an embodiment of the invention.
Detailed Description
In a first aspect, an embodiment of the present invention provides a method for dynamically publishing a website service, referring to fig. 1, the method includes steps S110 to S130:
s110, unified registration management is carried out on various services;
it can be appreciated that in the embodiment of the invention, unified registration and management are performed on various services so as to achieve the aim of encompassing numerous scenes and performing zero code release. The development of the service can be realized by a traditional hard coding mode or a simple configuration mode.
In one embodiment, the unified registration management for multiple services may include: registering the service in at least one of:
packaging and managing the existing remote procedure call protocol service;
registering existing classes and methods as services;
registering the metadata model under the low code frame as a service;
registering the read data from the database table as a service;
accessing and registering the service of the external system as the service of the current system;
the plurality of services are orchestrated and assembled into a new service.
For example, referring to fig. 2, various registration approaches are illustrated.
The bottleneck of a service manufacturing factory is opened through a polymorphic service registration mechanism, and a set of efficient and flexible service generation solutions is formed.
S120, setting standard template codes of website services, loading the standard template codes into a memory by adopting a dynamic loading technology, creating an instance, binding the instance with the services designated by the user according to front-end operation of the user to obtain service instances corresponding to the services, and publishing the service instances as the website services;
the registered service is actually released as a web interface which can be called by the outside through the S120.
Wherein, the standard template code of the website service only provides the technical framework of the website and does not contain any business information.
In one embodiment, the front-end operation of the root user to bind the instance with the user-specified service may include:
and providing a dynamic release page for the user to select the service bound with the instance in the dynamic release page and designating the corresponding URL address.
Specifically, the dynamic release page is provided with a service selection item, the user selects the service bound with the instance through the service selection item, and the dynamic release page is provided with a URL address filling item so as to further specify the URL address. And the dynamic release page is provided with a binding button, and after the user triggers the binding button, the binding of the instance and the service appointed by the user is realized, so that the service instance is obtained.
Further, the front-end operation of the root user binds the instance with the service specified by the user, and may further include: specifying a service joining-out parameter form and/or a service authentication mode in the binding process; the appointed input-output parameter form is mapped with the original input-output parameter form of the service, so that conversion of the input-output parameter form can be realized when the service is called.
That is, the dynamic release page is also provided with a entry and exit parameter form filling item and/or a service authentication mode filling item, so that a user can conveniently specify the entry and exit parameter form and/or the service authentication mode.
Because each service logic code has own input-output parameter form, the user can set the wanted input-output parameter form according to the own requirement, and after the setting is completed, the mapping relation, namely the conversion relation, between the appointed input-output parameter form and the original input-output parameter form of the service is established. And then the conversion of the two input-output ginseng forms is realized according to the conversion relation.
In one embodiment, the publishing the business instance as a web service may include: and responding to the trigger of the release button in the dynamic release page, releasing the service instance as a website service, wherein the website service becomes a website interface which can be called by the outside.
That is, there is a publish button in the dynamic publish page, and when the user triggers the publish button, the business instance will be published as a website service, which becomes a website interface that can be invoked. Based on the dynamic release mechanism, the dynamic start and stop of the service can be realized, so that the effect of changing along with the change of the service demand, namely, changing along with the use is realized.
In one embodiment, the method provided by the embodiment of the invention can further include:
and after the website service is released, generating a WSDL interface description document of the website service.
The above-mentioned publishing mode is a dynamic publishing mode, namely: if the user wants to modify the URL, the parameter entering and exiting form and the service authentication mode, the user can directly modify the URL, the parameter entering and exiting form and the service authentication mode in the dynamic release page, and release is performed again after modification is completed, so that a new website service is obtained. The logic code of the service does not need to be modified, so that the release mode is convenient and quick, and strong specialization of users is not needed.
And S130, when a request is received, determining a website service corresponding to the request according to the URL address of the request, and routing the request to the website service.
It is appreciated that route hopping is based on the URL of the service binding. Because the services are published based on the same standard template code, the business execution logic of each service does not have real code isolation, so when the system accesses different requested services, the system needs to filter and judge which service is finally routed to according to the URL of the request, and execute corresponding business logic.
Therefore, in the embodiment of the invention, a plurality of services are registered based on a unified registration management mechanism, dynamic release is realized based on a standard template code, and service operation is realized based on dynamic routing. Through the three steps, the development process is simplified, and the development experience and development efficiency are improved. Compared with the existing singleness of website service development, compiling and deployment, the embodiment of the invention provides a software design scheme for defining website services by using zero codes and performing dynamic service release. The design scheme can quickly generate the required website service according to the scene, and meanwhile, the input and output parameter forms of the service interface can be flexibly adjusted, so that the interface design and the interface release are integrated and defined, the flexibility of developing the website service scene by using zero codes is improved, the development flow is simplified, and the development efficiency is improved.
In a second aspect, an embodiment of the present invention provides a dynamic website service publishing device.
The device comprises:
the service registration module is used for carrying out unified registration management on a plurality of services;
the dynamic publishing module is used for setting standard template codes of website services, loading the standard template codes into a memory by adopting a dynamic loading technology, creating an instance, binding the instance with the services designated by the user according to front-end operation of the user to obtain a service instance corresponding to the services, and publishing the service instance as the website services;
and the dynamic routing module is used for determining the website service corresponding to the request according to the URL address of the request when the request is received, and routing the request to the website service.
In one embodiment, the dynamic publishing module may be specifically configured to: and providing a dynamic release page for the user to select the service bound with the instance in the dynamic release page and designating the corresponding URL address.
In one embodiment, the service registration module may be specifically configured to: registering the service in at least one of: packaging and managing the existing remote procedure call protocol service; registering existing classes and methods as services; registering the metadata model under the low code frame as a service; registering the read data from the database table as a service; accessing and registering the service of the external system as the service of the current system; the plurality of services are orchestrated and assembled into a new service.
In one embodiment, the front-end operation of the root user in the dynamic publishing module to bind the instance with the user-specified service may include: and providing a dynamic release page for the user to select the service bound with the instance in the dynamic release page and designating the corresponding URL address.
In one embodiment, the binding the instance with the user-specified service by the front-end operation of the root user in the dynamic publishing module may further include: specifying a service joining-out parameter form and/or a service authentication mode in the binding process; the appointed input-output parameter form is mapped with the original input-output parameter form of the service, so that conversion of the input-output parameter form can be realized when the service is called.
In one embodiment, the publishing the business instance as a web service in the dynamic publishing module may include: and responding to the trigger of the release button in the dynamic release page, releasing the service instance as a website service, wherein the website service becomes a website interface which can be called by the outside.
In one embodiment, the apparatus may further include:
and the document generation module is used for generating a WSDL interface description document of the website service after the website service is released.
It may be understood that, for explanation, specific implementation, beneficial effects, examples, etc. of the content in the apparatus provided by the embodiment of the present invention, reference may be made to corresponding parts in the method provided in the first aspect, which are not repeated herein.
In a third aspect, embodiments of the present invention provide a computer readable medium having stored thereon computer instructions which, when executed by a processor, cause the processor to perform the method provided in the first aspect.
Specifically, a system or apparatus provided with a storage medium on which a software program code realizing the functions of any of the above embodiments is stored, and a computer (or CPU or MPU) of the system or apparatus may be caused to read out and execute the program code stored in the storage medium.
In this case, the program code itself read from the storage medium may realize the functions of any of the above-described embodiments, and thus the program code and the storage medium storing the program code form part of the present invention.
Examples of the storage medium for providing the program code include a floppy disk, a hard disk, a magneto-optical disk, an optical disk (e.g., CD-ROM, CD-R, CD-RW, DVD-ROM, DVD-RAM, DVD-RW, DVD+RW), a magnetic tape, a nonvolatile memory card, and a ROM. Alternatively, the program code may be downloaded from a server computer by a communication network.
Further, it should be apparent that the functions of any of the above-described embodiments may be implemented not only by executing the program code read out by the computer, but also by causing an operating system or the like operating on the computer to perform part or all of the actual operations based on the instructions of the program code.
Further, it is understood that the program code read out by the storage medium is written into a memory provided in an expansion board inserted into a computer or into a memory provided in an expansion module connected to the computer, and then a CPU or the like mounted on the expansion board or the expansion module is caused to perform part and all of actual operations based on instructions of the program code, thereby realizing the functions of any of the above embodiments.
It may be appreciated that, for explanation, specific implementation, beneficial effects, examples, etc. of the content in the computer readable medium provided by the embodiment of the present invention, reference may be made to corresponding parts in the method provided in the first aspect, and details are not repeated herein.
In a fourth aspect, one embodiment of the present specification provides a computing device comprising a memory having executable code stored therein and a processor that, when executing the executable code, performs the method of any one of the embodiments of the specification.
It may be appreciated that, for explanation, specific implementation, beneficial effects, examples, etc. of the content in the computing device provided by the embodiment of the present invention, reference may be made to corresponding parts in the method provided in the first aspect, which are not repeated herein.
In this specification, each embodiment is described in a progressive manner, and identical and similar parts of each embodiment are all referred to each other, and each embodiment mainly describes differences from other embodiments. In particular, for the device embodiments, since they are substantially similar to the method embodiments, the description is relatively simple, and reference is made to the description of the method embodiments in part.
Those skilled in the art will appreciate that in one or more of the examples described above, the functions described in the present invention may be implemented in hardware, software, a pendant, or any combination thereof. When implemented in software, these functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium.
The foregoing embodiments have been provided for the purpose of illustrating the general principles of the present invention in further detail, and are not to be construed as limiting the scope of the invention, but are merely intended to cover any modifications, equivalents, improvements, etc. based on the teachings of the invention.

Claims (10)

1. A method for dynamically publishing a web service, comprising:
unified registration management is carried out on various services;
setting standard template codes of website services, loading the standard template codes into a memory by adopting a dynamic loading technology, creating an instance, binding the instance with the services appointed by a user according to front-end operation of the user to obtain a service instance corresponding to the services, and publishing the service instance as the website services;
when a request is received, determining a website service corresponding to the request according to the URL address of the request, and routing the request to the website service.
2. The method of claim 1, wherein the unified registration management for multiple services comprises: registering the service in at least one of:
packaging and managing the existing remote procedure call protocol service;
registering existing classes and methods as services;
registering the metadata model under the low code frame as a service;
registering the read data from the database table as a service;
accessing and registering the service of the external system as the service of the current system;
the plurality of services are orchestrated and assembled into a new service.
3. The method of claim 1, wherein the front-end operation of the root user binds the instance with a user-specified service, comprising:
and providing a dynamic release page for the user to select the service bound with the instance in the dynamic release page and designating the corresponding URL address.
4. The method of claim 3, wherein the front-end operation of the root user binds the instance with a user-specified service, further comprising:
specifying a service joining-out parameter form and/or a service authentication mode in the binding process;
the appointed input-output parameter form is mapped with the original input-output parameter form of the service, so that conversion of the input-output parameter form can be realized when the service is called.
5. The method of claim 3, wherein publishing the business instance as a web site service comprises:
and responding to the trigger of the release button in the dynamic release page, releasing the service instance as a website service, wherein the website service becomes a website interface which can be called by the outside.
6. The method as recited in claim 1, further comprising:
and after the website service is released, generating a WSDL interface description document of the website service.
7. A web service dynamic publishing device, comprising:
the service registration module is used for carrying out unified registration management on a plurality of services;
the dynamic publishing module is used for setting standard template codes of website services, loading the standard template codes into a memory by adopting a dynamic loading technology, creating an instance, binding the instance with the services designated by the user according to front-end operation of the user to obtain a service instance corresponding to the services, and publishing the service instance as the website services;
and the dynamic routing module is used for determining the website service corresponding to the request according to the URL address of the request when the request is received, and routing the request to the website service.
8. The apparatus of claim 7, wherein the dynamic publishing module is specifically configured to: and providing a dynamic release page for the user to select the service bound with the instance in the dynamic release page and designating the corresponding URL address.
9. A computer readable storage medium, having stored thereon a computer program which, when executed in a computer, causes the computer to perform the method of any of claims 1 to 6.
10. A computing device comprising a memory and a processor, the memory having executable code stored therein, the processor, when executing the executable code, implementing the method of any of claims 1-6.
CN202311490597.8A 2023-11-10 2023-11-10 Dynamic publishing method and device for website service, medium and equipment Pending CN117240928A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311490597.8A CN117240928A (en) 2023-11-10 2023-11-10 Dynamic publishing method and device for website service, medium and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311490597.8A CN117240928A (en) 2023-11-10 2023-11-10 Dynamic publishing method and device for website service, medium and equipment

Publications (1)

Publication Number Publication Date
CN117240928A true CN117240928A (en) 2023-12-15

Family

ID=89098526

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311490597.8A Pending CN117240928A (en) 2023-11-10 2023-11-10 Dynamic publishing method and device for website service, medium and equipment

Country Status (1)

Country Link
CN (1) CN117240928A (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140289699A1 (en) * 2009-08-18 2014-09-25 Adobe Systems Incorporated Methods and Systems for Data Service Development
CN112685030A (en) * 2020-12-31 2021-04-20 北京三快在线科技有限公司 Method, device, storage medium and electronic equipment for generating service code
CN114625353A (en) * 2020-12-14 2022-06-14 电科云(北京)科技有限公司 Model framework code generation system and method
CN115878092A (en) * 2022-12-09 2023-03-31 山东浪潮质量链科技有限公司 Code generation method, device and medium based on micro-service architecture

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140289699A1 (en) * 2009-08-18 2014-09-25 Adobe Systems Incorporated Methods and Systems for Data Service Development
CN114625353A (en) * 2020-12-14 2022-06-14 电科云(北京)科技有限公司 Model framework code generation system and method
CN112685030A (en) * 2020-12-31 2021-04-20 北京三快在线科技有限公司 Method, device, storage medium and electronic equipment for generating service code
CN115878092A (en) * 2022-12-09 2023-03-31 山东浪潮质量链科技有限公司 Code generation method, device and medium based on micro-service architecture

Similar Documents

Publication Publication Date Title
JP6629848B2 (en) Page processing for mobile applications
US7529833B2 (en) Method, system, and web service broker for dynamic web service invocation
US7287037B2 (en) Method and apparatus for generating service oriented state data mapping between extensible meta-data model and state data including logical abstraction
US7693973B2 (en) Pluggable state meta-data processors based on meta information modeling in a service oriented architecture
KR100453824B1 (en) XML based network management system and method for configuration management of heterogeneous network devices
US8448216B2 (en) Method and apparatus for orchestrating policies in service model of service-oriented architecture system
US20090158238A1 (en) Method and apparatus for providing api service and making api mash-up, and computer readable recording medium thereof
CN110244941B (en) Task development method and device, electronic equipment and computer readable storage medium
CN104156313A (en) Method for automatically generating Web service testing case
CN106997298A (en) A kind of application resource acquisition methods and device
US20210334149A1 (en) Api adapter creation device, api adapter creation method, and api adapter creation program
CN111930290B (en) Resource deployment method and device
Rosenberg et al. Integrating quality of service aspects in top-down business process development using WS-CDL and WS-BPEL
US9164734B2 (en) Ontology-based user requirement decomposition for component selection for service provision
CN106453250B (en) A kind of processing method of big data RPC
CN107239265B (en) Binding method and device of Java function and C function
CN117240928A (en) Dynamic publishing method and device for website service, medium and equipment
CN109218297A (en) A kind of method and device of request data
CN113791766A (en) Method for combining data interfaces, electronic device and readable storage medium
CN113791819A (en) Interface document generation method and device, storage medium and electronic equipment
CN112597036B (en) Universal baffle plate testing method and device
CN116088855B (en) Development method, development device, electronic device, and storage medium
KR101249449B1 (en) Apparatus for web platform verification tool and control method thereof
CN115293122A (en) H5 data templating method, device and equipment and storage medium
CN113791775B (en) Metadata flow arranging method and device, storage medium and electronic equipment

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