Commit Graph

423 Commits

Author SHA1 Message Date
Benjamin Fleischer
6d651bc9e3 Bump to 0.10.12 2020-12-10 12:42:12 -05:00
Ritikesh
f2643c1e3b Update rails dependency to < 6.2 2020-12-09 03:12:21 +05:30
Benjamin Fleischer
dac067fec4 Bump version 2020-12-04 08:59:17 -06:00
Wasif Hossain
64c7fee7a8 Code cleanup (#2369)
* Lint travis.yml on https://config.travis-ci.com/explore

* Replace deprecated 'thread_safe' with 'concurrent-ruby' alternative

'thread_safe' gem is now deprecated and merged into 'concurrent-ruby'.
Ref: 52e5f373a9 (diff-42d5a45da331eaa07d2b315bd3c9e738)

* Fix deprecation warning for Ruby 2.7

https://bugs.ruby-lang.org/issues/15539


* Remove a TODO tag that is already resolved
2020-01-02 21:53:59 -05:00
Alex Zherdev
1c028785eb Introduce use_sha1_digests config option 2019-10-16 13:06:45 -07:00
Alex Zherdev
5d3f56f0a4 Use SHA1 instead of MD5 for caching 2019-10-15 13:12:36 -07:00
Wasif Hossain
2581fe0362
Lookup fieldset using either string or symbol 2019-07-17 15:51:15 +06:00
Wasif Hossain
433c0c646f
Bump version to 0.10.10 2019-07-13 15:30:49 +06:00
Benjamin Fleischer
bb0f9d088d Bump version to 0.10.9 2019-02-08 11:25:53 -06:00
cintamani
15b7974fac
Merge pull request #2288 from cintamani/patch-1
Change the fetch method to deal with recyclable key cache strategy
2019-02-08 12:14:03 +00:00
Krzysztof Rybka
209834dc49 Performance and memory usage fixes (#2309)
* Use select and reject instead of partition.map

* Sort adapters keys in place

* Just select from options

* Add changelog entry
2019-01-29 15:38:11 -06:00
cintamani
141feeb259 Revert "Update caching.rb"
This reverts commit f31430a8185533246638a7cfebba325f0ac9b0fa.
2019-01-29 16:00:18 +00:00
cintamani
427dd05a73 Revert "Update caching.rb"
This reverts commit c6f34eb9e9df86b568b9463e2ea8c26f0f43a838.
2019-01-29 16:00:18 +00:00
cintamani
bd53d9b213 Update caching.rb 2019-01-29 16:00:18 +00:00
cintamani
b0039e3758 Update caching.rb 2019-01-29 16:00:18 +00:00
cintamani
be5fbf3d54 Use #cache_key_with_key when available
In order to keep compatibility between the AMS cache feature and with Rails > 5.1  cache versioning, we have to use the `cache_key_with_version`. 
**NOTE** - This is a quick fix to the issue, if there will be future plans a proper cache versioning with recyclable key needs to be implemented. 

More info: https://github.com/rails-api/active_model_serializers/issues/2287
2019-01-29 16:00:18 +00:00
Benjamin Fleischer
c6c3927e00
Merge pull request #2307 from faucct/bugfix/double-evaluation-of-object
Reevaluation of object
2019-01-10 11:58:27 -06:00
Nikita Sokolov
a39794df5b LazyAssociation#object should not reevaluate reflection values 2019-01-09 09:52:38 +03:00
Krzysztof Rybka
873cf4add2 Add frozen_string_literal pragma to ruby files 2018-12-17 16:54:56 +01:00
Benjamin Fleischer
bc4805cbc1 Bump version to v0.10.8 2018-11-01 16:24:08 -05:00
Benjamin Fleischer
b358271ef5 Note that we dup the entire reflection instance 2018-11-01 14:21:59 -05:00
Konstantin Munteanu
ca6c009273 typos 2018-10-25 09:45:34 +02:00
Konstantin Munteanu
0d3999c36d Support conditions in link statements 2018-10-25 09:45:34 +02:00
Benjamin Fleischer
4b2b9ef730
Merge pull request #2297 from vnbrs/patch-1
Remove unnecessary line break from exception message
2018-10-24 17:02:19 -05:00
Vinicius Brasil
bcf21ea0a6
Remove unnecessary line break from exception message
This removes the unnecessary line break from the exception message. Example:

```
Cannot infer root key from collection type. Please\n
specify the root or each_serializer option, or render a JSON String
```
2018-10-24 14:10:59 -03:00
Dzmitry
db4e5267fd Fix the bug that serializer could not be found if the association's serializer is namespaced but the model is not
[fix #2295]
2018-10-20 15:42:11 +03:00
quake wang
a9ea81a831 resolve collection cache error 2017-11-19 11:33:48 -06:00
Benjamin Fleischer
ca531789c3 Bump to 0.10.7; update changelog 2017-11-14 20:50:51 -06:00
Joe Meredith
c6a14c9eac Fail if collection type cannot be inferred with json adapter (#2210) 2017-10-30 13:37:37 -04:00
Christian
a89e78c655 Allow referencing sideloaded include by key. (#2136)
* If a `key` is set on the reflection use the `key` instead of `name`.
This ensures that associations with a key set are still included.
2017-05-18 15:59:14 -05:00
Benjamin Fleischer
dff621e174 Bump to v0.10.6 2017-05-01 10:59:14 -05:00
Benjamin Fleischer
96028a7b99 Document new reflection options; support :foreign_key 2017-05-01 10:18:13 -05:00
Benjamin Fleischer
c9b0e4e6ae Do not calculate cache_key unless caching 2017-04-30 23:03:18 -05:00
Benjamin Fleischer
6e41528515 Skip eval relationships object on belongs to 2017-04-30 18:32:08 -05:00
Benjamin Fleischer
5e01a93fc0 Update comments regarding lazy_association and TODOs 2017-04-30 15:09:18 -05:00
Benjamin Fleischer
ff5ab21a45 Make Association totally lazy 2017-04-23 18:40:46 -05:00
Benjamin Fleischer
7697d9f5ec Refactor: introduce lazy association 2017-04-23 17:53:00 -05:00
Benjamin Fleischer
34d55e4729 Remove extra reflection classes 2017-04-23 17:46:55 -05:00
Benjamin Fleischer
7d8fb1606b Cleanup 2017-04-23 17:42:30 -05:00
Benjamin Fleischer
ee69293c8f Refactor reflection building serializer class 2017-04-23 15:21:29 -05:00
Benjamin Fleischer
079b3d6841 Refactor collection reflection 2017-04-23 14:53:45 -05:00
Benjamin Fleischer
1bddd9fdb5 Refactor 2017-04-23 14:47:55 -05:00
Benjamin Fleischer
fad4ef1046 Refactor reflection building of association 2017-04-23 14:19:04 -05:00
Benjamin Fleischer
cb16457bb3 Make reflection explicitly dependents on association 2017-04-23 14:18:30 -05:00
Benjamin Fleischer
6cd6ed7e78 Move association serialization to association 2017-04-22 22:13:52 -05:00
Benjamin Fleischer
c2dccbac5f Move attributes cache method out of concern 2017-04-22 22:13:52 -05:00
Benjamin Fleischer
f327b6be0c Improve reflection internal interface 2017-03-27 22:46:07 -05:00
Benjamin Fleischer
2e71bc47f4 Improve comments; move caching concern to caching.rb 2017-03-16 10:14:18 -05:00
Benjamin Fleischer
36b4eac79b Make serializer interface more obvious 2017-03-14 20:54:54 -05:00
Benjamin Fleischer
28b8e3dd17 Bump to v0.10.5 2017-03-07 15:41:20 -06:00