From 1959e018445372165dd1d208bf53cb41a12026d9 Mon Sep 17 00:00:00 2001
From: rob bygrave {@code
*
* Customer customer =
- * server.find(Customer.class)
+ * database.find(Customer.class)
* .setUseDocStore(true)
* .setId(42)
* .findOne();
@@ -79,7 +79,7 @@ public interface DocumentStore {
* {@code
*
* List{@code
*
* PagedList
{@code
*
- * server.find(Order.class)
+ * database.find(Order.class)
* .setUseDocStore(true)
* .where()... // perhaps add predicates
* .findEach((Order order) -> {
@@ -145,7 +145,7 @@ public interface DocumentStore {
*
* {@code
*
- * server.find(Order.class)
+ * database.find(Order.class)
* .setUseDocStore(true)
* .where()... // perhaps add predicates
* .findEachWhile(new Predicate() {
@@ -190,7 +190,7 @@ public interface DocumentStore {
* Drop the index from the document store (similar to DDL drop table).
* {@code
*
- * DocumentStore documentStore = server.docStore();
+ * DocumentStore documentStore = database.docStore();
*
* documentStore.dropIndex("product_copy");
*
@@ -202,7 +202,7 @@ public interface DocumentStore {
* Create an index given a mapping file as a resource in the classPath (similar to DDL create table).
* {@code
*
- * DocumentStore documentStore = server.docStore();
+ * DocumentStore documentStore = database.docStore();
*
* // uses product_copy.mapping.json resource
* // ... to define mappings for the index
@@ -289,7 +289,7 @@ public interface DocumentStore {
* {@code
*
* // predicates to select the source documents to copy
- * Query query = server.find(Product.class)
+ * Query query = database.find(Product.class)
* .where()
* .ge("whenModified", new Timestamp(since))
* .ge("name", "A")
diff --git a/src/main/java/io/ebean/Ebean.java b/src/main/java/io/ebean/Ebean.java
index 814976a1d..8d40f0e18 100644
--- a/src/main/java/io/ebean/Ebean.java
+++ b/src/main/java/io/ebean/Ebean.java
@@ -187,7 +187,7 @@ public final class Ebean {
}
/**
- * Return the ExpressionFactory from the default server.
+ * Return the ExpressionFactory from the default database.
*
* The ExpressionFactory is used internally by the query and ExpressionList to
* build the WHERE and HAVING clauses. Alternatively you can use the
@@ -209,14 +209,14 @@ public final class Ebean {
/**
* Register the server with this Ebean singleton. Specify if the registered
- * server is the primary/default server.
+ * server is the primary/default database.
*/
public static void register(EbeanServer server, boolean defaultServer) {
serverMgr.register(server, defaultServer);
}
/**
- * Backdoor for registering a mock implementation of EbeanServer as the default server.
+ * Backdoor for registering a mock implementation of EbeanServer as the default database.
*/
protected static EbeanServer mock(String name, EbeanServer server, boolean defaultServer) {
EbeanServer originalPrimaryServer = serverMgr.defaultServer;
diff --git a/src/main/java/io/ebean/EbeanServerFactory.java b/src/main/java/io/ebean/EbeanServerFactory.java
index 0880dd25f..72dfb4925 100644
--- a/src/main/java/io/ebean/EbeanServerFactory.java
+++ b/src/main/java/io/ebean/EbeanServerFactory.java
@@ -48,7 +48,7 @@ public class EbeanServerFactory {
}
/**
- * Create using ebean.properties to configure the server.
+ * Create using ebean.properties to configure the database.
*/
public static synchronized EbeanServer create(String name) {
@@ -59,7 +59,7 @@ public class EbeanServerFactory {
}
/**
- * Create using the ServerConfig object to configure the server.
+ * Create using the ServerConfig object to configure the database.
*/
public static synchronized EbeanServer create(ServerConfig config) {
diff --git a/src/main/java/io/ebean/PrimaryServer.java b/src/main/java/io/ebean/PrimaryServer.java
index eb4204a1b..9b0140f6f 100644
--- a/src/main/java/io/ebean/PrimaryServer.java
+++ b/src/main/java/io/ebean/PrimaryServer.java
@@ -5,9 +5,9 @@ import io.ebean.config.properties.PropertiesLoader;
import java.util.Properties;
/**
- * Provides singleton state for the default server.
+ * Provides singleton state for the default database.
*
- * Intended for internal use as part of bootup, construction, registration of the default server.
+ * Intended for internal use as part of bootup, construction, registration of the default database.
*/
class PrimaryServer {
@@ -18,21 +18,21 @@ class PrimaryServer {
private static boolean skip;
/**
- * Set whether to skip automatically creating the primary server.
+ * Set whether to skip automatically creating the primary database.
*/
static synchronized void setSkip(boolean skip) {
PrimaryServer.skip = skip;
}
/**
- * Return true to skip automatically creating the primary server.
+ * Return true to skip automatically creating the primary database.
*/
static synchronized boolean isSkip() {
return skip;
}
/**
- * Return the default server name.
+ * Return the default database name.
*/
static synchronized String getDefaultServerName() {
getProperties();
diff --git a/src/main/java/io/ebean/QueryIterator.java b/src/main/java/io/ebean/QueryIterator.java
index f7a89223f..c4125a2ac 100644
--- a/src/main/java/io/ebean/QueryIterator.java
+++ b/src/main/java/io/ebean/QueryIterator.java
@@ -23,7 +23,7 @@ import java.util.Iterator;
* Try finally style
* {@code
*
- * Query query = server.find(Customer.class)
+ * Query query = database.find(Customer.class)
* .where().gt("id", 0)
* .orderBy("id")
* .setMaxRows(2);
diff --git a/src/main/java/io/ebean/Transaction.java b/src/main/java/io/ebean/Transaction.java
index a964aa6fd..9dd51c00d 100644
--- a/src/main/java/io/ebean/Transaction.java
+++ b/src/main/java/io/ebean/Transaction.java
@@ -295,7 +295,7 @@ public interface Transaction extends AutoCloseable {
*
* {@code
*
- * try (Transaction transaction = server.beginTransaction()) {
+ * try (Transaction transaction = database.beginTransaction()) {
*
* // turn on JDBC batch
* transaction.setBatchMode(true);
@@ -318,7 +318,7 @@ public interface Transaction extends AutoCloseable {
*
* {@code
*
- * try (Transaction transaction = server.beginTransaction()) {
+ * try (Transaction transaction = database.beginTransaction()) {
*
* transaction.setBatchMode(true);
* transaction.setBatchSize(100);
diff --git a/src/main/java/io/ebean/config/DocStoreConfig.java b/src/main/java/io/ebean/config/DocStoreConfig.java
index 31405d3f8..d83f67749 100644
--- a/src/main/java/io/ebean/config/DocStoreConfig.java
+++ b/src/main/java/io/ebean/config/DocStoreConfig.java
@@ -29,7 +29,7 @@ public class DocStoreConfig {
protected boolean create;
/**
- * The URL of the Document store server. For example: http://localhost:9200.
+ * The URL of the Document store. For example: http://localhost:9200.
*/
protected String url;
@@ -131,7 +131,7 @@ public class DocStoreConfig {
}
/**
- * Set the URL to the Document store server.
+ * Set the URL to the Document store.
*
* For a local ElasticSearch server this would be: http://localhost:9200
*/
diff --git a/src/main/java/io/ebean/config/ServerConfig.java b/src/main/java/io/ebean/config/ServerConfig.java
index cfeb0d3a2..3c11706ba 100644
--- a/src/main/java/io/ebean/config/ServerConfig.java
+++ b/src/main/java/io/ebean/config/ServerConfig.java
@@ -1886,7 +1886,7 @@ public class ServerConfig {
}
/**
- * Return the database platform to use for this server.
+ * Return the database platform to use for this database.
*/
public DatabasePlatform getDatabasePlatform() {
return databasePlatform;
@@ -2282,7 +2282,7 @@ public class ServerConfig {
*
*
* @param cls the entity type (or other type) that should be registered by this
- * server.
+ * database.
*/
public void addClass(Class> cls) {
classes.add(cls);
@@ -2329,7 +2329,7 @@ public class ServerConfig {
/**
* Set the list of classes (entities, listeners, scalarTypes etc) that should
- * be used for this server.
+ * be used for this database.
*
* If no classes are specified then the classes are found automatically via
* searching the class path.
@@ -2343,7 +2343,7 @@ public class ServerConfig {
}
/**
- * Return the classes registered for this server. Typically this includes
+ * Return the classes registered for this database. Typically this includes
* entities and perhaps listeners.
*/
public List> getClasses() {
diff --git a/src/main/java/io/ebean/dbmigration/DbMigration.java b/src/main/java/io/ebean/dbmigration/DbMigration.java
index e9d12efe6..7bab8f7db 100644
--- a/src/main/java/io/ebean/dbmigration/DbMigration.java
+++ b/src/main/java/io/ebean/dbmigration/DbMigration.java
@@ -93,7 +93,7 @@ public interface DbMigration {
/**
* Set the specific platform to generate DDL for.
*
- * If not set this defaults to the platform of the default server.
+ * If not set this defaults to the platform of the default database.
*
*/
void setPlatform(Platform platform);
@@ -101,7 +101,7 @@ public interface DbMigration {
/**
* Set the specific platform to generate DDL for.
*
- * If not set this defaults to the platform of the default server.
+ * If not set this defaults to the platform of the default database.
*
*/
void setPlatform(DatabasePlatform databasePlatform);
diff --git a/src/main/java/io/ebean/event/BeanPersistController.java b/src/main/java/io/ebean/event/BeanPersistController.java
index ed46dbdef..a546d0706 100644
--- a/src/main/java/io/ebean/event/BeanPersistController.java
+++ b/src/main/java/io/ebean/event/BeanPersistController.java
@@ -15,8 +15,8 @@ package io.ebean.event;
*
* Object extaBeanToSave = ...;
* Transaction t = request.getTransaction();
- * EbeanServer server = request.getEbeanServer();
- * server.save(extraBeanToSave, t);
+ * Database server = request.getEbeanServer();
+ * database.save(extraBeanToSave, t);
*
* }
*
diff --git a/src/main/java/io/ebean/plugin/SpiServer.java b/src/main/java/io/ebean/plugin/SpiServer.java
index e672158d8..2b55077fb 100644
--- a/src/main/java/io/ebean/plugin/SpiServer.java
+++ b/src/main/java/io/ebean/plugin/SpiServer.java
@@ -20,7 +20,7 @@ public interface SpiServer extends EbeanServer, BeanLoader {
ServerConfig getServerConfig();
/**
- * Return the DatabasePlatform for this server.
+ * Return the DatabasePlatform for this database.
*/
DatabasePlatform getDatabasePlatform();
diff --git a/src/main/java/io/ebean/search/TextCommonTerms.java b/src/main/java/io/ebean/search/TextCommonTerms.java
index cb0320bad..435e17a32 100644
--- a/src/main/java/io/ebean/search/TextCommonTerms.java
+++ b/src/main/java/io/ebean/search/TextCommonTerms.java
@@ -13,7 +13,7 @@ package io.ebean.search;
* .lowFreqOperatorAnd(true)
* .highFreqOperatorAnd(true);
*
- * List customers = server.find(Customer.class)
+ * List customers = database.find(Customer.class)
* .text()
* .textCommonTerms("the brown", options)
* .findList();
diff --git a/src/main/java/io/ebean/search/TextQueryString.java b/src/main/java/io/ebean/search/TextQueryString.java
index cb8b27508..7e70732e0 100644
--- a/src/main/java/io/ebean/search/TextQueryString.java
+++ b/src/main/java/io/ebean/search/TextQueryString.java
@@ -13,7 +13,7 @@ package io.ebean.search;
* .lenient(true)
* .opAnd();
*
- * List customers = server.find(Customer.class)
+ * List customers = database.find(Customer.class)
* .text()
* .textSimple("quick brown", options)
* .findList();
@@ -24,7 +24,7 @@ package io.ebean.search;
* // just use default options
* TextQueryString options = new TextQueryString();
*
- * List customers = server.find(Customer.class)
+ * List customers = database.find(Customer.class)
* .text()
* .textSimple("quick brown", options)
* .findList();
diff --git a/src/main/java/io/ebean/search/TextSimple.java b/src/main/java/io/ebean/search/TextSimple.java
index 197acd4ed..97dca17ae 100644
--- a/src/main/java/io/ebean/search/TextSimple.java
+++ b/src/main/java/io/ebean/search/TextSimple.java
@@ -13,7 +13,7 @@ package io.ebean.search;
* .lenient(true)
* .opAnd();
*
- * List customers = server.find(Customer.class)
+ * List customers = database.find(Customer.class)
* .text()
* .textSimple("quick brown", options)
* .findList();
diff --git a/src/main/java/io/ebean/service/SpiContainer.java b/src/main/java/io/ebean/service/SpiContainer.java
index d317ed4b8..bf4aa4aca 100644
--- a/src/main/java/io/ebean/service/SpiContainer.java
+++ b/src/main/java/io/ebean/service/SpiContainer.java
@@ -12,7 +12,7 @@ public interface SpiContainer {
/**
* Create the EbeanServer for a given configuration.
*
- * @param configuration The configuration information for this server.
+ * @param configuration The configuration information for this database.
*/
EbeanServer createServer(ServerConfig configuration);