question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

4.7.0 Application always uses Embedded MongoDB regardless of configuration

See original GitHub issue

Mid development I upgraded my STS to the latest version and noticed an interesting side effect that each time I start an application from eclipse, it uses the embedded MongoDB regardless of the supplied configuration (we have dedicated MongoDB servers for development). If I remove the dependency to the embedded DB then it successfully connects to the remote DB. This also works if I use @ImportAutoConfiguration(exclude = EmbeddedMongoAutoConfiguration.class) however this sort of poses a problem for the integration tests.

I did check out this project to my laptop with an older STS and with the same run configuration it connects to the remote DB.

As for my project setup it`s a plain spring boot (v2.5.5) back end project. de.flapdoodle.embed.mongo is used for the embedded db with a test scope. Dependencies are handled by Maven.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
martinlippertcommented, Feb 13, 2021

We fixed the default behavior for existing launch configs a while ago, so this should be working now out-of-the-box. If not, please comment and we can re-open this.

0reactions
kdvoldercommented, Jun 24, 2020

the result of me updating the workspace to that of this latest eclipse?

I beleave so, I think the ‘exclude test code’ behavior in Eclipse m2e has changed in the latest Eclipse and STS had to make some changes in boot launch to accomodate. The changes that we had to make was to switch on the ‘Exclude Test Code’ option by default. Unfortunately… defaults values for launch config attributes are set only when a launch config is created. Existing launch configs already have their options set and are persisted with whatever was set on them at creation time. So pre-existing launch configs will not have this option set.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Spring Data MongoDB - Reference Documentation
The Spring Data MongoDB project applies core Spring concepts to the development of solutions that use the MongoDB document style data store.
Read more >
Changelog | Meteor API Docs
In case you want types in your app using the core packages types/zodern:types (now you do have the ... Mongo changes to support...
Read more >
Unable to download embedded MongoDB, behind proxy ...
I am using Eclipse on Windows 7. I am behind a proxy that uses automatic configuration script, as I have observed in the...
Read more >
Images OpenShift Container Platform 4.7 | Red Hat Customer ...
As a developer, you can use Ruby on Rails to: Write your application: Set up a database. Create a welcome page. Configure your...
Read more >
Compatibility Changes in MongoDB 4.4
If you were relying on the MongoDB 4.2 or previous MSI installer to install the Database Tools along with the MongoDB Server, you...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found