All Versions
26
Latest Version
Avg Release Cycle
14 days
Latest Release
1267 days ago

Changelog History
Page 2

  • v2.10.1 Changes

    May 09, 2020
    • ๐Ÿ”„ Changed the behavior of response.File() and response.Download() to respond with a status 404 if the given file doesn't exist instead of panicking.
    • ๐Ÿ‘Œ Improved error handling:
      • log.Panicf is not used anymore to print panics, removing possible duplicate logs.
      • Added error checks during automatic migrations.
      • goyave.Start() now exits the program with the following error codes:
      • 2: Panic (server already running, error when loading language files, etc)
      • 3: Configuration is invalid
      • 4: An error occurred when opening network listener
      • 5: An error occurred in the HTTP server

    ๐Ÿ‘ This change will require a slightly longer main function but offers better flexibility for error handling and multi-services.

    if err := goyave.Start(route.Register); err != nil { os.Exit(err.(\*goyave.Error).ExitCode) }
    
    • ๐Ÿ›  Fixed a bug in TestSuite: HTTP client was re-created everytime getHTTPClient() was called.
    • ๐Ÿ›  Fixed testing documentation examples that didn't close http response body.
    • ๐Ÿ“š Documentation meta improvements.
    • Protect JSON requests with maxUploadSize.
    • ๐Ÿ”ง The server will now automatically return 413 Payload Too Large if the request's size exceeds the maxUploadSize defined in configuration.
    • ๐Ÿ“œ The request parsing middleware doesn't drain the body anymore, improving native handler compatibility.
    • 0๏ธโƒฃ Set a default status handler for all 400 errors.
    • ๐Ÿ›  Fixed a bug preventing query parameters to be parsed when the request had the Content-Type: application/json header.
    • โž• Added a dark theme for the documentation. It can be toggled by clicking the moon icon next to the search bar.
  • v2.10.0 Changes

    April 23, 2020
    • โž• Added router Get, Post, Put, Patch, Delete and Options methods to register routes directly without having to specify a method string.
    • โž• Added placeholder support in regular language lines.
  • v2.9.0 Changes

    April 08, 2020
    • โž• Added hidden fields.
    • ๐Ÿšš Entirely removed Gorilla mux. This change is not breaking: native middleware still work the same.
  • v2.8.0 Changes

    March 25, 2020
    • โž• Added a built-in logging system.
      • Added a middleware for access logs using the Common Log Format or Combined Log Format. This allows custom formatters too.
      • Added three standard loggers: goyave.Logger, goyave.AccessLogger and goyave.ErrLogger
    • ๐Ÿ›  Fixed bug: the gzip middleware now closes underlying writer on close.
  • v2.7.1 Changes

    March 12, 2020
    • ๐Ÿ”„ Changed MIME type of js and mjs files to text/javascript. This is in accordance with an IETF draft that treats application/javascript as obsolete.
    • ๐Ÿ‘Œ Improved error handling: stacktrace wasn't relevant on unexpected panic since it was retrieved from the route's request handler therefore not including the real source of the panic. Stacktrace retrieval has been moved to the recovery middleware to fix this.
  • v2.7.0 Changes

    February 23, 2020
    • โž• Added Request.Request() accessor to get the raw *http.Request.
    • ๐Ÿ›  Fixed a bug allowing non-core middleware applied to the root router to be executed when the "Not Found" or "Method Not Allowed" routes were matched.
    • ๐Ÿ›  Fixed a bug making route groups (sub-routers with empty prefix) conflict with their parent router when two routes having the same path but different methods are registered in both routers.
    • โž• Added chained writers.
    • โž• Added gzip compression middleware.
    • โž• Added the ability to register route-specific middleware in Router.Static().
  • v2.6.0 Changes

    February 19, 2020
    • Custom router implementation. Goyave is not using gorilla/mux anymore. The new router is twice as fast and uses about 3 times less memory.
    • ๐Ÿ”ง Now redirects to configured protocol if request scheme doesn't match.
    • โž• Added named routes.
    • โž• Added Route.GetFullURI() and Route.BuildURL() for dynamic URL generation.
    • โž• Added helper.IndexOfStr() and helper.ContainsStr() for better performance when using string slices.
    • ๐Ÿšš Moved from GoDoc to pkg.go.dev.
    • ๐Ÿ–จ Print errors to stderr.
  • v2.5.0 Changes

    February 05, 2020
    • โž• Added an authentication system.
    • Various optimizations.
    • ๐Ÿ“š Various documentation improvements.
    • โž• Added dbMaxLifetime configuration entry.
    • ๐Ÿ‘ท Moved from Travis CI to Github Actions.
    • ๐Ÿ›  Fixed a bug making duplicate log entries on error.
    • ๐Ÿ›  Fixed a bug preventing language lines containing a dot to be retrieved.
    • ๐Ÿ›  Fixed TestSuite.GetJSONBody() not working with structs and slices.
    • โž• Added TestSuite.ClearDatabaseTables().
    • โž• Added Config.Has() and Config.Register() to check for the existence of a config entry and to allow custom config entries valdiation.
    • โž• Added Request.BearerToken().
    • โž• Added Response.HandleDatabaseError() for easier database error handling and shorter controller handlers.
  • v2.4.3 Changes

    January 15, 2020
    • ๐Ÿ‘Œ Improved string validation by taking grapheme clusters into consideration when calculating length.
    • 0๏ธโƒฃ lang.LoadDefault now correctly creates a fresh language map and clones the default en-US language. This avoids the default language entries to be overridden permanently.
  • v2.4.2 Changes

    January 11, 2020
    • Don't override Content-Type header when sending a file if already set.
    • ๐Ÿ›  Fixed a bug with validation message placeholder :values, which was mistakenly using the :value placeholder.