GoogleCloudPlatform / serverless-photosharing-workshop
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
csproj
mod
properties
txt
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.

main3185 LOC (72%) 51 files
test146 LOC (3%) 2 files
generated0 LOC (0%) 0 files
build and deployment601 LOC (13%) 18 files
other460 LOC (10%) 19 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 ".*".
  • 51 files match defined criteria (3,185 LOC, 100.0% vs. main code):
    • 12 *.tf files (904 LOC)
    • 8 *.cs files (472 LOC)
    • 7 *.java files (432 LOC)
    • 10 *.js files (423 LOC)
    • 4 *.go files (410 LOC)
    • 5 *.yaml files (262 LOC)
    • 3 *.html files (222 LOC)
    • 1 *.py files (45 LOC)
    • 1 *.css files (15 LOC)
  • " *.tf" is biggest, containing 28.38% of LOC.
  • " *.css" is smallest, containing 0.47% of LOC.


*.tf904 LOC (28%) 12 files
*.cs472 LOC (14%) 8 files
*.java432 LOC (13%) 7 files
*.js423 LOC (13%) 10 files
*.go410 LOC (12%) 4 files
*.yaml262 LOC (8%) 5 files
*.html222 LOC (6%) 3 files
*.py45 LOC (1%) 1 file
*.css15 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 ".*/[Tt]est/.*".
  • 2 files match defined criteria (146 LOC, 4.6% vs. main code). All matches are in *.java files.


*.java146 LOC (100%) 2 files
Build and Deployment Code
Source code used to configure or support build and deployment process.
csproj
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 ".*/package[.]json".
    • files with paths like ".*[.]csproj".
    • files with paths like ".*[.]sh".
  • 18 files match defined criteria (601 LOC, 18.9% vs. main code):
    • 3 *.xml files (307 LOC)
    • 11 *.sh files (249 LOC)
    • 4 *.csproj files (45 LOC)
  • " *.xml" is biggest, containing 51.08% of LOC.
  • " *.csproj" is smallest, containing 7.49% of LOC.


*.xml307 LOC (51%) 3 files
*.sh249 LOC (41%) 11 files
*.csproj45 LOC (7%) 4 files
Other Code
mod
properties
txt
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*[.]json".
    • files with paths like ".*/go[.]mod".
    • files with paths like ".*[.]md".
    • files with paths like ".*/README[.][a-z0-9]+".
    • files with paths like ".*[.]properties".
    • files with paths like ".*[.]txt".
  • 19 files match defined criteria (460 LOC, 14.4% vs. main code):
    • 4 *.md files (314 LOC)
    • 8 *.json files (99 LOC)
    • 3 *.mod files (30 LOC)
    • 3 *.properties files (14 LOC)
    • 1 *.txt files (3 LOC)
  • " *.md" is biggest, containing 68.26% of LOC.
  • " *.txt" is smallest, containing 0.65% of LOC.


*.md314 LOC (68%) 4 files
*.json99 LOC (21%) 8 files
*.mod30 LOC (6%) 3 files
*.properties14 LOC (3%) 3 files
*.txt3 LOC (<1%) 1 file
Analyzers
Info about analyzers used for source code examinations.


2025-05-04 15:20