Taymyr: DDD Repository JPA

DDD Repository pattern for Lagom/Play frameworks

Лицензия

Лицензия

Категории

Категории

Java Языки программирования
Группа

Группа

org.taymyr.play
Идентификатор

Идентификатор

play-repository-jpa-java
Последняя версия

Последняя версия

0.0.1
Дата

Дата

Тип

Тип

jar
Описание

Описание

Taymyr: DDD Repository JPA
DDD Repository pattern for Lagom/Play frameworks
Организация-разработчик

Организация-разработчик

Digital Economy League

Скачать play-repository-jpa-java

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/org.taymyr.play/play-repository-jpa-java/ -->
<dependency>
    <groupId>org.taymyr.play</groupId>
    <artifactId>play-repository-jpa-java</artifactId>
    <version>0.0.1</version>
</dependency>
// https://jarcasting.com/artifacts/org.taymyr.play/play-repository-jpa-java/
implementation 'org.taymyr.play:play-repository-jpa-java:0.0.1'
// https://jarcasting.com/artifacts/org.taymyr.play/play-repository-jpa-java/
implementation ("org.taymyr.play:play-repository-jpa-java:0.0.1")
'org.taymyr.play:play-repository-jpa-java:jar:0.0.1'
<dependency org="org.taymyr.play" name="play-repository-jpa-java" rev="0.0.1">
  <artifact name="play-repository-jpa-java" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.taymyr.play', module='play-repository-jpa-java', version='0.0.1')
)
libraryDependencies += "org.taymyr.play" % "play-repository-jpa-java" % "0.0.1"
[org.taymyr.play/play-repository-jpa-java "0.0.1"]

Зависимости

compile (3)

Идентификатор библиотеки Тип Версия
org.taymyr.play : play-repository-api-java jar 0.0.1
org.hibernate : hibernate-entitymanager jar 5.3.6.Final
org.jetbrains.kotlin : kotlin-stdlib-jdk8 jar 1.2.71

provided (1)

Идентификатор библиотеки Тип Версия
com.typesafe.play : play-java-jpa_2.12 jar 2.6.0

test (4)

Идентификатор библиотеки Тип Версия
io.kotlintest : kotlintest-runner-junit5 jar 3.1.10
com.typesafe.play : play-test_2.12 jar 2.6.0
com.h2database : h2 jar 1.4.197
com.typesafe.play : play-jdbc-evolutions_2.12 jar 2.6.0

Модули Проекта

Данный проект не имеет модулей.

Gitter Gitter_RU Build Status Javadocs Javadocs codecov Maven

DDD Repository pattern for Lagom/Play

API of library contains only one interface Repository for DDD aggregate, inspired the book Implementing Domain-Driven Design by Vaughn Vernon.

Example

JPA

Create the interface of repository for aggregate

public interface AggregateRepository extends Repository<Aggregate, UUID> { }

and implement it

public class AggregateRepositoryImpl extends JPARepository<Aggregate, UUID> implements AggregateRepository {

    @Inject
    public AggregateRepositoryImpl(@Nonnull JPAApi jpaApi, @Nonnull DatabaseExecutionContext executionContext) {
        super(jpaApi, executionContext, Aggregate.class);
    }

    @Override
    public UUID nextIdentity() {
        return UUID.randomUUID();
    }
}

Contributors

Other persistence implementations (for MongoDB/Cassandra/Redis) are welcome.

License

Copyright © Digital Economy League (https://www.digitalleague.ru/).

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this project except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

org.taymyr.play

Taymyr

Microservices business platform

Версии библиотеки

Версия
0.0.1