π Help us spread the word about Prisma by starring the repo or tweeting about the release. π
Highlights
Improved serverless experience β smaller engines size
In this release, we have decreased the size of our engine files by an average of 50%. The size of the Query Engine used on Debian, with OpenSSL 3.0.x, for example, went from 39MB to 14MB. We will also remove some smaller engines to decrease the total size in future versions.
Additionally, we have started optimizing how the Prisma schema is loaded in Prisma Client. You should notice a considerable improvement when executing the first query if you're working with a bigger schema with many models and relations.
We will continue investing in this direction in the next releases and further improve the experience with Prisma and serverless environments.
Multi-schema support for CockroachDB (Preview)
We're pleased to share that this release adds Preview support for multi-schema for CockroachDB. π
This release adds support for:
- Introspecting databases that organize objects in multiple database schemas
- Managing multi-schema database setups directly from Prisma schema
- Generating migrations that are database schema-aware with Prisma Migrate
- Querying across multiple database schemas with Prisma Client
If you already have a CockroachDB database using multiple schemas, you can quickly get up and running set up multiple schemas by:
- Enabling the Preview feature in the Prisma schema
- Defining the schemas in the
schemas
property in thedatasource
block - Introspecting your database using
prisma db pull
You can further evolve your database schema using the multi-schema Preview feature by using prisma migrate dev
.
For further details, refer to our documentation and let us know what you think in this GitHub issue.
Improved OpenSSL 3.x support
Prisma now supports OpenSSL 3 builds for Linux Alpine on x86_64
architectures. This particularly impacts users running Prisma on node:alpine
and node:lts-alpine
Docker images. The images are based on an Alpine version that ships with OpenSSL 3.0.x, which isnβt compatible with OpenSSL 1.1.x (already supported by Prisma). You can read more details about it in this GitHub comment.
We also have rewritten our OpenSSL version detection logic, making it future-proof. We now expect Prisma to support systems running with any OpenSSL 3 minor versions out of the box.
Fixes and improvements
Prisma
- Migrate: @dbgenerated with @db.Time(0) keeps generating new migrations
- Error parsing attribute "@@index": The Gin index field type
Uuid
has no default operator class. - UTF-8 Error: index is not a char boundary
- Error in migration engine. Reason: entered unreachable code
- Regression in enum default value handling in 4.7.0
- Regression in relation field name deduplication
- multiSchema:
migrate reset
only resets first schema - Cross schema reference with foreign key not working in 4.7.0.
- Support SQL Server in
multiSchema
introspection migrate dev
does not detect drift between database schema and migration history formultiSchema
- Bad credentials when downloading using @prisma/fetch-engines
- multiSchema: migrate dev fails to apply cleanly to shadow database after custom migration renames table in secondary schema
Prisma Migrate
- Prisma db migration always altering my table contains mysql TIME data type inside of it
- Prisma migration fails with postgres
- Migrate Dev CMD Issue when using
multiSchema
preview feature with MySQL
Prisma Client
- Prisma 4.3.1 distribution is bundling a libquery_engine
- enum fields are missing in select's type when
clientExtensions
preview feature is used $extends
TS error: "Inferred type of this node exceeds the maximum length the compiler will serialize" with"declaration": true
intsconfig
- Regression bug: batched findUniqueOrThrow queries throw 'Field does not exist on enclosing type.'
- Prisma Client Extensions:
args
isundefined
- Support OpenSSL 3.0 for Alpine Linux
console.log
outputs incorrect value whenresult
extensions are used- 4.6.0 and newer does not let me spy using vitest.
- Investigate memory issues on Windows
- prisma@4.7.1 - "RangeError: Maximum call stack size exceeded" when clientExtensions enabled
- Unique constraint error when connecting an item in a 1-1 relation that is already connected
- Error when using "multiSchema" with custom database schema and implicit Many To Many relation
- binaries.prisma.sh not accessible via IPv6
- Nested disconnect fails with
extendedWhereUnique
on SQL
Language tools (e.g. VS Code)
- Auto completion suggests
@map
although already present - Update message for detecting both Stable and Insiders in workspace
- Update to use correct form of criteri(a/on)
- Extra
'
in optional arguments context
Prisma Engines
- Use correct forms of "criterion" (singular) and "criteria" (plural)
- Only use buildjet action runner where needed
- Bug:
@@schema
attribute should always be required whenschemas
is defined in the datasource
Credits
Huge thanks to @ivan, @Mini256, @cmd-johnson for helping!
Prisma Help Center (New)
We recently just launched our Help Center that you can use to find resources and get help from our support team for both the Prisma ORM and the Prisma Data Platform.
Check it out, and let us know what you think.
πΊ Join us for another "What's new in Prisma" live stream
Learn about the latest release and other news from the Prisma community by joining us for another "What's new in Prisma" live stream.
The stream takes place on YouTube on Thursday, December 22 at 5 pm Berlin | 8 am San Francisco.