uber / kraken
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
txt
mod
tpl
proto
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.

main22354 LOC (54%) 298 files
test17504 LOC (42%) 170 files
generated756 LOC (1%) 5 files
build and deployment17 LOC (<1%) 2 files
other730 LOC (1%) 22 files
Main Code
All manually created or maintained source code that defines logic of the product that is run in a production environment.
proto
tpl
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*".
  • 298 files match defined criteria (22,354 LOC, 100.0% vs. main code):
    • 277 *.go files (21,534 LOC)
    • 19 *.yaml files (706 LOC)
    • 1 *.proto files (82 LOC)
    • 1 *.tpl files (32 LOC)
  • " *.go" is biggest, containing 96.33% of LOC.
  • " *.tpl" is smallest, containing 0.14% of LOC.


*.go21534 LOC (96%) 277 files
*.yaml706 LOC (3%) 19 files
*.proto82 LOC (<1%) 1 file
*.tpl32 LOC (<1%) 1 file
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 ".*/mock[a-zA-Z0-9_\- ]+/.*".
    • files with paths like ".*/[Mm]ocks/.*".
    • files with paths like ".*_test[.].*".
    • files with paths like ".*/test[.].*".
    • files with paths like ".*/testing[.].*".
    • files with paths like ".*/[Tt]est/.*".
    • files with paths like ".*/test_.*".
  • 170 files match defined criteria (17,504 LOC, 78.3% vs. main code):
    • 163 *.go files (16,630 LOC)
    • 7 *.py files (874 LOC)
  • " *.go" is biggest, containing 95.01% of LOC.
  • " *.py" is smallest, containing 4.99% of LOC.


*.go16630 LOC (95%) 163 files
*.py874 LOC (4%) 7 files
Generated Code
Automatically generated files, not manually changed after generation.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with any line of content like "//[ ]*Generated by .*".
    • files with paths like ".*/gen/.*[.]go".
  • 5 files match defined criteria (756 LOC, 3.4% vs. main code). All matches are in *.go files.


*.go756 LOC (100%) 5 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 ".*[.]sh".
    • files with paths like ".*[.]git[a-z]+".
    • files with paths like ".*/[.]gitignore".
  • 2 files match defined criteria (17 LOC, 0.1% vs. main code). All matches are in *.sh files.


*.sh17 LOC (100%) 2 files
Other Code
mod
txt
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]txt".
    • files with paths like ".*[.]json".
    • files with paths like ".*/[Ee]xamples/.*".
    • files with paths like ".*[.]md".
    • files with paths like ".*/README[.][a-z0-9]+".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*/go[.]mod".
    • files with paths like ".*/[.]dockerignore".
  • 22 files match defined criteria (730 LOC, 3.3% vs. main code):
    • 6 *.md files (317 LOC)
    • 5 *.yaml files (187 LOC)
    • 7 *.sh files (96 LOC)
    • 1 *.mod files (67 LOC)
    • 1 *.json files (34 LOC)
    • 2 *.txt files (29 LOC)
  • " *.md" is biggest, containing 43.42% of LOC.
  • " *.txt" is smallest, containing 3.97% of LOC.


*.md317 LOC (43%) 6 files
*.yaml187 LOC (25%) 5 files
*.sh96 LOC (13%) 7 files
*.mod67 LOC (9%) 1 file
*.json34 LOC (4%) 1 file
*.txt29 LOC (3%) 2 files
Analyzers
Info about analyzers used for source code examinations.


2025-05-03 07:37