Enum Class GrouperDdl
- All Implemented Interfaces:
DdlVersionable
,Serializable
,Comparable<GrouperDdl>
,Constable
ddl versions and stuff for grouper. All ddl classes must have a currentVersion method that
returns the current version.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionfirst version of grouper, make sure the ddl table is theredelete field name/type if in the right situationdelete backup cols if configured to and if existdelete create source and modify source cols if they existchange stem name index if applicableif needs upgrade: backup attribute table, create group cols if not exist, move data to groups, delete old attribute data, if configured to drop backup attribute table, and it exists, then drop itadd indexes on group attribute name colsif needs upgrade: backup memberships table, create new tables, views, columns if not exist, move data around, delete old data, if configured to drop backup membership cols, and they exists, then drop themdrop original columns in membership table not needed for 1.5.add last membership changeadd user auditing and context idsall tables and indexes from grouper v1.3add alternate nameadd change logadd privilege managementadd column to grouper_attribute_assign_value, remove composite memberships where the member is a group, add owner_id column to grouper_group_setDelete flat tables, add PIT tables, update unique index in grouper_group_set, add external subject tables, add index for in table grouper_attribute_defAdd point in time indexes, add additional subject data to member table, add last immediate membership change column to grouper_groups.Grouper 2.1: add alternate name for stems, add source_id columns to point in time tablesGrouper 2.2: migrate from attributeDefType domain to service, add stem set table, add attribute read/update privs, take care of legacy attributesGrouper 2.2 - continued: finish legacy attributesGrouper 2.2.1add grouper loaderGrouper 2.3.0Grouper 2.4.0Grouper 2.5.0add in the hibernate_version_number colsconvert uuid/id to just iddelete uuid if in right situationdelete backup cols if configured to and is existdrop grouper_sessions table if existsupdate the fields id as a foreign key, keep backups of old data -
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addAllForeignKeysViewsEtc
(DdlVersionBean ddlVersionBean) add all foreign keysstatic int
keep the current version here, increment as things changestatic int
void
dropAllViews
(DdlVersionBean ddlVersionBean) drop all viewsget the table pattern for this dbname (would be nice if there were no overlap, so ext's should not start with grouper, e.g.abstract String
get the grouper version for this version, e.g.get the object name of this enum, e.g.String[]
an example table name so we can hone in on the exact metadataint
get the version of this enumboolean
boolean
if this version requires an empty changelogabstract void
updateVersionFromPrevious
(Database database, DdlVersionBean ddlVersionBean) check to see if the changes are already made, and then add the changes to the database object that should be used to update from the previous versionstatic GrouperDdl
Returns the enum constant of this class with the specified name.static GrouperDdl[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
V13
change stem name index if applicable -
V12
delete create source and modify source cols if they exist -
V14
if needs upgrade: backup attribute table, create group cols if not exist, move data to groups, delete old attribute data, if configured to drop backup attribute table, and it exists, then drop it
-
V15
add indexes on group attribute name cols -
V16
if needs upgrade: backup memberships table, create new tables, views, columns if not exist, move data around, delete old data, if configured to drop backup membership cols, and they exists, then drop them
-
V17
drop original columns in membership table not needed for 1.5. also add unique index and field indexes.
-
V18
add last membership change
-
V19
add user auditing and context ids
-
V20
add alternate name
-
V21
add change log
-
V22
add privilege management
-
V23
add column to grouper_attribute_assign_value, remove composite memberships where the member is a group, add owner_id column to grouper_group_set
-
V24
Delete flat tables, add PIT tables, update unique index in grouper_group_set, add external subject tables, add index for in table grouper_attribute_def
-
V25
Add point in time indexes, add additional subject data to member table, add last immediate membership change column to grouper_groups.
-
V26
Grouper 2.1: add alternate name for stems, add source_id columns to point in time tables
-
V11
delete backup cols if configured to and if exist -
V10
delete field name/type if in the right situation -
V9
update the fields id as a foreign key, keep backups of old data -
V8
drop grouper_sessions table if exists -
V7
delete backup cols if configured to and is exist -
V6
delete uuid if in right situation -
V5
convert uuid/id to just id -
V4
add in the hibernate_version_number cols -
V3
add grouper loader -
V2
all tables and indexes from grouper v1.3 -
V1
first version of grouper, make sure the ddl table is there -
V27
Grouper 2.2: migrate from attributeDefType domain to service, add stem set table, add attribute read/update privs, take care of legacy attributes
-
V28
Grouper 2.2 - continued: finish legacy attributes
-
V29
Grouper 2.2.1
-
V30
Grouper 2.3.0
-
V31
Grouper 2.4.0
-
V32
Grouper 2.5.0
-
V33
-
V34
-
V35
-
V36
-
V37
-
V38
-
V39
-
V40
-
V41
-
V42
-
V43
-
V44
-
V45
-
V46
-
V47
-
-
Field Details
-
COLUMN_CONTEXT_ID
context id column name- See Also:
-
BAK_GROUPER_ATTRIBUTES
- See Also:
-
ID_SIZE
size of id cols- See Also:
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
getVersion
public int getVersion()Description copied from interface:DdlVersionable
get the version of this enum- Specified by:
getVersion
in interfaceDdlVersionable
- Returns:
- the version
- See Also:
-
getGrouperVersion
get the grouper version for this version, e.g. x.y.z- Specified by:
getGrouperVersion
in interfaceDdlVersionable
- Returns:
- the grouper version
-
currentVersion
public static int currentVersion()keep the current version here, increment as things change- Returns:
- the current version
-
getObjectName
Description copied from interface:DdlVersionable
get the object name of this enum, e.g. if GrouperEnum, the object name is Grouper- Specified by:
getObjectName
in interfaceDdlVersionable
- Returns:
- the object name
- See Also:
-
getDefaultTablePattern
Description copied from interface:DdlVersionable
get the table pattern for this dbname (would be nice if there were no overlap, so ext's should not start with grouper, e.g. grouploader_ note that underscore is a wildcard which is unfortunate
- Specified by:
getDefaultTablePattern
in interfaceDdlVersionable
- Returns:
- the table patter, e.g. "GROUPER%"
- See Also:
-
updateVersionFromPrevious
Description copied from interface:DdlVersionable
check to see if the changes are already made, and then add the changes to the database object that should be used to update from the previous version- Specified by:
updateVersionFromPrevious
in interfaceDdlVersionable
- Parameters:
database
- ddlutils database objectddlVersionBean
- has references to stuff you need- See Also:
-
dropAllViews
drop all views- Specified by:
dropAllViews
in interfaceDdlVersionable
- Parameters:
ddlVersionBean
-
-
addAllForeignKeysViewsEtc
add all foreign keys- Specified by:
addAllForeignKeysViewsEtc
in interfaceDdlVersionable
- Parameters:
ddlVersionBean
-
-
getSampleTablenames
an example table name so we can hone in on the exact metadata- Specified by:
getSampleTablenames
in interfaceDdlVersionable
- Returns:
- the table name
-
requiresEmptyChangelog
public boolean requiresEmptyChangelog()Description copied from interface:DdlVersionable
if this version requires an empty changelog- Specified by:
requiresEmptyChangelog
in interfaceDdlVersionable
- Returns:
- true if so
-
defaultMinIdIndex
public static int defaultMinIdIndex() -
recreateViewsAndForeignKeys
public boolean recreateViewsAndForeignKeys()- Specified by:
recreateViewsAndForeignKeys
in interfaceDdlVersionable
- Returns:
- true if the update requires views/keys to be recreated
- See Also:
-