Password migration

Hi Guys

Just trying to manually migrate some data from backendless3 to backendless 5. Need to do this manually rather than using your built in migration as we wanted to change some values during the data migration process.

Using node.js for this, but we are stuck on trying to copy over the passwords on the users. Thought this might be a stumbling block. Is there a way to move over the passwords so they stay the same, we don’t need to see the passwords or modify them!

Sample code we are using:

var importedUser = {
name: users.data[i].name,
email: users.data[i].email,
surname: users.data[i].surname,
password: users.data[i].password
}

  Backendless5.Data.of("Users").save(importedUser)
    .then( function( savedObject ) {
      console.log( "new user has been saved into v5" );
    })
    .catch( function( error ) {
      console.log( "an error has occurred " + error.message );
    });

Hi Mike,
We don’t store decrypted passwords so there is no possibility to manually migrate your data.
Please consider to use built-in migration and change the values after the migration process.

Regards,
Maksym

Hi Maksym.

Thanks,

Is there a way to call the built in migration method via api or for certain dates. The problem we have is that there will be overlap between v3 backendless and v5 backendless for a while so we can’t migrate all the data over and be done with it. We need to move new users (and their passwords) every day or so as some users continue to use the v3 app and we need to make sure that this is moved across and is ready when they start using the app built for v5 backendless

Mike

The migration process can be made only via Console. You should create a new application in the version 5 of Backendless, migrate data and files from the 3.x application and then move the users to the new version. Both 3 and 5 version of your application will be available so users can migrate at any time.
For more information please visit the API Documentation:
https://backendless.com/docs/js/migrating_app_data.html

Regards,
Maksym

Unfortunately it is more complicated than that in our case. We also have a web app which will use the new version of backendless v5 data, and this needs to reflect the data being used by app v3 users as well as app v5 users, which would not be the case if we migrated the data via the console. We continually need to push data created by app v3 users over to backendless v5 tables until all the app v3 users have updated their apps to v5 apps.

As @Maksym_Khobotin wrote earlier - migration can be performed only via console. Partial migration cannot be done.
You may move data to v5 now and after that build up a set of afterCreate and afterUpdate handlers in v3 to continuously update v5 database with all required changes. But keep in mind that adding and setting new relations is impossible as objectId’s of newly created objects will differ in v3 and v5 apps. If you need help with this you may contact sales@backendless.com to order professional services or you can try experimenting with this by yourself.

Anton