[forge-issues] [JBoss JIRA] (FORGE-2373) jpa-new-entity should be able to use caching
Antonio Goncalves (JIRA)
issues at jboss.org
Mon Jun 22 05:15:05 EDT 2015
Antonio Goncalves created FORGE-2373:
----------------------------------------
Summary: jpa-new-entity should be able to use caching
Key: FORGE-2373
URL: https://issues.jboss.org/browse/FORGE-2373
Project: Forge
Issue Type: Sub-task
Components: Java EE
Affects Versions: 2.16.2.Final
Reporter: Antonio Goncalves
Fix For: 2.x Future
It would be good to enable second level cache in an Entity. Something like adding an extra parameter to the {{jpa-new-entity}} command :
{code}
jpa-new-entity --named MyEntity --isCacheable
{code}
This would generate the following with the {{javax.persistence.Cacheable}} annotation :
{code}
@Cacheable
@Entity
public class Book implements Serializable {
@Id
@GeneratedValue(strategy = GenerationType.AUTO)
@Column(name = "id", updatable = false, nullable = false)
private Long id;
@Version
@Column(name = "version")
private int version;
// ...
}
{code}
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
More information about the forge-issues
mailing list