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

New DB API: Storage #554

Merged
merged 10 commits into from
Jul 12, 2018
Merged

New DB API: Storage #554

merged 10 commits into from
Jul 12, 2018

Conversation

jonwinton
Copy link
Contributor

@jonwinton jonwinton commented Jun 21, 2018

  • Pulls out the DB module to use supplied storage
  • Refactors reads from DB to ALWAYS expect JSON, not strings of JSON

Issue: #553

})).then(JSON.parse).then(convertDBListToReferenceObjects);
}));

return promise.then(JSON.parse).then(convertDBListToReferenceObjects);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does pipeToPromise still return strings of JSON?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately yes because the stream requires strings to operate, so we have to parse it out. I've done a little refactor on this and will push it up soon. The only thing using method is scheduling, so when that gets pulled out this is just going to move over


Eventify.enable(module.exports);

_.each(['put', 'batch', 'del'], exposeMethodToOutsideListeners);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what outside listeners did we have (if any)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

None, we just never deprecated it 😬

@jonwinton jonwinton merged commit 8641b2a into v7 Jul 12, 2018
@jonwinton jonwinton deleted the db-restructure branch July 12, 2018 18:37
jonwinton added a commit that referenced this pull request Sep 20, 2018
* stashing small update

* stashing changes;

* stashing changes before beginning testing refactor

* testing for non-api tests

* fixing api tests

* updating db tests

* 100%

* eslint

* moving packages over to dev dependencies

* more updates

* lots of changes

* metadata for the layouts

* forgot file

* more layouts/meta work

* getting things in order

* New DB API: Storage (#554)

* stashing small update

* stashing changes;

* stashing changes before beginning testing refactor

* testing for non-api tests

* fixing api tests

* updating db tests

* 100%

* eslint

* moving packages over to dev dependencies

* Meta Patch Requests (#569)

* adding patch support

* code comments

* Publish data meta (#571)

* adding patch support

* code comments

* bringing in meta updating

* cleanup

* cleaning up some publish/unpublish logic and keeping page history

* passing bus publish method to plugins

* using meta object and raw query for db

* small pruning and comments

* using amphora-fs for file service

* updating for amphora-search

* lists api

* removing cache control

* moving plugins

* some testing work

* components & composer services

* stashing tests

* more tests

* middle of tests

* stashing test changes

* initial fixes done, moving to api tests

* most testing work done

* mostly done

* fixing model call

* making a doc of changing things

* linting and test changes

* writing plugin docs

* writing more docs

* adding to table of contents

* pass site to attachRoutes

* do not  need that package

* fixing issue

* newline

* no actual changes

* Validate site routes (#598)

* no actual changes

* attach amphora api routes to the router first to avoid misleading errors caused by less specific site-level routes

* set reservedRoutes in a function + pr feedback

* making long stacktraces an env var

* stashing changes

* fixing up some tests

* actually fixing tests

* V7 meta changes (#605)

* no actual changes

* some fixes discovered when working with kiln

* unwrap list routes in amphora-storage-postgres

* normalizing fields between page and layout metadata and removing unused fields

* use iso string timestamps

* 7.0.0-0

* Redirect From Published Meta (#607)

* adding in redirect and fixing eslint comment

* moving to responses

* name change

* look for custom url and dynamic prop before site pub chain

* removing comment

* package-lock
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

Successfully merging this pull request may close these issues.

2 participants