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

Serialization of Resource and ResourceCollection yields database queries. #43

Open
muratseyhan opened this issue Feb 13, 2015 · 2 comments

Comments

@muratseyhan
Copy link
Contributor

I have noticed that the serialization methods (to_rdf, to_ttl etc.) for Resource and ResourceCollection objects hit the database to retrieve resources that are previously loaded. Apart from the performance issues, this also means that the resources that are not persisted in the database cannot be serialized.

Is there perhaps a specific reason behind this, such as making sure that the output is consisted with the persisted data?

@RicSwirrl
Copy link
Member

This is because rdf.rb is really slow at parsing and serialising lots of data, so the principle here was to let the database do the work.

@muratseyhan
Copy link
Contributor Author

Ah, that makes much more sense now. Thanks!

Serialization of ResourceCollection objects fails in some cases, due to the use of broken CONSTRUCT queries produced by _describe_query_for_select.

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