Questions tagged [deltaspike-jpa]

10 questions
3
votes
2 answers

Persist value only in secondary table

Anyone have example of how to persist the values only in secondary table? @Entity @Named("account") @Table(name = "ACCOUNT", uniqueConstraints = {}) @SecondaryTables({ @SecondaryTable(name = "ACCOUNTCOMMENT", pkJoinColumns = {…
Sudha
  • 220
  • 2
  • 16
2
votes
1 answer

Deltaspike Data (CDI + JPA) Custom PrePersistAuditListener and PreUpdateAuditListener for custom java.time.ChronoLocalDateTime at UTC

Deltaspike Ver 1.7.2 on Wildfly 9.0.2.Final I'm using the JPA @EntityListeners(AuditEntityListener.class) and the audit functionality of Deltaspike Data (@CreatedOn, @ModifiedOn and @ModifiedBy annotations) on an entity bean with the difference…
nicoschl
  • 2,346
  • 1
  • 17
  • 17
1
vote
1 answer

Spring Data JPA query with optional paramters

I have an GET endpoint which fetches the data based on the below parameters. firstName is mandatory and rest all are optional. { "firstName:"", "lastName:"", "Gender:"", "city""" } How should i approach for the database query? i am using Sring…
Vinay Vullakula
  • 63
  • 1
  • 4
  • 13
1
vote
2 answers

Deltaspike alternative TransactionStrategy issue

In my wildfly swarm application I would like to use deltaspike with the data module, JPA and JTA. I have defined my beans.xml as this to use EnvironmentAwareTransactionStrategy as TransactionStrategy.
1
vote
1 answer

DeltaSpike Test-Control - Persistence Unit Not Found

I am trying to use DeltaSpike Test-Control Module to create integration tests for a new maven application that I am developing It is being deployed on a Wildfly 9 instance A simple test case: @RunWith(CdiTestRunner.class) @TestControl(projectStage =…
Marcos J.C Kichel
  • 6,887
  • 8
  • 38
  • 78
0
votes
1 answer

How to execute a stored procedure in Apache Delta Spike

I'm using Apache Delta Spike's Data module in my project, however, I don't find in it's documentation a proper way to execute and get results from a stored procedure call... Can someone help me?
0
votes
1 answer

OutOfMemoryError causes commit of JPA transaction

When my system gets "OutOfMemoryError: Java heap space", it commits the transaction (marked with org.apache.deltaspike.jpa.api.transaction.Transactional annotation). How to avoid this and make a rollback instead? "Regular" exceptions do cause the…
Aivar
  • 6,814
  • 5
  • 46
  • 78
0
votes
0 answers

Deltaspike repository transaction commits but nothing persists in DB in Java SE

I'm using DeltaSpike repositories to persist an entity in Java SE and I'm using file based H2 database. The problem is that while there is no error in the console, nothing gets persisted in the database. I checked the database contents using an…
zaerymoghaddam
  • 3,037
  • 1
  • 27
  • 33
0
votes
1 answer

Wildfly - deltaspike - transaction not committed?

I am using Wildfly 10 along with Deltaspike and having issues persisting an entity. The problem comes later on when I try to refresh it or persist another entity referring to it. When I try to refresh it, I get the exception indicating the entity…
Walter
  • 1,290
  • 2
  • 21
  • 46
0
votes
0 answers

Rollback JUnit Tests in Deltaspike

I am using Apache Deltaspike with OpenWebBeans for CDI in a Java SE project. I've used Spring Data JPA in a Java EE project and it was easy enough to setup unit tests that didn't commit data to the database by adding the @Transactional annotation…
David Yee
  • 3,515
  • 25
  • 45