0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-10 23:36:14 -05:00
ghost/core/server/api/v2
Rishabh Garg 8ec12d9eee
🏗 Extracted post metadata in new post_meta table (#11102)
NOTE: The post metadata table split is purely an internal optimization for v3 and doesn't require or expect any external actions including related API usage in v3

We keep running into issues adding new fields to the post table because there are too many fields making the post table "too wide". We have also hit MySQL limitations in how many bytes can be in a row (64kb) with post table.

In v3, we decided to split the 8 post fields (meta, twitter and og) used for meta data into a posts_meta table as these 8 fields are all "problem" `varchar` fields and make sense logically grouped together. The API layer is unaffected by the split as input/output serializers ensure the data flow works the same way as it was in v2. Only thing to note is json export in v3 will have slightly different structure with posts meta fields as separate.

- Creates new post_meta schema/table with 8 fields (2 meta_* , 3 twitter_* and 3 og_*)
- Update relations between post and post_meta table
- Update input/output serializers to keep existing API behavior
- Avoids new entry in post_meta table for post where all meta fields are null
- Keeps the current fields API param behavior
- Handles migration of existing posts to new table structure
- Updates importer/exporter to work seamlessly with table changes
2019-09-16 14:15:55 +05:30
..
utils 🏗 Extracted post metadata in new post_meta table (#11102) 2019-09-16 14:15:55 +05:30
actions.js
authentication.js Switched to use v2 http module instead of ovelooked v1 2019-08-01 13:06:15 +02:00
authors-public.js Renamed authors ctrl to authors-public 2019-02-26 08:33:10 +01:00
config.js Added "useGravatar" to config endpoint in Admin API v2 2019-02-25 15:39:47 +01:00
db.js Created DB Backup integration (#10974) 2019-08-02 17:28:02 +08:00
images.js Renamed uploads to images 2019-02-24 11:18:45 +07:00
index.js Migrated schedules controller to v2 2019-08-07 14:51:36 +02:00
integrations.js
invites.js Migrated to use url-utils from Ghost-SDK (#10787) 2019-06-18 15:13:55 +02:00
mail.js Updated links to docs (#10941) 2019-07-22 18:17:50 +08:00
members.js Updated getMember to return null rather than throw 2019-09-05 11:14:50 +08:00
notifications.js 🎨 Made notifications dismissible per user 2019-04-19 09:43:14 +02:00
oembed.js Refactored oembed controller data validation 2019-08-01 17:13:12 +05:30
pages-public.js
pages.js Migrated schedules controller to v2 2019-08-07 14:51:36 +02:00
posts-public.js
posts.js Migrated schedules controller to v2 2019-08-07 14:51:36 +02:00
preview.js
redirects.js Extracted frontend code from redirects API controllers (#10798) 2019-06-21 16:50:16 +02:00
roles.js
schedules.js Migrated schedules controller to v2 2019-08-07 14:51:36 +02:00
session.js 💡Migrated session controllers for compatibility with "frame" (#11101) 2019-09-11 11:28:55 +02:00
settings-public.js 🎨 Added url value to the Content API /settings/ endpoint (#10946) 2019-07-24 11:12:07 +01:00
settings.js Moved settings dynamicRouting to routing.settings 2019-06-21 16:34:17 +02:00
site.js Migrated to use url-utils from Ghost-SDK (#10787) 2019-06-18 15:13:55 +02:00
slack.js
slugs.js
subscribers.js
tags-public.js
tags.js
themes.js 🐛 Fixed cache invalidation header on theme override 2019-07-17 18:41:25 +05:30
users.js Removed all accesstokens and refreshtokens related code 2019-09-12 15:45:27 +01:00
webhooks.js