aws-observability / aws-otel-test-framework
Source Code Overview

Analysis scope, overview of main, test, generated, deployment, build, and other code.

Source Code Analysis Scope
Files includes and excluded from analyses
tpl
mod
txt
dockerignore
properties
  • 21 extensions are included in analyses: java, tf, tpl, yml, tfvars, json, mustache, md, go, gradle, sh, xml, mod, txt, gitignore, yaml, jsp, py, dockerignore, bat, properties
  • 7 criteria are used to exclude files from analysis:
    • exclude files with path like ".*/[.][a-zA-Z0-9_]+.*" (Hidden files and folders) (9 files).
    • exclude files with path like ".*/gradle/wrapper/.*" (Gradle) (1 file).
    • exclude files with path like ".*/docs/.*" (Documentation) (8 files).
    • exclude files with path like ".*/git[-]history[.]txt" (Git history) (1 file).
    • exclude files with path like ".*/git[-][a-zA-Z0-9_]+[.]txt" (Git data exports for sokrates analyses) (0 files).
    • exclude files with path like ".*[.]txt" (Text files) (3 files).
    • exclude files with path like ".*/sokrates_conventions[.]json" (Sokrates scoping conventions) (1 file).
Overview of Analyzed Files
Basic stats on analyzed files
Intro
For analysis purposes we separate files in scope into several categories: main, test, generated, deployment and build, and other.

  • The main category contains all manually created source code files that are being used in the production.
  • Files in the main category are used as input for other analyses: logical decomposition, concerns, duplication, file size, unit size, and conditional complexity.
  • Test source code files are used only for testing of the product. These files are normally not deployed to production.
  • Build and deployment source code files are used to configure or support build and deployment process.
  • Generated source code files are automatically generated files that have not been manually changed after generation.
  • While a source code folder may contain a number of files, we are primarily interested in the source code files that are being written and maintained by developers.
  • Files containing binaries, documentation, or third-party libraries, for instance, are excluded from analysis. The exception are third-party libraries that have been changed by developers.

main16021 LOC (80%) 362 files
test339 LOC (1%) 7 files
generated0 LOC (0%) 0 files
build and deployment350 LOC (1%) 13 files
other3156 LOC (15%) 59 files
Main Code
All manually created or maintained source code that defines logic of the product that is run in a production environment.
tpl
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*".
  • 362 files match defined criteria (16,021 lines of code, 100.0% vs. main code):
    • 74 *.tf files (5,335 lines of code)
    • 88 *.java files (3,809 lines of code)
    • 67 *.tpl files (3,010 lines of code)
    • 30 *.mustache files (1,715 lines of code)
    • 11 *.go files (938 lines of code)
    • 44 *.yml files (846 lines of code)
    • 44 *.tfvars files (265 lines of code)
    • 2 *.yaml files (46 lines of code)
    • 1 *.py files (42 lines of code)
    • 1 *.jsp files (15 lines of code)
  • " *.tf" is biggest, containing 33.3% of code.
  • " *.jsp" is smallest, containing 0.09% of code.


*.tf5335 LOC (33%) 74 files
*.java3809 LOC (23%) 88 files
*.tpl3010 LOC (18%) 67 files
*.mustache1715 LOC (10%) 30 files
*.go938 LOC (5%) 11 files
*.yml846 LOC (5%) 44 files
*.tfvars265 LOC (1%) 44 files
*.yaml46 LOC (<1%) 2 files
*.py42 LOC (<1%) 1 files
*.jsp15 LOC (<1%) 1 files
Test Code
Used only for testing of the product. Normally not deployed in a production environment.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*/[Tt]est/.*".
    • files with any line of content like ".*/simpletest/.*".
  • 7 files match defined criteria (339 lines of code, 2.1% vs. main code). All matches are in *.java files.


*.java339 LOC (100%) 7 files
Build and Deployment Code
Source code used to configure or support build and deployment process.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*/pom[.]xml".
    • files with paths like ".*[.]git[a-z]+".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*[.]sh".
    • files with paths like ".*[.]gradle".
    • files with paths like ".*[.]bat".
  • 13 files match defined criteria (350 lines of code, 2.2% vs. main code):
    • 6 *.gradle files (190 lines of code)
    • 6 *.sh files (92 lines of code)
    • 1 *.bat files (68 lines of code)
  • " *.gradle" is biggest, containing 54.29% of code.
  • " *.bat" is smallest, containing 19.43% of code.


*.gradle190 LOC (54%) 6 files
*.sh92 LOC (26%) 6 files
*.bat68 LOC (19%) 1 files
Other Code
mod
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]md".
    • files with paths like ".*/README[.][a-z0-9]+".
    • files with paths like ".*/[Ee]xamples/.*".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*/[.]dockerignore".
    • files with paths like ".*/go[.]mod".
    • files with paths like ".*[.]properties".
    • files with paths like ".*[.]json".
    • files with paths like ".*/checkstyle[.]xml".
    • files with paths like ".*[.]txt".
    • files with paths like ".*[.](xml|xsd|robot|sql|pgsql|dashboard|profile|ipynb|raml|avsc|al)".
  • 59 files match defined criteria (3,156 lines of code, 19.7% vs. main code):
    • 31 *.json files (1,944 lines of code)
    • 16 *.md files (696 lines of code)
    • 6 *.xml files (384 lines of code)
    • 1 *.yaml files (82 lines of code)
    • 5 *.mod files (50 lines of code)
  • " *.json" is biggest, containing 61.6% of code.
  • " *.mod" is smallest, containing 1.58% of code.


*.json1944 LOC (61%) 31 files
*.md696 LOC (22%) 16 files
*.xml384 LOC (12%) 6 files
*.yaml82 LOC (2%) 1 files
*.mod50 LOC (1%) 5 files
Analyzers
Info about analyzers used for source code examinations.
  • *.tf files are analyzed with YamlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.java files are analyzed with JavaAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Advanced heuristic dependency analysis (based on package names)
  • *.tpl files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.mustache files are analyzed with HtmlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Advanced heuristic dependency analysis
  • *.go files are analyzed with GoLangAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Basic heuristic dependency analysis
  • *.yml files are analyzed with YamlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.tfvars files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.yaml files are analyzed with YamlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.py files are analyzed with PythonAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Basic heuristic dependency analysis
  • *.jsp files are analyzed with JspAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis


2022-02-01 02:42