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

[meta] Finish Entity API integration #49

Closed
4 tasks done
SebCorbin opened this issue Sep 11, 2013 · 8 comments
Closed
4 tasks done

[meta] Finish Entity API integration #49

SebCorbin opened this issue Sep 11, 2013 · 8 comments
Milestone

Comments

@SebCorbin
Copy link

Backdrop was forked around the time that Entities were being converted into real objects (i.e. comment_save() now just wraps around $comment->save()), but the implementation is incomplete. We should finish the conversion to move entities to real objects to enable generic entity operations for such problems as #142.

Issues that need to be addressed (if backporting from D8) need to be handled in this order, as some earlier ones are required for the later ones:

@davereid
Copy link

The contrib entity API module is not the answer and has more learnability issues itself.

@quicksketch
Copy link
Member

Yeah, agreed with @davereid, Entity API module itself takes the approach that all all entities are treated equally, leading to enormous amounts of bloat. The Entity system overall can be improved significantly, making entities easier to make fieldable for example (saving a module like FileEntity from doing it all manually), but we certainly can't just throw Entity API into core wholesale.

@rudiedirkx
Copy link

I'd very much like to 'fix' core entity. What it could do is create abstract helpers that can be used by other modules. If your contrib module creates 2 non-fieldable entity types that don't use tokens etc etc, don't use the helpers. Otherwise do. First #11.

@alexweber
Copy link

@rudiedirkx Agreed, and while we're at it, it couldn't hurt to makes Nodes, Comments, Users, Taxonomy proper objects eh?

@rudiedirkx
Copy link

True dat, but even first #41

@quicksketch
Copy link
Member

Now that it's been a few months I'm coming back around to this issue because of #142. In D7, VBO module depended on Entity API module for saving arbitrary entities. As it turns out, the branch point of Backdrop (Feb 29, 2012), actually has resulted portions of Entity API already being in the project. It was added between these two drupal.org issues:

As @davereid noted above, D7 Entity API (which was in Backdrop from our branching), has really serious learnability and architectural issues. Fortunately, the approach used by D8 core (and Backdrop by association) is quite a bit better than the hacks the contrib project was forced to use. At this point, we have "proper" objects for Comments, but not for other entities. We'll need to convert at least nodes to be real objects in order to complete #142 for the basic node and comment use-cases.

@quicksketch
Copy link
Member

I created sub-issues and updated the description for this to become the main "meta" issue. Looks like since comments are already converted, we have 4 followup issues for each of Node, User, File, and Taxonomy objects.

@quicksketch
Copy link
Member

We've finished conversion of all the entity types in core. For starters, this issue is complete. We now have a consistent way of all CRUD for entities, as well as pulling out things like label, revision, id, etc. I've made a followup issue at #164 to simplify down the entity objects.

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

5 participants