Automated Source Code Tagging for Intelligent Logging
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Current software programming lacks efficient methods for intelligent content-based logging and documentation of program code, making it difficult to automatically generate log data and code documentation during development and execution.
Innovation Solution
A method that involves assigning tags to blocks of source code, processing these tags to generate logging data, and linking the data with compiled executable code, enabling automated logging and documentation by identifying start and end tag locations within the code blocks and generating logging data based on tag configurations and log file mappings.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Productivity
If manual logging and documentation methods are used, then code execution tracking can be achieved, but the process is time-consuming and inefficient
Solution Approach 1:
The system performs preliminary actions by automatically generating logging data and documentation during the code compilation process. Tags are embedded in source code and processed during compilation to pre-generate logging data, eliminating the need for manual logging setup and code execution tracking later.
Solution Approach 2:
The system enables self-service by allowing the code itself to generate its own logging data through embedded tags. The logging data is automatically generated from the source code tags during compilation, and the executable code self-detects and uses this logging data during runtime without external intervention.
2Ease of operation
If comprehensive logging data is generated for all code blocks, then code troubleshooting efficiency is improved, but the complexity of processing and managing logging data increases
Solution Approach 1:
The system segments logging data generation by using tags to identify and process specific code blocks independently. Each tagged code block generates its own logging data separately, allowing selective processing of only relevant code portions rather than handling all code uniformly, thus reducing overall processing complexity.
Solution Approach 2:
The system applies local quality by generating different types of logging data for different code blocks based on their specific tags. Each code block receives customized logging treatment appropriate to its function, rather than applying a uniform logging approach to all code, optimizing troubleshooting efficiency while managing complexity.
Data Source
AI summary
Methods, computer program products, and/or systems are provided that perform the following operations: reading lines of code included in a collection of source code; identifying an assigned tag in the collection of source code; identifying a start tag location and an end tag location associated with the assigned tag, wherein the lines of code included between the start tag location and the end tag location identify a code block; processing the code block to generate logging data for the code block based, at least in part, on the assigned tag; and providing the logging data for linking to executable byte code compiled from the collection of source code, wherein the logging data is used to log code data relating to the code block during execution of the executable byte code.


