Below is the list of changes that have just been committed into a local
6.0 repository of cpowers. When cpowers does a push these changes
will be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet@stripped, 2008-04-05 17:09:17-05:00, cpowers@stripped +16 -0
Added Information Schema tables FALCON_TABLESPACES and FALCON_TABLESPACE_FILES.
Disabled extended CREATE TABLESPACE options.
FALCON_TABLESPACES lists all tablespaces.
FALCON_TABLESPACE_FILES lists all tablespaces and their associated files.
storage/falcon/Database.cpp@stripped, 2008-04-05 17:09:13-05:00, cpowers@stripped +11
-4
Disabled extended tablespace options.
Added getTableSpaceFilesInfo().
storage/falcon/Database.h@stripped, 2008-04-05 17:09:14-05:00, cpowers@stripped +1 -0
Disabled extended tablespace options.
Added getTableSpaceFilesInfo().
storage/falcon/SQLParse.cpp@stripped, 2008-04-05 17:09:14-05:00, cpowers@stripped +10
-7
Disabled extended tablespace options.
storage/falcon/SRLCreateTableSpace.cpp@stripped, 2008-04-05 17:09:14-05:00,
cpowers@stripped +20 -12
Disabled extended tablespace options.
storage/falcon/SRLCreateTableSpace.h@stripped, 2008-04-05 17:09:14-05:00,
cpowers@stripped +5 -3
Disabled extended tablespace options.
storage/falcon/Statement.cpp@stripped, 2008-04-05 17:09:14-05:00, cpowers@stripped +15
-7
Disabled extended tablespace options.
storage/falcon/StorageDatabase.cpp@stripped, 2008-04-05 17:09:14-05:00,
cpowers@stripped +5 -0
Added getTableSpaceFilesInfo().
storage/falcon/StorageDatabase.h@stripped, 2008-04-05 17:09:14-05:00, cpowers@stripped
+1 -0
Added getTableSpaceFilesInfo().
storage/falcon/StorageHandler.cpp@stripped, 2008-04-05 17:09:14-05:00,
cpowers@stripped +15 -5
Disabled extended tablespace options.
Added getTableSpaceFilesInfo().
storage/falcon/StorageHandler.h@stripped, 2008-04-05 17:09:14-05:00, cpowers@stripped
+1 -0
Added getTableSpaceFilesInfo().
storage/falcon/TableSpace.cpp@stripped, 2008-04-05 17:09:14-05:00, cpowers@stripped +13
-29
Disabled extended tablespace options.
storage/falcon/TableSpace.h@stripped, 2008-04-05 17:09:14-05:00, cpowers@stripped +13
-9
Disabled extended tablespace options.
storage/falcon/TableSpaceManager.cpp@stripped, 2008-04-05 17:09:14-05:00,
cpowers@stripped +60 -26
Disabled extended tablespace options.
Added getTableSpaceInfo() and getTableSpaceFilesInfo().
storage/falcon/TableSpaceManager.h@stripped, 2008-04-05 17:09:14-05:00,
cpowers@stripped +2 -0
Disabled extended tablespace options.
Added getTableSpaceInfo() and getTableSpaceFilesInfo().
storage/falcon/ha_falcon.cpp@stripped, 2008-04-05 17:09:14-05:00, cpowers@stripped
+103 -60
Added Information Schema tables FALCON_TABLESPACES and FALCON_TABLESPACE_FILES.
Renamed some plugin handler methods with consistent names.
storage/falcon/ha_falcon.h@stripped, 2008-04-05 17:09:14-05:00, cpowers@stripped +16
-12
Added Information Schema tables FALCON_TABLESPACES and FALCON_TABLESPACE_FILES.
Renamed some plugin handler methods with consistent names.
diff -Nrup a/storage/falcon/Database.cpp b/storage/falcon/Database.cpp
--- a/storage/falcon/Database.cpp 2008-04-05 13:38:37 -05:00
+++ b/storage/falcon/Database.cpp 2008-04-05 17:09:13 -05:00
@@ -323,13 +323,15 @@ static const char *createTableSpaces =
"tablespace_id int not null,"
"filename varchar(512) not null,"
"type int,"
- "allocation bigint,"
- "extent bigint,"
- "autoextend bigint,"
+ /***
+ "initial_size bigint,"
+ "extent_size bigint,"
+ "autoextend_size bigint,"
"max_size bigint,"
"nodegroup int,"
"wait int,"
- "comment varchar(1024))";
+ ***/
+ "comment text)";
static const char *createTableSpaceSequence =
"upgrade sequence tablespace_ids";
@@ -2337,6 +2339,11 @@ void Database::getTransactionSummaryInfo
void Database::getTableSpaceInfo(InfoTable* infoTable)
{
tableSpaceManager->getTableSpaceInfo(infoTable);
+}
+
+void Database::getTableSpaceFilesInfo(InfoTable* infoTable)
+{
+ tableSpaceManager->getTableSpaceFilesInfo(infoTable);
}
void Database::updateCardinalities(void)
diff -Nrup a/storage/falcon/Database.h b/storage/falcon/Database.h
--- a/storage/falcon/Database.h 2008-03-28 17:44:33 -05:00
+++ b/storage/falcon/Database.h 2008-04-05 17:09:14 -05:00
@@ -207,6 +207,7 @@ public:
void rollbackByXid(int xidLength, const UCHAR* xid);
void getTransactionSummaryInfo(InfoTable* infoTable);
void getTableSpaceInfo(InfoTable* infoTable);
+ void getTableSpaceFilesInfo(InfoTable* infoTable);
void updateCardinalities(void);
void getIOInfo(InfoTable* infoTable);
void getTransactionInfo(InfoTable* infoTable);
diff -Nrup a/storage/falcon/SQLParse.cpp b/storage/falcon/SQLParse.cpp
--- a/storage/falcon/SQLParse.cpp 2008-03-28 17:44:33 -05:00
+++ b/storage/falcon/SQLParse.cpp 2008-04-05 17:09:14 -05:00
@@ -3298,19 +3298,22 @@ Syntax* SQLParse::parseCreateTableSpace(
for (;;)
{
- if (match("ALLOCATION"))
- options.append (makeNode(nod_allocation, parseNumber()));
- else if (match ("EXTENT"))
- options.append (makeNode(nod_extent, parseNumber()));
- else if (match ("AUTOEXTEND"))
- options.append (makeNode(nod_autoextend, parseNumber()));
+ /***
+ if (match("INITIAL_SIZE"))
+ options.append (makeNode(nod_initial_size, parseNumber()));
+ else if (match ("EXTENT_SIZE"))
+ options.append (makeNode(nod_extent_size, parseNumber()));
+ else if (match ("AUTOEXTEND_SIZE"))
+ options.append (makeNode(nod_autoextend_size, parseNumber()));
else if (match ("MAX_SIZE"))
options.append (makeNode(nod_max_size, parseNumber()));
else if (match ("NODEGROUP"))
options.append (makeNode(nod_nodegroup, parseNumber()));
else if (match ("WAIT"))
options.append (makeNode(nod_wait, parseNumber()));
- else if (match ("COMMENT"))
+ else
+ ***/
+ if (match ("COMMENT"))
options.append (makeNode(nod_comment, parseQuotedString()));
else if (match (","))
;
diff -Nrup a/storage/falcon/SRLCreateTableSpace.cpp
b/storage/falcon/SRLCreateTableSpace.cpp
--- a/storage/falcon/SRLCreateTableSpace.cpp 2008-03-28 17:44:33 -05:00
+++ b/storage/falcon/SRLCreateTableSpace.cpp 2008-04-05 17:09:14 -05:00
@@ -52,12 +52,14 @@ void SRLCreateTableSpace::append(TableSp
putInt(len);
putData(len, (const UCHAR*) p);
putInt(tableSpace->type);
- putInt64(tableSpace->allocation);
- putInt64(tableSpace->extent);
- putInt64(tableSpace->autoExtend);
+ /***
+ putInt64(tableSpace->initialSize);
+ putInt64(tableSpace->extentSize);
+ putInt64(tableSpace->autoextendSize);
putInt64(tableSpace->maxSize);
putInt(tableSpace->nodegroup);
putInt(tableSpace->wait);
+ ***/
p = tableSpace->comment;
len = (int)strlen(p);
putInt(len);
@@ -79,23 +81,27 @@ void SRLCreateTableSpace::read()
if (control->version >= srlVersion15)
{
- allocation = getInt64();
- extent = getInt64();
- autoExtend = getInt64();
+ /***
+ initialSize = getInt64();
+ extentSize = getInt64();
+ autoextendSize= getInt64();
maxSize = getInt64();
nodegroup = getInt();
wait = getInt();
+ ***/
commentLength = getInt();
comment = (const char*) getData(commentLength);
}
else
{
- allocation = 0;
- extent = 0;
- autoExtend = 0;
+ /***
+ initialSize = 0;
+ extentSize = 0;
+ autoextendSize= 0;
maxSize = 0;
nodegroup = 0;
wait = 0;
+ ***/
commentLength = 0;
comment = NULL;
}
@@ -105,12 +111,14 @@ void SRLCreateTableSpace::pass1()
{
TableSpaceInit tsInit;
- tsInit.allocation = allocation;
- tsInit.extent = extent;
- tsInit.autoExtend = autoExtend;
+ /***
+ tsInit.initialSize = initialSize;
+ tsInit.extentSize = extentSize;
+ tsInit.autoextendSize = autoextendSize;
tsInit.maxSize = maxSize;
tsInit.nodegroup = nodegroup;
tsInit.wait = wait;
+ ***/
tsInit.comment = comment;
log->database->tableSpaceManager->redoCreateTableSpace(tableSpaceId,
nameLength, name, filenameLength, filename, type, &tsInit);
diff -Nrup a/storage/falcon/SRLCreateTableSpace.h b/storage/falcon/SRLCreateTableSpace.h
--- a/storage/falcon/SRLCreateTableSpace.h 2008-03-28 17:44:33 -05:00
+++ b/storage/falcon/SRLCreateTableSpace.h 2008-04-05 17:09:14 -05:00
@@ -48,12 +48,14 @@ public:
int nameLength;
int filenameLength;
int type;
- int64 allocation;
- int64 extent;
- int64 autoExtend;
+ /***
+ int64 initialSize;
+ int64 extentSize;
+ int64 autoExtendSize;
int64 maxSize;
int nodegroup;
int wait;
+ ***/
const char *comment;
int commentLength;
};
diff -Nrup a/storage/falcon/Statement.cpp b/storage/falcon/Statement.cpp
--- a/storage/falcon/Statement.cpp 2008-03-29 13:22:15 -05:00
+++ b/storage/falcon/Statement.cpp 2008-04-05 17:09:14 -05:00
@@ -2949,23 +2949,29 @@ void Statement::createTableSpace(Syntax
if (syntax->type == nod_upgrade_tablespace && tableSpace &&
tableSpace->filename != fileName)
throw SQLError(DDL_ERROR, "can't change filename for tablespace");
- Syntax *options = syntax->getChild(2);
+ // Gather remaining options, if any
+
TableSpaceInit tsInit;
+ if (syntax->count > 2)
+ {
+ Syntax *options = syntax->getChild(2);
+
for (int n = 0; n < options->count; ++n)
{
Syntax *child = options->children[n];
switch (child->type)
{
- case nod_allocation:
- tsInit.allocation = child->getChild(0)->getQuad();
+ /***
+ case nod_initial_size:
+ tsInit.initial_size = child->getChild(0)->getQuad();
break;
- case nod_extent:
- tsInit.extent = child->getChild(0)->getQuad();
+ case nod_extent_size:
+ tsInit.extent_size = child->getChild(0)->getQuad();
break;
- case nod_autoextend:
- tsInit.autoExtend = child->getChild(0)->getQuad();
+ case nod_autoextend_size:
+ tsInit.autoextend_size = child->getChild(0)->getQuad();
break;
case nod_max_size:
tsInit.maxSize = child->getChild(0)->getQuad();
@@ -2976,11 +2982,13 @@ void Statement::createTableSpace(Syntax
case nod_wait:
tsInit.wait = child->getChild(0)->getNumber();
break;
+ ***/
case nod_comment:
tsInit.comment = child->getChild(0)->getString();
break;
default:
break;
+ }
}
}
diff -Nrup a/storage/falcon/StorageDatabase.cpp b/storage/falcon/StorageDatabase.cpp
--- a/storage/falcon/StorageDatabase.cpp 2008-03-28 17:44:34 -05:00
+++ b/storage/falcon/StorageDatabase.cpp 2008-04-05 17:09:14 -05:00
@@ -1185,3 +1185,8 @@ void StorageDatabase::getTableSpaceInfo(
masterConnection->database->getTableSpaceInfo(infoTable);
}
+void StorageDatabase::getTableSpaceFilesInfo(InfoTable* infoTable)
+{
+ if (masterConnection && masterConnection->database)
+ masterConnection->database->getTableSpaceFilesInfo(infoTable);
+}
diff -Nrup a/storage/falcon/StorageDatabase.h b/storage/falcon/StorageDatabase.h
--- a/storage/falcon/StorageDatabase.h 2008-03-28 17:44:34 -05:00
+++ b/storage/falcon/StorageDatabase.h 2008-04-05 17:09:14 -05:00
@@ -110,6 +110,7 @@ public:
void getSerialLogInfo(InfoTable* infoTable);
void getTransactionSummaryInfo(InfoTable* infoTable);
void getTableSpaceInfo(InfoTable* infoTable);
+ void getTableSpaceFilesInfo(InfoTable* infoTable);
};
#endif
diff -Nrup a/storage/falcon/StorageHandler.cpp b/storage/falcon/StorageHandler.cpp
--- a/storage/falcon/StorageHandler.cpp 2008-04-01 09:57:13 -05:00
+++ b/storage/falcon/StorageHandler.cpp 2008-04-05 17:09:14 -05:00
@@ -472,10 +472,12 @@ JString StorageHandler::genCreateTableSp
int nodegroup, bool wait, const char* comment)
{
CmdGen gen;
- gen.gen("create tablespace \"%s\" filename '%s' allocation " I64FORMAT " extent "
I64FORMAT
- " autoextend " I64FORMAT " max_size " I64FORMAT " nodegroup %d wait %d comment '%s'",
- tableSpaceName, filename, initialSize, extentSize, autoextendSize, maxSize,
nodegroup,
- (int)wait, comment ? comment : "");
+ /***
+ gen.gen("create tablespace \"%s\" filename '%s' initial_size " I64FORMAT " extent_size "
I64FORMAT
+ " autoextend_size " I64FORMAT " max_size " I64FORMAT " nodegroup %d wait %d comment
'%s'",
+ tableSpaceName, filename, initialSize, extentSize, autoextendSize, maxSize,
nodegroup, (int)wait, comment ? comment : "");
+ ***/
+ gen.gen("create tablespace \"%s\" filename '%s' comment '%s'", tableSpaceName, filename,
comment ? comment : "");
return (gen.getString());
}
@@ -946,6 +948,15 @@ void StorageHandler::getTableSpaceInfo(I
storageDatabase->getTableSpaceInfo(infoTable);
}
+void StorageHandler::getTableSpaceFilesInfo(InfoTable* infoTable)
+{
+ Sync sync(&hashSyncObject, "StorageHandler::getTableSpaceFilesInfo");
+ sync.lock(Shared);
+
+ for (StorageDatabase *storageDatabase = databaseList; storageDatabase; storageDatabase =
storageDatabase->next)
+ storageDatabase->getTableSpaceFilesInfo(infoTable);
+}
+
void StorageHandler::initialize(void)
{
if (initialized)
@@ -1124,7 +1135,6 @@ void StorageHandler::setRecordChillThres
if (dictionaryConnection)
dictionaryConnection->setRecordChillThreshold(value);
}
-
void StorageHandler::cleanFileName(const char* pathname, char* filename, int
filenameLength)
{
diff -Nrup a/storage/falcon/StorageHandler.h b/storage/falcon/StorageHandler.h
--- a/storage/falcon/StorageHandler.h 2008-04-01 09:57:13 -05:00
+++ b/storage/falcon/StorageHandler.h 2008-04-05 17:09:14 -05:00
@@ -107,6 +107,7 @@ public:
virtual void getSyncInfo(InfoTable* infoTable);
virtual void getTransactionSummaryInfo(InfoTable* infoTable);
virtual void getTableSpaceInfo(InfoTable* infoTable);
+ virtual void getTableSpaceFilesInfo(InfoTable* infoTable);
virtual void getTablesInfo(InfoTable* infoTable);
virtual void setIndexChillThreshold(uint value);
diff -Nrup a/storage/falcon/TableSpace.cpp b/storage/falcon/TableSpace.cpp
--- a/storage/falcon/TableSpace.cpp 2008-03-31 14:13:20 -05:00
+++ b/storage/falcon/TableSpace.cpp 2008-04-05 17:09:14 -05:00
@@ -50,13 +50,15 @@ TableSpace::TableSpace(Database *db, con
TableSpaceInit spaceInit;
TableSpaceInit *init = (tsInit ? tsInit : &spaceInit);
- allocation = init->allocation;
- extent = init->extent;
- autoExtend = init->autoExtend;
+ initialSize = init->initialSize;
+ comment = init->comment;
+ /***
+ extentSize = init->extentSize;
+ autoExtendSize = init->autoExtendSize;
maxSize = init->maxSize;
nodegroup = init->nodegroup;
wait = init->wait;
- comment = init->comment;
+ ***/
}
TableSpace::~TableSpace()
@@ -130,7 +132,7 @@ void TableSpace::open()
void TableSpace::create()
{
dbb->createPath(filename);
- dbb->create(filename, dbb->pageSize, 0, HdrTableSpace, 0, NULL, allocation);
+ dbb->create(filename, dbb->pageSize, 0, HdrTableSpace, 0, NULL, initialSize);
active = true;
dbb->flush();
}
@@ -161,19 +163,20 @@ void TableSpace::sync(void)
void TableSpace::save(void)
{
PStatement statement = database->prepareStatement(
- "replace into system.tablespaces (tablespace, tablespace_id, filename, type,
allocation, extent,"
- "autoextend, max_size, nodegroup, wait, comment) values
(?,?,?,?,?,?,?,?,?,?,?)");
+ "replace into system.tablespaces (tablespace, tablespace_id, filename, type, comment)
values (?,?,?,?,?)");
int n = 1;
statement->setString(n++, name);
statement->setInt(n++, tableSpaceId);
statement->setString(n++, filename);
statement->setInt(n++, type);
- statement->setLong(n++, allocation);
- statement->setLong(n++, extent);
- statement->setLong(n++, autoExtend);
+ /***
+ statement->setLong(n++, initialSize);
+ statement->setLong(n++, extentSize);
+ statement->setLong(n++, autoExtendSize);
statement->setLong(n++, maxSize);
statement->setInt(n++, nodegroup);
statement->setInt(n++, wait);
+ ***/
statement->setString(n++, comment);
statement->executeUpdate();
needSave = false;
@@ -192,25 +195,6 @@ void TableSpace::getIOInfo(InfoTable* in
infoTable->putRecord();
}
-void TableSpace::getTableSpaceInfo(InfoTable* infoTable)
-{
- int n = 0;
- infoTable->putString(n++, name);
- infoTable->putInt(n++, tableSpaceId);
- infoTable->putString(n++, filename);
- infoTable->putInt64(n++, allocation);
-// infoTable->putInt64(n++, extent); // cluster only
- infoTable->putInt64(n++, autoExtend);
- infoTable->putInt64(n++, maxSize);
-// infoTable->putInt(n++, nodegroup); // cluster only
- infoTable->putInt(n++, wait);
- infoTable->putString(n++, comment);
- infoTable->putInt(n++, type);
- infoTable->putInt(n++, active);
- infoTable->putInt(n++, needSave);
- infoTable->putRecord();
-}
-
void TableSpace::close(void)
{
dbb->close();
diff -Nrup a/storage/falcon/TableSpace.h b/storage/falcon/TableSpace.h
--- a/storage/falcon/TableSpace.h 2008-03-28 17:44:34 -05:00
+++ b/storage/falcon/TableSpace.h 2008-04-05 17:09:14 -05:00
@@ -29,14 +29,17 @@ static const int TABLESPACE_TYPE_REPOSIT
struct TableSpaceInit
{
- int64 allocation;
- int64 extent;
- int64 autoExtend;
+ int64 initialSize;
+ JString comment;
+ TableSpaceInit(): initialSize(0), comment("") {}
+ /***
+ int64 extentSize;
+ int64 autoExtendSize;
int64 maxSize;
int nodegroup;
int wait;
- JString comment;
- TableSpaceInit(): allocation(0), extent(0), autoExtend(0), maxSize(0), nodegroup(0),
wait(0), comment("") {}
+ TableSpaceInit(): initialSize(0), extentSize(0), autoExtendSize(0), maxSize(0),
nodegroup(0), wait(0), comment("") {}
+ ***/
};
class Dbb;
@@ -58,7 +61,6 @@ public:
void sync(void);
void save(void);
void getIOInfo(InfoTable* infoTable);
- void getTableSpaceInfo(InfoTable* infoTable);
JString name;
JString filename;
@@ -73,12 +75,14 @@ public:
bool active;
bool needSave;
- int64 allocation;
- int64 extent;
- int64 autoExtend;
+ int64 initialSize;
+ /***
+ int64 extentSize;
+ int64 autoExtendSize;
int64 maxSize;
int nodegroup;
int wait;
+ ***/
JString comment;
};
diff -Nrup a/storage/falcon/TableSpaceManager.cpp b/storage/falcon/TableSpaceManager.cpp
--- a/storage/falcon/TableSpaceManager.cpp 2008-04-05 13:38:39 -05:00
+++ b/storage/falcon/TableSpaceManager.cpp 2008-04-05 17:09:14 -05:00
@@ -27,6 +27,7 @@
#include "PStatement.h"
#include "RSet.h"
#include "Database.h"
+#include "Connection.h"
#include "SequenceManager.h"
#include "Sequence.h"
#include "Stream.h"
@@ -102,7 +103,7 @@ TableSpace* TableSpaceManager::findTable
syncDDL.lock(Shared);
PStatement statement = database->prepareStatement(
- "select tablespace_id, filename, type, allocation, extent, autoextend, max_size,
nodegroup, wait, comment from system.tablespaces where tablespace=?");
+ "select tablespace_id, filename, type, comment from system.tablespaces where
tablespace=?");
statement->setString(1, name);
RSet resultSet = statement->executeQuery();
@@ -113,12 +114,14 @@ TableSpace* TableSpaceManager::findTable
int type = resultSet->getInt(3);
TableSpaceInit tsInit;
- tsInit.allocation = resultSet->getLong(4);
- tsInit.extent = resultSet->getLong(5);
- tsInit.autoExtend = resultSet->getLong(6);
+ /***
+ tsInit.initialSize = resultSet->getLong(4);
+ tsInit.extentSize = resultSet->getLong(5);
+ tsInit.autoExtendSize = resultSet->getLong(6);
tsInit.maxSize = resultSet->getLong(7);
tsInit.nodegroup = resultSet->getInt(8);
tsInit.wait = resultSet->getInt(9);
+ ***/
tsInit.comment = resultSet->getString(10);
tableSpace = new TableSpace(database, name, id, fileName, 0, &tsInit);
@@ -162,13 +165,6 @@ TableSpace* TableSpaceManager::createTab
int type = (repository) ? TABLESPACE_TYPE_REPOSITORY : TABLESPACE_TYPE_TABLESPACE;
int id = (int) sequence->update(1, database->getSystemTransaction());
- // Set unsupported parameters to reasonable values
-
- if (tsInit->nodegroup == 65535)
- tsInit->nodegroup = 0;
- if (tsInit->comment == "(null)")
- tsInit->comment == "";
-
TableSpace *tableSpace = new TableSpace(database, name, id, fileName, type, tsInit);
if (!repository && tableSpace->dbb->doesFileExist(fileName))
@@ -211,32 +207,32 @@ void TableSpaceManager::bootstrap(int se
{
stream.getSegment(0, sizeof(buffer), buffer);
const UCHAR *p = buffer + 2;
- Value name, id, fileName, type, allocation, extent, autoExtend, maxSize, nodegroup,
wait, comment;
+ Value name, id, fileName, type;
p = EncodedDataStream::decode(p, &name, true);
p = EncodedDataStream::decode(p, &id, true);
p = EncodedDataStream::decode(p, &fileName, true);
p = EncodedDataStream::decode(p, &type, true);
/***
- p = EncodedDataStream::decode(p, &allocation, true);
- p = EncodedDataStream::decode(p, &extent, true);
- p = EncodedDataStream::decode(p, &autoExtend, true);
+ p = EncodedDataStream::decode(p, &initialSize, true);
+ p = EncodedDataStream::decode(p, &extentSsize, true);
+ p = EncodedDataStream::decode(p, &autoExtendSize, true);
p = EncodedDataStream::decode(p, &maxSize, true);
p = EncodedDataStream::decode(p, &nodegroup, true);
p = EncodedDataStream::decode(p, &wait, true);
p = EncodedDataStream::decode(p, &comment, true);
- ***/
-
+
TableSpaceInit tsInit;
- tsInit.allocation = allocation.getQuad();
- tsInit.extent = extent.getQuad();
- tsInit.autoExtend = autoExtend.getQuad();
+ tsInit.initialSize = initialSize.getQuad();
+ tsInit.extentSize = extentSize.getQuad();
+ tsInit.autoExtendSize = autoExtendSize.getQuad();
tsInit.maxSize = maxSize.getQuad();
tsInit.nodegroup = nodegroup.getInt();
tsInit.wait = wait.getInt();
tsInit.comment = comment.getString();
-
- TableSpace *tableSpace = new TableSpace(database, name.getString(), id.getInt(),
fileName.getString(), type.getInt(), &tsInit);
+ ***/
+
+ TableSpace *tableSpace = new TableSpace(database, name.getString(), id.getInt(),
fileName.getString(), type.getInt(), NULL);
Log::debug("New table space %s, id %d, type %d, filename %s\n", (const char*)
tableSpace->name, tableSpace->tableSpaceId, tableSpace->type, (const char*)
tableSpace->filename);
if (tableSpace->type == TABLESPACE_TYPE_TABLESPACE)
@@ -467,12 +463,50 @@ void TableSpaceManager::getIOInfo(InfoTa
tableSpace->getIOInfo(infoTable);
}
+JString TableSpaceManager::tableSpaceType(JString name)
+{
+ JString type;
+
+ if (name == "FALCON_USER")
+ type = "FALCON_USER";
+ else if (name == "FALCON_TEMPORARY")
+ type = "FALCON_TEMPORARY";
+ else if (name == "FALCON_SYSTEM_BASE") //cwp tbd: fix this
+ type = "SYSTEM_BASE";
+ else type = "USER_DEFINED";
+
+ return type;
+}
+
void TableSpaceManager::getTableSpaceInfo(InfoTable* infoTable)
{
- Sync sync(&syncObject, "TableSpaceManager::getTableSpaceInfo");
- sync.lock(Shared);
+ PStatement statement = database->systemConnection->prepareStatement(
+ "select tablespace, comment from system.tablespaces");
+ RSet resultSet = statement->executeQuery();
+
+ while (resultSet->next())
+ {
+ infoTable->putString(0, resultSet->getString(1)); // tablespace_name
+ infoTable->putString(1, tableSpaceType(resultSet->getString(1))); // type
+ infoTable->putString(2, resultSet->getString(2)); // comment
+ infoTable->putRecord();
+ }
+}
- for (TableSpace *tableSpace = tableSpaces; tableSpace; tableSpace = tableSpace->next)
- tableSpace->getTableSpaceInfo(infoTable);
+void TableSpaceManager::getTableSpaceFilesInfo(InfoTable* infoTable)
+{
+ PStatement statement = database->systemConnection->prepareStatement(
+ "select tablespace, filename from system.tablespaces");
+ RSet resultSet = statement->executeQuery();
+
+ while (resultSet->next())
+ {
+ infoTable->putString(0, resultSet->getString(1)); // tablespace_name
+ infoTable->putString(1, tableSpaceType(resultSet->getString(1))); // type
+ infoTable->putInt(2, 1); // file_id
+ infoTable->putString(3, resultSet->getString(2)); // file_name
+ infoTable->putRecord();
+ }
}
+
diff -Nrup a/storage/falcon/TableSpaceManager.h b/storage/falcon/TableSpaceManager.h
--- a/storage/falcon/TableSpaceManager.h 2008-03-28 17:44:34 -05:00
+++ b/storage/falcon/TableSpaceManager.h 2008-04-05 17:09:14 -05:00
@@ -52,8 +52,10 @@ public:
void dropDatabase(void);
void dropTableSpace(TableSpace* tableSpace);
void reportStatistics(void);
+ JString tableSpaceType(JString name);
void getIOInfo(InfoTable* infoTable);
void getTableSpaceInfo(InfoTable* infoTable);
+ void getTableSpaceFilesInfo(InfoTable* infoTable);
void validate(int optionMask);
void sync();
void expungeTableSpace(int tableSpaceId);
diff -Nrup a/storage/falcon/ha_falcon.cpp b/storage/falcon/ha_falcon.cpp
--- a/storage/falcon/ha_falcon.cpp 2008-04-05 13:38:39 -05:00
+++ b/storage/falcon/ha_falcon.cpp 2008-04-05 17:09:14 -05:00
@@ -2609,10 +2609,10 @@ NfsPluginHandler::~NfsPluginHandler()
//*****************************************************************************
//
-// System Memory Usage
+// FALCON_SYSTEM_MEMORY_DETAIL
//
//*****************************************************************************
-int NfsPluginHandler::callSystemMemoryDetailInfo(THD *thd, TABLE_LIST *tables, COND
*cond)
+int NfsPluginHandler::getSystemMemoryDetailInfo(THD *thd, TABLE_LIST *tables, COND *cond)
{
InfoTableImpl infoTable(thd, tables, system_charset_info);
@@ -2622,7 +2622,6 @@ int NfsPluginHandler::callSystemMemoryDe
return infoTable.error;
}
-
ST_FIELD_INFO memoryDetailFieldInfo[]=
{
{"FILE", 120, MYSQL_TYPE_STRING, 0, 0, "File", SKIP_OPEN_TABLE},
@@ -2639,7 +2638,7 @@ int NfsPluginHandler::initSystemMemoryDe
DBUG_ENTER("initSystemMemoryDetailInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE*) p;
schema->fields_info = memoryDetailFieldInfo;
- schema->fill_table = NfsPluginHandler::callSystemMemoryDetailInfo;
+ schema->fill_table = NfsPluginHandler::getSystemMemoryDetailInfo;
DBUG_RETURN(0);
}
@@ -2651,11 +2650,11 @@ int NfsPluginHandler::deinitSystemMemory
//*****************************************************************************
//
-// System memory usage summary
+// FALCON_SYSTEM_MEMORY_SUMMARY
//
//*****************************************************************************
-int NfsPluginHandler::callSystemMemorySummaryInfo(THD *thd, TABLE_LIST *tables, COND
*cond)
+int NfsPluginHandler::getSystemMemorySummaryInfo(THD *thd, TABLE_LIST *tables, COND
*cond)
{
//return(pluginHandler->fillSystemMemorySummaryTable(thd, tables, cond));
InfoTableImpl infoTable(thd, tables, system_charset_info);
@@ -2682,7 +2681,7 @@ int NfsPluginHandler::initSystemMemorySu
DBUG_ENTER("initSystemMemorySummaryInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
schema->fields_info = memorySummaryFieldInfo;
- schema->fill_table = NfsPluginHandler::callSystemMemorySummaryInfo;
+ schema->fill_table = NfsPluginHandler::getSystemMemorySummaryInfo;
DBUG_RETURN(0);
}
@@ -2695,11 +2694,11 @@ int NfsPluginHandler::deinitSystemMemory
//*****************************************************************************
//
-// Record cache usage detail
+// FALCON_RECORD_CACHE_DETAIL
//
//*****************************************************************************
-int NfsPluginHandler::callRecordCacheDetailInfo(THD *thd, TABLE_LIST *tables, COND *cond)
+int NfsPluginHandler::getRecordCacheDetailInfo(THD *thd, TABLE_LIST *tables, COND *cond)
{
InfoTableImpl infoTable(thd, tables, system_charset_info);
@@ -2725,7 +2724,7 @@ int NfsPluginHandler::initRecordCacheDet
DBUG_ENTER("initRecordCacheDetailInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
schema->fields_info = recordDetailFieldInfo;
- schema->fill_table = NfsPluginHandler::callRecordCacheDetailInfo;
+ schema->fill_table = NfsPluginHandler::getRecordCacheDetailInfo;
DBUG_RETURN(0);
}
@@ -2738,11 +2737,11 @@ int NfsPluginHandler::deinitRecordCacheD
//*****************************************************************************
//
-// Record cache usage summary
+// FALCON_RECORD_CACHE_SUMMARY
//
//*****************************************************************************
-int NfsPluginHandler::callRecordCacheSummaryInfo(THD *thd, TABLE_LIST *tables, COND
*cond)
+int NfsPluginHandler::getRecordCacheSummaryInfo(THD *thd, TABLE_LIST *tables, COND *cond)
{
InfoTableImpl infoTable(thd, tables, system_charset_info);
@@ -2768,7 +2767,7 @@ int NfsPluginHandler::initRecordCacheSum
DBUG_ENTER("initRecordCacheSummaryInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
schema->fields_info = recordSummaryFieldInfo;
- schema->fill_table = NfsPluginHandler::callRecordCacheSummaryInfo;
+ schema->fill_table = NfsPluginHandler::getRecordCacheSummaryInfo;
DBUG_RETURN(0);
}
@@ -2781,11 +2780,11 @@ int NfsPluginHandler::deinitRecordCacheS
//*****************************************************************************
//
-// Database IO
+// FALCON_TABLESPACE_IO
//
//*****************************************************************************
-int NfsPluginHandler::callTableSpaceIOInfo(THD *thd, TABLE_LIST *tables, COND *cond)
+int NfsPluginHandler::getTableSpaceIOInfo(THD *thd, TABLE_LIST *tables, COND *cond)
{
InfoTableImpl infoTable(thd, tables, system_charset_info);
@@ -2812,7 +2811,7 @@ int NfsPluginHandler::initTableSpaceIOIn
DBUG_ENTER("initTableSpaceIOInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
schema->fields_info = tableSpaceIOFieldInfo;
- schema->fill_table = NfsPluginHandler::callTableSpaceIOInfo;
+ schema->fill_table = NfsPluginHandler::getTableSpaceIOInfo;
DBUG_RETURN(0);
}
@@ -2825,11 +2824,11 @@ int NfsPluginHandler::deinitTableSpaceIO
//*****************************************************************************
//
-// Tablespace Information
+// FALCON_TABLESPACES
//
//*****************************************************************************
-int NfsPluginHandler::callTableSpaceInfo(THD *thd, TABLE_LIST *tables, COND *cond)
+int NfsPluginHandler::getTableSpaceInfo(THD *thd, TABLE_LIST *tables, COND *cond)
{
InfoTableImpl infoTableSpace(thd, tables, system_charset_info);
@@ -2841,19 +2840,9 @@ int NfsPluginHandler::callTableSpaceInfo
ST_FIELD_INFO tableSpaceFieldInfo[]=
{
- {"TABLESPACE", 127, MYSQL_TYPE_STRING, 0, 0, "TableSpace", SKIP_OPEN_TABLE},
- {"ID", 127, MYSQL_TYPE_LONG, 0, 0, "TableSpace Id", SKIP_OPEN_TABLE},
- {"DATAFILE", 127, MYSQL_TYPE_STRING, 0, 0, "Datafile", SKIP_OPEN_TABLE},
- {"INITIAL_SIZE", 127, MYSQL_TYPE_LONGLONG, 0, 0, "Initial Size", SKIP_OPEN_TABLE},
-// {"EXTENT", 127, MYSQL_TYPE_LONGLONG, 0, 0, "Extent", SKIP_OPEN_TABLE},
- {"AUTOEXTEND", 127, MYSQL_TYPE_LONGLONG, 0, 0, "Autoextend", SKIP_OPEN_TABLE},
- {"MAX_SIZE", 127, MYSQL_TYPE_LONGLONG, 0, 0, "Max Size", SKIP_OPEN_TABLE},
-// {"NODEGROUP", 127, MYSQL_TYPE_LONG, 0, 0, "Nodegroup", SKIP_OPEN_TABLE},
- {"WAIT", 127, MYSQL_TYPE_LONG, 0, 0, "Wait", SKIP_OPEN_TABLE},
+ {"TABLESPACE_NAME", 127, MYSQL_TYPE_STRING, 0, 0, "TableSpace Name", SKIP_OPEN_TABLE},
+ {"TYPE", 127, MYSQL_TYPE_STRING, 0, 0, "Type", SKIP_OPEN_TABLE},
{"COMMENT", 127, MYSQL_TYPE_STRING, 0, 0, "Comment", SKIP_OPEN_TABLE},
- {"TYPE", 127, MYSQL_TYPE_LONG, 0, 0, "Type", SKIP_OPEN_TABLE},
- {"ACTIVE", 127, MYSQL_TYPE_LONG, 0, 0, "Active", SKIP_OPEN_TABLE},
- {"SAVE", 127, MYSQL_TYPE_LONG, 0, 0, "Save", SKIP_OPEN_TABLE},
{0, 0, MYSQL_TYPE_STRING, 0, 0, 0, SKIP_OPEN_TABLE}
};
@@ -2862,7 +2851,7 @@ int NfsPluginHandler::initTableSpaceInfo
DBUG_ENTER("initTableSpaceInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
schema->fields_info = tableSpaceFieldInfo;
- schema->fill_table = NfsPluginHandler::callTableSpaceInfo;
+ schema->fill_table = NfsPluginHandler::getTableSpaceInfo;
DBUG_RETURN(0);
}
@@ -2875,11 +2864,52 @@ int NfsPluginHandler::deinitTableSpaceIn
//*****************************************************************************
//
-// Table Information
+// FALCON_TABLESPACE_FILES
+//
+//*****************************************************************************
+
+int NfsPluginHandler::getTableSpaceFilesInfo(THD *thd, TABLE_LIST *tables, COND *cond)
+{
+ InfoTableImpl infoTableSpace(thd, tables, system_charset_info);
+
+ if (storageHandler)
+ storageHandler->getTableSpaceFilesInfo(&infoTableSpace);
+
+ return infoTableSpace.error;
+}
+
+ST_FIELD_INFO tableSpaceFilesFieldInfo[]=
+{
+ {"TABLESPACE_NAME", 127, MYSQL_TYPE_STRING, 0, 0, "TableSpace Name", SKIP_OPEN_TABLE},
+ {"TYPE", 127, MYSQL_TYPE_STRING, 0, 0, "Type", SKIP_OPEN_TABLE},
+ {"FILE_ID", 127, MYSQL_TYPE_LONG, 0, 0, "File ID", SKIP_OPEN_TABLE},
+ {"FILE_NAME", 127, MYSQL_TYPE_STRING, 0, 0, "File Name", SKIP_OPEN_TABLE},
+ {0, 0, MYSQL_TYPE_STRING, 0, 0, 0, SKIP_OPEN_TABLE}
+};
+
+int NfsPluginHandler::initTableSpaceFilesInfo(void *p)
+{
+ DBUG_ENTER("initTableSpaceFilesInfo");
+ ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
+ schema->fields_info = tableSpaceFilesFieldInfo;
+ schema->fill_table = NfsPluginHandler::getTableSpaceFilesInfo;
+
+ DBUG_RETURN(0);
+}
+
+int NfsPluginHandler::deinitTableSpaceFilesInfo(void *p)
+{
+ DBUG_ENTER("deinitTableSpaceFilesInfo");
+ DBUG_RETURN(0);
+}
+
+//*****************************************************************************
+//
+// FALCON_TABLES
//
//*****************************************************************************
-int NfsPluginHandler::callTablesInfo(THD *thd, TABLE_LIST *tables, COND *cond)
+int NfsPluginHandler::getTablesInfo(THD *thd, TABLE_LIST *tables, COND *cond)
{
InfoTableImpl infoTable(thd, tables, system_charset_info);
@@ -2904,7 +2934,7 @@ int NfsPluginHandler::initTablesInfo(voi
DBUG_ENTER("initTablesInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
schema->fields_info = tablesFieldInfo;
- schema->fill_table = NfsPluginHandler::callTablesInfo;
+ schema->fill_table = NfsPluginHandler::getTablesInfo;
DBUG_RETURN(0);
}
@@ -2915,14 +2945,13 @@ int NfsPluginHandler::deinitTablesInfo(v
DBUG_RETURN(0);
}
-
//*****************************************************************************
//
-// Transaction Information
+// FALCON_TRANSACTIONS
//
//*****************************************************************************
-int NfsPluginHandler::callTransactionInfo(THD *thd, TABLE_LIST *tables, COND *cond)
+int NfsPluginHandler::getTransactionInfo(THD *thd, TABLE_LIST *tables, COND *cond)
{
InfoTableImpl infoTable(thd, tables, system_charset_info);
@@ -2952,7 +2981,7 @@ int NfsPluginHandler::initTransactionInf
DBUG_ENTER("initTransactionInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
schema->fields_info = transactionInfoFieldInfo;
- schema->fill_table = NfsPluginHandler::callTransactionInfo;
+ schema->fill_table = NfsPluginHandler::getTransactionInfo;
DBUG_RETURN(0);
}
@@ -2965,11 +2994,11 @@ int NfsPluginHandler::deinitTransactionI
//*****************************************************************************
//
-// Transaction Summary Information
+// FALCON_TRANSACTION_SUMMARY
//
//*****************************************************************************
-int NfsPluginHandler::callTransactionSummaryInfo(THD *thd, TABLE_LIST *tables, COND
*cond)
+int NfsPluginHandler::getTransactionSummaryInfo(THD *thd, TABLE_LIST *tables, COND *cond)
{
InfoTableImpl infoTable(thd, tables, system_charset_info);
@@ -2995,7 +3024,7 @@ int NfsPluginHandler::initTransactionSum
DBUG_ENTER("initTransactionSummaryInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
schema->fields_info = transactionInfoFieldSummaryInfo;
- schema->fill_table = NfsPluginHandler::callTransactionSummaryInfo;
+ schema->fill_table = NfsPluginHandler::getTransactionSummaryInfo;
DBUG_RETURN(0);
}
@@ -3006,14 +3035,13 @@ int NfsPluginHandler::deinitTransactionS
DBUG_RETURN(0);
}
-
//*****************************************************************************
//
-// SerialLog Information
+// FALCON_SERIAL_LOG_INFO
//
//*****************************************************************************
-int NfsPluginHandler::callSerialLogInfo(THD *thd, TABLE_LIST *tables, COND *cond)
+int NfsPluginHandler::getSerialLogInfo(THD *thd, TABLE_LIST *tables, COND *cond)
{
InfoTableImpl infoTable(thd, tables, system_charset_info);
@@ -3038,7 +3066,7 @@ int NfsPluginHandler::initSerialLogInfo(
DBUG_ENTER("initSerialLogInfoInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
schema->fields_info = serialSerialLogFieldInfo;
- schema->fill_table = NfsPluginHandler::callSerialLogInfo;
+ schema->fill_table = NfsPluginHandler::getSerialLogInfo;
DBUG_RETURN(0);
}
@@ -3051,11 +3079,11 @@ int NfsPluginHandler::deinitSerialLogInf
//*****************************************************************************
//
-// Falcon Version Information
+// FALCON_VERSION
//
//*****************************************************************************
-int NfsPluginHandler::callFalconVersionInfo(THD *thd, TABLE_LIST *tables, COND *cond)
+int NfsPluginHandler::getFalconVersionInfo(THD *thd, TABLE_LIST *tables, COND *cond)
{
InfoTableImpl infoTable(thd, tables, system_charset_info);
@@ -3077,7 +3105,7 @@ int NfsPluginHandler::initFalconVersionI
DBUG_ENTER("initFalconVersionInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
schema->fields_info = falconVersionFieldInfo;
- schema->fill_table = NfsPluginHandler::callFalconVersionInfo;
+ schema->fill_table = NfsPluginHandler::getFalconVersionInfo;
DBUG_RETURN(0);
}
@@ -3088,14 +3116,13 @@ int NfsPluginHandler::deinitFalconVersio
DBUG_RETURN(0);
}
-
//*****************************************************************************
//
-// Sync Information
+// FALCON_SYNCOBJECTS
//
//*****************************************************************************
-int NfsPluginHandler::callSyncInfo(THD *thd, TABLE_LIST *tables, COND *cond)
+int NfsPluginHandler::getSyncInfo(THD *thd, TABLE_LIST *tables, COND *cond)
{
InfoTableImpl infoTable(thd, tables, system_charset_info);
@@ -3120,7 +3147,7 @@ int NfsPluginHandler::initSyncInfo(void
DBUG_ENTER("initSyncInfo");
ST_SCHEMA_TABLE *schema = (ST_SCHEMA_TABLE *)p;
schema->fields_info = syncInfoFieldInfo;
- schema->fill_table = NfsPluginHandler::callSyncInfo;
+ schema->fill_table = NfsPluginHandler::getSyncInfo;
DBUG_RETURN(0);
}
@@ -3290,11 +3317,12 @@ static st_mysql_information_schema falco
static st_mysql_information_schema falcon_record_cache_detail = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
static st_mysql_information_schema falcon_record_cache_summary = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
static st_mysql_information_schema falcon_tablespace_io = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
-static st_mysql_information_schema falcon_transaction_info = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
-static st_mysql_information_schema falcon_transaction_summary_info= {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
-static st_mysql_information_schema falcon_sync_info = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
+static st_mysql_information_schema falcon_transactions = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
+static st_mysql_information_schema falcon_transaction_summary = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
+static st_mysql_information_schema falcon_syncobjects = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
static st_mysql_information_schema falcon_serial_log_info = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
-static st_mysql_information_schema falcon_tablespace_info = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
+static st_mysql_information_schema falcon_tablespaces = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
+static st_mysql_information_schema falcon_tablespace_files = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
static st_mysql_information_schema falcon_tables = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
static st_mysql_information_schema falcon_version = {
MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION};
@@ -3376,7 +3404,7 @@ mysql_declare_plugin(falcon)
{
MYSQL_INFORMATION_SCHEMA_PLUGIN,
- &falcon_transaction_info,
+ &falcon_transactions,
"FALCON_TRANSACTIONS",
"MySQL AB",
"Falcon Transactions.",
@@ -3391,7 +3419,7 @@ mysql_declare_plugin(falcon)
{
MYSQL_INFORMATION_SCHEMA_PLUGIN,
- &falcon_transaction_summary_info,
+ &falcon_transaction_summary,
"FALCON_TRANSACTION_SUMMARY",
"MySQL AB",
"Falcon Transaction Summary.",
@@ -3406,7 +3434,7 @@ mysql_declare_plugin(falcon)
{
MYSQL_INFORMATION_SCHEMA_PLUGIN,
- &falcon_sync_info,
+ &falcon_syncobjects,
"FALCON_SYNCOBJECTS",
"MySQL AB",
"Falcon SyncObjects.",
@@ -3466,7 +3494,7 @@ mysql_declare_plugin(falcon)
{
MYSQL_INFORMATION_SCHEMA_PLUGIN,
- &falcon_tablespace_info,
+ &falcon_tablespaces,
"FALCON_TABLESPACES",
"MySQL AB",
"Falcon TableSpaces.",
@@ -3479,6 +3507,21 @@ mysql_declare_plugin(falcon)
NULL /* config options */
},
+ {
+ MYSQL_INFORMATION_SCHEMA_PLUGIN,
+ &falcon_tablespace_files,
+ "FALCON_TABLESPACE_FILES",
+ "MySQL AB",
+ "Falcon TableSpace Files.",
+ PLUGIN_LICENSE_GPL,
+ NfsPluginHandler::initTableSpaceFilesInfo, /* plugin init */
+ NfsPluginHandler::deinitTableSpaceFilesInfo,/* plugin deinit */
+ 0x0005,
+ NULL, /* status variables */
+ NULL, /* system variables */
+ NULL /* config options */
+ },
+
{
MYSQL_INFORMATION_SCHEMA_PLUGIN,
&falcon_tables,
diff -Nrup a/storage/falcon/ha_falcon.h b/storage/falcon/ha_falcon.h
--- a/storage/falcon/ha_falcon.h 2008-03-28 17:44:34 -05:00
+++ b/storage/falcon/ha_falcon.h 2008-04-05 17:09:14 -05:00
@@ -189,51 +189,55 @@ public:
StorageConnection *storageConnection;
StorageTable *storageTable;
- static int callSystemMemoryDetailInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getSystemMemoryDetailInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initSystemMemoryDetailInfo(void *p);
static int deinitSystemMemoryDetailInfo(void *p);
- static int callSystemMemorySummaryInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getSystemMemorySummaryInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initSystemMemorySummaryInfo(void *p);
static int deinitSystemMemorySummaryInfo(void *p);
- static int callRecordCacheDetailInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getRecordCacheDetailInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initRecordCacheDetailInfo(void *p);
static int deinitRecordCacheDetailInfo(void *p);
- static int callRecordCacheSummaryInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getRecordCacheSummaryInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initRecordCacheSummaryInfo(void *p);
static int deinitRecordCacheSummaryInfo(void *p);
- static int callTableSpaceIOInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getTableSpaceIOInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initTableSpaceIOInfo(void *p);
static int deinitTableSpaceIOInfo(void *p);
- static int callTransactionInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getTransactionInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initTransactionInfo(void *p);
static int deinitTransactionInfo(void *p);
- static int callTransactionSummaryInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getTransactionSummaryInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initTransactionSummaryInfo(void *p);
static int deinitTransactionSummaryInfo(void *p);
- static int callSerialLogInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getSerialLogInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initSerialLogInfo(void *p);
static int deinitSerialLogInfo(void *p);
- static int callFalconVersionInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getFalconVersionInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initFalconVersionInfo(void *p);
static int deinitFalconVersionInfo(void *p);
- static int callSyncInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getSyncInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initSyncInfo(void *p);
static int deinitSyncInfo(void *p);
- static int callTableSpaceInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getTableSpaceInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initTableSpaceInfo(void *p);
static int deinitTableSpaceInfo(void *p);
- static int callTablesInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int getTableSpaceFilesInfo(THD *thd, TABLE_LIST *tables, COND *cond);
+ static int initTableSpaceFilesInfo(void *p);
+ static int deinitTableSpaceFilesInfo(void *p);
+
+ static int getTablesInfo(THD *thd, TABLE_LIST *tables, COND *cond);
static int initTablesInfo(void *p);
static int deinitTablesInfo(void *p);
};
| Thread |
|---|
| • bk commit into 6.0 tree (cpowers:1.2625) | cpowers | 6 Apr |