Skip to content

Releases: justtrackio/gosoline

v0.26.4

16 Oct 12:47
v0.26.4
38395b6
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.26.3...v0.26.4

v0.26.3

15 Oct 11:16
Compare
Choose a tag to compare

Currently, fixture loaders will get created, even if the fixture loading is disabled in the config.
In certain scenarios this could cause issues.
To improve it, this release ensures, that the fixture loading middleware does nothing if disabled.

What's Changed

  • fixtures: on disabled fixtures, the middleware will do nothing now by @j4k4 in #1165

Full Changelog: v0.26.2...v0.26.3

v0.26.2

11 Oct 19:00
v0.26.2
Compare
Choose a tag to compare

What's Changed

  • feat: Implement atomic mutates on the cache; by @bt-justtrack in #1161
  • fix: Implement restartability on producer daemon without reset; by @bt-justtrack in #1160
  • test: added option to disable all custom consumer retries by @j4k4 in #1159

Full Changelog: v0.26.1...v0.26.2

v0.26.1

07 Oct 14:18
v0.26.1
054d2b2
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.26.0...v0.26.1

v0.26.0

02 Oct 10:21
Compare
Choose a tag to compare

This release contains a couple of minor and major changes:

cloud/aws: unified default credentials config and added profile load option #1155

unified default credentials config

before:

cloud:
  aws:
    credentials:
      access_key_id: "*******************"
      secret_access_key: "****************************************"
      session_token: "********************************************************************"
    defaults:
      region: "eu-central-1"
      endpoint: ""

after:

cloud:
  aws:
    defaults:
      credentials:
        access_key_id: "justtrack"
        secret_access_key: "justtrack"
        session_token: "justtrack"
      endpoint: "http://localhost:4566"
      region: "eu-central-1"

added option to gain access via aws profile

It's possible now to use sso credentials via profiles. This can be done via global default or client specific.

cloud:
  aws:
    defaults:
      profile: "sdlc-dev-account"
    cloudwatch:
      clients:
        default:
          profile: "sdlc-dev-account"

ref: https://aws.github.io/aws-sdk-go-v2/docs/configuring-sdk/#specifying-profiles

EndpointResolver V1 deprecation

v1 of the endpoint resolver got deprecated and the code was migrated to use the v2. Resolving the endpoint has to be configured on client level in the code now. This change should be transparent for most of the gosoline use cases.
ref: https://aws.github.io/aws-sdk-go-v2/docs/configuring-sdk/endpoints/#customization

log/mocks: Refactored logger mock factory by adding options and changed return value to interface #1148

Deprecated NewLoggerMockedAll and NewLoggerMockedUntilLevel and replaced them with options to NewLoggerMock with the options WithMockUntilLevel and WithMockAll. Also added the WithTestingT
option to supply a testing.T instance to the logger, allowing for automatic expectation assertions and printing recorded log messages if a test fails for easier debugging.

This commit also breaks backwards compatibility by changing the return value of these methods to the new LoggerMock interface, so if you store the mock in a field of a test suite or similar, you need to adjust the type.

mdlsub: http source based fixture writer for subscribers #1154

fixture groups

On adding fixtures sets to an application, one has to define the group into which the data belongs as the first argument. \

app := application.Default(
    application.WithFixtureSetFactory("default", fixtureSetsFactory),
)

The default group is loaded on default and can be defined in the config:

fixtures:
  enabled: true
  groups: ["default"]

subscriber fixture loading

The mdlsub contains a FixtureSetFactory now which enables fixture loading for subscribers via http endpoints.
On subscriber start the app will request the fixtures via http and persists the data into the configured outputs.

application.RunMdlSubscriber(
    subscribers.Transformers,
    application.WithFixtureSetFactory("subscriber", mdlsub.FixtureSetFactory(subscribers.Transformers)),
)

The source is set via config:

fixtures:
  enabled: true
  groups: ["subscriber"]
  providers:
    subscriber:
      host: http://fixtures.io
      path: /v0/fixtures/subscriber
      dataset_name: management

What's Changed

  • cloud/aws: unified default credentials config and added profile load option by @j4k4 in #1155
  • db: provide connection for db settings instead of spawning a new one by @applike-ss in #1156
  • log/mocks: Refactored logger mock factory by adding options and changed return value to interface by @ajscholl in #1148
  • mdlsub: http source based fixture writer for subscribers by @j4k4 in #1154

Full Changelog: v0.25.1...v0.26.0

fixtures: changed AutoNumbered type to NumberSequence and added ByteSequence and UuidSequence types

24 Sep 08:10
Compare
Choose a tag to compare

To generate deterministic fixtures, we already had the AutoNumbered helper type. It now has been renamed to NumberSequence and two new helpers called ByteSequence and UuidSequence have been added. Both are initialized with a seed and generate random bytes and UUIDs (v4) respectively. The intended use case for them is to avoid using uuid.New().NewV4() in fixtures without needing to hard code a lot of values.

To ease the transition, AutoNumbered has been converted into a deprecated type alias and will be removed soon, but this should therefore not be a breaking change.

v0.25.0

16 Sep 11:09
Compare
Choose a tag to compare

In this release we've added a basic aws secretsmanager client for handling secrets (via GetSecretValue and UpdateSecret)

fixtures: remove pointer receiver from NamedFixtures and allow purging tables which don't exist (yet) in ddb

12 Sep 12:41
Compare
Choose a tag to compare

When purging a table in ddb, we delete and re-create it. However, this currently fails if the table doesn't exist yet. As deleting a non-existing table achieves our goal (of the table no longer existing), we don't need to treat this as an error.

Additionally, removing the pointer receiver from fixtures.NamedFixtures allows for easier usage of the type without impacting performance too much (if at all).

fixtures: removed redundant type declarations for kvstore fixtures

06 Sep 08:10
Compare
Choose a tag to compare

This release adds some small simplification for the kvstore fixtureset factories by removing a redundant type declaration.
In addition, we added 2 little helper to create named fixtures.

v0.24.1

04 Sep 09:53
Compare
Choose a tag to compare

This is a bugfix release for v0.24.0, which refactored the fixtures package.

The following signatures required adjustments after this refactoring, to allow specifying the underlying kvstore fixture value type:

  • fixtures.ConfigurableKvStoreFixtureSetFactory
  • fixtures.DynamoDbKvStoreFixtureSetFactory
  • fixtures.RedisKvStoreFixtureSetFactory