github gofr-dev/gofr v1.50.1

one day ago

Release v1.50.1

🚀 Enhancements

🔹 TLS / SSL Support for Database Connections

GoFr now supports secure TLS/SSL connections for relational databases(MySQL / MariaDB/PostgreSQL), improving security and compliance for production deployments.

  • New configuration DB_SSL_MODE with supported modes:

    • disable, preferred, require, skip-verify, verify-ca, verify-full
  • New environment variables for TLS configuration:

    • DB_TLS_CA_CERT

    • DB_TLS_CLIENT_CERT

    • DB_TLS_CLIENT_KEY

  • verify-ca and verify-full modes enforce CA certificate validation

  • Mutual TLS (mTLS) supported via client certificate & key

  • Refer Documentation : Tracing In GoFr for more info.


🔹 Custom Authentication Headers for Tracing Exporters

GoFr now allows configuring custom authentication headers for OpenTelemetry exporters, enabling better compatibility with hosted observability platforms.

Key Highlights:

  • New configuration: TRACER_HEADERS

    • Accepts comma-separated key=value pairs

    • Example: X-Api-Key=secret,Authorization=Bearer token

  • TRACER_HEADERS takes priority over the existing TRACER_AUTH_KEY

  • Refer Documentation : Connecting MySQL for more info.

🛠️ Fixes

🔹 Mock HTTP Services Deduplication in Tests

Fixed an issue where registering multiple mock HTTP services could result in deduplication, causing missing mocks and lost expectations during tests.

Fix Details:

  • Each service registered via WithMockHTTPService(...) now receives a distinct mock instance

  • Expectations must be set per service using: mocks.HTTPServices["serviceName"]

  • Refer Documentation : Testing in GoFr for more info.

Don't miss a new gofr release

NewReleases is sending notifications on new releases.