You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-user@db.apache.org by wo...@yahoo.co.jp on 2005/09/19 18:13:38 UTC

derby.drda.startNetworkServer property

Hi there,

I got a question about the derby.drda.startNetworkServer property.
I've read through the doc and it says the following.
-------------------------------------------------------
Use the derby.drda.startNetworkServer property to simplify embedding the 
Network Server in your application. When you set derby.drda.startNetworkServer,
the Network Server will automatically start when you start Derby. Only
one Network Server can be started in a JVM.
-------------------------------------------------------

Does it mean even though I start Derby using "Class.forName("org.apache.derby.jdbc.EmbeddedDriver");",
the Network Server will start if I set derby.drda.startNetworkServer true ?


Regards,
Wolfgang





__________________________________
 For All Sports Fans!
 http://pr.mail.yahoo.co.jp/yells/


Re: derby.drda.startNetworkServer property

Posted by Rajesh Kartha <ka...@Source-Zone.Org>.
wolfgang127us@yahoo.co.jp wrote:

>Hi there,
>
>I got a question about the derby.drda.startNetworkServer property.
>I've read through the doc and it says the following.
>-------------------------------------------------------
>Use the derby.drda.startNetworkServer property to simplify embedding the 
>Network Server in your application. When you set derby.drda.startNetworkServer,
>the Network Server will automatically start when you start Derby. Only
>one Network Server can be started in a JVM.
>-------------------------------------------------------
>
>Does it mean even though I start Derby using "Class.forName("org.apache.derby.jdbc.EmbeddedDriver");",
>the Network Server will start if I set derby.drda.startNetworkServer true ?
>
>
>Regards,
>Wolfgang
>
>
>
>
>
>__________________________________
> For All Sports Fans!
> http://pr.mail.yahoo.co.jp/yells/
>
>  
>
Maybe that explains why you were seeing two attempts to start the 
Network Server in your derby.log, from your earlier mail (?).

-Rajesh


Re: derby.drda.startNetworkServer property

Posted by Knut Anders Hatlen <Kn...@Sun.COM>.
wolfgang127us@yahoo.co.jp writes:

> Hi Knut,
>
> Thanks for your quick response.
>
> Then, how can I verify whether Derby, started using
> derby.drda.startNetworkServer=true and org.apache.derby.jdbc.EmbeddedDriver, 
> is ready or not to accept clients like NetworkServerControl#ping() ?

Haven't tested, but I think the following should work:

NetworkServerControl nsc = new NetworkServerControl(address, port);
try {
    nsc.ping();
    System.out.println("started");
} catch (Exception e) {
    System.out.println("not started");
}

-- 
Knut Anders


Re: derby.drda.startNetworkServer property

Posted by wo...@yahoo.co.jp.
Hi Knut,

Thanks for your quick response.

Then, how can I verify whether Derby, started using
derby.drda.startNetworkServer=true and org.apache.derby.jdbc.EmbeddedDriver, 
is ready or not to accept clients like NetworkServerControl#ping() ?

Regards,
Wolfgang

> 
> > Hi there,
> >
> > I got a question about the derby.drda.startNetworkServer property.
> > I've read through the doc and it says the following.
> > -------------------------------------------------------
> > Use the derby.drda.startNetworkServer property to simplify embedding the 
> > Network Server in your application. When you set derby.drda.startNetworkServer,
> > the Network Server will automatically start when you start Derby. Only
> > one Network Server can be started in a JVM.
> > -------------------------------------------------------
> >
> > Does it mean even though I start Derby using "Class.forName("org.apache.derby.jdbc.EmbeddedDriver");",
> > the Network Server will start if I set derby.drda.startNetworkServer true ?
> 
> Yes, that's what it means. When the embedded driver is loaded, it will
> check whether that property is set, and start the network server if it
> is true.
> 
> -- 
> Knut Anders


__________________________________
 For All Sports Fans!
 http://pr.mail.yahoo.co.jp/yells/


Re: derby.drda.startNetworkServer property

Posted by Knut Anders Hatlen <Kn...@sun.com>.
wolfgang127us@yahoo.co.jp writes:

> Hi there,
>
> I got a question about the derby.drda.startNetworkServer property.
> I've read through the doc and it says the following.
> -------------------------------------------------------
> Use the derby.drda.startNetworkServer property to simplify embedding the 
> Network Server in your application. When you set derby.drda.startNetworkServer,
> the Network Server will automatically start when you start Derby. Only
> one Network Server can be started in a JVM.
> -------------------------------------------------------
>
> Does it mean even though I start Derby using "Class.forName("org.apache.derby.jdbc.EmbeddedDriver");",
> the Network Server will start if I set derby.drda.startNetworkServer true ?

Yes, that's what it means. When the embedded driver is loaded, it will
check whether that property is set, and start the network server if it
is true.

-- 
Knut Anders