You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 8 Next »

Connector template migration script is designed and written in python 3.11. 

The connector script helps to migrate connectors from Aspire 4.0 to Aspire 5.0.

The script is designed to be robust and easily extensible using templates with transformation matrices.

It can currently migrate the following connector types: Filesystem, SMB, SharePoint online.

The workflows are now ignored and not migrated.

There are implemented these features:

  • ability to change version of template
  • ability passing connectionId, connectorId, workflowId,  policyId to seed, connection, credential
  • the ability passing list of tags
  • default values for properties which are not in 4.0.
  • multiple Starting Points -> split to multiple seeds and connections, script read file and for each line create seed.
  • ability to splitting url to connection and seed.
  • ability to pass as parameter a suffix of http object description

Repository

aspire-migration-component

Step-by-step guide

  1. Run Aspire 4.0 and Aspire 5.0

  2. Download zip file of connector from Aspire 4.0
  3. setup Aspire 5.0 url in file __init.py__, if you are using private certificates, needs to be setup also certificates

       

URL_ASPIRE = "http://localhost:50505/aspire/_api" 
# --- https with certificates
# CA_CERTS = ('client-2048.crt', 'client-2048.key')
# http = urllib3.PoolManager(cert_reqs='REQUIRED', ca_certs=CA_CERTS) 

     4. Run script

python __init.py__ -p smb_connector-content-source.zip

      5. After few second connector is migrated to Aspire 5.0, objects "seed", "connection", "connector", "credential" created with description "migration-{date}".

You can also check the created report about migration "migration-{date}.log" which will be in the  directory "reports" to see what exactly happened. 

Help

We can get information about script by command

python __init.py__ -h


Ability to change version of template

Templates are in directory "migration_template"

The Structure of the project looks similary a situation below.

-- migration

-- migration_template

-- 4.1

-- default

-- aspire-filesystem-source

-- aspire-sharepointonline-source

-- aspire-smb-source

-- type_transform_matrix.json

Connectors can have different properties related to their version 4.0, 4.1, 5.0, 5.1 etc. When we want to work with different version than "default", we need to create new directory there "4.1" everything from directory "default" needs to be copied to this new directory. Changes needs to be done in "*_transform_matrix.json" for current connector.

After we are done with changes. Script must to be run with other parameter "-v [name of new directory]"



  • No labels