CN114546387A - Service arrangement script execution system and method - Google Patents

Service arrangement script execution system and method Download PDF

Info

Publication number
CN114546387A
CN114546387A CN202210188412.7A CN202210188412A CN114546387A CN 114546387 A CN114546387 A CN 114546387A CN 202210188412 A CN202210188412 A CN 202210188412A CN 114546387 A CN114546387 A CN 114546387A
Authority
CN
China
Prior art keywords
script
module
service
execution
scene
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
CN202210188412.7A
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.)
Chongqing Changan Automobile Co Ltd
Original Assignee
Chongqing Changan Automobile 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 Chongqing Changan Automobile Co Ltd filed Critical Chongqing Changan Automobile Co Ltd
Priority to CN202210188412.7A priority Critical patent/CN114546387A/en
Publication of CN114546387A publication Critical patent/CN114546387A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/38Creation or generation of source code for implementing user interfaces
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/4881Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/48Indexing scheme relating to G06F9/48
    • G06F2209/484Precedence
    • 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

Abstract

The invention discloses a service editing script execution system and method, the core service layer of the execution system includes: the device comprises a script management module, a scene recognition module, a script decision module and a script execution module. The execution method is that firstly, the service is arranged to generate a script, and the script is stored in the engine; monitoring events or states defined by the scripts in real time, judging and identifying which script is triggered, then deciding whether the script is executed, and executing the script according to service functions defined by the script after the decision script needs to be executed. The method of the invention arranges the service functions according to the pre-defined script, and realizes the new scene function quickly with low code. The service is arranged to generate a script, a zero-code self-defined vehicle-using scene is realized, the current hard-coded product development system mode is changed, and the new function research and development efficiency is greatly improved; and a new visible, tactile and experienceable user use mode is formed, and the user experience and the product flexibility are greatly improved.

Description

Service arrangement script execution system and method
Technical Field
The invention relates to the technical field of Internet of vehicles, in particular to a service arrangement script execution system and method.
Background
With the continuous development of the car networking technology, the car intelligentization degree is higher and higher, the car capability is more and more open, the car architecture is continuously adjusted under the theoretical support of a new generation of software car, and the SOA architecture is implemented on the whole car. Based on the service-oriented architecture, various capabilities of the vehicle can be provided in a service-oriented manner. In the prior art, in the technical field of service-oriented architecture of vehicle networking, a hard-coded product development system mode is mainly adopted, and developers need to develop again every time a function is added, and then the function is published on a vehicle in a group version mode; the development time of simple functions is long, the efficiency is not high, the functions of the vehicle can not be defined by the user, and the user-defined degree is not high.
CN107659439A discloses a "dynamic service orchestration method" including: defining a service node model template which comprises abstract input, output and processing process definitions; establishing a service node model, and supporting the service node model which can realize specific functions through interface operation or simple coding on the basis of the model template; creating a service model, wherein the service model consists of one or more service node models; service model instantiation, entering an instantiation stage when applying for using a defined service, and instantiating all node models in stages; for each defined service, instantiating a context that initially generates the corresponding service; and executing the service, namely executing the service nodes one by one in serial or parallel or in a serial and parallel mixture after the service instantiation begins. It provides how the service model and flow are orchestrated, but does not relate to how the specific orchestration is performed). For another example, CN110286884A discloses a "micro service arrangement method, apparatus, device and computer readable storage medium", which provides a method for displaying related information of a plurality of resource components and resource components provided on a front-end arrangement page through a micro service technology platform, so as to be used by a user when establishing a desired target process, the user can complete arrangement of the target process by performing a selective arrangement operation on the resource components displayed on the arrangement page, the micro service technology platform can determine a dependency relationship between the target component and the target component of the target process according to the selective arrangement operation of the user on the resource components displayed on the arrangement page according to the desired target process, and automatically generate a process file; and deploying the target assembly according to the flow file, initializing the flow, the assembly and the environment variable of the target flow, scheduling the target assembly, and completing the debugging of the target flow, so that the human resources and time of each user are saved, and the efficiency of arranging the micro-services is improved. This document discloses the orchestration of cloud services, and how orchestrated pages, resource components, etc. are related, as well as not relating to how the specific orchestration is performed. Therefore, how to develop an engine suitable for automobile arrangement execution and automobile service execution thereof is a technical problem to be solved by those skilled in the art.
Disclosure of Invention
Aiming at the defects in the prior art, the invention aims to provide a service arrangement script execution system and a service arrangement script execution method, and solves the problem that the service arrangement is not convenient and efficient in the prior art.
In order to achieve the purpose, the invention adopts the following technical scheme:
a service orchestration script execution system, comprising, for a core business layer: the system comprises a script management module, a scene recognition module, a script decision module and a script execution module; wherein:
the script management module: the system is responsible for local and cloud planning downloading scripts and provides newly added scripts;
a scene recognition module: obtaining the status of the vehicle hardware, ecology and systems to identify which rule scripts are triggered;
a script decision module: when the rule script is triggered, the module combines the script precondition and the cooling time to decide whether the interaction and the service call of the script are executed;
the script execution module: and performing conflict judgment on the executable script and executing the action contained in the script.
Furthermore, the addition of the script comprises the operations of updating, deleting, inquiring, local storage and the like.
The vehicle hardware comprises a vehicle machine, a TBOX (tunnel boring machine), other vehicle-mounted controllers and the like.
The ecological and system states include content states such as weather, calendar, news, and other systems that can perform scene recognition.
The precondition includes vehicle state, time state, geographic information, environmental information and other state information which can be used for judgment; and after the cooling time scene occurs, the cooling cannot be repeatedly executed for a long time.
The invention also provides a service editing script executing method, firstly editing the service to generate a script, and storing the script to the engine; monitoring events or states defined by the scripts in real time, judging and identifying which script is triggered, deciding whether the script is executed or not, and executing the script according to service functions defined by the script after the script is decided to be executed. By adopting the service arrangement script execution system, the core service layer script executes the following processes:
s1, loading the script by the script management module: the script management module loads a current script and sets a trigger condition and a script ID in the script to the scene identification module;
s2, the scene recognition module judges which script is used: the scene recognition module monitors the vehicle signal change required by the current script through the adaptation layer and carries out triggering judgment on scene conditions; when the condition that the script triggering condition is met is identified, informing the script management module of the corresponding script triggering according to the script ID, and issuing the corresponding script to the decision module by the script management module for decision judgment;
s3, the script decision module decides whether the script executes: the script decision module takes out the script with the highest priority from the decision queue, judges the precondition and the cooling time of the script, and determines whether the script can be executed or not according to the judgment result; sending the script meeting the execution condition to an execution queue; discarding the scripts which do not meet the operation conditions;
s4, the script execution module executes the script: the script execution module acquires the script with the highest priority from the execution queue to perform conflict judgment, and starts to execute the script after the judgment is successful; the adaptation layer provides support for the respective execution function.
Compared with the prior art, the invention has the following beneficial effects:
1. the method of the invention arranges the service functions according to the pre-defined script, and realizes the new scene function quickly with low code. The service is arranged to generate a script, a zero-code self-defined vehicle-using scene is realized, the current hard-coded product development system mode is changed, and the new function research and development efficiency is greatly improved; around the 'service is programmable and the user can define', a new visible, tactile and experienceable user use mode is formed, and the user experience and the product flexibility are greatly improved.
2. The invention is based on the vehicle intelligent control facing the service architecture, combines the service functions into a new scene for the user to use by arranging the service functions in a service mode, and simultaneously enables the user to self-define the functions of the vehicle, thereby obviously improving the user experience, simultaneously improving the function research and development efficiency of the vehicle factory and reducing the development workload.
Drawings
FIG. 1 is a general logical architecture diagram of the present invention (scene orchestration execution engine);
FIG. 2 is a flow chart of a scene list update of the present invention;
FIG. 3 is a flow chart of script identification of the present invention;
FIG. 4 is a flow chart of script decision of the present invention;
FIG. 5 is a flow chart of script execution according to the present invention.
Detailed Description
In order to make those skilled in the art better understand the technical solution of the present invention, the following detailed description of the present invention is made with reference to the accompanying drawings, but the embodiments of the present invention are not limited thereto.
Referring to fig. 1, the logical architecture of the (scenario orchestration execution engine) is divided into 4 logical layers from top to bottom, namely a configuration layer, a core business layer, a core layer, and a generic capability layer. The configuration layer provides personalized configuration for the engine, and the personalized configuration comprises related configuration items such as script running quantity configuration, script start-stop configuration, thread quantity configuration, personalized setting and the like. And the method supports each module to set and obtain the relevant configuration parameters, and meets the service requirement. The adaptation layer is a layer that is extracted to achieve decoupling of the core layer and system functions. With the adaptation layer, the core layer does not have to be concerned with the specific implementation of the scenario, interaction, and service. The system mainly aims at events, vehicle machine services, vehicle control services, ecological services and three-party services to be adapted, and the differences of different systems and different manufacturers are digested. And maintaining different types of services by adopting a factory mode for the core layer, and providing a standard interface for the core layer to use. And an adapter mode is adopted externally, an abstract interface is exposed, and the system or the three-party application registers and completes the interface realization. Therefore, the scene engine only needs to pay attention to the definition of the abstract interface and does not need to pay attention to the function realization.
The universal capability layer is used for uniformly packaging single universal capability in the engine, so that the code reusability is improved, and the maintenance or optimization of the universal function is facilitated. Each service module needs to rely on the universal capability library, and the capabilities and configuration items provided in the capability library are selectively used according to the actual service requirements of the module. json resolution library: adopting jsoncpp and nlohmann modes to analyze json and convert structures; js analysis: adopting a three-party open source library jerryscript and Duktape to carry out semantic analysis and execution on js; network request library: providing network request capability, and uniformly encapsulating network request protocols such as HTTPS, MQTT and the like; cross-process communication library: providing cross-process interaction capability comprising HIDL and AIDL; thread pool: and the thread safety, the thread quantity and the thread order are uniformly managed.
The system comprises a script management module, a scene recognition module, a script decision module and a script execution module, wherein the script execution system is innovative in a core service layer, namely a service arrangement script; each module has the following work division:
the script management module: the system is responsible for local and cloud planning downloading scripts and provides newly added scripts;
a scene recognition module: obtaining the status of the vehicle hardware, ecology and systems to identify which rule scripts are triggered;
a script decision module: when the rule script is triggered, the module combines the script precondition and the cooling time to decide whether the interaction and the service call of the script are executed;
the script execution module: and performing conflict judgment on the executable script and executing the action contained in the script.
Furthermore, the addition of the script comprises the operations of updating, deleting, inquiring, local storage and the like.
The vehicle hardware comprises a vehicle machine, a TBOX, a vehicle-mounted controller and the like.
The ecological and system states include content states such as weather, calendar, news, and other systems that can perform scene recognition.
The precondition includes vehicle state, time state, geographic information, environmental information and other state information which can be used for judgment; the cooling time is not repeatedly executable for a long time after a scene occurs.
The invention also provides a service arranging script executing method, which adopts the service arranging script executing system, and the core service layer script executes the following processes:
s1, loading the script by the script management module: the script management module loads a current script and sets a trigger condition and a script ID in the script to the scene identification module;
s2, the scene recognition module judges which script is used: the scene recognition module monitors the vehicle signal change required by the current script through the adaptation layer and carries out triggering judgment on scene conditions; when the condition that the script triggering condition is met is identified, informing the script management module of the corresponding script triggering according to the script ID, and issuing the corresponding script to the decision module by the script management module for decision judgment;
s3, the script decision module decides whether the script executes: the script decision module takes out the script with the highest priority from the decision queue, judges the precondition and the cooling time of the script and determines whether the script can be executed or not according to the judgment result; sending the script meeting the execution condition to an execution queue; discarding the scripts which do not meet the operation conditions;
s4, the script execution module executes the script: the script execution module acquires the script with the highest priority from the execution queue to perform conflict judgment, and starts to execute the script after the judgment is successful; the adaptation layer provides support for the respective execution function.
As shown in fig. 2, in the scene list updating process, for updating the scene list, the module first loads a local script for caching, then obtains the script from the cloud, and returns the script to the cloud; and then storing the script locally, updating the script in the local storage, and then analyzing and updating the block information in the script by the execution module.
As shown in fig. 3, the script identification process: the identification module acquires event information or vehicle state information from the communication middleware, manages and inquires whether a script ID meeting conditions exists according to events and scripts, inquires condition rule information according to the state information, inquires whether the script ID meeting corresponding states exists, and finally adds the script ID into a decision queue for decision.
As shown in fig. 4, the script decision flow: firstly, a scene to be decided is obtained according to a script ID, then a precondition of the scene is obtained, whether the precondition is satisfied is inquired through a communication middleware, an inquiry result of the precondition is obtained, if the precondition is satisfied, whether an execution time interval of the script satisfies a requirement is judged, if the execution time interval satisfies the requirement, whether the script content has a mutual exclusion condition is judged, if the mutual exclusion condition does not exist, the scene script is added into an execution queue to wait for execution.
As shown in fig. 5, the script execution flow: the method comprises the steps of firstly analyzing logic block information in a scene script, putting script blocks into an execution queue, then starting execution, simultaneously recording corresponding execution logs by a log module, executing a javaScript script by a js engine, returning an execution result, then executing corresponding remote service call, returning a result, and finally returning a block execution result.
The invention can be used for editing the service function according to the script defined in advance, and the new scene function can be quickly realized by low codes. Firstly, arranging the service to generate a script, storing the script in an engine, arranging the service to generate the script, realizing a zero-code self-defined vehicle-using scene, changing the current hard-coded product development system mode, and greatly improving the research and development efficiency of new functions; monitoring events or states defined by the scripts in real time, judging and identifying which script is triggered, then deciding whether the script is executed, and executing the script according to service functions defined by the script after the decision script needs to be executed. Around the 'service is programmable and the user can define', a new visible, tactile and experienceable user use mode is formed, and the user experience and the product flexibility are greatly improved. And meanwhile, the user can customize the function of the automobile, the user experience is obviously improved, the function research and development efficiency of the automobile factory is also improved, and the development workload is reduced.
Finally, it should be noted that the above embodiments are only used for illustrating the technical solutions of the present invention and not for limiting the technical solutions, and those skilled in the art should understand that modifications or equivalent substitutions can be made on the technical solutions of the present invention without departing from the spirit and scope of the technical solutions, and all that should be covered by the claims of the present invention.

Claims (7)

1. A service orchestration script execution system, comprising, for a core business layer: the system comprises a script management module, a scene recognition module, a script decision module and a script execution module; wherein:
the script management module: the system is responsible for local and cloud planning downloading scripts and provides newly added scripts;
a scene recognition module: obtaining the status of the vehicle hardware, ecology and systems to identify which rule scripts are triggered;
a script decision module: when the rule script is triggered, the module combines the script precondition and the cooling time to decide whether the interaction and the service call of the script are executed;
the script execution module: and performing conflict judgment on the executable script and executing the action contained in the script.
2. The service orchestration script execution system of claim 1, wherein additions to the script include update, delete, query, and local store operations.
3. The service orchestration script execution system according to claim 1, wherein the vehicle hardware comprises car machines, TBOX, and other on-board controllers.
4. The service orchestration script execution system of claim 1, wherein the ecological and system states include weather, calendar, news content states, and other scene recognition enabled systems.
5. The service orchestration script execution system according to claim 1, wherein the preconditions include vehicle status, time status, geographical information, status information for which environmental information is used for determination; and after the cooling time scene occurs, the cooling cannot be repeatedly executed for a long time.
6. A service editing script execution method is characterized in that firstly, a script is generated by editing a service and is stored in an engine; monitoring events or states defined by the scripts in real time, judging and identifying which script is triggered, deciding whether the script is executed or not, and executing the script according to service functions defined by the script after the script is decided to be executed.
7. The service orchestration script execution method according to claim 6, wherein, with the service orchestration script execution system according to any one of claims 1 to 5, the core business layer script executes the following process:
s1, loading the script by the script management module: the script management module loads a current script and sets a trigger condition and a script ID in the script to the scene identification module;
s2, the scene recognition module judges which script is used: the scene recognition module monitors the vehicle signal change required by the current script through the adaptation layer and carries out triggering judgment on scene conditions; when the condition that the script triggering condition is met is identified, informing the script management module of the corresponding script triggering according to the script ID, and issuing the corresponding script to the decision module by the script management module for decision judgment;
s3, the script decision module decides whether the script executes: the script decision module takes out the script with the highest priority from the decision queue, judges the precondition and the cooling time of the script, and determines whether the script can be executed or not according to the judgment result; sending the script meeting the execution condition to an execution queue; discarding the scripts which do not meet the operation conditions;
s4, the script execution module executes the script: the script execution module acquires a script with the highest priority from the execution queue to perform conflict judgment, and starts to execute the script after the judgment is successful; the adaptation layer provides support for the respective execution function.
CN202210188412.7A 2022-02-28 2022-02-28 Service arrangement script execution system and method Pending CN114546387A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210188412.7A CN114546387A (en) 2022-02-28 2022-02-28 Service arrangement script execution system and method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210188412.7A CN114546387A (en) 2022-02-28 2022-02-28 Service arrangement script execution system and method

Publications (1)

Publication Number Publication Date
CN114546387A true CN114546387A (en) 2022-05-27

Family

ID=81678619

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210188412.7A Pending CN114546387A (en) 2022-02-28 2022-02-28 Service arrangement script execution system and method

Country Status (1)

Country Link
CN (1) CN114546387A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115202641A (en) * 2022-09-13 2022-10-18 深圳联友科技有限公司 Method for mixed task arrangement engine without limit of development language

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115202641A (en) * 2022-09-13 2022-10-18 深圳联友科技有限公司 Method for mixed task arrangement engine without limit of development language
CN115202641B (en) * 2022-09-13 2023-02-03 深圳联友科技有限公司 Method for mixed task arrangement engine without limit of development language

Similar Documents

Publication Publication Date Title
CN108846630B (en) Resource control system and method
CN111147555B (en) Heterogeneous resource mixed arrangement method
CN112272234B (en) Platform management system and method for realizing edge cloud cooperation intelligent service
CN108572845B (en) Upgrading method of distributed micro-service cluster and related system
CN111400000B (en) Network request processing method, device, equipment and storage medium
CN110673853B (en) Compiling method, device and system
CN111258565B (en) Method, system, server and storage medium for generating applet
CN109445323B (en) WEB-based distributed intelligent measurement and control software platform design method
CN110704178A (en) Machine learning model training method, platform, electronic equipment and readable storage medium
CN113867600A (en) Development method and device for processing streaming data and computer equipment
CN114546387A (en) Service arrangement script execution system and method
WO2022228156A1 (en) Policy orchestration processing method, apparatus, device and system and storage medium
CN116775041B (en) Real-time decision engine implementation method based on stream calculation and RETE algorithm
CN115550354A (en) Data processing method and device and computer readable storage medium
CN112558968A (en) Resource tree view generation method, device, equipment and storage medium
CN116149628A (en) Car end service assembly method, architecture, device, equipment and medium
CN111274018A (en) Distributed training method based on DL framework
CN105677331A (en) Task execution method and device
CN115756494A (en) Business data processing method and device, electronic equipment and storage medium
CN114564249A (en) Recommendation scheduling engine, recommendation scheduling method, and computer-readable storage medium
CN112463289A (en) Method, system, equipment and medium for realizing application service based on virtual machine
CN113821560A (en) DAP platform-based big data processing method and system
CN112632113B (en) Operator management method and operator management system
CN112148854B (en) Dialogue management method and device
CN116149635A (en) SOA-based automobile function scene setting method, device, equipment and medium

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