-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pin path migration #103
Pin path migration #103
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #103 +/- ##
===========================================
- Coverage 87.61% 86.43% -1.18%
===========================================
Files 43 39 -4
Lines 3092 5139 +2047
Branches 225 404 +179
===========================================
+ Hits 2709 4442 +1733
- Misses 383 697 +314 ☔ View full report in Codecov by Sentry. |
src/config/config.cpp
Outdated
{ | ||
MigrationConfig config {}; | ||
|
||
config.mMigrationPath = migration.GetValue<std::string>("migrationPath"); | ||
config.mMergedMigrationPath = migration.GetValue<std::string>("mergedMigrationPath"); | ||
|
||
for (const auto& moduleConfig : moduleConfigs) { | ||
aos::common::utils::CaseInsensitiveObjectWrapper object( | ||
moduleConfig.mParams.extract<Poco::JSON::Object::Ptr>()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's a constructor that accepts poco dynamic var that does extract in the implementation:
CaseInsensitiveObjectWrapper::CaseInsensitiveObjectWrapper(const Poco::Dynamic::Var& var)
moduleConfig.mParams.extract<Poco::JSON::Object::Ptr>()); | |
); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good. thank you. changed
src/database/database.cpp
Outdated
CreateMigrationData(migration); | ||
mMigration->MigrateToVersion(GetVersion()); | ||
DropMigrationData(); | ||
} catch (const Poco::Exception& e) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use unified version:
} catch (const Poco::Exception& e) { | |
catch (const std::exception& e) { | |
return utils::ToAosError(e); | |
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
tests/database/database_test.cpp
Outdated
} | ||
|
||
/** | ||
void Migration::CreateVersionTable() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
delete this code if not needed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
tests/database/database_test.cpp
Outdated
now; | ||
} | ||
|
||
*/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should be removed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure, done.
Signed-off-by: Mykola Kobets <[email protected]>
ee8bd1e
to
f15cd5a
Compare
Signed-off-by: Mykola Kobets <[email protected]>
f15cd5a
to
4ba0f10
Compare
|
No description provided.