Skip to content

Commit 8f95564

Browse files
authored
Merge pull request #1529 from marklogic/feature/remove-factory-methods
Removed factory methods that have been broken since 4.2.0
2 parents 4af7642 + 0a6e604 commit 8f95564

File tree

3 files changed

+2
-53
lines changed

3 files changed

+2
-53
lines changed

marklogic-client-api-functionaltests/src/test/java/com/marklogic/client/fastfunctest/TestDatabaseAuthentication.java

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -51,25 +51,6 @@ public void teardown() throws Exception {
5151
setAuthenticationAndDefaultUser(restServerName, originalServerAuthentication, "nobody");
5252
}
5353

54-
@Test
55-
public void testAuthenticationNone()
56-
{
57-
System.out.println("Running testAuthenticationNone");
58-
if (!IsSecurityEnabled()) {
59-
setAuthenticationAndDefaultUser(restServerName, "application-level", "rest-admin");
60-
// connect the client
61-
StringBuilder str = new StringBuilder();
62-
try {
63-
// This does not need to specify basePath since it's expected to fail
64-
DatabaseClientFactory.newClient(getRestServerHostName(), getRestServerPort());
65-
} catch (Exception ex) {
66-
str.append(ex.getMessage());
67-
}
68-
assertEquals( "makeSecurityContext should only be called with BASIC or DIGEST Authentication",
69-
str.toString().trim());
70-
}
71-
}
72-
7354
@Test
7455
public void testAuthenticationBasic() throws IOException
7556
{

marklogic-client-api/src/main/java/com/marklogic/client/DatabaseClientFactory.java

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1260,37 +1260,6 @@ public static DatabaseClient newClient(Function<String, Object> propertySource)
12601260
return new DatabaseClientPropertySource(propertySource).newClient();
12611261
}
12621262

1263-
/**
1264-
* Creates a client to access the database by means of a REST server
1265-
* without any authentication. Such clients can be convenient for
1266-
* experimentation but should not be used in production.
1267-
*
1268-
* @param host the host with the REST server
1269-
* @param port the port for the REST server
1270-
* @return a new client for making database requests
1271-
*/
1272-
static public DatabaseClient newClient(String host, int port) {
1273-
return newClient(host, port, null, null, null, null, null, null);
1274-
}
1275-
1276-
/**
1277-
* Creates a client to access the database by means of a REST server
1278-
* without any authentication. Such clients can be convenient for
1279-
* experimentation but should not be used in production.
1280-
*
1281-
* A data service interface can only call an endpoint for the configured content database
1282-
* of the appserver. You cannot specify the database when constructing a client for working
1283-
* with a data service.
1284-
*
1285-
* @param host the host with the REST server
1286-
* @param port the port for the REST server
1287-
* @param database the database to access (default: configured database for the REST server)
1288-
* @return a new client for making database requests
1289-
*/
1290-
static public DatabaseClient newClient(String host, int port, String database) {
1291-
return newClient(host, port, database, null, null, null, null, null);
1292-
}
1293-
12941263
/**
12951264
* Creates a client to access the database by means of a REST server.
12961265
*

marklogic-client-api/src/main/java/com/marklogic/client/eval/ServerEvaluationCall.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
* for a server-side {@link #xquery xquery} or {@link #javascript javascript} eval or
3030
* invoke ({@link #modulePath modulePath}) call. ServerEvaluationCall also
3131
* conveniently has the eval* methods which execute those calls and return the
32-
* results. You must call one and only one of the following methods: xquery,
32+
* results. You must call one and only one of the following methods: xquery,
3333
* javascript, or modulePath. The xquery
3434
* and javascript methods initialize this call for server-side eval and accept
3535
* source code as a String or a TextWriteHandle (in case you are streaming the
@@ -89,8 +89,7 @@
8989
* }</pre>
9090
*
9191
* <p>Each call can be executed within a {@link #transaction transaction}, within a
92-
* {@link DatabaseClientFactory#newClient(String, int, String) particular database},
93-
* and with particular {@link #namespaceContext namespaces} available for expansion
92+
* particular database, and with particular {@link #namespaceContext namespaces} available for expansion
9493
* of prefixed variable names.</p>
9594
*
9695
* <p>Each call can be executed with only one expected response of a particular {@link

0 commit comments

Comments
 (0)