Commit Graph
29 Commits
Author SHA1 Message Date
Nick Schonning f349dc4a36 typo: Double word "on" (dotnet/corefx#36265)
Commit migrated from https://github.com/dotnet/corefx/commit/63d0fb143a66400fd62099f60cd7958b8461ffda
2019-03-24 13:44:15 -07:00
Viktor Hofer bfe2b0e98c Add test targets to build script (dotnet/corefx#34385)
* Add test targets to build script

* Remove few manual copy targets in projects

* Remove PlatformAbstractions dependency

* Update ArchiveTests type to enum

* Set warnaserror false on arm/arm64

* Update docs

* Darc update from build '20190221.4'


Commit migrated from https://github.com/dotnet/corefx/commit/a619534cac9b7d000f0899248656d232cb44f61f
2019-02-21 15:18:47 +01:00
Raphael Miedl a254be83cf Fix several typos (dotnet/corefx#32779)
* explict => explicit
* compilant => compliant
* encounteres => encounters
* coresponding => corresponding
* conveted => converted

Commit migrated from https://github.com/dotnet/corefx/commit/1182fb8f4f43f45acfa04a93874ffaaf1cb9d627
2018-10-11 18:11:21 -07:00
Viktor Hofer 5648112ef8 Update required software and developer workflow (dotnet/corefx#30919)
* Update required software and developer workflow

* Address PR feedback

* Fix debugging packages instructions for builds

* Add desktop vs core msbuild disclaimer

* Delete obsolete file


Commit migrated from https://github.com/dotnet/corefx/commit/d9193a1bd70eee4320f8dcdd4e237ee9acf689e9
2018-08-23 23:23:36 +02:00
Viktor Hofer 8585939ef2 Update xunit to official 2.4.0 runner
Add necessary Test SDK assemblies

Enable test sdk props & targets only for netcoreapp


Commit migrated from https://github.com/dotnet/corefx/commit/f528b668fcd06efbde72a9510feb189e3988d795
2018-08-23 19:53:34 +02:00
Maryam Ariyan efc28d77e9 Update unix-instructions.md
Commit migrated from https://github.com/dotnet/corefx/commit/8fbe6c35a44be619fdce8dbca85e9273ac5bfc86
2018-06-20 15:27:30 -07:00
David Shulman 280b85f227 Add EventSource tracing to WinHttpHandler (dotnet/corefx#29604)
Add EventSource tracing to WinHttpHandler

Removed the custom OutputDebugString-style tracing from WinHttpHandler and replaced it with
NetEventSource. Didn't define any new event id's but tried to use "Info" vs. "Error"
in more places.

Due to the unique way the WinHttpHandler class gets built into two different binaries,
I needed to add a new EventSource name/GUID for the standalone System.Net.Http.WinHttpHandler.dll
binary. The logging output is similar but will show up in either "Microsoft-System-Net-Http" or
"Microsoft-System-Net-Http-WinHttpHandler" EventSource's depending on which binary is being used,
i.e. whether "new HttpClientHandler()" or "new WinHttpHandler()" was used.

For those curious about how the new GUID for "Microsoft-System-Net-Http-WinHttpHandler" was done, it
was not generated randomly. EventSource GUID's are generated based on the string name for the
EventSource according to a well-defined formula. Doing a construct like this will return back the
information:

```c#
Type esType = typeof(WinHttpHandler).GetTypeInfo().Assembly.GetType("System.Net.NetEventSource", true, false);
Console.WriteLine($"Name={EventSource.GetName(esType)}, Guid={EventSource.GetGuid(esType).ToString()}");
```

Closes dotnet/corefx#7856


Commit migrated from https://github.com/dotnet/corefx/commit/11222269ae3bc45cd414dcb973f2d92f1bad73f8
2018-05-10 14:33:25 -07:00
David Shulman 97f018a3fa Update download link for PerfView tool (dotnet/corefx#28822)
The PerfView tool has been moved to open-source. Updating the documentation link to point to the most recent place for downloading the tool.

Commit migrated from https://github.com/dotnet/corefx/commit/81e82818527c1fab743ced76ad33441f61af2636
2018-04-04 12:24:49 -07:00
William Godbe 4c1453c077 Update debugging with VS code instructions (dotnet/corefx#27384)
* Update debugging with VS code instructions

For https://github.com/dotnet/corefx/issues/21557. CC @tmds

* Change wording


Commit migrated from https://github.com/dotnet/corefx/commit/78fc0f0c6a103c43f68e17412589b331fdf971b9
2018-02-23 11:38:56 -08:00
Dan Moseley 1859d2ea16 lldb install link
Commit migrated from https://github.com/dotnet/corefx/commit/e548aec5876e1d8233809451fb5113b20d874be6
2018-01-01 15:25:54 -08:00
Dan Moseley 0a35d29e22 Show how to find libsosplugin.so
Commit migrated from https://github.com/dotnet/corefx/commit/fc20e5055676a5345a67a12779002813f0441143
2018-01-01 15:01:16 -08:00
Santiago Fernandez Madero 98cccd6a48 Update core dumps docs (dotnet/corefx#25398)
* Update core dumps docs

* Change quotes.


Commit migrated from https://github.com/dotnet/corefx/commit/8543f077fb48ee135dcc83d6305c0c439b4370c5
2017-11-20 16:29:26 -08:00
Mike McLaughlin 177977f786 Update build to clang/llvm 3.9
Update scripts, docs and build pipeline docker images to clang/llvm/lldb 3.9


Commit migrated from https://github.com/dotnet/corefx/commit/1bd2c02ebc269376cfc39d77b9cb5a233cc3b5ac
2017-09-26 13:47:40 -07:00
Jan Vorlicek a20a1b56f2 Revert "Update build to clang/llvm 3.9 (dotnet/corefx#24177)"
This reverts commit dotnet/corefx@21e008a340.


Commit migrated from https://github.com/dotnet/corefx/commit/092318d2e898b05581e6da1ef18e3521b5384302
2017-09-22 15:35:01 -07:00
Mike McLaughlin d1f5e6cd32 Update build to clang/llvm 3.9 (dotnet/corefx#24177)
Update scripts, docs and build pipeline docker images to clang/llvm/lldb 3.9

Commit migrated from https://github.com/dotnet/corefx/commit/21e008a3401a4d76ef5123df8f072e9f3c7823bb
2017-09-22 10:17:33 +02:00
Eric Mellino bc93b96f48 Add documentation for Dumpling (dotnet/corefx#22441)
Commit migrated from https://github.com/dotnet/corefx/commit/74a94741f979b7837b795e052b31d79990b740c0
2017-07-19 11:17:51 -07:00
Cristian Pop 1426f76d85 Update windows-instructions.md (dotnet/corefx#21992)
Commit migrated from https://github.com/dotnet/corefx/commit/cf08dab524525d58cd701eb8de52263b5b276369
2017-07-07 14:42:28 -07:00
Eric Mellino 21dec6ff26 Clarify lldb and libsosplugin requirements for core debugging
Commit migrated from https://github.com/dotnet/corefx/commit/e06d60e9fb11f68ead62338fd9dc6ee2210d3375
2017-04-28 11:14:23 -07:00
Eric Mellino 26ecaf5e49 Add a missing word.
Commit migrated from https://github.com/dotnet/corefx/commit/70186262dcd2cea4944b5d5768d67d156bda61dc
2017-04-27 19:50:23 -07:00
Eric Mellino 7cb373059a Add core dump debugging instructions
Commit migrated from https://github.com/dotnet/corefx/commit/c14185223acc62525b0af0887ebc4d3d4ecfeac7
2017-04-27 17:14:44 -07:00
Alex Perovich 8cda321ac1 Add linux debugging instructions (dotnet/corefx#13867)
* Add linux debugging instructions

* s/linux/unix


Commit migrated from https://github.com/dotnet/corefx/commit/4bf98d1729b503430e7cb8ac87c68872a970efb5
2016-11-21 15:39:22 -08:00
Cristian Pop cfe1d001d8 Adding new build/packaging documentation (dotnet/corefx#13026)
* Adding new APIs not part of NetStandard
* Adding package debugging.

Commit migrated from https://github.com/dotnet/corefx/commit/9df69fa5d8333991d9c62a47f0009fed8f1ae0b8
2016-11-09 08:06:52 -08:00
Stephen Toub 78652d624e Overhaul System.Net library logging
This PR overhauls how logging is accomplished in the System.Net libraries.

There are a few problems with the existing solution:
1. In the original sources, logging was split across a GlobalLog class and a Logging class.  Global-related tracing went to GlobalLog, and library-specific tracing went to Logging.  When the sources were moved to corefx, this evolved into multiple EventSource-based types, most of which were in Common and were then src-included into each System.Net assembly.  This has a significant problem, though, which is that the name/Guid identity of an EventSource can only exist once in a process, and subsequent EventSource instances with the same identity fail.  This means that whichever assembly ends up logging something first wins, and all other tracing from other System.Net assemblies ends up being lost.
2. The split also may have made sense when all components shared the same GlobalLog, but now that GlobalLog is included as a unique EventSource instance in each assembly, it's no longer global.  This means that we're not only loading multiple EventSources unnecessarily (each has its own costs), but we're also duplicating logging, as some logging is done to one or the other, but some logging is done to both.
3. Due to sharing the Logging class, which evolved into an EventSource-based type, many logging calls had to include which component they came from as an enum value, leading to bloating at the call sites.
4. Additionally, many logging operations included the name of the method in which the calling was being done, which meant both longer call sites as well as stale values as members got renamed over time.
5. Call sites ended up getting fairly long due to lots of string concatenation operations and other manipulations in the logging call.  This also then led to most call sites needing to be guarded behind checks for IsEnabled, leading to lots of code at every call site and obscuring the actual information being traced.
6. An additional requirement that got added with the move to corefx was that certain failure conditions should both Debug.Fail and do tracing, leading to some tracing operations taking upwards of 10 lines of code.

All of these issues are addressed by this PR.

- Each System.Net assembly that needs to log now loads a single NetEventSource type for doing logging, each with its own identity.
- That implementation is split across a common, partial NetEventSource.Common.cs file used by all such assemblies, and then a per-assembly partial NetEventSource.AssemblyName.cs file used by the individual assembly.  The former file contains most of the logging implementation.  The latter files typically contain just the partial class declaration along with the [EventSource] attribute that gives that assembly's NetEventSource its unique identity / name.
- The logging operations in NetEventSource.Common.cs use a variety of relatively-recent language enhancements to improve the logging.  Each operation uses a [CallerMemberName] so that the call sites don't need to specify the caller.  FormattableString is used so that call sites can use string interpolation while still providing the logging implementation the flexibility to format the individual components in a desired fashion (e.g. IntPtrs are formatted as hex, SafeHandles are rendered in a way that includes their name+hashcode+handle, etc.), along with a mechanism that allows individual libraries to add additional formatting rules.  Each operation allows the this reference (or another this-like context object) to be passed in, to simply identify the source of the call (in concert with the caller member name).  A debug-only mechanism is included in the tracing to help find potential perf issues due to misuse of the logger.  Etc.
- A Fail logging operation is included that both traces and does a Debug.Fail.

With these changes, most call sites are greatly simplified.  Some examples:
Before:
```C#
if (GlobalLog.IsEnabled)
{
    GlobalLog.AssertFormat("ContextAwareResult#{0}::ContextCopy|Called on completed result.", LoggingHash.HashString(this));
}
Debug.Fail("ContextAwareResult#" + LoggingHash.HashString(this) + "::ContextCopy |Called on completed result.");
```
After:
```C#
NetEventSource.Fail(this, "Called on completed result.");
```

Before:
```C#
if (NetEventSource.Log.IsEnabled()) NetEventSource.Enter(NetEventSource.ComponentType.Http, this, ".ctor", handler);
```
After:
```C#
NetEventSource.Enter(this, handler);
```

Etc.

In addition to fixing up all of the event sources, I of course also fixed up all usage in order to clean up the call sites.  However, this was a rather mechanical change: I did not remove existing logging (other than duplication) nor did I add new logging.  At some point, we should review the actual logging being done to determine what's missing and what's not needed.  I also did not revise the additional existing events on the sockets and security event sources, but we may want to remove those (or some of those) in favor of just using the shared events.


Commit migrated from https://github.com/dotnet/corefx/commit/92fd5c0814bcc0c03acfa9f3ad857661828b35a6
2016-10-29 10:01:53 -04:00
Cristian Pop 72ad1653c3 Update windows-instructions.md
The debugging extension is now copied in the test folder.

Commit migrated from https://github.com/dotnet/corefx/commit/7fefc299f58813447bf4d621eb2468c085873ead
2016-06-13 16:01:16 -07:00
Cristian Pop ba00fce5af Merge pull request dotnet/corefx#9010 from CIPop/doc
Adding image example for PerfView collection.

Commit migrated from https://github.com/dotnet/corefx/commit/5c85e22115f2b6361af786fd492ea236a2cec3cf
2016-05-31 17:42:59 -07:00
Cristian Pop 7f4c4f31c2 Adding image example for PerfView collection.
Commit migrated from https://github.com/dotnet/corefx/commit/4d8e48407275040ae9e38c14883da2757cd6f07f
2016-05-31 17:05:53 -07:00
Eric St. John 5a444416fd Update tests to use NETCoreApp1.0 moniker
Requires https://github.com/dotnet/buildtools/pull/751

This makes all the tests resolve using NETCoreApp1.0 instead of
DNXCore50.  I've removed the netstandard1.6 import since that is no
longer needed.  I've also removed the workarounds from tests that were
targeting netcoreapp1.0 on their own.  For restore compat I've added an
DNXCore50 import to every test project.  These can be removed once
test-runtime packages are updated to target NETCoreApp1.0.

I've updated all the test scripts which were assuming DNXCore50 as well
as docs which referred to this path.


Commit migrated from https://github.com/dotnet/corefx/commit/7ba4d296e3e0a2445ffa708c1e918d90d2bac69c
2016-05-24 21:49:17 -07:00
Cristian Pop 7b6bded174 Adding logman instructions and System.Net new providers.
Commit migrated from https://github.com/dotnet/corefx/commit/1a2ffc42ee6dd364396af8e4762587853cbc80c9
2016-01-20 10:05:23 -08:00
Cristian Pop 04058dc524 Windows advanced debugging documentation.
Commit migrated from https://github.com/dotnet/corefx/commit/9dda8dfef549658ec53bda7e0aebdbfb5494de2c
2015-11-02 16:13:13 -08:00