Troubles Integrating diesel_migration in my library #3003
Unanswered
case-prudolicce
asked this question in
Q&A
Replies: 1 comment
-
I'm not sure what information you like to get here, as this strategy is exactly the right way to handle migrations using the |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello, I am currently stuck with one of my projects, IntelCache, with inplementing an init command for my server.
The issue I have is implementing
diesel_migrations
in the library backend portion of the code (which would be called by servers and any rust based clients). The idea is that my server would call a function from that library (init,build_server, whatever)Thing is, I've tried doing that. And at first glance it works but when verifying mysql it clearly isn't doing anything. However there aren't any errors or warnings to point me in any direction.
Im wondering why this isn't working and how/what can I do about this.
I dont have the code but if I recall added a
build_sql
function in libbackend. Libbackend had theembed_migrations!
with the right relative path,#[macro_use]
on top ofextern crate diesel_migrations
, thebuild_sql
function calledembedded_migrations::run(&db_con)
and thedb_con
was verified.build_sql
was being called from another crate (server) within the same workspace. No errors, no warnings, seems to work, empty databse. I'm at a loss of words.Beta Was this translation helpful? Give feedback.
All reactions