[
https://issues.apache.org/jira/browse/CAY-2077?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15249475#comment-15249475
]
Andrus Adamchik commented on CAY-2077:
--------------------------------------
duplicating my PR comment:
Analyzing this some more, I think the fix should be different. Instead of
cleaning the String from special chars, we should simply pass any objects whose
encoding is not immediately clear as parameters to formatter String:
throw new CayenneRuntimeException(""No cached list for %s",
serverMetadata.getCacheKey())
> Bug in CayenneRuntimeException using wrong specified string in Formatter
> ------------------------------------------------------------------------
>
> Key: CAY-2077
> URL: https://issues.apache.org/jira/browse/CAY-2077
> Project: Cayenne
> Issue Type: Bug
> Affects Versions: 4.0.M4
> Reporter: Olga Bondareva
>
> INFO: Exception processing message org.apache.cayenne.remote.QueryMessage of
> type Query
> java.util.UnknownFormatConversionException: Conversion = '"'
> at java.util.Formatter.checkText(Formatter.java:2579)
> at java.util.Formatter.parse(Formatter.java:2565)
> at java.util.Formatter.format(Formatter.java:2501)
> at java.util.Formatter.format(Formatter.java:2455)
> at java.lang.String.format(String.java:2928)
> at
> org.apache.cayenne.access.ClientServerChannelQueryAction.interceptSinglePageQuery(ClientServerChannelQueryAction.java:99)
> at
> org.apache.cayenne.access.ClientServerChannelQueryAction.execute(ClientServerChannelQueryAction.java:64)
> at
> org.apache.cayenne.access.ClientServerChannel.onQuery(ClientServerChannel.java:51)
> at
> org.apache.cayenne.remote.service.DispatchHelper.dispatch(DispatchHelper.java:39)
> at
> org.apache.cayenne.remote.service.BaseRemoteService.processMessage(BaseRemoteService.java:135)
> at org.apache.cayenne.rop.ROPServlet.doPost(ROPServlet.java:122)
> invalid format specifiers
> String.format(messageFormat, messageArgs)
> For example , Painting/name likeIgnoreCase "gi%"/l2 can't be used as
> messageFormat
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)