Questions tagged [micronaut-data]
210 questions
10
votes
1 answer
Is Micronaut Data with R2DBC a more scalable approach than classical “one thread per connection” model Micronaut Data JDBC
According to micronaut-data reactive guide,
"...
In the case of reactive execution and if the backing implementation is blocking, Micronaut Data will use the Configured I/O thread pool to schedule the query execution on a different thread.
If the…

Jim C
- 3,957
- 25
- 85
- 162
10
votes
5 answers
How do I resolve error "No bean of type [io.micronaut.data.operations.PrimaryRepositoryOperations] exists" in micronaut application?
I am evaluating micronaut and am attempting to port a small application as a pilot project. I have run into a snag dealing with datasources/repositories.
I have the following application.yml:
micronaut:
application:
name:…

John Boone
- 111
- 1
- 1
- 6
10
votes
3 answers
Micronaut data : No backing RepositoryOperations configured for repository
I am getting this following exception when I try configuring micronaut-data with inmemory h2 database and Jpa.
I have been following the documentation
I created the project from command line with maven as build tool. I have the following …

pvpkiran
- 25,582
- 8
- 87
- 134
6
votes
1 answer
Micronaut Data JDBC Nested Entities
I have been investigating using Micronaut Data JDBC as an augmentation for existing jdbi queries. Is it possible to do nested MappedEntity's and return the children?
Example is for a simple Warehouse Management System with a relation:
company
+-…

Gary
- 153
- 6
6
votes
1 answer
Micronaut Data DTO projection with properties from joined entities
I use Micronaut Data with JPA and have two entities. The first one is Recipe:
@Entity
public class Recipe {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Integer id;
private String name;
@ManyToOne
private…

cgrim
- 4,890
- 1
- 23
- 42
5
votes
2 answers
'Batch update returned unexpected row count from update' - after update to Micronaut 3.1+
I'm attempting to upgrade to Micronaut 3.2, but starting from 3.1 some write operations on the db started failing. I have created a sample project to showcase this: https://github.com/dpozinen/optimistic-lock
furthermore I have created an issue at…

dpozinen
- 131
- 7
5
votes
0 answers
Micronaut Data: INSERT of Parent-Child relationship with autogenerated Parent ID fails cause Foreign Key not set
stumbled over a problem: Within One-to-Many relationship it seems that auto-generated primary key from parent entity is NOT fed to child entity.
I've boiled down production code to following example:
Entities, One-to-Many relationship of Parent and…

Christian
- 293
- 2
- 14
5
votes
2 answers
How to write integration tests for Micronaut APIs?
Let's say I have an API to GET list of users. Controller -> Service -> Repository.
Coming from Spring background, where for writing test for this API, in test, we could declare the repository with @Autowired and insert the user data using this…

AmitB10
- 425
- 6
- 16
5
votes
1 answer
Configuring database for integration tests in micronaut
I am trying to write an integration test in micronaut.
I have a controller class:
@Controller("/hello")
public class HelloController {
@Inject
private HelloRepository helloRepository;
@Get("/")
public HttpResponse get() {
…

Rajshree Rai
- 533
- 7
- 14
4
votes
1 answer
How to find all employees that contain all character sequenences in their name?
I'm trying to write a Micronaut Data JPA finder that finds all employees that match to a list of strings.
Given the following employees (first name, last name)
John Doe
Jane Doe
Peter Pan
Silvio Wangler
Franka Potente
Frank Potter
Lets pretend a…

saw303
- 8,051
- 7
- 50
- 90
4
votes
0 answers
Multiple Datasource with Micronautor or Quarkus
I want to migrate to Micronaut or Quarkus from Spring Boot, but in Spring boot there is one feature as AbstractRoutingDataSource, which in runtime change datasouce. Is there anything similar or any mechanism in micronaut or quarkus which gives…

Bohdan Myslyvchuk
- 1,657
- 3
- 24
- 39
4
votes
1 answer
Micronaut Unable to implement Repository method: Repository.update(Object entity). No possible implementations found
Here's my stack:
- Micronaut 1.3.2
- Java 8
- Eclipse STS 4
Pom.xml excerpt:
io.micronaut.configuration
micronaut-jdbc-hikari
compile
…

HienaKill
- 101
- 2
- 10
4
votes
2 answers
Getting error while connecting to jpa using micronaut-data-hibernate-jpa library
I want to use JPA for micronaut. For that I am using io.micronaut.data:micronaut-data-hibernate-jpa:1.0.0.M1 library. Whenever I run my application and hit the endpoint to get the data, I get the following error:
{
message: "Internal Server…

tony allen
- 67
- 1
- 9
3
votes
0 answers
Delete all not supported for entities with no ID - Groovy and JPA
I have an issue with a very simple application I'm writing.
The persistence is handled with micronaut-data /w JPA, the DB is H2 for now.
I have a Comment model which looks like this:
package cloud.intepreting.models
import…

Bartosz Budzyński
- 41
- 3
3
votes
0 answers
Order resulting collection of JPA query by @OrderColumn of join table
I have the following entities within my Micronaut 3.0.3 application.
public class Game extends BaseEntity {
...
@OneToMany(cascade = CascadeType.ALL, orphanRemoval = true)
@ToString.Exclude
@OrderColumn(name = "sort_index")
private…

dpozinen
- 131
- 7