MongoDB Migration
As part of the iFIX-2.0-alpha release, we have migrated the following master data from ifix_db to mgramseva_db:
Adapter Master Data Service
Department
Expenditure
Project
Department Entity Service
Department Entity
Department Hierarchy
Out of these, the project data SHOULD NOT be copied to the new DB because a new feature of the multi-tenant (GP) project is introduced with this release. New projects can be created and linked to multiple GPs.
Other master data can be copied.
Pre-requisites
Make sure the playground pod is “dwssio/playground:mongo-v2” or newer.
Keep the MongoDB Credentials handy in the following format
Host(in this format): “<host-address>:27017”
Username - a user that has access to BOTH source and destination dbs
Password
Source and Destination DB Names
List of collection names to be copied
The
mongo-migration.sh
script copied to the playground pod. (You must have necessary kube permissions to copy a file to a pod.)Sample Command to copy the file:
kubectl cp mongo_migration.sh ifix/<playground pod>:/
Migration Instructions
A MongoDB Dump script is provided that will copy a list of collections from a source DB to the destination DB.
Execute the provided script using following parameters:
-h = Host Address
-u = username
-p = password
-s = source db
-d = destination db
-c = collection name - You can provide multiple collection as depicted in the following example
./mongo-migration.sh -h <host-address>:27017 -u <ifix username> -p <ifix password> - s <ifix db> -d <mgramseva db> -c department -c expenditure -c departmentHierarchyLevel -c departmentEntity
Last updated