CN111930690B - File generation method and device - Google Patents

File generation method and device Download PDF

Info

Publication number
CN111930690B
CN111930690B CN202010811637.4A CN202010811637A CN111930690B CN 111930690 B CN111930690 B CN 111930690B CN 202010811637 A CN202010811637 A CN 202010811637A CN 111930690 B CN111930690 B CN 111930690B
Authority
CN
China
Prior art keywords
file
file generation
generating
generation
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010811637.4A
Other languages
Chinese (zh)
Other versions
CN111930690A (en
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.)
Industrial and Commercial Bank of China Ltd ICBC
Original Assignee
Industrial and Commercial Bank of China Ltd ICBC
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 Industrial and Commercial Bank of China Ltd ICBC filed Critical Industrial and Commercial Bank of China Ltd ICBC
Priority to CN202010811637.4A priority Critical patent/CN111930690B/en
Publication of CN111930690A publication Critical patent/CN111930690A/en
Application granted granted Critical
Publication of CN111930690B publication Critical patent/CN111930690B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/16File or folder operations, e.g. details of user interfaces specifically adapted to file systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/25Integrating or interfacing systems involving database management systems
    • G06F16/252Integrating or interfacing systems involving database management systems between a Database Management System and a front-end application
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/28Databases characterised by their database models, e.g. relational or object models
    • G06F16/284Relational databases
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/12Use of codes for handling textual entities
    • G06F40/126Character encoding
    • 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/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44505Configuring for program initiating, e.g. using registry, configuration files
    • G06F9/4451User profiles; Roaming
    • 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/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5061Partitioning or combining of resources
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/50Indexing scheme relating to G06F9/50
    • G06F2209/5011Pool
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/50Indexing scheme relating to G06F9/50
    • G06F2209/5018Thread allocation
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Human Computer Interaction (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application provides a file generation method and device, which can be used in the financial field and other fields. The method comprises the following steps: determining file generation strategies of a plurality of file generation tasks according to the file generation strategy configuration information; determining a file generation mode corresponding to each file generation task based on the file generation mode configuration information; determining a file generation rule corresponding to each file generation task based on the file generation rule configuration information; and generating a target file based on the file generation strategy, the file generation mode and the file generation rule, and distributing the target file to a target application system. The method and the device can improve the efficiency and the flexibility of large-batch file generation, and further can improve the efficiency of file interaction between applications.

Description

File generation method and device
Technical Field
The present application relates to the field of data processing technologies, and in particular, to the financial field and other fields, and in particular, to a method and an apparatus for generating a file.
Background
As the number of monomer applications increases, the applications are more and more closely related. Each application focuses on the implementation of the main body function of the application, focuses on the implementation of the related field functions and other comprehensive functions, and provides omnibearing service for clients. This highlights the importance of data association between applications and also tends to result in more frequent data interaction between applications. The online interface can acquire related data of the related field in real time, but a large amount of online interaction causes excessive pressure of a server, and meanwhile, the online interaction effect is not ideal due to factors such as limited network resources, so that a batch file mode is important as an important supplement of online interaction. Meanwhile, under the scene of low data interaction instantaneity requirement, the batch file mode can realize the interaction of large data volume among applications.
When a single application needs to generate a plurality of data files for other applications, traditional development and design for file generation are lower and lower, and particularly under the condition that more applications have more and more vigorous interaction demands on the data files, the traditional mode cannot well solve the problem, and file interaction demands can be possibly dispersed in various functions of a system under the scenes of different manpower quality and complex file dependence, so that the generation time, mode and dependence of interaction files cannot be managed finally until the subsequent maintenance cannot be performed.
While the distributed batch framework may enable file generation, it is of more concern for batch scheduling and distribution characteristics, with higher time costs.
Disclosure of Invention
Aiming at the problems in the prior art, the application provides a file generation method and device, which can improve the efficiency and flexibility of large-batch file generation, and further can improve the efficiency of file interaction between applications.
In order to solve the technical problems, the application provides the following technical scheme:
in a first aspect, the present application provides a file generating method, including:
determining file generation strategies of a plurality of file generation tasks according to the file generation strategy configuration information;
determining a file generation mode corresponding to each file generation task based on the file generation mode configuration information;
determining a file generation rule corresponding to each file generation task based on the file generation rule configuration information;
and generating a target file based on the file generation strategy, the file generation mode and the file generation rule, and distributing the target file to a target application system.
Further, the file generating method further comprises the following steps: configuring the file generation policy configuration information, wherein the file generation policy configuration information comprises: the file generation frequency corresponding to each file generation task and the dependency relationship among the file generation tasks; configuring the file generation mode configuration information, wherein the file generation mode configuration information comprises the following components: generating tools, program paths, generating catalogues, encoding formats and file formats which correspond to the file generating tasks respectively; configuring the file generation rule configuration information, wherein the file generation rule configuration information comprises: and the file generating tasks respectively correspond to file names, file transmission types and transmission interfaces.
Further, after the concurrently executing each target file generating task, the method further includes: and generating a plurality of target files based on the file generation strategy, the file generation mode and the file generation rule, and distributing the target files to a target application system.
Further, the generating the target file based on the file generating policy, the file generating mode and the file generating rule and distributing the target file to the target application system further includes: and monitoring the process of generating the target file and distributing the target file to the target application system in real time.
In a second aspect, the present application provides a document generating apparatus, including:
the determining policy module is used for determining file generating policies of a plurality of file generating tasks according to the file generating policy configuration information;
the file generation method comprises a generation mode determining module, a file generation mode determining module and a file generation mode determining module, wherein the generation mode determining module is used for determining the file generation mode corresponding to each file generation task based on file generation mode configuration information;
the determining and generating rule module is used for determining the file generating rule corresponding to each file generating task based on the file generating rule configuration information;
and the execution module is used for generating a target file based on the file generation strategy, the file generation mode and the file generation rule and distributing the target file to a target application system.
Further, the file generating apparatus further includes: the configuration policy module is configured to configure the file generation policy configuration information, where the file generation policy configuration information includes: the file generation frequency corresponding to each file generation task and the dependency relationship among the file generation tasks; the configuration generating mode module is configured to configure the file generating mode configuration information, where the file generating mode configuration information includes: generating tools, program paths, generating catalogues, encoding formats and file formats which correspond to the file generating tasks respectively; the configuration rule module is configured to configure the file generation rule configuration information, where the file generation rule configuration information includes: and the file generating tasks respectively correspond to file names, file transmission types and transmission interfaces.
Further, the execution module further includes: and the execution unit is used for generating a plurality of target files based on the file generation strategy, the file generation mode and the file generation rule and distributing the target files to the target application system.
Further, the execution module further includes: and the monitoring unit is used for monitoring the process of generating the target file and distributing the target file to the target application system in real time.
In a third aspect, the present application provides an electronic device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, the processor implementing the file generation method when executing the program.
In a fourth aspect, the present application provides a computer-readable storage medium having stored thereon computer instructions that, when executed, implement the file generation method.
According to the technical scheme, the application provides a file generation method and device. Wherein the method comprises the following steps: determining file generation strategies of a plurality of file generation tasks according to the file generation strategy configuration information; determining a file generation mode corresponding to each file generation task based on the file generation mode configuration information; determining a file generation rule corresponding to each file generation task based on the file generation rule configuration information; based on the file generation strategy, the file generation mode and the file generation rule, generating a target file and distributing the target file to a target application system, so that the efficiency and the flexibility of generating a large amount of files can be improved, and the efficiency of file interaction between applications can be improved; specifically, a plurality of types of database systems are supported, a plurality of file generation modes can be adapted, a plurality of file generation strategies are supported, a plurality of file generation rules are met, a file generation process can be flexibly configured, the universality is strong, the efficiency is improved, and the later maintenance and expansion are easy. In addition, the occupied memory resources are few, and the deployment is flexible.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present application, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow diagram of a file generation method in an embodiment of the present application;
FIG. 2 is a flow chart of steps 201 to 203 of the file generation method in the embodiment of the present application;
FIG. 3 is a flowchart of a file generating method including step 301 according to an embodiment of the present application;
FIG. 4 is a schematic view of the structure of a file generating apparatus according to an embodiment of the present application;
FIG. 5 is a logical schematic of a file generation system in an example application of the present application;
FIG. 6 is a logic diagram of a user decision definition device in an example application of the present application;
FIG. 7 is a schematic structural diagram of a rule parsing device in an application example of the present application;
FIG. 8 is a schematic structural diagram of a policy resolution device in an application example of the present application;
FIG. 9 is a schematic structural diagram of a generating mode analyzing device in an application example of the present application;
FIG. 10 is a flow chart of a file generation method in an application example of the present application;
fig. 11 is a schematic block diagram of a system configuration of an electronic device according to an embodiment of the present application.
Detailed Description
In order to better understand the technical solutions in the present specification, the following description will clearly and completely describe the technical solutions in the embodiments of the present application with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only some embodiments of the present application, but not all embodiments. All other embodiments, which can be made by one of ordinary skill in the art without undue burden from the present disclosure, are within the scope of the present disclosure.
In order to solve the problems of frequent file interaction between applications, low efficiency, poor maintainability and the like caused by the adoption of the traditional design and development aiming at file generation, the invention provides a file generation method and device, which support the derivation of a large number of data files from a plurality of types of database systems, adapt to a plurality of file generation modes, support a plurality of file generation strategies, meet a plurality of file generation rules, convert the traditional design and development thought aiming at file content into the design and development aiming at file generation configuration, have strong universality, can be flexibly configured, improve the efficiency and facilitate the subsequent maintenance and expansion. It should be noted that the method and apparatus for generating the present application document may be used in the financial field, and may also be used in any field other than the financial field, and the application field of the method and apparatus for generating the present application document is not limited.
The following examples are presented in detail.
In order to improve the efficiency and flexibility of mass file generation and further improve the efficiency of file interaction between applications, the embodiment provides a file generation method in which an execution subject is a file generation device, and the file generation device includes, but is not limited to, a server, as shown in fig. 1, and the method specifically includes the following contents:
step 101: and determining file generation strategies of a plurality of file generation tasks according to the file generation strategy configuration information.
Step 102: and determining the file generation mode corresponding to each file generation task based on the file generation mode configuration information.
Step 103: and determining the file generation rule corresponding to each file generation task based on the file generation rule configuration information.
Step 104: and generating a target file based on the file generation strategy, the file generation mode and the file generation rule, and distributing the target file to a target application system.
Specifically, one or more target files may be generated; the target application system may be a monolithic application; the method can apply task thread pools and concurrently execute file generation, greatly improve the execution efficiency, and also can track and record the state of each task in the whole course so as to ensure the reliability of file generation; the paging inquiry of big data can be used, so that the hundred million data can be completely written into the file; and using multiple database adaptation to support the data query and writing of mainstream databases such as Oracle, mySql and the like.
In order to further improve flexibility and configurability of file generation, in an embodiment of the present application, referring to fig. 2, the file generation method further includes:
step 201: configuring the file generation policy configuration information, wherein the file generation policy configuration information comprises: and the file generation frequency corresponding to each file generation task and the dependency relationship among the file generation tasks are respectively carried out.
In particular, the file generation frequency may be one of monthly, daily, and real-time; through the dependency relationship among the file generation tasks, the file export strategy under the special scene can be satisfied.
Step 202: configuring the file generation mode configuration information, wherein the file generation mode configuration information comprises the following components: generating tools, program paths, generating catalogs, encoding formats and file formats of the file generating tasks.
Specifically, the file generating tool may be a jar package, a shell program, a bin program, other exe, and the like with a file generating function, and can support command generation files. The coding formats can be UTF-8, UTF-16, GB2312, GBK18030, ANSI and the like. The file format can be XML, custom fixed-length file, custom separator file and other file formats. The file generation mode configuration information may further include database system information.
Step 203: configuring the file generation rule configuration information, wherein the file generation rule configuration information comprises: and the file generating tasks respectively correspond to file names, file transmission types and transmission interfaces.
To achieve interaction of large volumes of files between monolithic applications, the interaction process is efficient and reliable, and in one embodiment of the present application, referring to fig. 3, step 104 includes:
step 301: and generating a plurality of target files based on the file generation strategy, the file generation mode and the file generation rule, and distributing the target files to a target application system.
In order to improve the reliability of the generated file, in an embodiment of the present application, step 104 further includes:
and monitoring the process of generating the target file and distributing the target file to the target application system in real time.
Specifically, the execution state of each target file generation task may be recorded, and if an abnormality occurs in the execution state, alarm information corresponding to the abnormality is output.
In order to improve efficiency and flexibility of generating a large amount of files and further improve efficiency of file interaction between applications from a software aspect, the present application provides an embodiment of a file generating device for implementing all or part of content in the file generating method, see fig. 4, where the file generating device specifically includes:
a determining policy module 10, configured to determine a file generating policy of the plurality of file generating tasks according to the file generating policy configuration information;
the determining and generating mode module 20 is configured to determine, based on the file generating mode configuration information, a file generating mode corresponding to each of the file generating tasks;
a determining rule module 30, configured to determine a file generating rule corresponding to each of the file generating tasks based on the file generating rule configuration information;
and the execution module 40 is used for generating and distributing the target file to the target application system based on the file generation strategy, the file generation mode and the file generation rule.
In one embodiment of the present application, the file generating apparatus further includes:
the configuration policy module is configured to configure the file generation policy configuration information, where the file generation policy configuration information includes: the file generation frequency corresponding to each file generation task and the dependency relationship among the file generation tasks;
the configuration generating mode module is configured to configure the file generating mode configuration information, where the file generating mode configuration information includes: generating tools, program paths, generating catalogues, encoding formats and file formats which correspond to the file generating tasks respectively;
the configuration rule module is configured to configure the file generation rule configuration information, where the file generation rule configuration information includes: and the file generating tasks respectively correspond to file names, file transmission types and transmission interfaces.
In one embodiment of the present application, the execution module includes:
and the execution unit is used for generating a plurality of target files based on the file generation strategy, the file generation mode and the file generation rule and distributing the target files to the target application system.
In one embodiment of the present application, the execution module further includes:
and the monitoring unit is used for monitoring the process of generating the target file and distributing the target file to the target application system in real time.
The embodiments of the document generating apparatus provided in the present specification may be specifically used to execute the processing flow of the embodiments of the document generating method, and the functions thereof are not described herein, and reference may be made to the detailed description of the embodiments of the document generating method.
To further illustrate the present solution, the present application further provides an application example of a file generating system, referring to fig. 5, in the present application example, the system includes: a user decision definition device 1, a rule analysis device 2, a policy analysis device 3, a generation mode analysis device 4, and a generation execution device 5. The user decision definition device 1 is connected with the rule analysis device 2, the strategy analysis device 3 and the generation mode analysis device 4; the rule analysis device 2, the policy analysis device 3, and the generation system analysis device 4 are connected to the generation execution device 5. The specific description is as follows:
user decision definition means 1: the method is used for configuring file generation rules, generation strategies and generation modes. The configuration information can be supported by the system and can be realized in a self-defined way. The relevant configuration information is saved in a system configuration table.
Rule analysis device 2: the configured file generation rule is read from the user decision definition device 1, mainly including information such as file name, file transmission type, transmission interface, file session, and the like, and the rule analysis device 2 is instantiated.
Policy analysis device 3: the configured file generation policy is read from the user decision definition device 1, and mainly includes information such as file generation frequency (frequency configuration at any time of any month and any day may be selected), file generation dependency (file dependency relationship may be selected, and file export policy under special circumstances may be satisfied), and the policy analysis device 3 is instantiated.
The generation scheme analysis device 4: the file generation method for reading the configuration from the user decision definition device 1 mainly includes information such as a generation tool, a program path, a generation directory, an encoding format, and a file format. Because the generating tool is configurable, integration of multiple generating modes can be realized; the file coding format is configurable, and can easily support a plurality of common coding formats such as UTF-8, UTF-16, GB2312, GBK18030, ANSI and the like; the file format is configurable, and can support various formats such as common XML, custom fixed-length files, custom separator files and the like.
The generation execution device 5: the generation execution device 5 determines the file generation type according to the rule, determines whether the current condition is met or not according to the strategy, triggers the file generation task or not, and writes the data into the file according to the generation mode. The device uses the task thread pool to concurrently process file generation and execution, greatly improves the execution efficiency, keeps the whole course tracking record of each task state, and ensures the reliable generation of files; the large data paging inquiry is used to ensure that billions of data are completely written into the file; and using multiple database adaptation to support the data query and writing of mainstream databases such as Oracle, mySql and the like.
Fig. 6 is a schematic structural diagram of the user decision defining apparatus 1, and as shown in fig. 6, the user decision defining apparatus 1 includes a rule configuration unit 11, a policy configuration unit 12, and a generation manner configuration unit 13, in which:
rule configuration unit 11: file name, file transmission type, transmission interface, file scene, etc. information for configuration file generation task. The rule parameters can be configured at will, and the specific business modules corresponding to the files are not coupled at all.
Policy configuration unit 12: file generation frequency, file generation dependency, and the like for configuring the file generation task. The file generation frequency supports various configurations, including frequencies in units of quarters of the year, month and year, and can be flexibly configured according to the time of processing the file by the downstream application. The file generation dependence supports various configurations, including execution result dependence of shell, sql, date and time, jar and the like, and can correlate file generation tasks with other tasks of an application system to ensure that file contents are accurate. For example: a certain file A can be generated only after a certain batch task B is finished, so that the effect of the batch task B on data processing is ensured to be reflected in the file A.
The generation mode configuration unit 13: generating tools, program paths, generating directories, encoding formats, file formats and the like for configuration file generating tasks. The file generation tool may be configured in a variety of ways, such as jar packages, shell, sql page turning, and save, that are supported by default in the system. The program can flexibly load the file generation tool type specified in the configuration and call up the file generation program of the specified path. The configuration can flexibly integrate the existing file generation mode, which is all of me.
Fig. 7 is a schematic structural diagram of the rule analysis device 2, and as shown in fig. 7, the rule analysis device 2 includes a rule analysis unit 21 and a rule execution unit 22, in which:
rule analysis section 21: the file for parsing the configuration generates rule configuration information, which is assembled into runtime configuration information required by the rule execution unit 22.
Rule execution unit 22: the execution unit prepares different instances according to the parameter configuration information input by the rule parsing unit 21. Such as instantiating file session information, etc.
Fig. 8 is a schematic structural diagram of the policy resolution device 3, and as shown in fig. 8, the policy resolution device 3 includes a policy resolution unit 31 and a policy execution unit 32, in which:
policy resolution unit 31: the file for parsing the configuration generates policy configuration information, which is assembled into parameter configuration information required when the policy enforcement unit 32 operates.
Policy enforcement unit 32: different instances are prepared according to the parameter configuration information input by the policy resolution unit 31. The strategy can grasp the generation time of the file according to the file interaction frequency and the file generation dependency relationship, and notify the file executing device to write data under the allowable condition.
Fig. 9 is a schematic configuration diagram of the generation scheme analysis device 4, and as shown in fig. 9, the generation scheme analysis device 4 includes a generation scheme analysis unit 41 and a generation scheme execution unit 42, in which:
generation scheme analysis section 41: the file generation mode configuration information for parsing the configuration is assembled into parameter configuration information required for the operation of the policy execution unit 42.
Generation method execution unit 42: different instances are prepared according to the parameter configuration information input by the generation mode analyzing unit 41. The generation system unit notifies the generation execution device 5 of how to write data based on the data writing tool, the encoding format, and the file location information configured by the user.
The generation execution device 5 includes: a data file generation unit 51 in which:
the data file generation unit 51: for validating when and where and in what manner to write a data file using data of a rule execution unit, a policy execution unit, and a generation manner execution unit, wherein both the policy execution unit and the generation manner execution unit are scalable.
In combination with the file generation system, the present application further provides a specific application example of a file generation method, referring to fig. 10, where the method includes: step S100: and starting the system, namely starting the application system. Step S200: loading a user decision device. Step S300: and rule analysis, namely generating rule analysis by a user decision file. Step S400: rule instantiation, i.e. user decision file generation rule execution. Step S500: and (3) strategy analysis, namely generating strategy analysis by a user decision file. Step S600: and judging whether the policies are matched, namely if the user decides that the file generation policies are matched, executing step S900. Step S700: and resolving the generation mode, namely resolving the generation mode of the user decision file. Step S800: the generation mode is instantiated, namely the generation mode of the user decision file is executed. Step S900: and loading the generation execution device to write the file data.
As can be seen from the above description, the file generation method and apparatus provided by the present application can improve efficiency and flexibility of generating a large amount of files, and further can improve efficiency of file interaction between applications; specifically, a plurality of types of database systems are supported, a plurality of file generation modes can be adapted, a plurality of file generation strategies are supported, a plurality of file generation rules are met, a file generation process can be flexibly configured, the universality is strong, the efficiency is improved, and the later maintenance and expansion are easy.
In order to improve efficiency and flexibility of generating a large amount of files and further improve efficiency of file interaction between applications, in terms of hardware, the embodiment of an electronic device for implementing all or part of content in the file generating method specifically includes the following contents:
a processor (processor), a memory (memory), a communication interface (Communications Interface), and a bus; the processor, the memory and the communication interface complete communication with each other through the bus; the communication interface is used for realizing information transmission between the file generating device and related equipment such as a user terminal; the electronic device may be a desktop computer, a tablet computer, a mobile terminal, etc., and the embodiment is not limited thereto. In this embodiment, the electronic device may be implemented with reference to an embodiment for implementing the file generating method and an embodiment for implementing the file generating apparatus according to the embodiments, and the contents thereof are incorporated herein, and the repetition is omitted.
Fig. 11 is a schematic block diagram of a system configuration of an electronic device 9600 of an embodiment of the present application. As shown in fig. 11, the electronic device 9600 may include a central processor 9100 and a memory 9140; the memory 9140 is coupled to the central processor 9100. Notably, this fig. 11 is exemplary; other types of structures may also be used in addition to or in place of the structures to implement telecommunications functions or other functions.
In one or more embodiments of the present application, the file generating apparatus functions may be integrated into the central processor 9100. The central processor 9100 may be configured to perform the following control:
step 101: and determining file generation strategies of a plurality of file generation tasks according to the file generation strategy configuration information.
Step 102: and determining the file generation mode corresponding to each file generation task based on the file generation mode configuration information.
Step 103: and determining the file generation rule corresponding to each file generation task based on the file generation rule configuration information.
Step 104: and generating a target file based on the file generation strategy, the file generation mode and the file generation rule, and distributing the target file to a target application system.
From the above description, it can be known that the electronic device provided by the embodiment of the present application can improve efficiency and flexibility of generating a large amount of files, and further can improve efficiency of file interaction between applications.
In another embodiment, the file generating apparatus may be configured separately from the central processing unit 9100, for example, the file generating apparatus may be configured as a chip connected to the central processing unit 9100, and the file generating apparatus functions are implemented by control of the central processing unit.
As shown in fig. 11, the electronic device 9600 may further include: a communication module 9110, an input unit 9120, an audio processor 9130, a display 9160, and a power supply 9170. It is noted that the electronic device 9600 need not include all of the components shown in fig. 11; in addition, the electronic device 9600 may further include components not shown in fig. 11, and reference may be made to the related art.
As shown in fig. 11, the central processor 9100, sometimes referred to as a controller or operational control, may include a microprocessor or other processor device and/or logic device, which central processor 9100 receives inputs and controls the operation of the various components of the electronic device 9600.
The memory 9140 may be, for example, one or more of a buffer, a flash memory, a hard drive, a removable media, a volatile memory, a non-volatile memory, or other suitable device. The information about failure may be stored, and a program for executing the information may be stored. And the central processor 9100 can execute the program stored in the memory 9140 to realize information storage or processing, and the like.
The input unit 9120 provides input to the central processor 9100. The input unit 9120 is, for example, a key or a touch input device. The power supply 9170 is used to provide power to the electronic device 9600. The display 9160 is used for displaying display objects such as images and characters. The display may be, for example, but not limited to, an LCD display.
The memory 9140 may be a solid state memory such as Read Only Memory (ROM), random Access Memory (RAM), SIM card, etc. But also a memory which holds information even when powered down, can be selectively erased and provided with further data, an example of which is sometimes referred to as EPROM or the like. The memory 9140 may also be some other type of device. The memory 9140 includes a buffer memory 9141 (sometimes referred to as a buffer). The memory 9140 may include an application/function storage portion 9142, the application/function storage portion 9142 storing application programs and function programs or a flow for executing operations of the electronic device 9600 by the central processor 9100.
The memory 9140 may also include a data store 9143, the data store 9143 for storing data, such as contacts, digital data, pictures, sounds, and/or any other data used by an electronic device. The driver storage portion 9144 of the memory 9140 may include various drivers of the electronic device for communication functions and/or for performing other functions of the electronic device (e.g., messaging applications, address book applications, etc.).
The communication module 9110 is a transmitter/receiver 9110 that transmits and receives signals via an antenna 9111. A communication module (transmitter/receiver) 9110 is coupled to the central processor 9100 to provide input signals and receive output signals, as in the case of conventional mobile communication terminals.
Based on different communication technologies, a plurality of communication modules 9110, such as a cellular network module, a bluetooth module, and/or a wireless local area network module, etc., may be provided in the same electronic device. The communication module (transmitter/receiver) 9110 is also coupled to a speaker 9131 and a microphone 9132 via an audio processor 9130 to provide audio output via the speaker 9131 and to receive audio input from the microphone 9132 to implement usual telecommunications functions. The audio processor 9130 can include any suitable buffers, decoders, amplifiers and so forth. In addition, the audio processor 9130 is also coupled to the central processor 9100 so that sound can be recorded locally through the microphone 9132 and sound stored locally can be played through the speaker 9131.
As can be seen from the above description, the electronic device provided by the embodiment of the present application can improve efficiency and flexibility of generating a large amount of files, and further can improve efficiency of file interaction between applications.
The embodiments of the present application also provide a computer-readable storage medium capable of implementing all the steps of the file generation method in the above embodiments, the computer-readable storage medium storing thereon a computer program that, when executed by a processor, implements all the steps of the file generation method in the above embodiments, for example, the processor implements the following steps when executing the computer program:
step 101: and determining file generation strategies of a plurality of file generation tasks according to the file generation strategy configuration information.
Step 102: and determining the file generation mode corresponding to each file generation task based on the file generation mode configuration information.
Step 103: and determining the file generation rule corresponding to each file generation task based on the file generation rule configuration information.
Step 104: and generating a target file based on the file generation strategy, the file generation mode and the file generation rule, and distributing the target file to a target application system.
As can be seen from the above description, the computer readable storage medium provided in the embodiments of the present application can improve efficiency and flexibility of generating a large amount of files, and further can improve efficiency of file interaction between applications.
All embodiments of the method are described in a progressive manner, and identical and similar parts of all embodiments are mutually referred to, and each embodiment mainly describes differences from other embodiments. For relevance, see the description of the method embodiments.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
The principles and embodiments of the present application are described herein with reference to specific examples, the description of which is only for the purpose of aiding in the understanding of the methods of the present application and the core ideas thereof; meanwhile, as those skilled in the art will have modifications in the specific embodiments and application scope in accordance with the ideas of the present application, the present description should not be construed as limiting the present application in view of the above.

Claims (8)

1. A document generation method, comprising:
determining file generation strategies of a plurality of file generation tasks according to file generation strategy configuration information, wherein the file generation strategies comprise file generation frequencies and dependency relations among the file generation tasks;
determining a file generation mode corresponding to each file generation task based on the file generation mode configuration information, wherein the file generation mode comprises a generation tool, a program path, a generation directory, a coding format and a file format;
determining a file generation rule corresponding to each file generation task based on file generation rule configuration information, wherein the file generation rule is a rule containing a file name, a file transmission type and a transmission interface;
generating a target file based on the file generation strategy, the file generation mode and the file generation rule, and distributing the target file to a target application system;
the generating a target file based on the file generating strategy, the file generating mode and the file generating rule and distributing the target file to a target application system, and the method further comprises the following steps: and monitoring and generating target files in real time and distributing the target files to a target application system, recording the execution state of each target file generation task, and if the execution state is abnormal, outputting alarm information corresponding to the abnormal state.
2. The file generation method according to claim 1, characterized by further comprising:
configuring the file to generate strategy configuration information;
configuring the file generation mode configuration information;
and configuring the file to generate rule configuration information.
3. The file generation method according to claim 1, wherein generating and distributing the target file to the target application system based on the file generation policy, the file generation manner, and the file generation rule comprises:
and generating a plurality of target files based on the file generation strategy, the file generation mode and the file generation rule, and distributing the target files to a target application system.
4. A document generating apparatus, comprising:
the determining policy module is used for determining file generating policies of a plurality of file generating tasks according to the file generating policy configuration information, wherein the file generating policies are policies containing file generating frequencies and dependency relations among the file generating tasks;
the file generation mode determining module is used for determining a file generation mode corresponding to each file generation task based on file generation mode configuration information, wherein the file generation mode comprises a generation tool, a program path, a generation catalog, a coding format and a file format;
the file generation rule determining module is used for determining file generation rules corresponding to the file generation tasks respectively based on file generation rule configuration information, wherein the file generation rules comprise file names, file transmission types and transmission interfaces;
the execution module is used for generating a target file based on the file generation strategy, the file generation mode and the file generation rule and distributing the target file to a target application system;
the execution module further comprises: the monitoring unit is used for monitoring the process of generating the target file and distributing the target file to the target application system in real time, recording the execution state of each target file generating task, and outputting alarm information corresponding to the abnormal execution state if the abnormal execution state occurs.
5. The file generating apparatus as recited in claim 4, further comprising:
the configuration strategy module is used for configuring the file to generate strategy configuration information;
the configuration generation mode module is used for configuring the file generation mode configuration information;
and the configuration rule module is used for configuring the file generation rule configuration information.
6. The file generation device of claim 4, wherein the execution module further comprises:
and the execution unit is used for generating a plurality of target files based on the file generation strategy, the file generation mode and the file generation rule and distributing the target files to the target application system.
7. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the file generation method of any of claims 1 to 3 when executing the program.
8. A computer readable storage medium having stored thereon computer instructions, which when executed by a processor, implement the file generation method of any of claims 1 to 3.
CN202010811637.4A 2020-08-13 2020-08-13 File generation method and device Active CN111930690B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010811637.4A CN111930690B (en) 2020-08-13 2020-08-13 File generation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010811637.4A CN111930690B (en) 2020-08-13 2020-08-13 File generation method and device

Publications (2)

Publication Number Publication Date
CN111930690A CN111930690A (en) 2020-11-13
CN111930690B true CN111930690B (en) 2024-03-01

Family

ID=73311653

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010811637.4A Active CN111930690B (en) 2020-08-13 2020-08-13 File generation method and device

Country Status (1)

Country Link
CN (1) CN111930690B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113067866B (en) * 2021-03-18 2022-07-05 中国工商银行股份有限公司 Batch file transmission method and device between heterogeneous systems
CN113360452A (en) * 2021-06-07 2021-09-07 中国工商银行股份有限公司 Distributed file generation method and device

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109976803A (en) * 2017-12-27 2019-07-05 航天信息股份有限公司 A kind of generation method and device of file
CN110188135A (en) * 2019-05-30 2019-08-30 中国联合网络通信集团有限公司 Document generating method and equipment

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080184200A1 (en) * 2007-01-26 2008-07-31 Microsoft Corporation Software configuration policies' validation, distribution, and enactment

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109976803A (en) * 2017-12-27 2019-07-05 航天信息股份有限公司 A kind of generation method and device of file
CN110188135A (en) * 2019-05-30 2019-08-30 中国联合网络通信集团有限公司 Document generating method and equipment

Also Published As

Publication number Publication date
CN111930690A (en) 2020-11-13

Similar Documents

Publication Publication Date Title
CN111325626B (en) Account checking data pushing method and device
TW202042100A (en) Method and device for cooperatively editting document, computer device and storage media
CN111930690B (en) File generation method and device
CN112597199B (en) Heterogeneous multi-data source adaptation method and device
US20190243669A1 (en) Skill discovery and brokering framework
CN112784112B (en) Message verification method and device
CN110378778A (en) Multi-data source account checking method, system, electronic equipment and storage medium
CN111427918A (en) Transaction detail data comparison method and device
CN112396511B (en) Distributed wind control variable data processing method, device and system
CN113297179A (en) Method and device for processing supervision submission data
CN113282590A (en) Interface joint debugging method and device based on 5G message
CN113434423B (en) Interface testing method and device
CN111782260A (en) Gray scale distribution method and gray scale distribution device
CN116233254A (en) Business cut-off method, device, computer equipment and storage medium
CN113837870B (en) Financial risk data approval method and device
CN111652580B (en) Method and device for processing data of nodes
CN113419957B (en) Rule-based big data offline batch processing performance capacity scanning method and device
CN114064630A (en) Data sharing method and device and computer readable storage medium
CN113221177A (en) Data access method, device and system in distributed system
CN113176854A (en) Service management data processing method, device and system
CN112035162A (en) Configuration file batch modification method and device
CN112965952B (en) Data asset processing method and device
CN115277682B (en) Method and device for collecting massive small files
CN109542531A (en) A kind of file layout method of adjustment and device
CN115208875B (en) Information integration system of multi-transmission middleware

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
GR01 Patent grant
GR01 Patent grant