Commit graph

210 commits

Author SHA1 Message Date
Bond_009 1c74e2f40e Fix build 2021-02-24 02:57:10 +01:00
Bond_009 1ea2b200c0 JsonSerializer deserialize from bytes where possible
This is faster and uses way less memory
```
BenchmarkDotNet=v0.12.1, OS=fedora 32
Intel Core i7-6700HQ CPU 2.60GHz (Skylake), 1 CPU, 8 logical and 4 physical cores
.NET Core SDK=5.0.100
  [Host]     : .NET Core 5.0.0 (CoreCLR 5.0.20.51904, CoreFX 5.0.20.51904), X64 RyuJIT
  DefaultJob : .NET Core 5.0.0 (CoreCLR 5.0.20.51904, CoreFX 5.0.20.51904), X64 RyuJIT

| Method |     Mean |   Error |  StdDev |   Gen 0 | Gen 1 | Gen 2 | Allocated |
|------- |---------:|--------:|--------:|--------:|------:|------:|----------:|
|  Bytes | 158.4 us | 2.56 us | 2.14 us | 16.8457 |     - |     - |  52.08 KB |
| String | 172.8 us | 0.78 us | 0.70 us | 41.5039 |     - |     - | 127.82 KB |
| Custom | 155.5 us | 2.95 us | 2.76 us | 10.0098 |     - |     - |  31.27 KB |
```
2021-01-12 15:28:02 +01:00
David 3dec1fd6b2 Use UTF8 encoding and async correctly 2020-12-29 00:35:59 +01:00
David 21fd124bca Code revie 2020-12-27 11:15:46 +01:00
David f73bb92ce3 Remove manual N/A removal and write directly to stream 2020-12-26 20:00:54 +01:00
David 043d045448 Put json serializer options in private field 2020-12-24 11:22:34 +01:00
David e835dfb27d Use sync string instead of file 2020-12-24 10:31:51 +01:00
David 2a574914ea Use streams instead of strings 2020-12-23 19:24:58 +01:00
David 196388d607 Remove custom Json serializer from Emby.Server.Implementations 2020-12-23 13:14:40 +01:00
Fernando Fernández e21e00cad5 Merge remote-tracking branch 'upstream/master' into no-scaling 2020-11-19 23:18:25 +01:00
Fernando Fernández 38c3b6fcd3 Fix build and thread detection logic 2020-11-18 10:20:59 +01:00
Bond_009 4b1c9dc9ea Pass cancellation where possible 2020-11-17 19:43:00 +01:00
Fernando Fernández 94cae4f145 Specify threads to ffmpeg properly 2020-11-17 16:44:04 +01:00
Bond_009 49569ca0a0 Use nameof where possible 2020-10-17 16:19:57 +02:00
crobibero 23df4991b6 Use proper buffer size 2020-09-04 08:24:21 -06:00
crobibero 2a8653b309 Merge remote-tracking branch 'upstream/master' into http-client-migrate 2020-09-04 08:16:49 -06:00
crobibero 4038d15c83 Properly migrate all HttpCompletionOption 2020-09-01 07:51:06 -06:00
Bond_009 e653eef44f Fix some warnings 2020-08-31 22:20:19 +02:00
crobibero 8d592777c4 change to using declaration 2020-08-31 12:46:42 -06:00
crobibero 50a1e35765 migrate to IHttpClientFactory in EmbyTV 2020-08-31 11:39:40 -06:00
crobibero 804b0fc034 migrate to IHttpClientFactory in DirectRecorder 2020-08-31 11:38:47 -06:00
Patrick Barron 9fa4fff15d Merge branch 'master' into event-rewrite-1
# Conflicts:
#	Emby.Dlna/Emby.Dlna.csproj
#	Emby.Dlna/Eventing/DlnaEventManager.cs
#	Emby.Dlna/Service/BaseService.cs
#	Emby.Server.Implementations/ScheduledTasks/ScheduledTaskWorker.cs
#	MediaBrowser.Controller/Subtitles/SubtitleDownloadEventArgs.cs
2020-08-24 20:04:13 -04:00
Bond_009 ab2147751f Make MediaBrowser.MediaEncoding warnings free 2020-08-20 12:16:24 +02:00
Bond_009 2b400c99ef Fix warnings 2020-08-19 17:50:50 +02:00
Patrick Barron ca1f15af19 Move GenericEventArgs to Jellyfin.Data.Events 2020-08-13 20:52:55 -04:00
Patrick Barron ab396225ea Migrate Display Preferences to EF Core 2020-07-17 16:11:53 -04:00
telans 3d9049ef08
fix SA1508 2020-06-15 10:45:55 +12:00
telans acd4389653
fix SA1005 2020-06-15 10:41:00 +12:00
telans 726e116d5b
fix SA1510 2020-06-15 10:40:57 +12:00
dkanada 403cd3205f
Merge pull request #3254 from crobibero/ilogger
Use typed logger where possible
2020-06-13 00:29:43 +09:00
aled 22a860a806 Fix a small number of compile warnings 2020-06-06 20:17:49 +01:00
crobibero 44957c5a9a Use typed logger where possible 2020-06-05 18:15:56 -06:00
Vasily 668e10ceb7
Merge pull request #2767 from Bond-009/nullable3
Enable nullabe reference types for MediaBrowser.Model
2020-06-03 12:26:54 +03:00
Bond_009 7439e095e2 Merge branch 'master' into nullable3 2020-05-27 20:49:18 +02:00
Bond_009 10e381f66f Fix some 'bugs' flagged by sonarcloud 2020-05-25 23:52:51 +02:00
Mark Monteiro 43c22a5822 Add GetLoopbackHttpApiUrl() helper method to replace forceHttps functionality
Also refactor to use return a Uri instead of a string and use UriBuilder under the hood
2020-05-10 14:36:11 -04:00
Bond_009 fc049caba2 Merge branch 'master' into nullable3 2020-04-15 11:09:14 +02:00
Mark Monteiro 4113288278 Fix style issues 2020-04-11 13:46:31 -04:00
Mark Monteiro 7152b55747 Use a separate line for each property initializer 2020-04-11 13:28:21 -04:00
Bond_009 30ce346f34 Enable nullabe reference types for MediaBrowser.Model 2020-04-05 18:10:56 +02:00
Mark Monteiro 658e963e93 replace 'try-finally' with 'using' where appropriate 2020-04-05 09:23:44 -04:00
Mark Monteiro e0f40f57d8 Merge remote-tracking branch 'upstream/master' into remove-common-process 2020-04-03 20:22:03 -04:00
Bond_009 2be394089e Enable Microsoft.CodeAnalysis.FxCopAnalyzers for Jellyfin.Common 2020-04-02 20:12:18 +02:00
Bond_009 3ab50f5a3f Address comments 2020-04-01 19:05:41 +02:00
Mark Monteiro 7447ea8960 Make sure Process objects are all disposed correctly 2020-03-27 00:49:22 +01:00
Mark Monteiro b947d98266 Delete unnecessary ProcessFactory abstraction 2020-03-27 00:45:48 +01:00
Mark Monteiro ee2f911a2b Remove unnecessary CommonProcess abstraction 2020-03-27 00:10:16 +01:00
Bond-009 94fe9b8f6d
Merge branch 'master' into warn17 2020-03-11 20:26:43 +01:00
Mark Monteiro b67e9cde8c Replace ILogger with ILogger<T> wherever possible
Log entries will contain additional class context when using this interface
2020-03-03 23:07:10 +01:00
Bond_009 07cc4be6a7 Fix some warnings
* Add analyzers to MediaBrowser.XbmcMetadata
* Enable TreatWarningsAsErrors for MediaBrowser.XbmcMetadata
* Add analyzers to MediaBrowser.WebDashboard
* Enable TreatWarningsAsErrors for MediaBrowser.WebDashboard
* Disable SA1600 in favor of CS1591
2020-02-23 12:11:43 +01:00