All Projects → outworkers → Morpheus

outworkers / Morpheus

Licence: other
Reactive type-safe Scala driver for SQL databases

Programming Languages

scala
5932 projects
dsl
153 projects

Projects that are alternatives of or similar to Morpheus

Vertx Sql Client
High performance reactive SQL Client written in Java
Stars: ✭ 690 (+583.17%)
Mutual labels:  reactive, mysql, postgres
Monogamy
Add table-level database locking to ActiveRecord
Stars: ✭ 12 (-88.12%)
Mutual labels:  mysql, postgres
Schemats
Generate typescript interface definitions from SQL database schema
Stars: ✭ 799 (+691.09%)
Mutual labels:  mysql, postgres
East
node.js database migration tool
Stars: ✭ 53 (-47.52%)
Mutual labels:  mysql, postgres
Go Structured Query
Type safe SQL query builder and struct mapper for Go
Stars: ✭ 101 (+0%)
Mutual labels:  mysql, postgres
Migrate
Database migrations. CLI and Golang library.
Stars: ✭ 7,712 (+7535.64%)
Mutual labels:  mysql, postgres
Goqu
SQL builder and query library for golang
Stars: ✭ 984 (+874.26%)
Mutual labels:  mysql, postgres
Mouthful
Mouthful is a self-hosted alternative to Disqus
Stars: ✭ 681 (+574.26%)
Mutual labels:  mysql, postgres
Ebean
Ebean ORM
Stars: ✭ 1,172 (+1060.4%)
Mutual labels:  mysql, postgres
Sql
MySQL & PostgreSQL pipe
Stars: ✭ 81 (-19.8%)
Mutual labels:  mysql, postgres
Electrocrud
Database CRUD Application Built on Electron | MySQL, Postgres, SQLite
Stars: ✭ 1,267 (+1154.46%)
Mutual labels:  mysql, postgres
Vscode Sqltools
Database management for VSCode
Stars: ✭ 741 (+633.66%)
Mutual labels:  mysql, postgres
Metabase
The simplest, fastest way to get business intelligence and analytics to everyone in your company 😋
Stars: ✭ 26,803 (+26437.62%)
Mutual labels:  mysql, postgres
Xorm
Simple and Powerful ORM for Go, support mysql,postgres,tidb,sqlite3,mssql,oracle, Moved to https://gitea.com/xorm/xorm
Stars: ✭ 6,464 (+6300%)
Mutual labels:  mysql, postgres
Fizz
A Common DSL for Migrating Databases
Stars: ✭ 92 (-8.91%)
Mutual labels:  mysql, postgres
Python Database Sanitizer
Python based database sanitizer for removing sensitive data from your database dumps
Stars: ✭ 29 (-71.29%)
Mutual labels:  mysql, postgres
Search cop
Search engine like fulltext query support for ActiveRecord
Stars: ✭ 660 (+553.47%)
Mutual labels:  mysql, postgres
Blog
Everything about database,business.(Most for PostgreSQL).
Stars: ✭ 6,330 (+6167.33%)
Mutual labels:  mysql, postgres
Docker Backup Database
Docker image to periodically backup your database (MySQL, Postgres, or MongoDB) to S3 or local disk.
Stars: ✭ 57 (-43.56%)
Mutual labels:  mysql, postgres
Prisma
Next-generation ORM for Node.js & TypeScript | PostgreSQL, MySQL, MariaDB, SQL Server, SQLite & MongoDB (Preview)
Stars: ✭ 18,168 (+17888.12%)
Mutual labels:  mysql, postgres

morpheus Build Status Coverage Status Bintray

==============================================================

morpheus

To stay up-to-date with our latest releases and news, follow us on Twitter: @outworkers.

Named after the Greek God of Dreams, morpheus is a reactive type-safe Scala DSL for MySQL, Postgres, MSSQL, MariaDB, Oracle and Sybase. "Morpheus" morphs into the SQL implementation of your desire, so instead of implementing a Slick like leaking abstraction, we have instead opted to implement an entire engine for each of the mainstream SQL databases and unify them to offer a consistent fluent DSL experience.

With the single switch of a dependency and an import, morpheus will perform a full feature swap from MySQL to OracleSQL for example. It doesn't have a query compiler, instead it entirely mimics the functionality the database has, so if a method exists in OracleSQL but not in MySQL, you will get a compile time error if you attempt to use it.

There are no renames, no new things to learn, no new features or abstractions like in Slick, just dear old SQL as you've grown to love i or hate it.

Using morpheus

The current version is: val morpheusVersion = Bintray .

Morpheus is actively and avidly developed. It is not yet production ready, so trial at your own risk.

  • The stable release is always available on Maven Central and will be indicated by the badge at the top of this readme. The Maven Central badge is pointing at the latest version

  • Intermediary releases are available through our managed Bintray repository available at Resolver.bintrayRepo("outworkers", "oss-releases"). The latest version available on our Bintray repository is indicated by the Bintray badge at the top of this readme.

Table of contents

  1. Design philosophy
  2. Integrating Morpheus
  3. Supported databases and documentation

  4. Support
  5. Copyright

Design philosophy

You're probably wondering how Morpheus fairs compared to the more established players in the Scala SQL market and why we set out to do something new in the first place. To sum it up, we believe Slick is an excellent tool but we do not believe you should learn about our abstractions to get things done. A DSL should auto-magically encode the same syntax and the logic as the tool it's designed for.

Instead of learning about primitives and rules we thought of to abstract away discrepancies between the various SQL implementations, Morpheus features a unique approach, what we call the auto-magical flip. Although at this point in time only MySQL is supported, Morpheus is designed to give you an "all-you-can-eat" buffet through a single import.

As follows: import com.outworkers.morpheus.mysql._.

And done, you can now define tables, query and so on. Say you have something like this:

Recipes.select.distinctRow.where(_.name eqs "test"). DISTINCTROW doesn't exist in the Postgres SELECT statement syntax, but it's a standard thing as far as MySQL is concerned.

Here's how Morpheus operates:

If you change the top level import to: com.outworkers.morpheus.postgres._ and you try to compile the same distinctRow query. But there will be none. The method will simply not exist. Morpheus has now auto-magically performed a full feature swap, changed communication protocol and all underlying settings, and all you get now is Postgres features.

How? Quite a lot of fun magic under the hood, have a look throughout our decently documented codebase for more information. The beauty of it is that you don't have to care. Slick makes it easy to move from one SQL database to the other with less code changes, but if you're well set on a database you already know and love, it may be counter productive to have to learn about a framework when you could use Morpheus and all you need is IDE auto-completes to get lightning fast development productivity.

Oh, and did we mention it's entirely asynchronous and reactive? No JDBC.

Integrating Morpheus

back to top

Morpheus is designed to give you an all-you-can eat buffet through a single import, so all you really have to do is to pick the module corresponding to the database you want to use. At this point in time only MySQL is supported.

If you are using MySQL, you would simply use the following:

libraryDependencies ++= Seq(
  "com.outworkers"  %% "morpheus-mysql"                % morpheusVersion
)

And then you can: import com.outworkers.morpheus.mysql._, which will give you the full set of MySQL methods and features without any overlaps or unsupported operations. Morpheus guarantees you can almost never write an invalid SQL query unless you try really really hard.

Available modules

The full list of available modules is:

libraryDependencies ++= Seq(
  "com.outworkers"  %% "morpheus-dsl"                  % morpheusVersion,
  "com.outworkers"  %% "morpheus-mysql"                % morpheusVersion,
  "com.outworkers"  %% "morpheus-postgres"             % morpheusVersion
)

Contributors

back to top

Morpheus was developed by us from scratch in an attempt to evolve the SQL tooling in the Scala ecosystem to the new level and bring in fully reactive database access while preserving the complete SQL syntax you are used to.

Commercial support

back to top

We, the people behind phantom run a software development house specialised in Scala and NoSQL. If you are after enterprise grade training or support for using phantom, Outworkers is here to help!

We offer a comprehensive range of elite Scala development services, including but not limited to:

  • Software development
  • Remote Scala contractors for hire
  • Advanced Scala and Morpheus training

We are big fans of open source and we will open source every project we can! To read more about our OSS efforts, click here.

Copyright

back to top

Copyright (c) 2012 - 2017 outworkers.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].