You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user-java@ibatis.apache.org by Marco Berri <ma...@bluestudio.it> on 2005/07/19 16:24:33 UTC

Problem Oscache + Ibatis

Hy all!
I realized an Ibatis embedded Java application with OScache.
Within Linux environment everything is right, but within Win environment 
(Windows 2003 Server) OS cache falls down and cache can't be written.
Anybody could help me?
Lot of thanks


Specifications::

SO: windows 2003 Server EE
Ibatis: 2.1.0.565
OSCACHE: 2.1.1

Tomcat: 5.0

oscache.properties

cache.memory=false
cache.key=__oscache_cache
cache.persistence.class =
com.opensymphony.oscache.plugins.diskpersistence.HashDiskPersistenceListener
#because the windows don't write file with "|"
cache.persistence.disk.hash.algorithm = MD5

cache.path=f:\\oscache
cache.algorithm=com.opensymphony.oscache.base.algorithm.UnlimitedCache
cache.capacity=150
cache.unlimited.disk=true


Re: synchronization between DB and ibatis sqlmaps

Posted by Ed Griebel <ed...@gmail.com>.
You could try httpunit which runs unit tests against your web server,
which would implicitly check your database mappings. And it would have
the side-effect of testing your web app too.

-ed

On 7/20/05, Darek Dober <do...@op.pl> wrote:
>  
> Because of laziness:) 
> Writting test cases takes some time. 
>   
> I'm developing application using Tomcat, and I start to realize, that
> testing on real application takes to much time, including deploying, logging
> on, and so on. 
>   
> At the beginning it seemed to be a good choice, but it isn't. I have the
> problem with refreshing sqlmap files by tomcat (it was mentioned on this
> group, but doesn't work for me), so I have to deploy and reload application.
> Even using ant to reloadTask and than logon is a little slow. So test case
> seems to be the fastest way. 
>   
> What is your advice. 
> Is building test cases  the best practise and fastest of doing this? 
>   
> Darek
>  
>   
>   
>  
> ----- Original Message ----- 
> From: Clinton Begin 
> To: user-java@ibatis.apache.org 
> Sent: Wednesday, July 20, 2005 4:06 PM 
> Subject: Re: synchronization between DB and ibatis sqlmaps 
> 
> 
> Why wouldn't you have test cases to test your statements anyway?
> 
> Cheers,
> Clinton
> 
>  
> On 7/20/05, Darek Dober <do...@op.pl> wrote: 
> > Do you have any solutions for that?
> > 
> > Let's assume, that something changed in database, i.e names of tables or
> > columns. And you forgot to change it.
> > 
> > As far as I know I cannot check if sqlmap command is still valid, unless i
> > execute it. It is difficult to execute and check all of the sqlmaps. Bean
> > properties
> > are checked at creation of ibatis instance so you get an error, but what
> if
> > something changed in database?
> > 
> > One of the way is to write test case, which should test all of the sqlmaps
> > against any changes.
> > 
> > Is the simplier way to check correctness of all sqlmaps
> > 
> > Darek Dober
> > 
> > 
> 
>

Re: synchronization between DB and ibatis sqlmaps

Posted by Larry Meadors <la...@gmail.com>.
OK, I am going to mark this day on my calendar in bright orange ink.

Wednesday July 25th, 2005: The day Vic and Larry agreed.

;-D

Larry

On 7/20/05, netsql <ne...@roomity.com> wrote:
> Darek Dober wrote:
> > Because of laziness:)
> > Writting test cases takes some time.
> >
> 
> Most of us feel that unit testing it the lazies thing to do.
> 
> >
> > What is your advice.
> > Is building test cases  the best practise and fastest of doing this?
> >
> > Darek
> >
> 
> YES!
> Unless you like random debuging.
> 
> unit testing increases productivity!
> you should unit test only if you are lazy or in a rush.
> 
> Otherwise, if you bill by the hour.... don't unit test.
> .V
> 
>

Re: synchronization between DB and ibatis sqlmaps

Posted by netsql <ne...@roomity.com>.
Darek Dober wrote:
> Because of laziness:)
> Writting test cases takes some time.
>  

Most of us feel that unit testing it the lazies thing to do.

>  
> What is your advice.
> Is building test cases  the best practise and fastest of doing this?
>  
> Darek
>  

YES!
Unless you like random debuging.

unit testing increases productivity!
you should unit test only if you are lazy or in a rush.

Otherwise, if you bill by the hour.... don't unit test.
.V


Re: synchronization between DB and ibatis sqlmaps

Posted by Darek Dober <do...@op.pl>.
Because of laziness:)
Writting test cases takes some time.

I'm developing application using Tomcat, and I start to realize, that testing on real application takes to much time, including deploying, logging on, and so on.

At the beginning it seemed to be a good choice, but it isn't. I have the problem with refreshing sqlmap files by tomcat (it was mentioned on this group, but doesn't work for me), so I have to deploy and reload application. Even using ant to reloadTask and than logon is a little slow. So test case seems to be the fastest way.

What is your advice.
Is building test cases  the best practise and fastest of doing this?

Darek


  ----- Original Message ----- 
  From: Clinton Begin 
  To: user-java@ibatis.apache.org 
  Sent: Wednesday, July 20, 2005 4:06 PM
  Subject: Re: synchronization between DB and ibatis sqlmaps



  Why wouldn't you have test cases to test your statements anyway?

  Cheers,
  Clinton


  On 7/20/05, Darek Dober <do...@op.pl> wrote:
    Do you have any solutions for that?

    Let's assume, that something changed in database, i.e names of tables or
    columns. And you forgot to change it.

    As far as I know I cannot check if sqlmap command is still valid, unless i 
    execute it. It is difficult to execute and check all of the sqlmaps. Bean
    properties
    are checked at creation of ibatis instance so you get an error, but what if
    something changed in database?

    One of the way is to write test case, which should test all of the sqlmaps 
    against any changes.

    Is the simplier way to check correctness of all sqlmaps

    Darek Dober




Re: synchronization between DB and ibatis sqlmaps

Posted by Clinton Begin <cl...@gmail.com>.
Why wouldn't you have test cases to test your statements anyway?

Cheers,
Clinton

On 7/20/05, Darek Dober <do...@op.pl> wrote:
> 
> Do you have any solutions for that?
> 
> Let's assume, that something changed in database, i.e names of tables or
> columns. And you forgot to change it.
> 
> As far as I know I cannot check if sqlmap command is still valid, unless i
> execute it. It is difficult to execute and check all of the sqlmaps. Bean
> properties
> are checked at creation of ibatis instance so you get an error, but what 
> if
> something changed in database?
> 
> One of the way is to write test case, which should test all of the sqlmaps
> against any changes.
> 
> Is the simplier way to check correctness of all sqlmaps
> 
> Darek Dober
> 
>

synchronization between DB and ibatis sqlmaps

Posted by Darek Dober <do...@op.pl>.
Do you have any solutions for that?

Let's assume, that something changed in database, i.e names of tables or
columns. And you forgot to change it.

As far as I know I cannot check if sqlmap command is still valid, unless i
execute it. It is difficult to execute and check all of the sqlmaps. Bean
properties
are checked at creation of ibatis instance so you get an error, but what if
something changed in database?

One of the way is to write test case, which should test all of the sqlmaps
against any changes.

Is the simplier way to check correctness of all sqlmaps

Darek Dober


Re: [SOLVED]Re: [HELP] [HELP ]Problem Oscache + Ibatis

Posted by Ron Grabowski <ro...@yahoo.com>.
I discovered the IBatisNet is the same way IBATISNET-87 :(  One of the
contributing factors may be that there isn't an easy way to check if
the same row handler has been passed in on subsequent calls to
QueryWithRowsHandler. If the same parameters and row handler has been
passed in, then the value stored in the cache should be returned
without having to iterate. Some people may expect the row handler to be
run against the cached data each time. What behavior would you expect?
I can think of useful scenarios for both.

--- Marco Berri <ma...@bluestudio.it> wrote:

> I solved the Problem,
> 
> My application Use API QueryWithRowsHandler.
> this API NOT SUPPORT write/read the CACHE!
> 
> by
> Marco Berri
> 
> 
> Marco Berri wrote:
> > 
> > Hi all!
> > 
> > I tried a lot of times and I noticed that Ibatis is the matter.
> > 
> > Recalling OScache API in writing and reading, everything is
> completely 
> > functional.
> > 
> > OScache logs make me know they are able to write cache
> informations.
> > 
> > Other sqlmap specifications:
> > 
> > <?xml version="1.0" encoding="UTF-8" ?>
> > <!DOCTYPE sqlMapConfig PUBLIC "-//iBATIS.com//DTD SQL Map Config 
> > 2.0//EN" "http://www.ibatis.com/dtd/sql-map-config-2.dtd">
> > <sqlMapConfig>
> >    <settings cacheModelsEnabled="true"
> >                        enhancementEnabled="true"
> >                        lazyLoadingEnabled="true"
> >                        maxRequests="32"
> >                        maxSessions="10"
> >                        maxTransactions="10"
> >                        useStatementNamespaces="false"
> >                />
> >            <transactionManager type="JDBC">
> >                <dataSource type="SIMPLE">
> >                    <property name="JDBC.Driver" 
> > value="org.postgresql.Driver"/>
> >                    <property name="JDBC.ConnectionURL" 
> > value="jdbc:postgresql://127.0.0.1:5432/tnes2"/>
> >                    <property name="JDBC.Username" value="xxx"/>
> >                    <property name="JDBC.Password" value="xxx"/>
> >                </dataSource>
> >            </transactionManager>
> >    <sqlMap 
> >
>
url="file:////usr/local/customers/tnes2/www/WEB-INF/tnes/conf/storage/login.xml"/>
> 
> > 
> > 
> > ...
> > ...
> > ..
> > ..
> > ..
> > ..
> > ..
> > ..
> > ..
> > </sqlMapConfig>
> > 
> > 
> > file login.xml
> > 
> > <?xml version="1.0" encoding="UTF-8" ?>
> > <!DOCTYPE sqlMap PUBLIC "-//iBATIS.com//DTD SQL Map 2.0//EN" 
> > "http://www.ibatis.com/dtd/sql-map-2.dtd">
> > <sqlMap namespace="Login">
> > 
> >    <cacheModel id="login-cache" type="OSCACHE">
> >        <flushOnExecute statement="updLoginInfobyLoginId"/>
> >        <flushOnExecute statement="insLogin"/>
> >        <flushOnExecute statement="delLoginById"/>
> >        <flushOnExecute statement="updRetrybyId"/>
> >    </cacheModel>         <cacheModel id="pswpolicy-cache"
> type="OSCACHE">
> >        <flushOnExecute statement="insPswPolicy"/>
> >        <flushOnExecute statement="delPswPolicy"/>
> >        <flushOnExecute statement="updPswPolicybyId"/>
> >    </cacheModel>
> >       <select id="getCountLoginbyUsrCtx"
> resultClass="java.lang.Integer" 
> > cacheModel="login-cache">
> >        SELECT COUNT(VLOGIN_ID) FROM TNES2.VLOGIN WHERE 
> > TRIM(UPPER(TNES2.VLOGIN.VLOGIN_USERNAME)) = UPPER(TRIM(#username#))
> AND 
> > UPPER(TRIM(TNES2.VLOGIN.VLOGIN_CONTEXT)) = UPPER(TRIM(#area#))
> >    </select>
> > 
> > ..........
> > .........
> > .........
> > .......
> > ........
> > .....
> > 
> > 
> >  >>>>>
> >  >>>>> SO: windows 2003 Server EE
> >  >>>>> Ibatis: 2.1.0.565
> >  >>>>> OSCACHE: 2.1.1
> >  >>>>>
> >  >>>>> Tomcat: 5.0
> >  >>>>>
> >  >>>>> oscache.properties
> >  >>>>>
> >  >>>>> cache.memory=false
> >  >>>>> cache.key=__oscache_cache
> >  >>>>> cache.persistence.class =
> >  >>>>> 
> >
>
com.opensymphony.oscache.plugins.diskpersistence.HashDiskPersistenceListener
> 
> > 
> >  >>>>>
> >  >>>>> #because the windows don't write file with "|"
> >  >>>>> cache.persistence.disk.hash.algorithm = MD5
> >  >>>>>
> >  >>>>> cache.path=f:\\oscache
> >  >>>>> 
> >
>
cache.algorithm=com.opensymphony.oscache.base.algorithm.UnlimitedCache
> >  >>>>> cache.capacity=150
> >  >>>>> cache.unlimited.disk=true
> >  >>>>>
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > Marco Berri wrote:
> > 
> >> Hi,
> >> no f is the Local Hard disk Drive
> >>
> >> cache.path=f:\\oscache
> >>
> >>
> >> Larry Meadors wrote:
> >>
> >>> Is F: a network drive?
> >>>
> >>> Larry
> >>>
> >>>
> >>> On 7/20/05, Marco Berri <ma...@bluestudio.it> wrote:
> >>>
> >>>> Hi!
> >>>> Thanks for your answer.
> >>>> Application runs using Administrator user and OSCache writes the
> folder
> >>>> f:\oscache, the sub-folders Application and group and put files
> into
> >>>> them, but it seems that it has some problems reading these
> files;
> >>>> application runs in an infinite loop without any message.
> >>>> Anyboby have suggestions?
> >>>> Thank you!
> >>>>
> >>>>
> >>>>
> >>>> Daniel Henrique Ferreira e Silva wrote:
> >>>>
> >>>>> Hi Marco,
> >>>>>
> >>>>> Not sure but it seems to be not iBATIS.
> >>>>> I'd guess your windows box has a filesystem permissions issue.
> How are
> >>>>> the permissions for f:\\oscache? Does the user that Tomcat
> relies on
> >>>>> has write permission on that directory?
> >>>>>
> >>>>> Hope that helped,
> >>>>> Daniel Silva.
> >>>>>
> >>>>> On 7/19/05, Marco Berri <ma...@bluestudio.it> wrote:
> >>>>>
> >>>>>
> >>>>>> Hy all!
> >>>>>> I realized an Ibatis embedded Java application with OScache.
> >>>>>> Within Linux environment everything is right, but within Win 
> >>>>>> environment
> >>>>>> (Windows 2003 Server) OS cache falls down and cache can't be
> written.
> >>>>>> Anybody could help me?
> >>>>>> Lot of thanks
> >>>>>>
> >>>>>>
> >>>>>> Specifications::
> >>>>>>
> >>>>>> SO: windows 2003 Server EE
> >>>>>> Ibatis: 2.1.0.565
> >>>>>> OSCACHE: 2.1.1
> >>>>>>
> >>>>>> Tomcat: 5.0
> >>>>>>
> >>>>>> oscache.properties
> 
=== message truncated ===


[SOLVED]Re: [HELP] [HELP ]Problem Oscache + Ibatis

Posted by Marco Berri <ma...@bluestudio.it>.
I solved the Problem,

My application Use API QueryWithRowsHandler.
this API NOT SUPPORT write/read the CACHE!

by
Marco Berri


Marco Berri wrote:
> 
> Hi all!
> 
> I tried a lot of times and I noticed that Ibatis is the matter.
> 
> Recalling OScache API in writing and reading, everything is completely 
> functional.
> 
> OScache logs make me know they are able to write cache informations.
> 
> Other sqlmap specifications:
> 
> <?xml version="1.0" encoding="UTF-8" ?>
> <!DOCTYPE sqlMapConfig PUBLIC "-//iBATIS.com//DTD SQL Map Config 
> 2.0//EN" "http://www.ibatis.com/dtd/sql-map-config-2.dtd">
> <sqlMapConfig>
>    <settings cacheModelsEnabled="true"
>                        enhancementEnabled="true"
>                        lazyLoadingEnabled="true"
>                        maxRequests="32"
>                        maxSessions="10"
>                        maxTransactions="10"
>                        useStatementNamespaces="false"
>                />
>            <transactionManager type="JDBC">
>                <dataSource type="SIMPLE">
>                    <property name="JDBC.Driver" 
> value="org.postgresql.Driver"/>
>                    <property name="JDBC.ConnectionURL" 
> value="jdbc:postgresql://127.0.0.1:5432/tnes2"/>
>                    <property name="JDBC.Username" value="xxx"/>
>                    <property name="JDBC.Password" value="xxx"/>
>                </dataSource>
>            </transactionManager>
>    <sqlMap 
> url="file:////usr/local/customers/tnes2/www/WEB-INF/tnes/conf/storage/login.xml"/> 
> 
> 
> ...
> ...
> ..
> ..
> ..
> ..
> ..
> ..
> ..
> </sqlMapConfig>
> 
> 
> file login.xml
> 
> <?xml version="1.0" encoding="UTF-8" ?>
> <!DOCTYPE sqlMap PUBLIC "-//iBATIS.com//DTD SQL Map 2.0//EN" 
> "http://www.ibatis.com/dtd/sql-map-2.dtd">
> <sqlMap namespace="Login">
> 
>    <cacheModel id="login-cache" type="OSCACHE">
>        <flushOnExecute statement="updLoginInfobyLoginId"/>
>        <flushOnExecute statement="insLogin"/>
>        <flushOnExecute statement="delLoginById"/>
>        <flushOnExecute statement="updRetrybyId"/>
>    </cacheModel>         <cacheModel id="pswpolicy-cache" type="OSCACHE">
>        <flushOnExecute statement="insPswPolicy"/>
>        <flushOnExecute statement="delPswPolicy"/>
>        <flushOnExecute statement="updPswPolicybyId"/>
>    </cacheModel>
>       <select id="getCountLoginbyUsrCtx" resultClass="java.lang.Integer" 
> cacheModel="login-cache">
>        SELECT COUNT(VLOGIN_ID) FROM TNES2.VLOGIN WHERE 
> TRIM(UPPER(TNES2.VLOGIN.VLOGIN_USERNAME)) = UPPER(TRIM(#username#)) AND 
> UPPER(TRIM(TNES2.VLOGIN.VLOGIN_CONTEXT)) = UPPER(TRIM(#area#))
>    </select>
> 
> ..........
> .........
> .........
> .......
> ........
> .....
> 
> 
>  >>>>>
>  >>>>> SO: windows 2003 Server EE
>  >>>>> Ibatis: 2.1.0.565
>  >>>>> OSCACHE: 2.1.1
>  >>>>>
>  >>>>> Tomcat: 5.0
>  >>>>>
>  >>>>> oscache.properties
>  >>>>>
>  >>>>> cache.memory=false
>  >>>>> cache.key=__oscache_cache
>  >>>>> cache.persistence.class =
>  >>>>> 
> com.opensymphony.oscache.plugins.diskpersistence.HashDiskPersistenceListener 
> 
>  >>>>>
>  >>>>> #because the windows don't write file with "|"
>  >>>>> cache.persistence.disk.hash.algorithm = MD5
>  >>>>>
>  >>>>> cache.path=f:\\oscache
>  >>>>> 
> cache.algorithm=com.opensymphony.oscache.base.algorithm.UnlimitedCache
>  >>>>> cache.capacity=150
>  >>>>> cache.unlimited.disk=true
>  >>>>>
> 
> 
> 
> 
> 
> 
> 
> Marco Berri wrote:
> 
>> Hi,
>> no f is the Local Hard disk Drive
>>
>> cache.path=f:\\oscache
>>
>>
>> Larry Meadors wrote:
>>
>>> Is F: a network drive?
>>>
>>> Larry
>>>
>>>
>>> On 7/20/05, Marco Berri <ma...@bluestudio.it> wrote:
>>>
>>>> Hi!
>>>> Thanks for your answer.
>>>> Application runs using Administrator user and OSCache writes the folder
>>>> f:\oscache, the sub-folders Application and group and put files into
>>>> them, but it seems that it has some problems reading these files;
>>>> application runs in an infinite loop without any message.
>>>> Anyboby have suggestions?
>>>> Thank you!
>>>>
>>>>
>>>>
>>>> Daniel Henrique Ferreira e Silva wrote:
>>>>
>>>>> Hi Marco,
>>>>>
>>>>> Not sure but it seems to be not iBATIS.
>>>>> I'd guess your windows box has a filesystem permissions issue. How are
>>>>> the permissions for f:\\oscache? Does the user that Tomcat relies on
>>>>> has write permission on that directory?
>>>>>
>>>>> Hope that helped,
>>>>> Daniel Silva.
>>>>>
>>>>> On 7/19/05, Marco Berri <ma...@bluestudio.it> wrote:
>>>>>
>>>>>
>>>>>> Hy all!
>>>>>> I realized an Ibatis embedded Java application with OScache.
>>>>>> Within Linux environment everything is right, but within Win 
>>>>>> environment
>>>>>> (Windows 2003 Server) OS cache falls down and cache can't be written.
>>>>>> Anybody could help me?
>>>>>> Lot of thanks
>>>>>>
>>>>>>
>>>>>> Specifications::
>>>>>>
>>>>>> SO: windows 2003 Server EE
>>>>>> Ibatis: 2.1.0.565
>>>>>> OSCACHE: 2.1.1
>>>>>>
>>>>>> Tomcat: 5.0
>>>>>>
>>>>>> oscache.properties
>>>>>>
>>>>>> cache.memory=false
>>>>>> cache.key=__oscache_cache
>>>>>> cache.persistence.class =
>>>>>> com.opensymphony.oscache.plugins.diskpersistence.HashDiskPersistenceListener 
>>>>>>
>>>>>> #because the windows don't write file with "|"
>>>>>> cache.persistence.disk.hash.algorithm = MD5
>>>>>>
>>>>>> cache.path=f:\\oscache
>>>>>> cache.algorithm=com.opensymphony.oscache.base.algorithm.UnlimitedCache 
>>>>>>
>>>>>> cache.capacity=150
>>>>>> cache.unlimited.disk=true
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>
>>>
>>
>>
> 
> 

[HELP] [HELP ]Problem Oscache + Ibatis

Posted by Marco Berri <ma...@bluestudio.it>.
Hi all!

I tried a lot of times and I noticed that Ibatis is the matter.

Recalling OScache API in writing and reading, everything is completely 
functional.

OScache logs make me know they are able to write cache informations.

Other sqlmap specifications:

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE sqlMapConfig PUBLIC "-//iBATIS.com//DTD SQL Map Config 
2.0//EN" "http://www.ibatis.com/dtd/sql-map-config-2.dtd">
<sqlMapConfig>
    <settings cacheModelsEnabled="true"
                        enhancementEnabled="true"
                        lazyLoadingEnabled="true"
                        maxRequests="32"
                        maxSessions="10"
                        maxTransactions="10"
                        useStatementNamespaces="false"
                />
            <transactionManager type="JDBC">
                <dataSource type="SIMPLE">
                    <property name="JDBC.Driver" 
value="org.postgresql.Driver"/>
                    <property name="JDBC.ConnectionURL" 
value="jdbc:postgresql://127.0.0.1:5432/tnes2"/>
                    <property name="JDBC.Username" value="xxx"/>
                    <property name="JDBC.Password" value="xxx"/>
                </dataSource>
            </transactionManager>
    <sqlMap 
url="file:////usr/local/customers/tnes2/www/WEB-INF/tnes/conf/storage/login.xml"/>

...
...
..
..
..
..
..
..
..
</sqlMapConfig>


file login.xml

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE sqlMap PUBLIC "-//iBATIS.com//DTD SQL Map 2.0//EN" 
"http://www.ibatis.com/dtd/sql-map-2.dtd">
<sqlMap namespace="Login">

    <cacheModel id="login-cache" type="OSCACHE">
        <flushOnExecute statement="updLoginInfobyLoginId"/>
        <flushOnExecute statement="insLogin"/>
        <flushOnExecute statement="delLoginById"/>
        <flushOnExecute statement="updRetrybyId"/>
    </cacheModel>         <cacheModel id="pswpolicy-cache" type="OSCACHE">
        <flushOnExecute statement="insPswPolicy"/>
        <flushOnExecute statement="delPswPolicy"/>
        <flushOnExecute statement="updPswPolicybyId"/>
    </cacheModel>
       <select id="getCountLoginbyUsrCtx" 
resultClass="java.lang.Integer" cacheModel="login-cache">
        SELECT COUNT(VLOGIN_ID) FROM TNES2.VLOGIN WHERE 
TRIM(UPPER(TNES2.VLOGIN.VLOGIN_USERNAME)) = UPPER(TRIM(#username#)) AND 
UPPER(TRIM(TNES2.VLOGIN.VLOGIN_CONTEXT)) = UPPER(TRIM(#area#))
    </select>

..........
.........
.........
.......
........
.....


 >>>>>
 >>>>> SO: windows 2003 Server EE
 >>>>> Ibatis: 2.1.0.565
 >>>>> OSCACHE: 2.1.1
 >>>>>
 >>>>> Tomcat: 5.0
 >>>>>
 >>>>> oscache.properties
 >>>>>
 >>>>> cache.memory=false
 >>>>> cache.key=__oscache_cache
 >>>>> cache.persistence.class =
 >>>>> 
com.opensymphony.oscache.plugins.diskpersistence.HashDiskPersistenceListener 

 >>>>>
 >>>>> #because the windows don't write file with "|"
 >>>>> cache.persistence.disk.hash.algorithm = MD5
 >>>>>
 >>>>> cache.path=f:\\oscache
 >>>>> 
cache.algorithm=com.opensymphony.oscache.base.algorithm.UnlimitedCache
 >>>>> cache.capacity=150
 >>>>> cache.unlimited.disk=true
 >>>>>







Marco Berri wrote:
> Hi,
> no f is the Local Hard disk Drive
> 
> cache.path=f:\\oscache
> 
> 
> Larry Meadors wrote:
> 
>> Is F: a network drive?
>>
>> Larry
>>
>>
>> On 7/20/05, Marco Berri <ma...@bluestudio.it> wrote:
>>
>>> Hi!
>>> Thanks for your answer.
>>> Application runs using Administrator user and OSCache writes the folder
>>> f:\oscache, the sub-folders Application and group and put files into
>>> them, but it seems that it has some problems reading these files;
>>> application runs in an infinite loop without any message.
>>> Anyboby have suggestions?
>>> Thank you!
>>>
>>>
>>>
>>> Daniel Henrique Ferreira e Silva wrote:
>>>
>>>> Hi Marco,
>>>>
>>>> Not sure but it seems to be not iBATIS.
>>>> I'd guess your windows box has a filesystem permissions issue. How are
>>>> the permissions for f:\\oscache? Does the user that Tomcat relies on
>>>> has write permission on that directory?
>>>>
>>>> Hope that helped,
>>>> Daniel Silva.
>>>>
>>>> On 7/19/05, Marco Berri <ma...@bluestudio.it> wrote:
>>>>
>>>>
>>>>> Hy all!
>>>>> I realized an Ibatis embedded Java application with OScache.
>>>>> Within Linux environment everything is right, but within Win 
>>>>> environment
>>>>> (Windows 2003 Server) OS cache falls down and cache can't be written.
>>>>> Anybody could help me?
>>>>> Lot of thanks
>>>>>
>>>>>
>>>>> Specifications::
>>>>>
>>>>> SO: windows 2003 Server EE
>>>>> Ibatis: 2.1.0.565
>>>>> OSCACHE: 2.1.1
>>>>>
>>>>> Tomcat: 5.0
>>>>>
>>>>> oscache.properties
>>>>>
>>>>> cache.memory=false
>>>>> cache.key=__oscache_cache
>>>>> cache.persistence.class =
>>>>> com.opensymphony.oscache.plugins.diskpersistence.HashDiskPersistenceListener 
>>>>>
>>>>> #because the windows don't write file with "|"
>>>>> cache.persistence.disk.hash.algorithm = MD5
>>>>>
>>>>> cache.path=f:\\oscache
>>>>> cache.algorithm=com.opensymphony.oscache.base.algorithm.UnlimitedCache
>>>>> cache.capacity=150
>>>>> cache.unlimited.disk=true
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>
>>
> 
> 

Re: Problem Oscache + Ibatis

Posted by Marco Berri <ma...@bluestudio.it>.
Hi,
no f is the Local Hard disk Drive

cache.path=f:\\oscache


Larry Meadors wrote:
> Is F: a network drive?
> 
> Larry
> 
> 
> On 7/20/05, Marco Berri <ma...@bluestudio.it> wrote:
> 
>>Hi!
>>Thanks for your answer.
>>Application runs using Administrator user and OSCache writes the folder
>>f:\oscache, the sub-folders Application and group and put files into
>>them, but it seems that it has some problems reading these files;
>>application runs in an infinite loop without any message.
>>Anyboby have suggestions?
>>Thank you!
>>
>>
>>
>>Daniel Henrique Ferreira e Silva wrote:
>>
>>>Hi Marco,
>>>
>>>Not sure but it seems to be not iBATIS.
>>>I'd guess your windows box has a filesystem permissions issue. How are
>>>the permissions for f:\\oscache? Does the user that Tomcat relies on
>>>has write permission on that directory?
>>>
>>>Hope that helped,
>>>Daniel Silva.
>>>
>>>On 7/19/05, Marco Berri <ma...@bluestudio.it> wrote:
>>>
>>>
>>>>Hy all!
>>>>I realized an Ibatis embedded Java application with OScache.
>>>>Within Linux environment everything is right, but within Win environment
>>>>(Windows 2003 Server) OS cache falls down and cache can't be written.
>>>>Anybody could help me?
>>>>Lot of thanks
>>>>
>>>>
>>>>Specifications::
>>>>
>>>>SO: windows 2003 Server EE
>>>>Ibatis: 2.1.0.565
>>>>OSCACHE: 2.1.1
>>>>
>>>>Tomcat: 5.0
>>>>
>>>>oscache.properties
>>>>
>>>>cache.memory=false
>>>>cache.key=__oscache_cache
>>>>cache.persistence.class =
>>>>com.opensymphony.oscache.plugins.diskpersistence.HashDiskPersistenceListener
>>>>#because the windows don't write file with "|"
>>>>cache.persistence.disk.hash.algorithm = MD5
>>>>
>>>>cache.path=f:\\oscache
>>>>cache.algorithm=com.opensymphony.oscache.base.algorithm.UnlimitedCache
>>>>cache.capacity=150
>>>>cache.unlimited.disk=true
>>>>
>>>>
>>>
>>>
>>>
> 
> 

Re: Problem Oscache + Ibatis

Posted by Larry Meadors <la...@gmail.com>.
Is F: a network drive?

Larry


On 7/20/05, Marco Berri <ma...@bluestudio.it> wrote:
> Hi!
> Thanks for your answer.
> Application runs using Administrator user and OSCache writes the folder
> f:\oscache, the sub-folders Application and group and put files into
> them, but it seems that it has some problems reading these files;
> application runs in an infinite loop without any message.
> Anyboby have suggestions?
> Thank you!
> 
> 
> 
> Daniel Henrique Ferreira e Silva wrote:
> > Hi Marco,
> >
> > Not sure but it seems to be not iBATIS.
> > I'd guess your windows box has a filesystem permissions issue. How are
> > the permissions for f:\\oscache? Does the user that Tomcat relies on
> > has write permission on that directory?
> >
> > Hope that helped,
> > Daniel Silva.
> >
> > On 7/19/05, Marco Berri <ma...@bluestudio.it> wrote:
> >
> >>Hy all!
> >>I realized an Ibatis embedded Java application with OScache.
> >>Within Linux environment everything is right, but within Win environment
> >>(Windows 2003 Server) OS cache falls down and cache can't be written.
> >>Anybody could help me?
> >>Lot of thanks
> >>
> >>
> >>Specifications::
> >>
> >>SO: windows 2003 Server EE
> >>Ibatis: 2.1.0.565
> >>OSCACHE: 2.1.1
> >>
> >>Tomcat: 5.0
> >>
> >>oscache.properties
> >>
> >>cache.memory=false
> >>cache.key=__oscache_cache
> >>cache.persistence.class =
> >>com.opensymphony.oscache.plugins.diskpersistence.HashDiskPersistenceListener
> >>#because the windows don't write file with "|"
> >>cache.persistence.disk.hash.algorithm = MD5
> >>
> >>cache.path=f:\\oscache
> >>cache.algorithm=com.opensymphony.oscache.base.algorithm.UnlimitedCache
> >>cache.capacity=150
> >>cache.unlimited.disk=true
> >>
> >>
> >
> >
> >
>

Re: Problem Oscache + Ibatis

Posted by Marco Berri <ma...@bluestudio.it>.
Hi!
Thanks for your answer.
Application runs using Administrator user and OSCache writes the folder 
f:\oscache, the sub-folders Application and group and put files into 
them, but it seems that it has some problems reading these files; 
application runs in an infinite loop without any message.
Anyboby have suggestions?
Thank you!



Daniel Henrique Ferreira e Silva wrote:
> Hi Marco,
> 
> Not sure but it seems to be not iBATIS.
> I'd guess your windows box has a filesystem permissions issue. How are
> the permissions for f:\\oscache? Does the user that Tomcat relies on
> has write permission on that directory?
> 
> Hope that helped,
> Daniel Silva.
> 
> On 7/19/05, Marco Berri <ma...@bluestudio.it> wrote:
> 
>>Hy all!
>>I realized an Ibatis embedded Java application with OScache.
>>Within Linux environment everything is right, but within Win environment
>>(Windows 2003 Server) OS cache falls down and cache can't be written.
>>Anybody could help me?
>>Lot of thanks
>>
>>
>>Specifications::
>>
>>SO: windows 2003 Server EE
>>Ibatis: 2.1.0.565
>>OSCACHE: 2.1.1
>>
>>Tomcat: 5.0
>>
>>oscache.properties
>>
>>cache.memory=false
>>cache.key=__oscache_cache
>>cache.persistence.class =
>>com.opensymphony.oscache.plugins.diskpersistence.HashDiskPersistenceListener
>>#because the windows don't write file with "|"
>>cache.persistence.disk.hash.algorithm = MD5
>>
>>cache.path=f:\\oscache
>>cache.algorithm=com.opensymphony.oscache.base.algorithm.UnlimitedCache
>>cache.capacity=150
>>cache.unlimited.disk=true
>>
>>
> 
> 
> 

Re: Problem Oscache + Ibatis

Posted by Daniel Henrique Ferreira e Silva <dh...@gmail.com>.
Hi Marco,

Not sure but it seems to be not iBATIS.
I'd guess your windows box has a filesystem permissions issue. How are
the permissions for f:\\oscache? Does the user that Tomcat relies on
has write permission on that directory?

Hope that helped,
Daniel Silva.

On 7/19/05, Marco Berri <ma...@bluestudio.it> wrote:
> Hy all!
> I realized an Ibatis embedded Java application with OScache.
> Within Linux environment everything is right, but within Win environment
> (Windows 2003 Server) OS cache falls down and cache can't be written.
> Anybody could help me?
> Lot of thanks
> 
> 
> Specifications::
> 
> SO: windows 2003 Server EE
> Ibatis: 2.1.0.565
> OSCACHE: 2.1.1
> 
> Tomcat: 5.0
> 
> oscache.properties
> 
> cache.memory=false
> cache.key=__oscache_cache
> cache.persistence.class =
> com.opensymphony.oscache.plugins.diskpersistence.HashDiskPersistenceListener
> #because the windows don't write file with "|"
> cache.persistence.disk.hash.algorithm = MD5
> 
> cache.path=f:\\oscache
> cache.algorithm=com.opensymphony.oscache.base.algorithm.UnlimitedCache
> cache.capacity=150
> cache.unlimited.disk=true
> 
>