Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename ISpan and ITransaction #2676

Closed
jamescrosswell opened this issue Sep 27, 2023 · 1 comment · Fixed by #2731
Closed

Rename ISpan and ITransaction #2676

jamescrosswell opened this issue Sep 27, 2023 · 1 comment · Fixed by #2731
Assignees
Milestone

Comments

@jamescrosswell
Copy link
Collaborator

jamescrosswell commented Sep 27, 2023

ISpan might be more appropriately named ISpanTracer since it represents properties and methods that are only implemented by SpanTracer and TransactionTracer.

For the same reason, ITransaction could be more appropriately named ITransactionTracer.

See entity relationship diagram below:

erDiagram
    NoOpSpan ||--|| ISpan : implements

    SpanTracer ||--|| ISpan : implements
    SpanTracer {
        bool IsSentryRequest
        TransactionTracer Transaction
        void Unfinish()
    }


    ISpan ||--|| ISpanData : implements
    ISpan {
        string Description
        string Operation
        SpanStatus Status
        ISpan StartChild()
        void Finish()
    }

    Span ||--|| ISpanData : implements

    ISpanData ||--|| ITraceContext : implements
    ISpanData ||--|| IHasTags : implements
    ISpanData ||--|| IHasExtra : implements
    ISpanData {
        DateTimeOffset StartTimestamp
        DateTimeOffset EndTimestamp
        bool IsFinished
        SentryTraceHeader GetTraceHeader()
    }

    NoOpTransaction ||--|| ITransaction : implements

    TransactionTracer ||--|| ISpan : implements
    TransactionTracer ||--|| ITransaction : implements
    TransactionTracer ||--|| ITransactionData : implements
    TransactionTracer ||--|| ISpan : implements
    TransactionTracer {
        bool IsSentryRequest
        double SampleRate
        IReadOnlyCollection Spans
        DynamicSamplingContext DynamicSamplingContext
        ITransactionProfiler TransactionProfiler
        void AddChildSpan()
        ISpan GetLastActiveSpan()
    }

    ITransaction ||--|| ITransactionData : implements
    ITransaction ||--|| ISpan : implements
    ITransaction {
        string Name
        bool IsParentSampled
        IReadOnlyCollection Spans
        ISpan GetLastActiveSpan()
    }

    Transaction ||--|| ITransactionData : implements
    Transaction {
        SentryId EventId
        double SampleRate
        DynamicSamplingContext DynamicSamplingContext
        ITransactionProfiler TransactionProfiler
        IReadOnlyCollection Spans
        void Redact()
        void WriteTo()
        Transaction FromJson()
    }

    ITransactionData ||--||  ISpanData : implements
    ITransactionData ||--|| ITransactionContext : implements
    ITransactionData ||--|| IEventLike : implements

    ITransactionContext ||--|| ITraceContext : implements

    IEventLike ||--|| IHasTags : implements
    IEventLike ||--|| IHasExtra : implements

    TransactionContext ||--|| SpanContext : implements
    TransactionContext ||--|| ITransactionContext : implements

    SpanContext ||--|| ITraceContext : implements
Loading
@bitsandfoxes
Copy link
Contributor

Worth considering #1491 while we're at it.

@jamescrosswell jamescrosswell changed the title Give classes and interfaces better names for v4.0.0 Rename ISpan and ITransaction Oct 16, 2023
@jamescrosswell jamescrosswell self-assigned this Oct 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants