implement limitation with only on logfile group, since SR is really buggy with several


mysql-test/r/ndb_dd_ddl.result:
  Test that only 1 logfile group can be created
mysql-test/r/ndb_dd_dump.result:
  Test that only 1 logfile group can be created
mysql-test/t/ndb_dd_ddl.test:
  Test that only 1 logfile group can be created
mysql-test/t/ndb_dd_dump.test:
  Test that only 1 logfile group can be created
storage/ndb/include/kernel/signaldata/CreateFilegroupImpl.hpp:
  New error code for "only one logfile group" limitation
storage/ndb/src/kernel/blocks/lgman.cpp:
  New error code for "only one logfile group" limitation
storage/ndb/src/ndbapi/ndberror.c:
  New error code for "only one logfile group" limitation
This commit is contained in:
unknown 2006-03-10 14:36:48 +01:00
commit 59846f91e7
7 changed files with 37 additions and 34 deletions

View file

@ -70,7 +70,8 @@ struct CreateFilegroupImplRef {
NoError = 0,
FilegroupAlreadyExists = 1502,
OutOfFilegroupRecords = 1503,
OutOfLogBufferMemory = 1504
OutOfLogBufferMemory = 1504,
OneLogfileGroupLimit = 1514
};
Uint32 senderData;

View file

@ -326,6 +326,13 @@ Lgman::execCREATE_FILEGROUP_REQ(Signal* signal){
break;
}
if (!m_logfile_group_list.isEmpty())
{
jam();
err = CreateFilegroupImplRef::OneLogfileGroupLimit;
break;
}
if (!m_logfile_group_pool.seize(ptr))
{
jam();
@ -1035,10 +1042,8 @@ int
Logfile_client::sync_lsn(Signal* signal,
Uint64 lsn, Request* req, Uint32 flags)
{
Lgman::Logfile_group key;
key.m_logfile_group_id= m_logfile_group_id;
Ptr<Lgman::Logfile_group> ptr;
if(m_lgman->m_logfile_group_hash.find(ptr, key))
if(m_lgman->m_logfile_group_list.first(ptr))
{
if(ptr.p->m_last_synced_lsn >= lsn)
{

View file

@ -413,6 +413,7 @@ ErrorBundle ErrorCodes[] = {
{ 1511, DMEC, IE, "Out of memory" },
{ 1512, DMEC, SE, "File read error" },
{ 1513, DMEC, IE, "Filegroup not online" },
{ 1514, DMEC, SE, "Currently there is a limit of one logfile group" },
{ 773, DMEC, SE, "Out of string memory, please modify StringMemory config parameter" },