To be honest with all of you, the migration process won't be easy. The new version introduces a lot of breaking changes especially on the query part. Some features are still not available for the moment such as the authentication, users & permissions, email, media upload and GraphQL. **If you're using one of theses features, you shouldn't be able to migrate unless you rewrite these features from scratch.**
**Here are the major changes:**
- Moved from Waterline to specialized ORMs such as Mongoose (MongoDB) and Bookshelf (Postgres, MySQL, Maria, SQLite).
- New configurations structure.
- Moved from Koa@1 (generators) to Koa@2 (async functions).
- Removed middlewares from core (koa-graphql, koa-proxy, koa-ssl, koa-views).
The best way to migrate your project is to generate a new empty project using the v3. Then, copy and paste your `v1-app/api` folder to the new app `v3-app/api`. The next step is to follow the categories one by one in order and you will be able to migrate your project without issues.
See the [Quick start](../getting-started/quick-start.md) section to install the latest version of Strapi.
## Configurations
The structure of the configurations has been harmonised and simplified. Files has been renamed or deleted, and some others has been added.
Please refer to the [new documentation](https://github.com/strapi/strapi/blob/master/docs/3.0.0-alpha.x/en/configurations/configurations.md) to set the correct values in each file.
The format of the routes has changed to easily integrate multiple strategies to hit the controllers' actions. It means that the routes are not REST-limited.
Koa@1.x.x was based on generators whereas Koa@2.x.x is based on async functions. It means that the `yield` word has been replaced by the `await` word. Then the `context` was passed via the function context itself. Now, the `context` is passed through the function's parameters. Also, you don't need to apply the `try/catch` pattern in each controller's actions.
The services files should stay as they are. Your generator functions can be converted into async functions but it shouldn't be necessary.
## Models
The models didn't change a lot. The `autoCreatedAt`, `autoUpdatedAt` and `autoPK` attributes have been removed and replaced by the `hasTimestamps` attribute.
The `enum` type is not available for now. Also, the validations are not working properly. It means that most of the validations have to be done manually.
We were based on the popular Waterline ORM. As we said in our blog posts, Waterline suffers from a lack of maintenance and we decided to move to more specific ORMs depending on the database. It increases the performances and unblock particular features for the users. Currently, we are supporting these databases:
- MongoDB (through Mongoose).
- Postgres, MySQL, SQLite3 and more (through Bookshelf).
- Redis (through ioredis).
**This major change means that you will have to rewrite every single query of your app. So, please to be sure that you need to switch to the new version of Strapi before starting the migration.**
We decided to reduce the core to the minimum. So, we removed middlewares with features that shouldn't be handled by a Node.js server such as:
- GraphQL: **We love GraphQL at Strapi** and we will provide a `strapi-plugin-graphql`**very soon**.
- Proxy: There are many great server solutions to handle a proxy feature such as nginx or Caddy.
- SSL: Same as proxy.
- Views: We are building APIs, not website. However, we know that sometimes you need to render views from your API server. That's why we created a `strapi-views` hook.
### GraphQL
We are not able to give you a solution at the moment. As we said above, **we will develop in the next weeks** a dedicated plugin to integrate GraphQL into a project.
### Proxy & SSL
You should take a look at these articles to configure SSL and proxy with nginx:
- [Configuring Nginx and SSL with Node.js](https://www.sitepoint.com/configuring-nginx-ssl-node-js/)
- [Using Nginx as a reverse proxy with a Node.js app](http://www.nikola-breznjak.com/blog/javascript/nodejs/using-nginx-as-a-reverse-proxy-in-front-of-your-node-js-application/)
### Views
It works exactly as before. You need to add `strapi-views` into your app's dependencies and configure the views as below:
Boom is deeply integrated into the core which allows you to enjoy the entire [Boom API](https://github.com/hapijs/boom) through the context of your request. Every error throw in your project will be intercepted and decorated with Boom.