提交 faa9789d authored 作者: Evgenij Ryazanov's avatar Evgenij Ryazanov

Fix typos and update dictionary.txt

上级 5d27f38d
......@@ -33,7 +33,7 @@ Change Log
</li>
<li>PR #1176: Magic value replacement with constant
</li>
<li>PR #1171: Introduce last commited value into a VersionedValue
<li>PR #1171: Introduce last committed value into a VersionedValue
</li>
<li>PR #1175: tighten test conditions - do not ignore any exceptions
</li>
......
......@@ -321,7 +321,7 @@ public abstract class Command implements CommandInterface {
if (start != 0 && TimeUnit.NANOSECONDS.toMillis(now - start) > session.getLockTimeout()) {
throw DbException.get(ErrorCode.LOCK_TIMEOUT_1, e);
}
// Only in PageStore mode we need to sleep here to avoid buzy wait loop
// Only in PageStore mode we need to sleep here to avoid busy wait loop
Database database = session.getDatabase();
if (database.getMvStore() == null) {
int sleep = 1 + MathUtils.randomInt(10);
......
......@@ -2568,7 +2568,7 @@ public class MVStore {
String oldName = getMapName(id);
if (oldName != null && !oldName.equals(newName)) {
String idHexStr = Integer.toHexString(id);
// we need to cope whith the case of previously unfinished rename
// we need to cope with the case of previously unfinished rename
String existingIdHexStr = meta.get("name." + newName);
DataUtils.checkArgument(
existingIdHexStr == null || existingIdHexStr.equals(idHexStr),
......
......@@ -119,7 +119,7 @@ public class MVTable extends TableBase {
*/
private final ArrayDeque<Session> waitingSessions = new ArrayDeque<>();
private final Trace traceLock;
private final AtomicInteger changesUnitlAnalyze;
private final AtomicInteger changesUntilAnalyze;
private int nextAnalyze;
private final boolean containsLargeObject;
private Column rowIdColumn;
......@@ -130,7 +130,7 @@ public class MVTable extends TableBase {
public MVTable(CreateTableData data, MVTableEngine.Store store) {
super(data);
nextAnalyze = database.getSettings().analyzeAuto;
changesUnitlAnalyze = nextAnalyze <= 0 ? null : new AtomicInteger(nextAnalyze);
changesUntilAnalyze = nextAnalyze <= 0 ? null : new AtomicInteger(nextAnalyze);
this.store = store;
this.transactionStore = store.getTransactionStore();
this.isHidden = data.isHidden;
......@@ -714,8 +714,8 @@ public class MVTable extends TableBase {
Index index = indexes.get(i);
index.truncate(session);
}
if (changesUnitlAnalyze != null) {
changesUnitlAnalyze.set(nextAnalyze);
if (changesUntilAnalyze != null) {
changesUntilAnalyze.set(nextAnalyze);
}
}
......@@ -745,12 +745,12 @@ public class MVTable extends TableBase {
}
private void analyzeIfRequired(Session session) {
if (changesUnitlAnalyze != null) {
if (changesUnitlAnalyze.decrementAndGet() == 0) {
if (changesUntilAnalyze != null) {
if (changesUntilAnalyze.decrementAndGet() == 0) {
if (nextAnalyze <= Integer.MAX_VALUE / 2) {
nextAnalyze *= 2;
}
changesUnitlAnalyze.set(nextAnalyze);
changesUntilAnalyze.set(nextAnalyze);
session.markTableForAnalyze(this);
}
}
......
......@@ -28,7 +28,7 @@ final class CommitDecisionMaker extends MVMap.DecisionMaker<VersionedValue> {
assert decision == null;
if (existingValue == null ||
// map entry was treated as already committed, and then
// it has been removed by another transaction (commited and closed by now )
// it has been removed by another transaction (committed and closed by now)
existingValue.getOperationId() != undoKey) {
// this is not a final undo log entry for this key,
// or map entry was treated as already committed and then
......
......@@ -30,8 +30,8 @@ final class RollbackDecisionMaker extends MVMap.DecisionMaker<Object[]> {
@Override
public MVMap.Decision decide(Object[] existingValue, Object[] providedValue) {
assert decision == null;
// normaly existingValue will always be there except of db initialization
// where some undo log enty was captured on disk but actual map entry was not
// normally existingValue will always be there except of db initialization
// where some undo log entry was captured on disk but actual map entry was not
if (existingValue != null ) {
VersionedValue valueToRestore = (VersionedValue) existingValue[2];
long operationId;
......
......@@ -109,7 +109,7 @@ public class TransactionMap<K, V> {
// Entries describing removals from the map by this transaction and all transactions,
// which are committed but not closed yet,
// and antries about additions to the map by other uncommitted transactions were counted,
// and entries about additions to the map by other uncommitted transactions were counted,
// but they should not contribute into total count.
if (2 * undoLogSize > size) {
// the undo log is larger than half of the map - scan the entries of the map directly
......
......@@ -89,7 +89,7 @@ public class TransactionStore {
private final AtomicReferenceArray<Transaction> transactions =
new AtomicReferenceArray<>(MAX_OPEN_TRANSACTIONS + 1);
private static final String UNDO_LOG_NAME_PEFIX = "undoLog";
private static final String UNDO_LOG_NAME_PREFIX = "undoLog";
private static final char UNDO_LOG_COMMITTED = '-'; // must come before open in lexicographical order
private static final char UNDO_LOG_OPEN = '.';
......@@ -101,7 +101,7 @@ public class TransactionStore {
public static String getUndoLogName(boolean committed, int transactionId) {
return UNDO_LOG_NAME_PEFIX +
return UNDO_LOG_NAME_PREFIX +
(committed ? UNDO_LOG_COMMITTED : UNDO_LOG_OPEN) +
(transactionId > 0 ? String.valueOf(transactionId) : "");
}
......@@ -120,7 +120,7 @@ public class TransactionStore {
*
* @param store the store
* @param dataType the data type for map keys and values
* @param timeoutMillis lock aquisition timeout in milliseconds, 0 means no wait
* @param timeoutMillis lock acquisition timeout in milliseconds, 0 means no wait
*/
public TransactionStore(MVStore store, DataType dataType, int timeoutMillis) {
this.store = store;
......@@ -143,10 +143,10 @@ public class TransactionStore {
public void init() {
if (!init) {
for (String mapName : store.getMapNames()) {
if (mapName.startsWith(UNDO_LOG_NAME_PEFIX)) {
boolean committed = mapName.charAt(UNDO_LOG_NAME_PEFIX.length()) == UNDO_LOG_COMMITTED;
if (mapName.startsWith(UNDO_LOG_NAME_PREFIX)) {
boolean committed = mapName.charAt(UNDO_LOG_NAME_PREFIX.length()) == UNDO_LOG_COMMITTED;
if (store.hasData(mapName) || committed) {
int transactionId = Integer.parseInt(mapName.substring(UNDO_LOG_NAME_PEFIX.length() + 1));
int transactionId = Integer.parseInt(mapName.substring(UNDO_LOG_NAME_PREFIX.length() + 1));
VersionedBitSet openTxBitSet = openTransactions.get();
if (!openTxBitSet.get(transactionId)) {
Object[] data = preparedTransactions.get(transactionId);
......
......@@ -49,7 +49,7 @@ public abstract class TxDecisionMaker extends MVMap.DecisionMaker<VersionedValue
logIt(existingValue.value == null ? null : VersionedValue.getInstance(existingValue.value));
decision = MVMap.Decision.PUT;
} else if(fetchTransaction(blockingId) == null) {
// condition above means transaction has been committed/rplled back and closed by now
// condition above means transaction has been committed/rolled back and closed by now
decision = MVMap.Decision.REPEAT;
} else {
// this entry comes from a different transaction, and this
......
......@@ -163,7 +163,7 @@ public class DefaultAuthenticator implements Authenticator {
}
/**
* Initializes the authenticator (it is called by AuthententicationManager)
* Initializes the authenticator.
*
* this method is skipped if skipDefaultInitialization is set Order of
* initialization is
......
......@@ -24,7 +24,7 @@ import org.h2.security.auth.ConfigProperties;
* <li>bindDnPattern bind dn pattern with %u instead of username
* (example: uid=%u,ou=users,dc=example,dc=com)</li>
* <li>host ldap server</li>
* <li>port of ldap service; optional, by default 389 for unsecure, 636 for secure</li>
* <li>port of ldap service; optional, by default 389 for insecure, 636 for secure</li>
* <li>secure, optional by default is true (use SSL)</li>
* </ul>
*/
......
......@@ -126,7 +126,7 @@ public class TestAuthentication extends TestBase {
protected void allTests() throws Exception {
testInvalidPassword();
testExternalUserWihoutRealm();
testExternalUserWithoutRealm();
testExternalUser();
testAssignRealNameRole();
testStaticRole();
......@@ -146,7 +146,7 @@ public class TestAuthentication extends TestBase {
}
}
protected void testExternalUserWihoutRealm() throws Exception {
protected void testExternalUserWithoutRealm() throws Exception {
try {
Connection wrongLoginConnection = DriverManager.getConnection(getDatabaseURL(), getExternalUser(),
getExternalUserPassword());
......@@ -265,8 +265,8 @@ public class TestAuthentication extends TestBase {
try {
try {
testExternalUser();
throw new Exception("External user shouldnt be allowed");
}catch (Exception e) {
throw new Exception("External user shouldn't be allowed");
} catch (Exception e) {
}
} finally {
configureAuthentication(database);
......
......@@ -404,7 +404,7 @@ public class TestTransactionStore extends TestBase {
}
}
// re-open TransactionStore, because we rolled back
// underlying MVStore without rolling back TranactionStore
// underlying MVStore without rolling back TransactionStore
s.close();
s = MVStore.open(fileName);
ts = new TransactionStore(s);
......
......@@ -777,4 +777,9 @@ geometries sourceschema destschema generatedcolumn alphanumerically usages
sizable instantiates renders sdt txcommit unhelpful optimiser treats rejects referring untrusted computes vacate inverted
reordered colliding evgenij archaic invocations apostrophe hypothetically testref ryazanov useless completes highlighting tends degrade
summands minuend subtrahend
summands minuend subtrahend localtime localtimestamp governs unfinished pressure closure discovered victim seemingly
flaw capture coherent removals silence opentransactions picture tokar mailto andrei dur discarded blocker captures txdm
intentionally authenticator authrealm ventura credentials alessandro validator acquisition vital mariadb preventing
ewkt ewkb informations authzpwd realms mappers jaxb realmname configurationfile unmarshal jaas externals customize
authenticators appname interrogate metatable barrier preliminary staticuser staticpassword unregistered inquiry
ldapexample remoteuser assignments djava validators mock relate mapid tighten
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论