Здравствуйте, гость ( Вход | Регистрация )

Навигация

Ссылки форума

Навигация по форуму

Mysql запрос => сервер, Загрузка ЦП, ошибка запроса.
Dragon
сообщение 3.10.2009, 14:00
Сообщение #1



Познающий
Группа: Members
Сообщений: 72
Регистрация: 23.5.2007
Поблагодарили: 55 *


Здравствуйте, юзаю основу l2j + свои наработки с ребятами..

так вот... не знаю что делать, было все хорошо, потом стреслась проблема с БД, я ее устранил, но после того случая

ЛЮБЫЕ значения в clanhall__functions или castle_functions ВНОСИТЬСЯ с бешаной скоростью N ое количество раз!!!

и Цп уходит в 100%.

Кусок кода из Clanhall.java
Код
public void dbSave(boolean newFunction)
        {
            Connection con = null;
            try
            {
                PreparedStatement statement;
                
                con = L2DatabaseFactory.getInstance().getConnection();
                if (newFunction)
                {
                    statement = con.prepareStatement("INSERT INTO clanhall_functions (hall_id, type, lvl, lease, rate, endTime) VALUES (?,?,?,?,?,?)");
                    statement.setInt(1, getId());
                    statement.setInt(2, getType());
                    statement.setInt(3, getLvl());
                    statement.setInt(4, getLease());
                    statement.setLong(5, getRate());
                    statement.setLong(6, getEndTime());
                }
                else
                {
                    statement = con.prepareStatement("UPDATE clanhall_functions SET lvl=?, lease=?, endTime=? WHERE hall_id=? AND type=?");
                    statement.setInt(1, getLvl());
                    statement.setInt(2, getLease());
                    statement.setLong(3, getEndTime());
                    statement.setInt(4, getId());
                    statement.setInt(5, getType());
                }
                statement.execute();
                statement.close();
            }
            catch (Exception e)
            {
                _log.log(Level.SEVERE, "Exception: ClanHall.updateFunctions(int type, int lvl, int lease, long rate, long time, boolean addNew): "
                        + e.getMessage(), e);
            }
            finally
            {
                try
                {
                    con.close();
                }
                catch (Exception e)
                {
                }
            }
        }
    }



сами ошибки в MYSQL log
Код
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235285 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235285 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235285 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235285 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235286 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235286 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235286 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235286 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235286 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235286 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235286 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235287 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235287 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235287 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235287 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235287 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235287 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235287 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235287 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235287 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235288 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235288 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235288 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235288 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235288 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235288 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235288 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235288 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235289 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235289 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235289 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235289 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235289 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235289 WHERE hall_id=48 AND type=8
           1838 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235289 WHERE hall_id=48 AND type=8
           2457 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235289 WHERE hall_id=48 AND type=8
           2455 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235290 WHERE hall_id=48 AND type=8
           2457 Query       UPDATE clanhall_functions SET lvl=2, lease=0, endTime=1254561235290 WHERE hall_id=48 AND type=8
Go to the top of the page
 
+Quote Post
 
Start new topic
Ответов
Dragon
сообщение 4.10.2009, 10:53
Сообщение #2



Познающий
Группа: Members
Сообщений: 72
Регистрация: 23.5.2007
Поблагодарили: 55 *


тему клоуз фиксанул...
Go to the top of the page
 
+Quote Post



Closed TopicStart new topic
1 чел. читают эту тему (гостей: 1, скрытых пользователей: 0)
Пользователей: 0

 

RSS Текстовая версия Сейчас: 14.6.2026, 11:51