Changes between Version 2 and Version 3 of TracDev/PluginDevelopment/ExtensionPoints/trac.env.IEnvironmentSetupParticipant
- Timestamp:
- May 12, 2010, 8:26:54 PM (14 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
TracDev/PluginDevelopment/ExtensionPoints/trac.env.IEnvironmentSetupParticipant
v2 v3 4 4 ||'''Module'''||''trac.env''||'''Source'''||[source:trunk/trac/env.py#L51 env.py]|| 5 5 6 The ''IEnvironmentSetupParticipant'' is responsible for either creating a new environment or to upgrade (aka migrate) an existing environment to a newer version of that environment. 7 8 Implementations of the extension point interface will be called during both ''trac-admin <env-dir> initenv'' and on ''trac-admin <env-dir> upgrade''. 6 The ''IEnvironmentSetupParticipant'' will be called during both the creation of a new environment (''trac-admin <env-dir> initenv'') and on upgrade of an existing environment (''trac-admin <env-dir> upgrade''). 9 7 10 8 == Purpose == 11 9 12 Responsibilities of the interface are to participate in the creation of a newenvironment. This includes adding information to the database schema, such as table declarations and so on. Some implementations, see below, might also opt in for adding default data to the newly created database, or to set up the folder where the environment will be created in.10 Responsibilities of the interface are to both participate in the creation of a new environment and during upgrade of an existing environment. This includes adding information to the database schema, such as table declarations and so on. Some implementations, see below, might also opt in for adding default data to the newly created database, or to set up the folder where the environment will be created in. 13 11 14 12 On environment upgrade, the responsibilities of the participant are to non-destructively migrate existing user data to a newer database schema, provided that the data model has changed at the SQL level, and of course to migrate the environment's folder structure and content to meet the requirements of the participant.