[jira] Created: (IBATIS-621) Improper cache create mechanism

View: New views
2 Messages — Rating Filter:   Alert me  

[jira] Created: (IBATIS-621) Improper cache create mechanism

by JIRA ibatis-dev@incubator.apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Improper cache create mechanism
-------------------------------

                 Key: IBATIS-621
                 URL: https://issues.apache.org/jira/browse/IBATIS-621
             Project: iBatis for Java
          Issue Type: Bug
    Affects Versions: 3.0.0
            Reporter: Yuan Tao
             Fix For: 3.0.0


My sql map has some ${XXX} tag, no #{..} tag. When execute it with deferent patameterObject in the one session, It retrurn the same result.

In BaseExecutor :

  public CacheKey createCacheKey(MappedStatement ms, Object parameterObject, int offset, int limit) {
    BoundSql boundSql = ms.getBoundSql(parameterObject);
    CacheKey cacheKey = new CacheKey();
    cacheKey.update(ms.getId());  // *************  Maybe use  cacheKey.update(boundSql.getSql()) is better.
    cacheKey.update(offset);
    cacheKey.update(limit);
    List<ParameterMapping> parameterMappings = boundSql.getParameterMappings();
    if (parameterMappings.size() > 0 && parameterObject != null) {
..........



--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@...
For additional commands, e-mail: dev-help@...


[jira] Closed: (IBATIS-621) Improper cache create mechanism

by JIRA ibatis-dev@incubator.apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


     [ https://issues.apache.org/jira/browse/IBATIS-621?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Clinton Begin closed IBATIS-621.
--------------------------------

       Resolution: Fixed
    Fix Version/s:     (was: 3.next)
                   3.0 Beta 2
         Assignee: Clinton Begin

Fixed.  

> Improper cache create mechanism
> -------------------------------
>
>                 Key: IBATIS-621
>                 URL: https://issues.apache.org/jira/browse/IBATIS-621
>             Project: iBatis for Java
>          Issue Type: Bug
>    Affects Versions: 3.0 Beta 1
>            Reporter: Yuan Tao
>            Assignee: Clinton Begin
>             Fix For: 3.0 Beta 2
>
>
> My sql map has some ${XXX} tag, no #{..} tag. When execute it with deferent patameterObject in the one session, It retrurn the same result.
> In BaseExecutor :
>   public CacheKey createCacheKey(MappedStatement ms, Object parameterObject, int offset, int limit) {
>     BoundSql boundSql = ms.getBoundSql(parameterObject);
>     CacheKey cacheKey = new CacheKey();
>     cacheKey.update(ms.getId());  // *************  Maybe use  cacheKey.update(boundSql.getSql()) is better.
>     cacheKey.update(offset);
>     cacheKey.update(limit);
>     List<ParameterMapping> parameterMappings = boundSql.getParameterMappings();
>     if (parameterMappings.size() > 0 && parameterObject != null) {
> ..........

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@...
For additional commands, e-mail: dev-help@...