예제 #1
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void shouldStopConnectionsWhenRelatedJobIsRejectedOnShutdown() throws Throwable
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
        public virtual void ShouldStopConnectionsWhenRelatedJobIsRejectedOnShutdown()
        {
            // Connect and get two connections into idle state
            _connection1 = EnterStreaming();
            ExitStreaming(_connection1);
            _connection2 = EnterStreaming();
            ExitStreaming(_connection2);

            // Connect and get other set of connections to keep threads busy
            _connection3 = EnterStreaming();
            _connection4 = EnterStreaming();

            // Clear any log output till now
            _internalLogProvider.clear();

            // Shutdown the server
            _server.shutdownDatabase();

            // Expect no scheduling error logs
            _userLogProvider.rawMessageMatcher().assertNotContains("since there are no available threads to serve it at the moment. You can retry at a later time");
            _internalLogProvider.rawMessageMatcher().assertNotContains("since there are no available threads to serve it at the moment. You can retry at a later time");
        }
예제 #2
0
 private void RestartNeo4jServerWithOverriddenSettings <T1>(System.Action <T1> overrideSettingsFunction)
 {
     Server.shutdownDatabase();
     Server.ensureDatabase(AsSettings(overrideSettingsFunction));
 }