embedded firebird 를 사용 중입니다.
쓰레드 30 개에서 각각 DB에 연결 Stored Procedure 를 호출 합니다.
30개 쓰레드에서 1초에 총 100번 정도 stored procedure 를 호출 하는데
stored procedure 는 업데이트만 하게 되어 있습니다.
이 상태에서 30분에 약 0.2MB 정도씩 용량이 늘어 납니다.
24시간 돌리면 약 10M 정도 커집니다.
속도도 조금씩 느려지고요.
TIBStoredProc 를 사용하고,
with FProc do
begin
try
if Transaction.InTransaction then
begin
Transaction.Rollback;
Close;
end;
Transaction.StartTransaction;
StoredProcName := 'PR_UPDATE';
Params.Clear;
...........................
if not Prepared then
Prepare;
ExecProc;
UnPrepare;
Result := ParamByName('PO_RET').AsInteger = 1;
if Result then
begin
Transaction.Commit;
end
else
Transaction.Rollback;
Close;
except
Result := False;
Transaction.Rollback;
Close;
end;
end;
XP, 쿼드코어 에서 사용중입니다.
|