Skip to content

Releases: Hawxy/Discord.Addons.Hosting

v3.0.0

14 Jun 13:06
cc65ef9
Compare
Choose a tag to compare

Breaking changes

  • The previous builder has been replaced with a simple action that modifies the host configuration.
//....
.ConfigureDiscordHost<DiscordSocketClient>((context, config) =>
  {
     config.SocketConfig = new DiscordSocketConfig
      {
          LogLevel = LogSeverity.Verbose,
          AlwaysDownloadUsers = true,
          MessageCacheSize = 200
      };

    config.Token = context.Configuration["token"];
  })
  • The experimental Reliability extensions have been removed as Discord.NET's reliability has improved a lot over the last few releases and these extensions were never very, ahem, reliable themselves. Replace RunReliablyAsync() with RunAsync() within your code.
  • Microsoft.Extensions.Hosting v3.1.5 & Discord.NET v2.2.0 are now the minimum supported versions.

Other changes

  • Cancellation is now better handled within the hosted service.
  • IOptions is now used throughout the library, permitting usage of services.Configure<T>() to configure either the host or the command service depending on your scenario.

v2.1.0

14 Nov 11:04
7aee911
Compare
Choose a tag to compare
  • Added the InitializedService base class to cover one-time initialization requirements, see the README for more information.
  • Cleaned up some internal extension logic
  • Fixed a typo in the configuration builder

v2.0.0

10 Oct 08:31
5ff05fe
Compare
Choose a tag to compare

Breaking changes

  • The various configuration calls within the builder for the discord client have been simplified to a single extension:
               .ConfigureDiscordHost<DiscordSocketClient>((context, configurationBuilder) =>
                {
                    configurationBuilder.SetDiscordConfiguration(new DiscordSocketConfig
                    {
                        LogLevel = LogSeverity.Verbose,
                        AlwaysDownloadUsers = true,
                        MessageCacheSize = 200
                    });

                    configurationBuilder.SetToken(context.Configuration["token"]);
                   
                    configurationBuilder.SetCustomLogFormat((message, exception) => $"{message.Source}: {message.Message}");
                })
  • The token's location now needs to manually set via the SetToken() method
  • Microsoft.Extensions.Hosting v3.0.0 is now the minimum supported version

Other changes

  • Host will now handle startup cancellation correctly & exit
  • Added netstandard2.1 target
  • Updated examples to .NET Core 3.0

v1.3.0

10 Feb 04:51
d7d7e88
Compare
Choose a tag to compare
  • Hosted service will now respect the host's shutdown timeout. This fixes issues with deadlocked clients blocking the host from exiting.
  • Discord Client & CommandService are now both logged to the Discord.Client log category

v1.2.1

06 Jan 10:14
Compare
Choose a tag to compare

(v.1.2.0)

  • Change HostedService to be a singleton (.Net Core 3.0 behavior).
  • Update dependencies to .Net Core 2.2
  • Require Discord.Net v2.0.1

(v1.2.1)

  • Fix startup failures in v1.2.0

v1.1.2

25 Nov 09:48
9d36d84
Compare
Choose a tag to compare
  • Cleanup of a few leftover code smells from v1.1.0

v1.1.1

16 Nov 11:51
Compare
Choose a tag to compare
  • Fix a Serilog formatting mistake

v1.1.0

10 Nov 12:08
75af1b2
Compare
Choose a tag to compare
  • Refactor internals and simplify generics - Client must now be or inherit from DiscordSocketClient
  • Add reliability extensions - See github description
  • Fix various issues with event handlers
  • Update package description