public void Startup()
 {
   DatabaseSubSchemaManager updater = new DatabaseSubSchemaManager(UserProfileDataManagement_SubSchema.SUBSCHEMA_NAME);
   updater.AddDirectory(UserProfileDataManagement_SubSchema.SubSchemaScriptDirectory);
   int curVersionMajor;
   int curVersionMinor;
   if (!updater.UpdateSubSchema(out curVersionMajor, out curVersionMinor) ||
       curVersionMajor != UserProfileDataManagement_SubSchema.EXPECTED_SCHEMA_VERSION_MAJOR ||
       curVersionMinor != UserProfileDataManagement_SubSchema.EXPECTED_SCHEMA_VERSION_MINOR)
     throw new IllegalCallException(string.Format(
         "Unable to update the UserProfileDataManagement's subschema version to expected version {0}.{1}",
         UserProfileDataManagement_SubSchema.EXPECTED_SCHEMA_VERSION_MAJOR, UserProfileDataManagement_SubSchema.EXPECTED_SCHEMA_VERSION_MINOR));
 }
Exemplo n.º 2
0
 public void Startup()
 {
   DatabaseSubSchemaManager updater = new DatabaseSubSchemaManager(ClientManager_SubSchema.SUBSCHEMA_NAME);
   updater.AddDirectory(ClientManager_SubSchema.SubSchemaScriptDirectory);
   int curVersionMajor;
   int curVersionMinor;
   if (!updater.UpdateSubSchema(out curVersionMajor, out curVersionMinor) ||
       curVersionMajor != ClientManager_SubSchema.EXPECTED_SCHEMA_VERSION_MAJOR ||
       curVersionMinor != ClientManager_SubSchema.EXPECTED_SCHEMA_VERSION_MINOR)
     throw new IllegalCallException(string.Format(
         "Unable to update the ClientManager's subschema version to expected version {0}.{1}",
         ClientManager_SubSchema.EXPECTED_SCHEMA_VERSION_MAJOR, ClientManager_SubSchema.EXPECTED_SCHEMA_VERSION_MINOR));
   IDictionary<string, MPClientMetadata> attachedClients = ReadAttachedClientsFromDB();
   lock (_syncObj)
     _attachedClients = attachedClients;
   _controlPoint.AttachedClientSystemIds = attachedClients.Keys;
   _controlPoint.Start();
 }
Exemplo n.º 3
0
 public void Startup()
 {
   DatabaseSubSchemaManager updater = new DatabaseSubSchemaManager(MediaLibrary_SubSchema.SUBSCHEMA_NAME);
   updater.AddDirectory(MediaLibrary_SubSchema.SubSchemaScriptDirectory);
   int curVersionMajor;
   int curVersionMinor;
   if (!updater.UpdateSubSchema(out curVersionMajor, out curVersionMinor) ||
       curVersionMajor != MediaLibrary_SubSchema.EXPECTED_SCHEMA_VERSION_MAJOR ||
       curVersionMinor != MediaLibrary_SubSchema.EXPECTED_SCHEMA_VERSION_MINOR)
     throw new IllegalCallException(string.Format(
         "Unable to update the MediaLibrary's subschema version to expected version {0}.{1}",
         MediaLibrary_SubSchema.EXPECTED_SCHEMA_VERSION_MAJOR, MediaLibrary_SubSchema.EXPECTED_SCHEMA_VERSION_MINOR));
   _miaManagement = new MIA_Management();
   NotifySystemOnline(_localSystemId, SystemName.GetLocalSystemName());
 }