[ 
https://issues.apache.org/jira/browse/OPENJPA-2974?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18111063#comment-18111063
 ] 

ASF subversion and git services commented on OPENJPA-2974:
----------------------------------------------------------

Commit 5505aa813e7dfcec95a0f0a013070dad758d3650 in openjpa's branch 
refs/heads/master from Paulo Cristovão de Araújo Silva Filho
[ https://gitbox.apache.org/repos/asf?p=openjpa.git;h=5505aa813 ]

Merge pull request #174 from apache/OPENJPA-2974

[OPENJPA-2974] Convert String cache mode properties to their enum again

> String cache mode properties no longer converted to enum
> --------------------------------------------------------
>
>                 Key: OPENJPA-2974
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-2974
>             Project: OpenJPA
>          Issue Type: Sub-task
>          Components: jpa
>    Affects Versions: 4.2.0
>            Reporter: Maxim Solodovnik
>            Priority: Major
>             Fix For: 4.2.0
>
>
> Discussion thread: 
> https://github.com/apache/openjpa/pull/144#discussion_r3683004301
> **(medium)** The early `return (T) value;` now also fires for String values 
> of `cache.retrieveMode`/`cache.storeMode`, skipping the enum conversion 
> below. Since EntityManagerImpl now exposes 
> `setCacheRetrieveMode(CacheRetrieveMode)`, 
> `em.setProperty("jakarta.persistence.cache.retrieveMode", "USE")` will try to 
> inject a raw String into the enum setter and fail, whereas the old code 
> converted it. Should Strings still be converted to the target enum here?



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to