How to configure MongoDB Java driver MongoOptions for production use?

Updated to 2.9 : autoConnectRetry simply means the driver will automatically attempt to reconnect to the server(s) after unexpected disconnects. In production environments you usually want this set to true. connectionsPerHost are the amount of physical connections a single Mongo instance (it’s singleton so you usually have one per application) can establish to a mongod/mongos … Read more

Setup sunspot solr with rails in production environment

The Sunspot gem includes the sunspot-solr binary. The simplest setup would be just to run sunspot-solr start. Depending on how your application is deployed, you might also include a task in your Capistrano deploy that uses Sunspot’s provided rake task to start a Solr server. Namely, rake sunspot:solr:start RAILS_ENV=production. Getting more in-depth from that could … Read more

PushSharp APNS production: The credentials supplied to the package were not recognized (development works fine though)

I figured out the problem. I revoked and regenerated the certificate again, and this time I only exported the private key (without the certificate). In Keychain access, I exported as .p12 and used the new file and it worked. For some reason, PushSharp wasn’t play well with .p12 when both certificate and private key are … Read more

Access environment variables in production build Angular 4

The environment*.ts file contain build time configurations, which you cannot change after the build. If you need to change your configuration after the build, you need to put them in a different place and retrieve them dynamically when the application starts What you can do is: Step #1: put your json configuration files under src/assets/config/[envName].json. … Read more

What is the difference between production and development mode in Angular2?

In development mode, change detection does a second run immediately after the first run and produces an error if any bound value has changed between the first and the second run. This helps to locate bugs where checking values has side-effects or fields or functions don’t return the same value on subsequent calls which undermines … Read more