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

skyapm dotnet support log collecting #467

Merged
merged 7 commits into from
May 4, 2022
Merged

skyapm dotnet support log collecting #467

merged 7 commits into from
May 4, 2022

Conversation

KawhiWei
Copy link
Contributor

Please answer these questions before submitting pull request


skywalking link tracing log

  • Dotnet program connects to skywalking link tracing log.

@wu-sheng wu-sheng requested review from ElderJames and snakorse April 16, 2022 12:09
@wu-sheng wu-sheng changed the title skyapm dotnet 对接日志记录 skyapm dotnet support log collecting Apr 16, 2022
@wu-sheng wu-sheng requested a review from liuhaoyang April 16, 2022 12:09
@wu-sheng wu-sheng added this to the 2.0.0 milestone Apr 16, 2022
@wu-sheng wu-sheng added the enhancement New feature or request label Apr 16, 2022
.AddLogging(logging =>
{
logging.AddSkyApmLogger();
}));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it necessary to report logs to Skywalking as the default option?

src/SkyApm.Core/SkyLogging/SkyApmLogger.cs Outdated Show resolved Hide resolved
@liuhaoyang
Copy link
Collaborator

Please add a copyright header to all new files

@wu-sheng
Copy link
Member

Please add a copyright header to all new files

@liuhaoyang Please consider skywalking-eyes to this repository.

@@ -23,5 +23,6 @@ namespace SkyApm.Logging
public interface ILoggerFactory
{
ILogger CreateLogger(Type type);
SkyApm.Logging.ILogger CreateSkyApmLogger(Type type);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
SkyApm.Logging.ILogger CreateSkyApmLogger(Type type);
ILogger CreateSkyApmLogger(Type type);


public ILogger CreateSkyApmLogger(Type type)
{
throw new NotImplementedException();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not implement the method?

@@ -78,7 +78,6 @@ public SegmentContext CreateEntrySegment(string operationName, ICarrier carrier,
};
segmentContext.References.Add(segmentReference);
}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this page needs to be modified

_entrySegmentContextAccessor = serviceProvider.GetService<IEntrySegmentContextAccessor>();
_skyApmLogDispatcher = serviceProvider.GetService<ISkyApmLogDispatcher>();
_loggerName = type;
_pushSkywalking= pushSkywalking;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand what the meaning of this switch is.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Users can decide whether to push logs to Skywallking

@wu-sheng wu-sheng requested review from ElderJames and liuhaoyang May 2, 2022 12:55
@liuhaoyang liuhaoyang removed the request for review from snakorse May 4, 2022 08:54
src/SkyApm.Utilities.Logging/SkyApmLogger.cs Outdated Show resolved Hide resolved
@liuhaoyang liuhaoyang merged commit 9da12cb into SkyAPM:master May 4, 2022
@wu-sheng wu-sheng mentioned this pull request Jun 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants