Package org.apache.derby.drda

Examples of org.apache.derby.drda.NetworkServerControl.shutdown()


        try {
            if (specifyPort)
            {
                NetworkServerControl nsctrl =
                    NetworkServerTestSetup.getNetworkServerControl(port);
                nsctrl.shutdown();
            }
            else
            {
                NetworkServerControl nsctrl =
                    NetworkServerTestSetup.getNetworkServerControlDefault();
View Full Code Here


            }
            else
            {
                NetworkServerControl nsctrl =
                    NetworkServerTestSetup.getNetworkServerControlDefault();
                nsctrl.shutdown();
            }
        } catch (Exception e) {
            return "failed to shutdown server with API parameter (" + e + ")";
        }
        if (canPingServer(port,false)) {
View Full Code Here

        createDatabase();
       
        NetworkServerControl server = NetworkServerTestSetup.getNetworkServerControl();

        // shut down the server
        server.shutdown();

        // check if db.lck exists
        String fileName = getSystemProperty("derby.system.home") +
                java.io.File.separator +
                TestConfiguration.getCurrent().getDefaultDatabaseName() +
View Full Code Here

        try
        {
            NetworkServerControl server =
        new NetworkServerControl(InetAddress.getByName(hostName),
                   portNumber);
      server.shutdown();
            Thread.sleep(5000);
        }
        catch( Exception e)
        {
            System.out.println( "  Exception thrown while trying to shutdown the remote server.");
View Full Code Here

       
        NetworkServerTestSetup.waitForServerStart(server);
        int sizeAfterPing = bos.size();
        assertTrue("Create log with start message", 0 < sizeAfterPing);       
       
        server.shutdown();

        // DERBY-5598: The shutdown command doesn't wait until the message has
        // been written before it returns. Give the message a little time (up
        // to half a minute) to propagate to the log.
        int sizeAfterShutDown = bos.size();
View Full Code Here

                .getByName(TestConfiguration.getCurrent().getHostName()),
                TestConfiguration.getCurrent().getPort());

        server.start(null);
        NetworkServerTestSetup.waitForServerStart(server);
        server.shutdown();

        //to show this is a right workflow.
        assertTrue(true);
    }
View Full Code Here

        Statement stmt = connection.createStatement();
        ResultSet rs = stmt
        .executeQuery("Select  tablename   from  sys.systables");
        JDBC.assertDrainResults(rs);
        // Leave the connection open before shutdown
        serverControl.shutdown();
    }

    public static Test suite() {
        Test test;
        test = TestConfiguration
View Full Code Here

        File traceDirF = new File(traceDir);

        checkAccessToOwner(
            traceDirF, true, POSITIVE);
        nsctrl.shutdown();
        assertDirectoryDeleted(traceDirF);
    }


    public void doTestNonCliServerIsLax() throws Exception {
View Full Code Here

        File traceDirF = new File(traceDir);

        checkAccessToOwner(
            traceDirF, true, NEGATIVE);

        nsctrl.shutdown();
        assertDirectoryDeleted(traceDirF);
    }


    public void dotestEmbeddedIsLax() throws Exception {
View Full Code Here

       
        assertEquals("Network Server state incorrect",
                serverShouldBeUp, isServerUp);
       
        if (isServerUp)
            control.shutdown();
    }
   
    /**
     * Return true if a full auto-boot of the engine is expected
     * due to jdbc.drivers containing the name of the embedded driver.
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.