Ordinary database engine is deprecated but there is no simple mean to change database engine to Atomic for existing databases.

Possible options:
- ALTER DATABASE MODIFY ENGINE query.
- Flag that triggers migration at ClickHouse startup.

The latter should be easier to implement. 

ContextMutablePtr context,
    const String & database,
    const String & database_path,
    bool force_restore_data)
{
    String database_attach_query;
    String database_metadata_file = database_path + ".sql";
    if (fs::exists(fs::path(database_metadata_file)))
    {
        
        ReadBufferFromFile in(database_metadata_file, 1024);
        readStringUntilEOF(database_attach_query, in);
    }
    else
    {
        
        
        database_attach_query = "CREATE DATABASE " + backQuoteIfNeed(database);
    }
    try
    {
        executeCreateQuery(database_attach_query, context, database, database_metadata_file,  true, force_restore_data);
    }
    catch (Exception & e)
    {
        e.addMessage(fmt::format("while loading database {} from path {}", backQuote(database), database_path));
        throw;
    }
}
static void checkUnsupportedVersion(ContextMutablePtr context, const String & database_name)