db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gabriele Kahlout <gabri...@mysimpatico.com>
Subject Re: Hanging around derby.log, how to center it?
Date Wed, 17 Mar 2010 21:10:01 GMT
Does this look okay:

  final Properties prop = new java.util.Properties();
            prop.store(new FileOutputStream(new File(dir,
"derby.properties")), "derby.properties");
            prop.setProperty("derby.locks.deadlockTrace", "true");
            prop.setProperty("derby.stream.error.logSeverityLevel",
Integer.toString(20000));
            prop.setProperty("derby.language.logStatementText", "true");
            prop.setProperty("derby.stream.error.file",
dir.getAbsolutePath()+"derby.log");

            final Connection con =
SqlWrapper.connectToDerby(dir.getAbsolutePath(), true);

This is an one-time executed init.

2010/3/16, Knut Anders Hatlen <Knut.Hatlen@sun.com>:
> On 03/16/10 15:29, Kristian Waagan wrote:
>> On 16.03.10 14:01, Gabriele Kahlout wrote:
>>> and then, are these property settings permanent (stored by derby in
>>> some way), or do I need to set them at each app execution?
>>>
>>
>> The two properties mentioned must be set each time Derby is booted. More
>> about properties in the Reference Manual [1].
>>
>> As a side note, you can also control the value of derby.system.home by
>> changing the current working directory before starting the VM (this is
>> probably not a feasible solution in most cases).
>
> It is possible to make derby.stream.error.file permanent by setting it
> in derby.properties in the directory pointed to by derby.system.home (or
> the current working directory if derby.system.home is not set).
>
> --
> Knut Anders
>


-- 
Regards,
K. Gabriele

--- unchanged since 25/1/10 ---
P.S. Unless a notification (LON), please reply either with an answer
OR with " ACK" appended to this subject within 48 hours. Otherwise, I
might resend.
In(LON, this) ∨ In(48h, TimeNow) ∨ ∃x. In(x, MyInbox) ∧ IsAnswerTo(x,
this) ∨ (In(subject(this), subject(x)) ∧ In(ACK, subject(x)) ∧
¬IsAnswerTo(x,this)) ⇒ ¬IResend(this).

Also note that correspondence may be received only from specified a
priori senders, or if the subject of this email ends with a code, eg.
-LICHT01X, then also from senders whose reply contains it.
∀x. In(x, MyInbox) ⇒ In(senderAddress(x), MySafeSenderList) ∨ (∃y.
In(y, subject(this) ) ∧ In(y,x) ∧ isCodeLike(y, -LICHT01X) ).

Mime
View raw message