Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

json: unknown field "expireAfterSeconds" #44

Closed
SasonBraha opened this issue Feb 16, 2021 · 1 comment
Closed

json: unknown field "expireAfterSeconds" #44

SasonBraha opened this issue Feb 16, 2021 · 1 comment

Comments

@SasonBraha
Copy link

SasonBraha commented Feb 16, 2021

Hi,
I'm trying to generate a collection with TTL Index, but I'm getting this error:

error in configuration file: object / array / Date badly formatted: 

                json: unknown field "expireAfterSeconds"

This is my schema:

[
    {
      "database": "example",
      "collection": "test",
      "count": 1,
      "content": {
        "expireAt": {
          "type": "date",
          "startDate": "2020-01-01T22:00:00+00:00",
          "endDate": "2020-01-05T22:00:00+00:00"
        }
      },
      "indexes": [
            {
                "name": "expireAt_1",
                "key": {
                    "expireAt": 1
                },
                "expireAfterSeconds": 0
            }
        ]
    }
  ]

Thank you.

feliixx added a commit that referenced this issue Feb 17, 2021
fix json parsing for 'expireAfterSeconds' and remove deprecated fields
from doc

closes #44
@feliixx
Copy link
Owner

feliixx commented Feb 17, 2021

Hi @SasonBraha , I've just released a new version which should fix the issue: v0.8.5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants