No announcement yet.

Using SQLite, MongoDB or other DBs as internal DB

  • Filter
  • Time
  • Show
Clear All
new posts

  • Using SQLite, MongoDB or other DBs as internal DB


    is there a way to get mirth installed on a MongoDB or SQLite?
    I've seen a SQLite Driver/Option for the database reader/writer channels.
    Is it possible to use it for mirth as well?

    Simply editing the won't do it, right?
    Something like:

    # options: derby, mysql, postgres, oracle, sqlserver
    #database = sqlite
    database = mongodb
    # examples:
    #	Derby		jdbc:derby:${dir.appdata}/mirthdb;create=true
    #	PostgreSQL	jdbc:postgresql://localhost:5432/mirthdb
    # 	MySQL		jdbc:mysql://localhost:3306/mirthdb
    #	Oracle		jdbc:oracle:thin:@localhost:1521:DB
    #	SQLServer	jdbc:jtds:sqlserver://localhost:1433/mirthdb
    database.url = jdbc:mongodb://username:[email protected]:27017/mirthdb
    Thank you in advance and best regards!
    Last edited by gkittlaus; 09-10-2014, 02:25 AM.

  • #2
    Right, just editing won't make it work. You'll need to actually edit the source code and add XML query mappings for a new DB (like here and here) and possibly implement a specific DAO factory for it (here). There's a lot of work that goes into supporting a backend database. Not only writing all those queries, but also all the testing on different server/channel configurations to make sure there are no problems (like concurrency issues / deadlocks / etc.).

    Also, SQLite might work since it's an actual RDBMS, but not MongoDB (which is NoSQL). Supporting a NoSQL internal database would require a lot more changes to the source code.
    Step 1: JAVA CACHE...DID YOU CLEAR ...wait, ding dong the witch is dead?

    Nicholas Rupley
    Work: 949-237-6069
    Always include what Mirth Connect version you're working with. Also include (if applicable) the code you're using and full stacktraces for errors (use CODE tags). Posting your entire channel is helpful as well; make sure to scrub any PHI/passwords first.

    - How do I foo?
    - You just bar.