Fast json for go. Lightweight fork of jsoniter.

Related tags

JSON go golang json
Overview

jx Go Reference codecov

Fast json for go. Lightweight fork of jsoniter.

Features

  • Reduced scope (no reflection or encoding/json adapter)
  • Fuzzing, improved test coverage
  • Drastically refactored and simplified
    • Explicit error returns
    • No Config or API

Capture

The Decoder.Capture method allows to unread everything is read in callback. This is useful for multi-pass parsing:

func TestDecoder_Capture(t *testing.T) {
	d := DecodeString(`["foo", "bar", "baz"]`)
	var elems int
	if err := d.Capture(func(d *Reader) error {
		return d.Arr(func(d *Reader) error {
			elems++
			return d.Skip()
		})
	}); err != nil {
		t.Fatal(err)
	}
	// Buffer is rolled back to state before "Capture" call:
	require.Equal(t, Array, d.Next())
	require.Equal(t, 3, elems)
}

ObjectBytes

The Decoder.ObjectBytes method tries not to allocate memory for keys, reusing existing buffer:

d := DecodeString(`{"id":1,"randomNumber":10}`)
d.ObjectBytes(func(d *Decoder, key []byte) error {
    switch string(key) {
    case "id":
    case "randomNumber":
    }
    return d.Skip()
})
Comments
  • chore(deps): bump github.com/go-faster/errors from 0.5.0 to 0.6.0

    chore(deps): bump github.com/go-faster/errors from 0.5.0 to 0.6.0

    Bumps github.com/go-faster/errors from 0.5.0 to 0.6.0.

    Release notes

    Sourced from github.com/go-faster/errors's releases.

    v0.6.0

    What's Changed

    New Contributors

    Full Changelog: https://github.com/go-faster/errors/compare/v0.5.0...v0.6.0

    Commits
    • fa67b69 Merge pull request #19 from tdakkota/feat/add-into-and-must
    • b53f5de feat: add Into and Must generic helpers
    • bef5a9b chore: bump Go version requirement to 1.18
    • 01fe582 ci: use x
    • 244984d Merge pull request #18 from go-faster/dependabot/github_actions/wagoid/commit...
    • bb5994e build(deps): bump wagoid/commitlint-github-action from 4.1.10 to 4.1.11
    • f7f0b01 Merge pull request #17 from go-faster/dependabot/github_actions/codecov/codec...
    • b9aa4bf build(deps): bump codecov/codecov-action from 2.1.0 to 3
    • 246ca19 Merge pull request #16 from go-faster/dependabot/github_actions/wagoid/commit...
    • 455cae5 build(deps): bump wagoid/commitlint-github-action from 4.1.9 to 4.1.10
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies go 
    opened by dependabot[bot] 2
  • feat: array iterator

    feat: array iterator

    name                     time/op
    DecodeBools/Callback-12   1.67µs ± 3%
    DecodeBools/Iterator-12   1.47µs ± 1%
    
    name                     speed
    DecodeBools/Callback-12  574MB/s ± 3%
    DecodeBools/Iterator-12  651MB/s ± 2%
    
    opened by tdakkota 2
  • feat: improve string encoding

    feat: improve string encoding

    Benchstat result:

    name                           old time/op    new time/op    delta
    EncoderBigObject-12              7.56µs ± 2%    4.01µs ± 1%  -46.97%  (p=0.000 n=10+10)
    Encoder_Field/1/Manual-12        20.6ns ± 2%    18.6ns ± 0%   -9.83%  (p=0.000 n=10+9)
    Encoder_Field/1/Callback-12      26.2ns ± 5%    24.8ns ± 5%   -5.20%  (p=0.034 n=10+10)
    Encoder_Field/5/Manual-12        84.3ns ± 1%    81.9ns ± 0%   -2.89%  (p=0.000 n=10+9)
    Encoder_Field/5/Callback-12       112ns ± 4%     126ns ± 1%  +12.43%  (p=0.000 n=10+10)
    Encoder_Field/10/Manual-12        173ns ± 1%     150ns ± 0%  -13.15%  (p=0.000 n=10+9)
    Encoder_Field/10/Callback-12      200ns ± 2%     182ns ± 1%   -9.30%  (p=0.000 n=9+10)
    Encoder_Field/100/Manual-12      1.62µs ± 1%    1.39µs ± 0%  -13.91%  (p=0.000 n=10+9)
    Encoder_Field/100/Callback-12    1.86µs ± 1%    1.65µs ± 0%  -11.15%  (p=0.000 n=10+10)
    
    name                           old speed      new speed      delta
    EncoderBigObject-12             674MB/s ± 2%  1271MB/s ± 1%  +88.57%  (p=0.000 n=10+10)
    
    opened by tdakkota 2
  • chore(deps): bump actions/cache from 2.1.6 to 2.1.7

    chore(deps): bump actions/cache from 2.1.6 to 2.1.7

    Bumps actions/cache from 2.1.6 to 2.1.7.

    Release notes

    Sourced from actions/cache's releases.

    v2.1.7

    Support 10GB cache upload using the latest version 1.0.8 of @actions/cache

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies github_actions 
    opened by dependabot[bot] 2
  • chore(deps): bump github.com/stretchr/testify from 1.8.0 to 1.8.1

    chore(deps): bump github.com/stretchr/testify from 1.8.0 to 1.8.1

    Bumps github.com/stretchr/testify from 1.8.0 to 1.8.1.

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies go 
    opened by dependabot[bot] 1
  • chore(deps): bump github.com/stretchr/testify from 1.7.5 to 1.8.0

    chore(deps): bump github.com/stretchr/testify from 1.7.5 to 1.8.0

    Bumps github.com/stretchr/testify from 1.7.5 to 1.8.0.

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies go 
    opened by dependabot[bot] 1
  • chore(deps): bump github.com/stretchr/testify from 1.7.4 to 1.7.5

    chore(deps): bump github.com/stretchr/testify from 1.7.4 to 1.7.5

    Bumps github.com/stretchr/testify from 1.7.4 to 1.7.5.

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies go 
    opened by dependabot[bot] 1
  • fix: parse Num correctly

    fix: parse Num correctly

    name                         old time/op    new time/op    delta
    Decoder_Num/Number/Buffer-4    36.1ns ± 2%    41.4ns ± 2%   +14.55%  (p=0.000 n=15+15)
    Decoder_Num/Number/Reader-4     112ns ± 4%     181ns ± 2%   +62.01%  (p=0.000 n=14+15)
    Decoder_Num/String/Buffer-4    43.7ns ± 5%    55.1ns ± 1%   +26.15%  (p=0.000 n=14+13)
    Decoder_Num/String/Reader-4     142ns ± 1%      75ns ± 6%   -47.13%  (p=0.000 n=13+13)
    
    name                         old alloc/op   new alloc/op   delta
    Decoder_Num/Number/Buffer-4     0.00B          0.00B           ~     (all equal)
    Decoder_Num/Number/Reader-4     16.0B ± 0%     64.0B ± 0%  +300.00%  (p=0.000 n=15+15)
    Decoder_Num/String/Buffer-4     0.00B          0.00B           ~     (all equal)
    Decoder_Num/String/Reader-4     24.0B ± 0%      0.0B       -100.00%  (p=0.000 n=15+15)
    
    name                         old allocs/op  new allocs/op  delta
    Decoder_Num/Number/Buffer-4      0.00           0.00           ~     (all equal)
    Decoder_Num/Number/Reader-4      1.00 ± 0%      2.00 ± 0%  +100.00%  (p=0.000 n=15+15)
    Decoder_Num/String/Buffer-4      0.00           0.00           ~     (all equal)
    Decoder_Num/String/Reader-4      2.00 ± 0%      0.00       -100.00%  (p=0.000 n=15+15)
    
    opened by tdakkota 1
  • chore(deps): bump github.com/stretchr/testify from 1.7.2 to 1.7.4

    chore(deps): bump github.com/stretchr/testify from 1.7.2 to 1.7.4

    Bumps github.com/stretchr/testify from 1.7.2 to 1.7.4.

    Commits
    • 48391ba Fix panic in AssertExpectations for mocks without expectations (#1207)
    • 840cb80 arrays value types in a zero-initialized state are considered empty (#1126)
    • 07dc7ee Bump actions/setup-go from 3.1.0 to 3.2.0 (#1191)
    • c33fc8d Bump actions/checkout from 2 to 3 (#1163)
    • 3c33e07 Added Go 1.18.1 as a build/supported version (#1182)
    • e2b56b3 Bump github.com/stretchr/objx from 0.1.0 to 0.4.0
    • See full diff in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies go 
    opened by dependabot[bot] 1
  • chore(deps): bump github.com/stretchr/testify from 1.7.1 to 1.7.2

    chore(deps): bump github.com/stretchr/testify from 1.7.1 to 1.7.2

    Bumps github.com/stretchr/testify from 1.7.1 to 1.7.2.

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies go 
    opened by dependabot[bot] 1
  • chore(deps): bump github.com/segmentio/asm from 1.1.5 to 1.2.0

    chore(deps): bump github.com/segmentio/asm from 1.1.5 to 1.2.0

    Bumps github.com/segmentio/asm from 1.1.5 to 1.2.0.

    Release notes

    Sourced from github.com/segmentio/asm's releases.

    v1.2.0

    What's Changed

    Full Changelog: https://github.com/segmentio/asm/compare/v1.1.5...v1.2.0

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies go 
    opened by dependabot[bot] 1
  • idea: provide fast encoders and decoders for popular types

    idea: provide fast encoders and decoders for popular types

    Provide fast decoder for UUIDs, time.Time, netip.IP, etc. May be useful for ogen purposes.

    See encoding/decoding optimization for UUID https://github.com/ogen-go/ogen/pull/98.

    enhancement 
    opened by tdakkota 0
  • test: cleanup

    test: cleanup

    • [x] Use Go test naming convention (TestDecoder_Skip instead of Test_skip)
    • [ ] Unify benchmarks and delete duplicates (BenchmarkValid vs BenchmarkSkip)
    • [x] Populate testdata with different cases (real world objects, big array of primitives, use some benchmark sets)
      • #12 (added floats.json)
      • #15 (added small/medium/large/etc)
      • #18 (added bools.json and nulls.json)
      • https://github.com/go-faster/jx/commit/e00d36c7cc43d995161f8cc4aca458573bdd3bb5 (added corpus from JSONTestSuite)
    • [x] Use table tests, generate cases for in-memory and streaming decoding
    good first issue 
    opened by tdakkota 0
Releases(v0.40.0)
  • v0.40.0(Oct 6, 2022)

    What's Changed

    • feat: add 8/16-bit integers decoder by @tdakkota in https://github.com/go-faster/jx/pull/66

    Full Changelog: https://github.com/go-faster/jx/compare/v0.39.0...v0.40.0

    Source code(tar.gz)
    Source code(zip)
  • v0.39.0(Aug 7, 2022)

    What's Changed

    • ci: they finally did it by @tdakkota in https://github.com/go-faster/jx/pull/64
    • chore: drop go1.17 by @ernado in https://github.com/go-faster/jx/pull/65

    Full Changelog: https://github.com/go-faster/jx/compare/v0.38.1...v0.39.0

    Source code(tar.gz)
    Source code(zip)
  • v0.38.1(Jul 15, 2022)

    What's Changed

    • fix: do not reference buffer for key if decoder is buffered by @tdakkota in https://github.com/go-faster/jx/pull/63
    • test(fuzz): add FuzzDecEncReader by @ernado in https://github.com/go-faster/jx/pull/62

    Full Changelog: https://github.com/go-faster/jx/compare/v0.38.0...v0.38.1

    Source code(tar.gz)
    Source code(zip)
  • v0.38.0(Jun 24, 2022)

    What's Changed

    • chore(deps): bump github.com/stretchr/testify from 1.7.4 to 1.7.5 by @dependabot in https://github.com/go-faster/jx/pull/60
    • fix: parse Num correctly by @tdakkota in https://github.com/go-faster/jx/pull/59

    Full Changelog: https://github.com/go-faster/jx/compare/v0.37.0...v0.38.0

    Source code(tar.gz)
    Source code(zip)
  • v0.37.0(Jun 21, 2022)

    What's Changed

    • test: ensure correct behaviour of Raw and Capture used together by @tdakkota in https://github.com/go-faster/jx/pull/54
    • feat: reduce streaming Raw memory usage by @tdakkota in https://github.com/go-faster/jx/pull/55
    • chore(deps): bump github.com/stretchr/testify from 1.7.2 to 1.7.4 by @dependabot in https://github.com/go-faster/jx/pull/56
    • fix: handling io.EOF error by @tdakkota in https://github.com/go-faster/jx/pull/57

    Full Changelog: https://github.com/go-faster/jx/compare/v0.36.0...v0.37.0

    Source code(tar.gz)
    Source code(zip)
  • v0.36.0(Jun 14, 2022)

    What's Changed

    • chore(deps): bump github.com/stretchr/testify from 1.7.1 to 1.7.2 by @dependabot in https://github.com/go-faster/jx/pull/52
    • feat: add Raw support for reader by @tdakkota in https://github.com/go-faster/jx/pull/53

    Full Changelog: https://github.com/go-faster/jx/compare/v0.35.2...v0.36.0

    Source code(tar.gz)
    Source code(zip)
  • v0.35.2(May 31, 2022)

    What's Changed

    • fix: support go1.17 by @ernado in https://github.com/go-faster/jx/pull/51

    Full Changelog: https://github.com/go-faster/jx/compare/v0.35.1...v0.35.2

    Source code(tar.gz)
    Source code(zip)
  • v0.35.1(May 29, 2022)

  • v0.35.0(May 16, 2022)

    What's Changed

    • chore(deps): bump github.com/segmentio/asm from 1.1.3 to 1.1.4 by @dependabot in https://github.com/go-faster/jx/pull/44
    • chore(deps): bump github.com/segmentio/asm from 1.1.4 to 1.1.5 by @dependabot in https://github.com/go-faster/jx/pull/45
    • chore(deps): bump github.com/segmentio/asm from 1.1.5 to 1.2.0 by @dependabot in https://github.com/go-faster/jx/pull/46
    • feat: add object iterator by @tdakkota in https://github.com/go-faster/jx/pull/48

    Full Changelog: https://github.com/go-faster/jx/compare/v0.34.0...v0.35.0

    Source code(tar.gz)
    Source code(zip)
  • v0.34.0(Apr 6, 2022)

    What's Changed

    • feat: add byte slice as JSON string writer by @tdakkota in https://github.com/go-faster/jx/pull/43

    Full Changelog: https://github.com/go-faster/jx/compare/v0.33.0...v0.34.0

    Source code(tar.gz)
    Source code(zip)
  • v0.33.0(Mar 26, 2022)

    What's Changed

    • test: add testcases from stdlib for float parser by @tdakkota in https://github.com/go-faster/jx/pull/37
    • feat: array iterator by @tdakkota in https://github.com/go-faster/jx/pull/33
    • chore(deps): bump github.com/stretchr/testify from 1.7.0 to 1.7.1 by @dependabot in https://github.com/go-faster/jx/pull/38
    • feat: reduce float decoding allocations by using unsafe by @tdakkota in https://github.com/go-faster/jx/pull/39
    • feat: use number set to speed up number parsing by @tdakkota in https://github.com/go-faster/jx/pull/40
    • feat: improve float decoding layout, add more float benchmarks by @tdakkota in https://github.com/go-faster/jx/pull/41
    • test: use integers.json file to benchmark integer decoder by @tdakkota in https://github.com/go-faster/jx/pull/42

    Full Changelog: https://github.com/go-faster/jx/compare/v0.32.2...v0.33.0

    Source code(tar.gz)
    Source code(zip)
  • v0.32.2(Feb 22, 2022)

    What's Changed

    • fix: do not unread, if next was failed by @tdakkota in https://github.com/go-faster/jx/pull/36

    Full Changelog: https://github.com/go-faster/jx/compare/v0.32.1...v0.32.2

    Source code(tar.gz)
    Source code(zip)
  • v0.32.1(Jan 25, 2022)

    What's Changed

    • fix: skip space if needed, when decoding bool/null by @tdakkota in https://github.com/go-faster/jx/pull/32

    Full Changelog: https://github.com/go-faster/jx/compare/v0.32.0...v0.32.1

    Source code(tar.gz)
    Source code(zip)
  • v0.32.0(Jan 21, 2022)

    What's Changed

    • fix: float decoding, improve coverage by @tdakkota in https://github.com/go-faster/jx/pull/25
    • feat: speed up escaped string decoding by @tdakkota in https://github.com/go-faster/jx/pull/28
    • feat: add Writer pool by @tdakkota in https://github.com/go-faster/jx/pull/31

    Full Changelog: https://github.com/go-faster/jx/compare/v0.31.0...v0.32.0

    Source code(tar.gz)
    Source code(zip)
  • v0.31.0(Jan 17, 2022)

    What's Changed

    • feat: unroll string decoder by @tdakkota in https://github.com/go-faster/jx/pull/23
    • test: add json corpus by @ernado in https://github.com/go-faster/jx/pull/24

    Full Changelog: https://github.com/go-faster/jx/compare/v0.30.0...v0.30.1

    Source code(tar.gz)
    Source code(zip)
  • v0.30.0(Jan 16, 2022)

    What's Changed

    • feat: unroll skipStr loop by @tdakkota in https://github.com/go-faster/jx/pull/22

    Full Changelog: https://github.com/go-faster/jx/compare/v0.29.0...v0.30.0

    Source code(tar.gz)
    Source code(zip)
  • v0.29.0(Jan 15, 2022)

    What's Changed

    • feat: inline read and match to consume by @tdakkota in https://github.com/go-faster/jx/pull/21

    Full Changelog: https://github.com/go-faster/jx/compare/v0.28.0...v0.29.0

    Source code(tar.gz)
    Source code(zip)
  • v0.28.0(Jan 14, 2022)

    What's Changed

    • feat: smarter object and array skip by @tdakkota in https://github.com/go-faster/jx/pull/19
    • feat: improve null and bool decoding by @tdakkota in https://github.com/go-faster/jx/pull/18

    Full Changelog: https://github.com/go-faster/jx/compare/v0.27.0...v0.28.0

    Source code(tar.gz)
    Source code(zip)
  • v0.27.0(Jan 13, 2022)

    What's Changed

    • test: cleanup some tests, add more testdata by @tdakkota in https://github.com/go-faster/jx/pull/15
    • feat: inline reading to consume by @tdakkota in https://github.com/go-faster/jx/pull/17
    • feat: smarter string skip by @tdakkota in https://github.com/go-faster/jx/pull/16

    Full Changelog: https://github.com/go-faster/jx/compare/v0.26.0...v0.27.0

    Source code(tar.gz)
    Source code(zip)
  • v0.26.0(Jan 13, 2022)

    What's Changed

    • feat: improve string encoding by @tdakkota in https://github.com/go-faster/jx/pull/9
    • feat: add writer by @ernado in https://github.com/go-faster/jx/pull/10
    • test(bench): use Writer in OTEL encode by @ernado in https://github.com/go-faster/jx/pull/11
    • feat(writer): improve base64 encoding by @ernado in https://github.com/go-faster/jx/pull/13
    • feat: rewrite skipNumber by @tdakkota in https://github.com/go-faster/jx/pull/12

    New Contributors

    • @ernado made their first contribution in https://github.com/go-faster/jx/pull/10

    Full Changelog: https://github.com/go-faster/jx/compare/v0.25.1...v0.26.0

    Source code(tar.gz)
    Source code(zip)
  • v0.26.0-alpha.0(Jan 12, 2022)

    What's Changed

    • feat: improve string encoding by @tdakkota in https://github.com/go-faster/jx/pull/9
    • feat: add writer by @ernado in https://github.com/go-faster/jx/pull/10

    New Contributors

    • @ernado made their first contribution in https://github.com/go-faster/jx/pull/10

    Full Changelog: https://github.com/go-faster/jx/compare/v0.25.1...v0.26.0-alpha.0

    Source code(tar.gz)
    Source code(zip)
  • v0.25.1(Jan 11, 2022)

    What's Changed

    • feat: improve BCE by @tdakkota in https://github.com/go-faster/jx/pull/7

    Full Changelog: https://github.com/go-faster/jx/compare/v0.25.0...v0.25.1

    Source code(tar.gz)
    Source code(zip)
  • v0.25.0(Nov 25, 2021)

    What's Changed

    • feat: generate integer encoders by @tdakkota in https://github.com/go-faster/jx/pull/6

    Full Changelog: https://github.com/go-faster/jx/compare/v0.24.0...v0.24.1

    Source code(tar.gz)
    Source code(zip)
  • v0.24.0(Nov 23, 2021)

    What's Changed

    • feat: add Capture support for readers by @tdakkota in https://github.com/go-faster/jx/pull/5

    New Contributors

    • @tdakkota made their first contribution in https://github.com/go-faster/jx/pull/5

    Full Changelog: https://github.com/go-faster/jx/compare/v0.23.3...v0.24.0

    Source code(tar.gz)
    Source code(zip)
  • v0.23.3(Nov 10, 2021)

  • v0.23.2(Nov 10, 2021)

  • v0.23.0(Nov 7, 2021)

  • v0.22.0(Nov 7, 2021)

Owner
ogen
OpenAPI v3 Code Generation for Go
ogen
Fast JSON encoder/decoder compatible with encoding/json for Go

Fast JSON encoder/decoder compatible with encoding/json for Go

Masaaki Goshima 2k Jan 6, 2023
JSON Spanner - A Go package that provides a fast and simple way to filter or transform a json document

JSON SPANNER JSON Spanner is a Go package that provides a fast and simple way to

null 6 Sep 14, 2022
Get JSON values quickly - JSON parser for Go

get json values quickly GJSON is a Go package that provides a fast and simple way to get values from a json document. It has features such as one line

Josh Baker 11.6k Dec 28, 2022
JSON diff library for Go based on RFC6902 (JSON Patch)

jsondiff jsondiff is a Go package for computing the diff between two JSON documents as a series of RFC6902 (JSON Patch) operations, which is particula

William Poussier 215 Dec 4, 2022
Package json implements encoding and decoding of JSON as defined in RFC 7159

Package json implements encoding and decoding of JSON as defined in RFC 7159. The mapping between JSON and Go values is described in the documentation for the Marshal and Unmarshal functions

High Performance, Kubernetes Native Object Storage 2 Jun 26, 2022
Json-go - CLI to convert JSON to go and vice versa

Json To Go Struct CLI Install Go version 1.17 go install github.com/samit22/js

Samit Ghimire 7 Jul 29, 2022
Fast JSON parser and validator for Go. No custom structs, no code generation, no reflection

fastjson - fast JSON parser and validator for Go Features Fast. As usual, up to 15x faster than the standard encoding/json. See benchmarks. Parses arb

Aliaksandr Valialkin 1.7k Jan 5, 2023
Fast and flexible JSON encoder for Go

Jettison Jettison is a fast and flexible JSON encoder for the Go programming language, inspired by bet365/jingo, with a richer features set, aiming at

William Poussier 141 Dec 21, 2022
Fast JSON serializer for golang.

easyjson Package easyjson provides a fast and easy way to marshal/unmarshal Go structs to/from JSON without the use of reflection. In performance test

Free and open source software developed at Mail.Ru 4k Jan 4, 2023
Fast Color JSON Marshaller + Pretty Printer for Golang

ColorJSON: The Fast Color JSON Marshaller for Go What is this? This package is based heavily on hokaccha/go-prettyjson but has some noticible differen

Tyler Brock 117 Dec 19, 2022
A fast json parser for go

rjson rjson is a json parser that relies on Ragel-generated state machines for most parsing. rjson's api is minimal and focussed on efficient parsing.

WillAbides 50 Sep 26, 2022
A blazingly fast JSON serializing & deserializing library

Sonic A blazingly fast JSON serializing & deserializing library, accelerated by JIT(just-in-time compiling) and SIMD(single-instruction-multi-data). B

Bytedance Inc. 3.9k Jan 5, 2023
Kazaam was created with the goal of supporting easy and fast transformations of JSON data with Golang

kazaam Description Kazaam was created with the goal of supporting easy and fast transformations of JSON data with Golang. This functionality provides

Qntfy 205 Sep 17, 2021
Abstract JSON for golang with JSONPath support

Abstract JSON Abstract JSON is a small golang package provides a parser for JSON with support of JSONPath, in case when you are not sure in its struct

Stepan Pyzhov 145 Jan 5, 2023
Small utility to create JSON objects

gjo Small utility to create JSON objects. This was inspired by jpmens/jo. Support OS Mac Linux Windows Requirements Go 1.1.14~ Git Installtion Build $

skanehira 116 Dec 8, 2022
A Go package for handling common HTTP JSON responses.

go-respond A Go package for handling common HTTP JSON responses. Installation go get github.com/nicklaw5/go-respond Usage The goal of go-respond is to

Nick Law 50 Sep 26, 2022
JSON query in Golang

gojq JSON query in Golang. Install go get -u github.com/elgs/gojq This library serves three purposes: makes parsing JSON configuration file much easie

Qian Chen 183 Dec 28, 2022
Automatically generate Go (golang) struct definitions from example JSON

gojson gojson generates go struct definitions from json or yaml documents. Example $ curl -s https://api.github.com/repos/chimeracoder/gojson | gojson

Aditya Mukerjee 2.6k Jan 1, 2023
A JSON diff utility

JayDiff A JSON diff utility. Install Downloading the compiled binary Download the latest version of the binary: releases extract the archive and place

Guillaume de Sagazan 95 Dec 11, 2022