CN111930690A - File generation method and device - Google Patents

File generation method and device Download PDF

Info

Publication number
CN111930690A
CN111930690A CN202010811637.4A CN202010811637A CN111930690A CN 111930690 A CN111930690 A CN 111930690A CN 202010811637 A CN202010811637 A CN 202010811637A CN 111930690 A CN111930690 A CN 111930690A
Authority
CN
China
Prior art keywords
file generation
file
configuration information
target
generating
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.)
Granted
Application number
CN202010811637.4A
Other languages
Chinese (zh)
Other versions
CN111930690B (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

Images

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)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Human Computer Interaction (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 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 generation of the large-batch files, 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, in particular, to the field of finance and other fields, and more particularly, to a method and an apparatus for generating a file.
Background
With the increasing number of monomer applications, the relationship between the applications becomes more and more compact. Each application pays attention to the realization of the main body function of the application, pays more attention to the embodiment of the function of the associated field and other comprehensive functions, and provides all-round service for customers. This highlights the importance of data association between applications and also tends to cause data interaction between applications to be more frequent. The online interface can obtain relevant data of the associated field immediately, but the server pressure is too large due to a large amount of online interaction, and meanwhile, the online interaction effect is not ideal due to the factors of limited network resources and the like, so that the batch file mode is particularly important as an important supplement of the online interaction. Meanwhile, under the scene that the requirement on the instantaneity of data interaction is not high, 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, the traditional development and design aiming at file generation become increasingly inefficient, and particularly under the condition that the interaction requirements of more applications on the data files are more and more vigorous, the traditional mode not only can not well solve the problems, but also can realize the file interaction requirements to be dispersed in each function of the system under the scenes of different human qualities and complex file dependence, and finally the generation time, mode and dependence of the interaction files cannot be managed until the subsequent maintenance cannot be carried out.
Although the distributed batch framework can realize file generation, the batch scheduling and distribution characteristics are more concerned, and the time cost is higher.
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 improve the efficiency of file interaction between applications.
In order to solve the technical problem, the present application provides the following technical solutions:
in a first aspect, the present application provides a file generation 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 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 generation method further comprises: configuring the file generation policy configuration information, wherein 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 are obtained; configuring the file generation mode configuration information, wherein the file generation mode configuration information comprises: generating tools, program paths, generating catalogues, encoding formats and file formats corresponding to the file generating tasks respectively; configuring the file generation rule configuration information, wherein the file generation rule configuration information comprises: and the file generation tasks respectively correspond to file names, file transmission types and transmission interfaces.
Further, after the concurrently executing each target file generation task, the method further includes: and concurrently 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 a target file and distributing the target file to a target application system based on the file generation policy, the file generation method and the file generation rule 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 file generation apparatus, including:
the strategy determining module is used for determining file generation strategies of a plurality of file generation tasks according to the file generation strategy configuration information;
the generation mode determining module is used for determining a file generation mode corresponding to each file generation task based on the file generation mode configuration information;
the file generation rule determining module is used for determining a file generation rule corresponding to each file generation task based on file generation rule configuration information;
and the execution module is used for generating a target file and distributing the target file to a target application system based on the file generation strategy, the file generation mode and the file generation rule.
Further, the file generation apparatus further includes: a configuration policy module, 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 are obtained; a configuration generation mode module, configured to configure the file generation mode configuration information, where the file generation mode configuration information includes: generating tools, program paths, generating catalogues, encoding formats and file formats corresponding to the file generating tasks respectively; a configuration rule module, configured to configure the file generation rule configuration information, where the file generation rule configuration information includes: and the file generation tasks respectively correspond to file names, file transmission types and transmission interfaces.
Further, the execution module further comprises: and the execution unit is used for generating a plurality of target files concurrently and distributing the target files to the target application system based on the file generation strategy, the file generation mode and the file generation rule.
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, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements 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 file generation rule configuration information; 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, so that the efficiency and the flexibility of large-batch file generation can be improved, and further the efficiency of file interaction between applications can be improved; the method and the system support various database systems, can adapt to various file generation modes, support various file generation strategies, meet various file generation rules, flexibly configure the file generation process, have strong universality, and are easy to maintain and expand in the later period while improving the efficiency. In addition, less occupied memory resources and flexible deployment are achieved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a schematic flow chart diagram illustrating a document generation method according to an embodiment of the present application;
FIG. 2 is a schematic flowchart of steps 201 to 203 of a file generation method in an embodiment of the present application;
FIG. 3 is a flowchart illustrating a file generation method including step 301 according to an embodiment of the present application;
FIG. 4 is a schematic structural diagram of a document generating apparatus in an embodiment of the present application;
FIG. 5 is a logic diagram of a file generation system in an example of application of the present application;
FIG. 6 is a logic diagram of a user decision definition device in an application example of the present application;
FIG. 7 is a schematic structural diagram of a rule parsing apparatus 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 generation mode analysis device in an application example of the present application;
FIG. 10 is a schematic flowchart 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 make those skilled in the art better understand the technical solutions in the present specification, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In order to solve the problems of frequent file interaction between applications, low efficiency, poor maintainability and the like caused by the traditional design and development aiming at file generation, the invention provides a file generation method and a device, which support the export of a large number of data files from various database systems, adapt to various file generation modes, support various file generation strategies, meet various file generation rules, convert the traditional design and development thinking aiming at file contents into the design and development aiming at file generation configuration, have strong universality and flexible configuration, improve the efficiency and are easy to maintain and expand subsequently. The method and the apparatus for generating a document of the present application may be used in the financial field, and may also be used in any field other than the financial field.
The following examples are intended to illustrate the details.
In order to improve efficiency and flexibility of generating a large batch of files and further improve efficiency of file interaction between applications, the present embodiment provides a file generating method in which an execution subject is a file generating device, where the file generating device includes but is not limited to a server, and as shown in fig. 1, the method specifically includes the following contents:
step 101: and determining the file generation strategies of the 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 task thread pool can be applied, the file generation can be executed concurrently, the execution efficiency is greatly improved, the whole-process tracking record can be carried out on each task state, and the reliability of the file generation is ensured; large data paging query can be used to ensure that hundred million levels of data are completely written into files; and the data query writing of mainstream databases such as Oracle and MySql is supported by using multi-database adaptation.
In order to further improve the 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 includes: and generating frequency of the files corresponding to the file generation tasks and the dependency relationship among the file generation tasks.
Specifically, the file generation frequency may be one of monthly, daily, and real-time; through the dependency relationship among the file generation tasks, a file export strategy under a special scene can be met.
Step 202: configuring the file generation mode configuration information, wherein the file generation mode configuration information comprises: and generating tools, program paths, generating catalogues, encoding formats and file formats of the file generating tasks.
Specifically, the file generation tool may be a jar package, a shell program, a bin program, other exes and the like having a file generation function, and can support commands to generate files. The encoding format can be UTF-8, UTF-16, GB2312, GBK18030, ANSI and other encoding formats. The file format can be XML, a user-defined fixed-length file, a user-defined 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 generation tasks respectively correspond to file names, file transmission types and transmission interfaces.
In order to achieve interaction between single applications for large-scale files, the interaction process is efficient and reliable, in an embodiment of the present application, referring to fig. 3, step 104 includes:
step 301: and concurrently 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 generating the file, in an embodiment of the present application, the 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 the execution state is abnormal, alarm information corresponding to the abnormal state is output.
In terms of software, in order to improve efficiency and flexibility of generating a large amount of files and further improve efficiency of file interaction between applications, the present application provides an embodiment of a file generating apparatus for implementing all or part of contents in the file generating method, and referring to fig. 4, the file generating apparatus specifically includes the following contents:
a policy determining module 10, configured to determine a file generation policy of the multiple file generation tasks according to the file generation policy configuration information;
a generation mode determining module 20, configured to determine, based on the file generation mode configuration information, a file generation mode corresponding to each file generation task;
a determining and generating rule module 30, configured to determine, based on file generating rule configuration information, a file generating rule corresponding to each file generating task;
and the execution module 40 is used for generating a target file and distributing the target file to a target application system based on the file generation strategy, the file generation mode and the file generation rule.
In an embodiment of the present application, the file generating apparatus further includes:
a configuration policy module, 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 are obtained;
a configuration generation mode module, configured to configure the file generation mode configuration information, where the file generation mode configuration information includes: generating tools, program paths, generating catalogues, encoding formats and file formats corresponding to the file generating tasks respectively;
a configuration rule module, configured to configure the file generation rule configuration information, where the file generation rule configuration information includes: and the file generation 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 concurrently and distributing the target files to the target application system based on the file generation strategy, the file generation mode and the file generation rule.
In an 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 embodiment of the file generation apparatus provided in this specification may be specifically configured to execute the processing procedure of the embodiment of the file generation method, and its functions are not described herein again, and refer to the detailed description of the embodiment of the file generation method.
To further illustrate the present solution, the present application further provides an application example of a file generation system, referring to fig. 5, in the application example, the system includes: a user decision definition device 1, a rule analysis device 2, a policy analysis device 3, a generation method 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 method analysis device 4 are connected to the generation execution device 5. The specific description is as follows:
the user decision definition apparatus 1: the method is used for configuring file generation rules, generating strategies and generating modes. The configuration information can be supported by the system and can be realized by self-definition. The relevant configuration information is saved in a system configuration table.
The rule analysis device 2: the configured file generation rule is read from the user decision definition device 1, and mainly comprises information such as a file name, a file transmission type, a transmission interface, a file field and the like, and the rule analysis device 2 is instantiated.
The 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 in any day and any month can be selected), file generation dependency and the like (file dependency relationship can be selected, and a file export policy under a special scene is satisfied), and the policy analysis device 3 is instantiated.
Generation method analysis device 4: the file generation method of the configuration read from the user decision definition apparatus 1 mainly includes information such as a generation tool, a program path, a generation directory, an encoding format, and a file format. The generation tool can be configured, so that integration of multiple generation modes can be realized; the file coding format is configurable, and various common coding formats such as UTF-8, UTF-16, GB2312, GBK18030, ANSI and the like can be easily supported; the file format can be configured, and various formats such as common XML, a user-defined fixed-length file, a user-defined separator file and the like can be supported.
The generation execution device 5: the generation executing device 5 determines the file generation type according to the rule, determines whether the current condition is met or not according to the policy, whether the file generation task can be triggered or not, and writes the data into the file according to the generation mode. The device uses the task thread pool to concurrently process the file generation and execution, thereby greatly improving the execution efficiency, keeping the whole-process tracking record of each task state and ensuring the reliable generation of the file; large data paging query is used to ensure that hundred million levels of data are completely written into files; and the data query writing of mainstream databases such as Oracle and MySql is supported by using multi-database adaptation.
Fig. 6 is a schematic structural diagram of a user decision definition apparatus 1, and as shown in fig. 6, the user decision definition apparatus 1 includes a rule configuration unit 11, a policy configuration unit 12, and a generation manner configuration unit 13, where:
the rule configuration unit 11: the file name, the file transmission type, the transmission interface, the file field and other information used for configuring the file generation task. The rule parameters can be configured at will without any coupling with the specific business module corresponding to the file.
The policy configuration unit 12: and the file generation frequency, file generation dependence and other information for the configuration file generation task. The file generation frequency supports various configurations, comprises frequency taking the time of the day, the month, the year and the quarter as a unit, can process the file time according to downstream application, and is flexibly configured. The file generation dependence supports various configurations, including shell, sql, date and time, jar and other execution result dependence, and can correlate the file generation task with other tasks of the application system, so that the file content is accurate. For example: a certain file A can be generated only after a certain batch task B is finished, and the effect of the batch task B on data processing is ensured to be embodied in the file A.
Generation method configuration unit 13: and information such as a generation tool, a program path, a generation directory, an encoding format, a file format and the like for configuring the file generation task. The file generation tool can configure jar packages, shells, sql page turning and storage and other modes supported by the default of the cost system. The program can flexibly load the file generation tool type specified in the configuration and call the file generation program of the specified path. The configuration can flexibly integrate the existing file generation modes and is owned by me.
Fig. 7 is a schematic structural diagram of the rule parsing device 2, and as shown in fig. 7, the rule parsing device 2 includes a rule parsing unit 21 and a rule execution unit 22, where:
the rule analysis unit 21: the file for parsing the configuration generates rule configuration information, and the rule configuration information is assembled into runtime configuration information required by the rule execution unit 22.
The rule execution unit 22: the execution unit prepares different instances based on the parameter configuration information input by the rule parsing unit 21. Such as instantiated 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, where:
the policy analysis unit 31: the file for parsing the configuration generates policy configuration information, and assembles the policy configuration information into parameter configuration information required by the operation of the policy execution unit 32.
The policy execution unit 32: different instances are prepared according to the parameter configuration information input by the policy resolution unit 31. The strategy grasps the file generation time according to the file interaction frequency and the file generation dependency relationship, and notifies the file execution device under the permission condition to write data.
Fig. 9 is a schematic structural diagram of the generation method analysis device 4, and as shown in fig. 9, the generation method analysis device 4 includes a generation method analysis unit 41 and a generation method execution unit 42, where:
generation method analysis section 41: the file generation mode configuration information for parsing the configuration is assembled into parameter configuration information required by the operation of the policy execution unit 42.
Generation mode execution unit 42: different examples are prepared according to the parameter configuration information input by the generation manner analysis unit 41. The generation means 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 means 5 includes: a data file generating unit 51, wherein:
the data file generating unit 51: and the data used for utilizing the rule execution unit, the strategy execution unit and the generation mode execution unit to confirm when and where the data file is written in which mode, wherein the strategy execution unit and the generation mode execution unit can be expanded.
In combination with the above 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: and loading the user decision device. Step S300: and (4) rule analysis, namely generating rule analysis by the user decision file. Step S400: and (4) instantiating the rule, namely generating the rule execution by the user decision file. Step S500: and (4) strategy analysis, namely generating the strategy analysis by the user decision file. Step S600: and (5) judging whether the strategies are matched, namely executing the step (S900) if the user decision file generation strategies are matched. Step S700: and (4) analyzing the generation mode, namely analyzing the generation mode of the user decision file. Step S800: and instantiating the generation mode, namely executing the generation mode of the user decision file. Step S900: and loading the generation executing device to write the file data.
According to the description, the file generation method and the file generation device provided by the application can improve the efficiency and the flexibility of large-batch file generation, and further can improve the efficiency of file interaction between applications; the method and the system support various database systems, can adapt to various file generation modes, support various file generation strategies, meet various file generation rules, flexibly configure the file generation process, have strong universality, and are easy to maintain and expand in the later period while improving the efficiency.
In terms of hardware, in order to improve efficiency and flexibility of generating a large amount of files and further improve efficiency of file interaction between applications, the present application provides an embodiment of an electronic device for implementing all or part of contents in the file generating method, where the electronic device 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 mutual communication through the bus; the communication interface is used for realizing information transmission between the file generation device and the user terminal and other related equipment; the electronic device may be a desktop computer, a tablet computer, a mobile terminal, and the like, but the embodiment is not limited thereto. In this embodiment, the electronic device may be implemented with reference to the embodiment for implementing the file generating method and the embodiment for implementing the file generating apparatus in the embodiments, and the contents thereof are incorporated herein, and repeated details are not repeated.
Fig. 11 is a schematic block diagram of a system configuration of an electronic device 9600 according to an embodiment of the present application. As shown in fig. 11, the electronic device 9600 can 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 structure to implement telecommunications or other functions.
In one or more embodiments of the present application, the file generation apparatus function can be integrated into the central processor 9100. The central processor 9100 may be configured to control as follows:
step 101: and determining the file generation strategies of the 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 electronic device 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.
In another embodiment, the file generating apparatus may be configured separately from the central processor 9100, for example, the file generating apparatus may be configured as a chip connected to the central processor 9100, and the function of the file generating apparatus is realized by the control of the central processor.
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 also does not necessarily include all of the components shown in fig. 11; in addition, the electronic device 9600 may further include components not shown in fig. 11, which may be referred to in the prior art.
As shown in fig. 11, a central processor 9100, sometimes referred to as a controller or operational control, can include a microprocessor or other processor device and/or logic device, which central processor 9100 receives input and controls the operation of the various components of the electronic device 9600.
The memory 9140 can 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 relating to the failure may be stored, and a program for executing the information may be stored. And the central processing unit 9100 can execute the program stored in the memory 9140 to realize information storage or processing, or 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. Power supply 9170 is used to provide power to electronic device 9600. The display 9160 is used for displaying display objects such as images and characters. The display may be, for example, an LCD display, but is not limited thereto.
The memory 9140 can be a solid state memory, e.g., Read Only Memory (ROM), Random Access Memory (RAM), a SIM card, or the like. There may also be a memory that holds information even when power is off, can be selectively erased, and is provided with more data, an example of which is sometimes called an EPROM or the like. The memory 9140 could also be some other type of device. 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 being used for storing application programs and function programs or for executing a flow of operations of the electronic device 9600 by the central processor 9100.
The memory 9140 can also include a data store 9143, the data store 9143 being used to store 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 for the electronic device for communication functions and/or for performing other functions of the electronic device (e.g., messaging applications, contact book applications, etc.).
The communication module 9110 is a transmitter/receiver 9110 that transmits and receives signals via an antenna 9111. The communication module (transmitter/receiver) 9110 is coupled to the central processor 9100 to provide input signals and receive output signals, which may be the same as in the case of a conventional mobile communication terminal.
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, 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 receive audio input from the microphone 9132, thereby implementing ordinary telecommunications functions. The audio processor 9130 may include any suitable buffers, decoders, amplifiers and so forth. In addition, the audio processor 9130 is also coupled to the central processor 9100, thereby enabling recording locally through the microphone 9132 and enabling locally stored sounds to be played through the speaker 9131.
As can be seen from the above description, the electronic device provided in 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.
An embodiment of the present application further provides a computer-readable storage medium capable of implementing all the steps in the file generation method in the foregoing embodiment, where the computer-readable storage medium stores thereon a computer program, and when the computer program is executed by a processor, the computer program implements all the steps in the file generation method in the foregoing embodiment, for example, when the processor executes the computer program, the processor implements the following steps:
step 101: and determining the file generation strategies of the 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 batch of files, and further can improve efficiency of file interaction between applications.
In the present application, each embodiment of the method is described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. Reference is made to the description of the method embodiments.
As will be appreciated by one skilled in the art, 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 flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams 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 principle and the implementation mode of the present application are explained by applying specific embodiments in the present application, and the description of the above embodiments is only used to help understanding the method and the core idea of the present application; meanwhile, for a person skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (10)

1. A file generation method, comprising:
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 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.
2. The file generation method according to claim 1, further comprising:
configuring the file generation policy configuration information, wherein 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 are obtained;
configuring the file generation mode configuration information, wherein the file generation mode configuration information comprises: generating tools, program paths, generating catalogues, encoding formats and file formats corresponding to the file generating tasks respectively;
configuring the file generation rule configuration information, wherein the file generation rule configuration information comprises: and the file generation tasks respectively correspond to file names, file transmission types and transmission interfaces.
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 method, and the file generation rule includes:
and concurrently 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. 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 method, and the file generation rule further comprises:
and monitoring the process of generating the target file and distributing the target file to the target application system in real time.
5. A file generation apparatus, comprising:
the strategy determining module is used for determining file generation strategies of a plurality of file generation tasks according to the file generation strategy configuration information;
the generation mode determining module is used for determining a file generation mode corresponding to each file generation task based on the file generation mode configuration information;
the file generation rule determining module is used for determining a file generation rule corresponding to each file generation task based on file generation rule configuration information;
and the execution module is used for generating a target file and distributing the target file to a target application system based on the file generation strategy, the file generation mode and the file generation rule.
6. The file generation apparatus according to claim 5, further comprising:
a configuration policy module, 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 are obtained;
a configuration generation mode module, configured to configure the file generation mode configuration information, where the file generation mode configuration information includes: generating tools, program paths, generating catalogues, encoding formats and file formats corresponding to the file generating tasks respectively;
a configuration rule module, configured to configure the file generation rule configuration information, where the file generation rule configuration information includes: and the file generation tasks respectively correspond to file names, file transmission types and transmission interfaces.
7. The file generation apparatus of claim 5, wherein the execution module further comprises:
and the execution unit is used for generating a plurality of target files concurrently and distributing the target files to the target application system based on the file generation strategy, the file generation mode and the file generation rule.
8. The file generation apparatus according to claim 5, wherein 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.
9. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the file generation method of any one of claims 1 to 4 when executing the program.
10. A computer-readable storage medium having computer instructions stored thereon, wherein the instructions, when executed, implement the file generation method of any one of claims 1 to 4.
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 true CN111930690A (en) 2020-11-13
CN111930690B 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)

Cited By (1)

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

Citations (3)

* 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
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

Patent Citations (3)

* 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
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

Cited By (1)

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

Also Published As

Publication number Publication date
CN111930690B (en) 2024-03-01

Similar Documents

Publication Publication Date Title
CN110413673B (en) Database data unified acquisition and distribution method and system
CN112784112B (en) Message verification method and device
WO2020042878A1 (en) Calendar event reminder interaction method and system for smart terminal, and smart terminal
CN111930690B (en) File generation method and device
CN112396511B (en) Distributed wind control variable data processing method, device and system
CN113282590A (en) Interface joint debugging method and device based on 5G message
CN111443945B (en) Component code modification method and device
CN114968917A (en) Method and device for rapidly importing file data
US20080195627A1 (en) System and method for managing databases associated with respective personal information manager service accounts
CN112417018B (en) Data sharing method and device
CN111652580B (en) Method and device for processing data of nodes
CN112486979B (en) Data processing method, device and system, electronic equipment and computer readable storage medium
CN113392091A (en) Distributed cluster data migration method and device
CN114064630A (en) Data sharing method and device and computer readable storage medium
CN111930841A (en) Data synchronization method and device
CN111161047A (en) Bank business data processing and inquiring method and device
CN113157277B (en) Host file processing method and device
CN113760683B (en) Log acquisition method and device
CN114070902B (en) Message processing method and device based on DELPHI
CN111522783B (en) Data synchronization method, device, electronic equipment and computer readable storage medium
CN117435402A (en) Method and device for scheduling tape drives with backup strategy
CN114896321A (en) Data lake platform system
CN112905623A (en) Business data combination display method and device
CN113590622A (en) Distributed data access method and device
CN116880930A (en) Function switch control method, device, computer equipment and storage 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
GR01 Patent grant
GR01 Patent grant