We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
When using jsonapi: renderer I found out it was effectively adding an extra call to the resources, impacting performance:
jsonapi:
Compare results when using Rails' default json: rednerer and jsonapi-serializer directly:
json:
jsonapi-serializer
The text was updated successfully, but these errors were encountered:
It's actually adding the 2 extra prev. steps of Property Count and Property Exists? as well
Property Count
Property Exists?
Sorry, something went wrong.
@benoror could you share your serializer implementation?
Also this is probably an issue for the https://github.com/jsonapi-serializer/jsonapi-serializer/ ?
The second example is only using jsonapi-serializer (sans jsonapi.rb wrapper) and it's clearly not causing it AFAICT
jsonapi.rb
class PropertySerializer include JSONAPI::Serializer belongs_to :broker belongs_to :status, serializer: :tag, id_method_name: :status_tag_key belongs_to :type, serializer: :tag, id_method_name: :type_tag_key belongs_to :location, serializer: :tag, id_method_name: :location_tag_key belongs_to :agent, serializer: :account has_many :features attributes :title, :description, :published, :built_at, :retail_price, :retail_price_cents, :retail_price_currency, :rent_price, :rent_price_cents, :rent_price_currency, :rto_price, :rto_price_cents, :rto_price_currency, :rooms, :bathrooms, :floors, :parking_lots, :video_url, :area, :area_units, :land_area, :land_area_units, :latitude, :longitude, :street_address, :street_number, :postal_code attribute :images do |object| attachments(object.images) end attribute :plans do|object| attachments(object.plans) end end
No branches or pull requests
When using
jsonapi:
renderer I found out it was effectively adding an extra call to the resources, impacting performance:Compare results when using Rails' default
json:
rednerer andjsonapi-serializer
directly:The text was updated successfully, but these errors were encountered: