Sha256: d6badd6753aef47b8a2f10f2b2ddd09dfc2eb623aa32f0f399a47540d4459e00

Contents?: true

Size: 1000 Bytes

Versions: 94

Compression:

Stored size: 1000 Bytes

Contents

# Compatibility

**Ruby**

Oj is compatible with Ruby 2.0.0, 2.1, 2.2, 2.3, 2.4 and RBX.
Support for JRuby has been removed as JRuby no longer supports C extensions and
there are bugs in the older versions that are not being fixed.

**Rails**

Although up until 4.1 Rails uses [multi_json](https://github.com/intridea/multi_json), an [issue in Rails](https://github.com/rails/rails/issues/9212) causes ActiveSupport to fail to make use Oj for JSON handling.
There is a
[gem to patch this](https://github.com/GoodLife/rails-patch-json-encode) for
Rails 3.2 and 4.0. As of the Oj 2.6.0 release the default behavior is to not use
the `to_json()` method unless the `:use_to_json` option is set. This provides
another work around to the rails older and newer behavior.

The latest ActiveRecord is able to work with Oj by simply using the line:

```
serialize :metadata, Oj
```

In version Rails 4.1, multi_json has been removed, and this patch is unnecessary and will no longer work.
See {file:Rails.md}.

Version data entries

94 entries across 94 versions & 3 rubygems

Version Path
devcycle-ruby-server-sdk-2.0.0 vendor/bundle/ruby/3.0.0/gems/oj-3.13.2/pages/Compatibility.md
oj-3.13.20 pages/Compatibility.md
oj-3.13.19 pages/Compatibility.md
oj-3.13.18 pages/Compatibility.md
oj-3.13.17 pages/Compatibility.md
oj-3.13.16 pages/Compatibility.md
oj-3.13.15 pages/Compatibility.md
oj-3.13.14 pages/Compatibility.md
oj-3.13.13 pages/Compatibility.md
oj-3.13.12 pages/Compatibility.md
oj-3.13.11 pages/Compatibility.md
oj-3.13.10 pages/Compatibility.md
oj-3.13.9 pages/Compatibility.md
oj-3.13.8 pages/Compatibility.md
oj-3.13.7 pages/Compatibility.md
oj-3.13.6 pages/Compatibility.md
oj-3.13.5 pages/Compatibility.md
oj-3.13.4 pages/Compatibility.md
oj-3.13.3 pages/Compatibility.md
oj-3.13.2 pages/Compatibility.md