Skip to content

Proposal: Reorganize directories for simplicity and clarity #951

@zacharycmontoya

Description

@zacharycmontoya

Main Goals

  • Simplify root directory so the repository feels more accessible to first time readers or contributors.
    • There are 4 sample* directories and 2 reproduction* directories that should be more clearly identified as test projects
    • There are several build and test files cluttered in the root directory that could be placed in more specific subdirectories
  • Change the convention of "customer-samples" to "samples". My assumption is that new developers would expect to look at samples as small code projects that use the provided SDK in some meaningful way, so this proposed change would align with that.
  • Change the convention of "samples" to "test-applications". The "samples" in our repository really act as test applications to ensure our automatic instrumentation works as advertised. Renaming to "test-applications" is a little more clear about the intent, but I'm open to other suggestions on the name of this.
  • Change the convention of "reproductions" to "regression". These test applications serve as small regression tests to make sure previous bugs do not reoccur. Renaming to regression might convey that idea more clearly.

Proposed directory structure

Directory: /

Subdirectory name Purpose
blog Articles and walkthroughs (i.e. not code) to describe how the .NET Tracer can be used in various scenarios
build Contains artifacts, docker files, shell scripts, and code needed to run builds and CI
docs High-level documents
samples Previously named customer-samples, this contains .NET code that can be easily built against the Datadog.Trace NuGet package to demonstrate how it can be used for custom instrumentation
src Contains all project files and source files for .NET code, profiler code, and MSI code
test Contains all test projects (managed and native) and test applications
tools Miscellaneous .NET projects that are not product code or directly related to generating build artifacts

Directory: /build

Subdirectory name Purpose
artifacts createLogPath.sh, Datadog png's, and integrations.json
docker Directly moved from the /docker directory
tools Contains GeneratePackageVersions and PrepareRelease that were previously in the /tools directory

Directory: /blog

Contents unchanged

Directory: /docs

Contents unchanged

Directory: /samples (renamed from /customer-samples)

Contents unchanged

Directory: /src

Subdirectory name Purpose
WindowsInstaller Project that generates MSI. Directly moved from the /deploy/Datadog.Trace.ClrProfiler.WindowsInstaller directory
Datadog.Trace.ClrProfiler.Native/lib CoreCLR headers needed to build CLR Profiler. Directly moved from the /lib directory
Remaining Datadog.Trace.* projects Unchanged

Directory: /test

Subdirectory name Purpose
benchmarks Contains all benchmark projects
Datadog.Trace.*Tests Unchanged
test-applications All sample applications intended to test automatic instrumentation will be moved to this directory

Directory: /tools

Subdirectory name Purpose
Datadog.Core.Tools Unchanged
StartDistributedTrace Unchanged
UpdateVendors Unchanged

Directory: /test/test-applications

Subdirectory name Purpose
aspnet Contents will be a combination of the original /samples-aspnet directory and the /samples-iis directory
integrations Directly moved from the /samples directory
integrations/dependency-libs Directly moved from the /sample-libs directory
regression Directly moved from the /reproductions directory
regression/dependency-libs Directly moved from the /reproduction-dependencies directory

Updates

  • Originally the two subfolders aspnet and iis were proposed as subdirectories of /test/Datadog.Trace.ClrProfiler.IntegrationTests/test-applications. Instead, they'll be combined into the aspnet subdirectory
  • Originally the test-applications directory was proposed to be a subdirectory of /test/Datadog.Trace.ClrProfiler.IntegrationTests. Instead, it will be a subdirectory of test
  • Updated new directory name to /src/WindowsInstaller based on feedback
  • Updated the proposal to reflect the directory move from /lib to /src/Datadog.Trace.ClrProfiler.Native/lib

Metadata

Metadata

Labels

area:buildsproject files, build scripts, pipelines, versioning, releases, packagesstatus:work-in-progressActively worked on. If this is a PR, no review needed yet. WIP.type:refactor

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions