GoogleCloudPlatform / k8s-stackdriver
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
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.

main7781 LOC (43%) 68 files
test7747 LOC (43%) 24 files
generated0 LOC (0%) 0 files
build and deployment314 LOC (1%) 8 files
other1957 LOC (10%) 30 files
Main Code
All manually created or maintained source code that defines logic of the product that is run in a production environment.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*".
  • 68 files match defined criteria (7,781 LOC, 100.0% vs. main code):
    • 57 *.go files (6,287 LOC)
    • 9 *.yaml files (1,174 LOC)
    • 2 *.py files (320 LOC)
  • " *.go" is biggest, containing 80.8% of LOC.
  • " *.py" is smallest, containing 4.11% of LOC.


*.go6287 LOC (80%) 57 files
*.yaml1174 LOC (15%) 9 files
*.py320 LOC (4%) 2 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 ".*_test[.].*".
    • files with paths like ".*/[Tt]est/.*".
  • 24 files match defined criteria (7,747 LOC, 99.6% vs. main code):
    • 23 *.go files (7,483 LOC)
    • 1 *.yaml files (264 LOC)
  • " *.go" is biggest, containing 96.59% of LOC.
  • " *.yaml" is smallest, containing 3.41% of LOC.


*.go7483 LOC (96%) 23 files
*.yaml264 LOC (3%) 1 file
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".
  • 8 files match defined criteria (314 LOC, 4.0% vs. main code). All matches are in *.sh files.


*.sh314 LOC (100%) 8 files
Other Code
txt
mod
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]txt".
    • files with paths like ".*[.]md".
    • files with paths like ".*/README[.][a-z0-9]+".
    • files with paths like ".*/go[.]mod".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*[.]json".
    • files with paths like ".*/[Ee]xamples/.*".
  • 30 files match defined criteria (1,957 LOC, 25.2% vs. main code):
    • 9 *.md files (811 LOC)
    • 10 *.txt files (520 LOC)
    • 7 *.mod files (333 LOC)
    • 2 *.go files (154 LOC)
    • 2 *.yaml files (139 LOC)
  • " *.md" is biggest, containing 41.44% of LOC.
  • " *.yaml" is smallest, containing 7.1% of LOC.


*.md811 LOC (41%) 9 files
*.txt520 LOC (26%) 10 files
*.mod333 LOC (17%) 7 files
*.go154 LOC (7%) 2 files
*.yaml139 LOC (7%) 2 files
Analyzers
Info about analyzers used for source code examinations.


2025-05-04 14:30