https://bz.apache.org/bugzilla/show_bug.cgi?id=66050

--- Comment #3 from feng <809364...@qq.com> ---
To Felix Schumacher:
First of all,thanks for your reply.I took your advice and make some changes:
1.There are historical reasons for using prepared statements,but anyway , i
changed to select statement and follow your 6th and 7th advice.
I put Jmeter on the intranet,set the pool size to "0",using select statement,
and the problem remains.

2.I collect a few thread dumps,gc-log,async profiler while the script is
running:
It seems its been blocked by AbstractJdbcTestElement.getStringFromResult
Is that mean ,the dolphindb_jdbc.jar is very inefficient in parsing data.
Is there any way i can avoid this . like : not parsing data or parsing data
won't block the query thread?

Well,maybe i can change sql into :
select count(*) from (select timestamp,value from ..)
but this goes against my needs in the first place

3.I don't program with java sampler.I just make a runnable java program which
support to start multiple threads to query continuously for 1 minute.
In my code , i don't parse the data, just query.
The core code like this :

            long runningtime = System.currentTimeMillis()+minute*60*1000;

            long begintime = System.currentTimeMillis();
            do {

                count++;
                try {
                        // genarate a random sql                         
                        sql = createSql.genSql();
                        long b = System.currentTimeMillis();
                        PreparedStatement stmt = conn.prepareStatement(sql);
                        ResultSet rs = stmt.executeQuery();
                        long c = System.currentTimeMillis();
                        System.out.println("cost:"+(c-b));
                }catch ...
             } while (System.currentTimeMillis()<runningtime);

I have upload the logs , dumps , async profile。
Looking forward to your reply.
                                                             Thanks !

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to