Closed (duplicate)
Project:
Drupal core
Version:
8.0.x-dev
Component:
node.module
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
9 Sep 2012 at 17:41 UTC
Updated:
29 Jul 2014 at 21:08 UTC
Jump to comment: Most recent file
Comments
Comment #1
chx commentedThis issue is only about converting the variables. The node types themselves will need to become ConfigEntities (i think that's what Thingies(TM) ended up being called :) ).
Comment #2
sunClarifying issue title.
Comment #3
julien commentedone very simple patch to start with, with the most general ones.
Comment #5
sunThanks for kick-starting this! :)
Let's make sure to follow the guidelines: http://drupal.org/node/1667896
Comment #6
julien commentedfew more functions change. even if the yml structure is not right, it will just need to adapt the config object name and variables name.
Comment #7
julien commentedok an update even if some tests fail.
Comment #8
julien commentedsimpler one.
Comment #10
julien commentedanother one which actually save content type settings
Comment #12
cosmicdreams commentedGreat work, you got it working with the tests. Looks like the errors point to common problems in the patch. There's likely some low hanging fruit here.
Comment #13
sunGreat progress! :)
However, please note that the variables belonging to individual node types should not be converted here. They belong to the node type configuration objects, whose conversion is subject to #111715: Convert node/content types into configuration
Thus, only the variables of node.settings are relevant here.
Comment #14
julien commentedComment #16
sunThanks! :)
I have a couple of remarks:
Let's remove "node" from these.
This variable is not configuration (but "state" information instead) and should thus be left alone.
This should be block.recent.limit
Let's use sub-keys for these; e.g., rank.relevance.
Speaking of, rank.relevance is the only one out of these which is not self-descriptive. Unfortunately, the patch/diff context doesn't show what this rank variable actually means and refers to.
These are example code snippets that demonstrate how to implement node module hooks and thus do not actually belong to Node module's settings. :)
However, we should convert them nevertheless, but into fake settings of hypothetical modules; e.g.: vote_node_enabled becomes vote.settings:node.enabled
The configuration of a module is uninstalled automatically, so these deletions can just simply be removed.
Comment #17
julien commentedThanks for the review.
Comment #18
julien commentedHere is the latest one.
Regarding cron_last, i understand but i need more details on how you want to convert it, as it was used with variable_set and when a node get indexed.
All the remainings one are done.
Comment #19
julien commentedOops, forgot something.
Comment #21
julien commentedThis one is just to be sure that the general settings variables are ok with all the tests.
Comment #23
julien commented#21: 1779486.patch queued for re-testing.
Comment #24
julien commentedComment #25
julien commentedComment #26
julien commentedComment #28
julien commentedComment #30
julien commentedComment #32
julien commentedComment #34
julien commentedComment #36
julien commentedComment #38
julien commentedComment #40
julien commented#38: 1779486_last.patch queued for re-testing.
Comment #41
julien commentedComment #43
julien commentedComment #44
andypostLooks good except
As mentionet above stis is a state not a variable, see #1175054: Add a storage (API) for persistent non-configuration state
Comment #45
julien commentedYou're right, the last patch is not up to date as this issue #1175054: Add a storage (API) for persistent non-configuration state have been created after the latest patch.
Looking at the last patch there, i think that maybe more node module related variables could go in the state storage instead, but before that, i'm still looking forward that this issue get resolved first. see #111715: Convert node/content types into configuration
Comment #46
aspilicious commentedI didn't read everything, I've been out of core for a while so I can be wrong in some places.
Why do we need the $variable stuff in here?
I think with the newer version of php we can write this as isset($preview_type) ?: DRUPAL_OPTIONAL
node_access_test_settings sounds more like state
trailing whitespace
Why aren't the comments wrapped at 80 chars.
In general I have a problem with test only config elements. These never will be changed and smell like state (as I said before)
Comment #47
pcambraMarking postponed as for #45: #111715: Convert node/content types into configuration
Comment #48
znerol commentedI've put together a separate patch for the search-module integration (aka node_rank_-variables) in #1831632: Convert node_rank_ $rank variables to use configuration system. That part can be attackad independantly from the whole business over at #111715: Convert node/content types into configuration.
Comment #49
aspilicious commentedComment #50
alexpott#111715: Convert node/content types into configuration actually covered most of this. And other issues are being split out to smaller more manageable tasks eg: #2066145: Convert node_admin_theme to the configuration system and #1831632: Convert node_rank_ $rank variables to use configuration system
Comment #50.0
alexpottupdate issue summary