Skip to content
This repository was archived by the owner on Sep 24, 2018. It is now read-only.

Conversation

@rmccue
Copy link
Member

@rmccue rmccue commented Sep 23, 2016

Fixes #2558.

@rmccue rmccue added the Bug label Sep 23, 2016
@rmccue rmccue added this to the 2.0 Beta 14 milestone Sep 23, 2016
@danielbachhuber
Copy link
Member

Do you think it will ever post a problem to have the schema cached? e.g. what happens if a field is registered after the schema is cached?

@BE-Webdesign
Copy link
Member

BE-Webdesign commented Sep 23, 2016

Do you think it will ever post a problem to have the schema cached? e.g. what happens if a field is registered after the schema is cached?

The tests seem to reflect that concern, as the additional fields aren't registering anymore. The registering could be changed to just work with the object property though. I mainly think using schema as an object property would be a problem with internal requests, via batch processes.

@rmccue
Copy link
Member Author

rmccue commented Sep 28, 2016

Do you think it will ever post a problem to have the schema cached? e.g. what happens if a field is registered after the schema is cached?

This will already be a problem, since the schema won't be exposed to the client, and will be inconsistent internally. I think having internal consistency makes it more obvious if you're hooking in at the wrong point.

@danielbachhuber
Copy link
Member

I think having internal consistency makes it more obvious if you're hooking in at the wrong point.

Maybe all of these schemas should be generated and cached at the same time (on some hook) to ensure there's internal consistency from hook to hook.

@rmccue
Copy link
Member Author

rmccue commented Sep 28, 2016

I'm pretty sure it is consistently generated right now on rest_api_init, since the schema is passed into the route registration. See also #2694.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants