Skip to content
This repository has been archived by the owner on Apr 2, 2024. It is now read-only.

Add struct tags to dataset config objects #1807

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

nhudson
Copy link
Contributor

@nhudson nhudson commented Dec 20, 2022

Description

This change adds the struct tags around the dataset.Config{} struct so we can use this as an external config validator. Without this you will get the following error when trying to Unmarshal data into the struct.

/Users/nhudson/.go/pkg/mod/github.com/timescale/promscale@v0.0.0-20221220155011-19d8e3e51658/pkg/dataset/config.go:39:2: encountered struct field "" without JSON tag in type "Config"
/Users/nhudson/.go/pkg/mod/github.com/timescale/promscale@v0.0.0-20221220155011-19d8e3e51658/pkg/dataset/config.go:40:2: encountered struct field "" without JSON tag in type "Config"

Merge requirements

Please take into account the following non-code changes that you may need to make with your PR:

  • CHANGELOG entry for user-facing changes
  • Updated the relevant documentation

@nhudson nhudson self-assigned this Dec 20, 2022
@nhudson nhudson force-pushed the nhudson/add_struct_tags branch 2 times, most recently from a26f1f2 to 20f330f Compare December 20, 2022 19:58
@nhudson nhudson marked this pull request as ready for review December 20, 2022 20:00
@nhudson nhudson requested a review from a team as a code owner December 20, 2022 20:00
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants