configuration

On scala project - Getting error GC overhead limit exceeded when running sbt test command

僤鯓⒐⒋嵵緔 提交于 2020-01-02 02:33:51
问题 I'm new in scala programming and getting GC overhead limit exceeded error when I execute sbt test command in one of big scala project. Anyone knows how can I solve this? 回答1: I got help from my friends :) Increase the memory option by executing with -mem option for example: sbt -mem 2048 test Other options: For Mac & Linux user: if we need to execute this a lot. We can update the .bash_profile file and add below command: export SBT_OPTS="-Xmx2G" Other solution (works with Windows as well):

Why config files should't be changed line-by-line with Chef / Puppet?

*爱你&永不变心* 提交于 2020-01-02 01:55:25
问题 Why is changing lines in configuration file considered an anti-pattern in Chef or Puppet? It's something like bad habit, as I understood. I assume that this file-editing is done in some idempotent way and with advanced tools (augeas for example). Why is deploying the whole files, with ERB templates, considered a preferred method? You can find a lot of examples where dev-ops are suggesting usage of templates instead of file-editing. For example here, here, here, etc. 回答1: Actually there is a

View Complete WCF response on error using Visual Studio 2010

☆樱花仙子☆ 提交于 2020-01-02 00:56:12
问题 In Visual Studio 2010 I get an error which tells me the first 1024 bytes of a response from a WCF service when consumed, but no more. I would really like to see the entire response so I can work out what is going wrong, where can I get this info from? Is there a way of logging the full text of an error or are they all limited by the 1024 byte rule? How to View more than 1024 bytes of a wcf response when an error occurs in Visual Studio 2010? 回答1: If you are doing this in debugging mode, where

Modifying application settings in unit tests

自作多情 提交于 2020-01-02 00:39:14
问题 I have a class library I want to unit test using Microsofts unit test framework. Some of the classes I want to test are configured using application settings. These settings are defined inside the Settings.settings file having application scope and suitable default values. When the library is used by the application these settings can be overriden in the App.Config file. If not the default values are used. That's exactly how I want it to be. In some of my test cases I want to test special

Autowired property is null - Spring Boot Configuration

北战南征 提交于 2020-01-01 18:53:34
问题 I am stuck with null values in an autowired property. I am hoping I could get some help. We are using for the project spring-boot version 0.5.0.M6. The four configuration files with beans are in one package and are sorted by "area": Data source configuration Global method security configuration (as we use Spring-ACL) MVC configuration Spring Security configuration The main method that bootstraps everything is in the following file: @EnableAspectJAutoProxy @EnableSpringConfigured

How to set up two-way SSL in Nginx for custom location?

混江龙づ霸主 提交于 2020-01-01 17:28:07
问题 I have a rails 4 project with some API. This project runs with nginx v.1.6.3 and https on production. Nginx configurations: upstream app { # Path to Unicorn SOCK file, as defined previously server unix:/tmp/unicorn.my_domain.sock fail_timeout=0; } server { listen 80; server_name my_domain.com; return 301 https://$server_name$request_uri; } server { listen 443 ssl; ssl_certificate /etc/nginx/ssl/public.crt; ssl_certificate_key /etc/nginx/ssl/private.rsa; server_name my_domain.com; root /var

Setting up dynamic connection string for log4net

痴心易碎 提交于 2020-01-01 12:01:36
问题 I am using log4net and I am have a connection string I want to reference in my log4net config, because the connectionString in "/Config/connectionStrings.config" will be dynamic input from the user. Here is what I am trying to do: <log4net xmlns="log4net"> <root> <level value="ERROR" /> <appender-ref ref="DatabaseAppender" /> </root> <appender name="DatabaseAppender" type="log4net.Appender.AdoNetAppender"> <bufferSize value="100" /> <connectionType value="System.Data.SqlClient.SqlConnection,

Easiest way to manage my CLASSPATH?

和自甴很熟 提交于 2020-01-01 10:50:08
问题 I'm beginning to play with Clojure a bit and my Java experience is pretty limited. I'm coming from the dynamic world of Ruby and OO, so the functional side of things is very interesting! Anyway, as I discover libraries and various tools for use (and the tutorial files for the Pragmatic Clojure Book), everything typically calls for placing files in the CLASSPATH in order for Clojure to see the library for use. Is there such thing as good CLASSPATH practice? Would I ever want to only have a

Configuring File Names for PHPUnit

余生长醉 提交于 2020-01-01 10:28:13
问题 I am a new user of PHPUnit, and I am converting our existing tests (asserts) into the PHPUnit framework to provide a better test environment and code coverage. However, I need to know how to try to get PHPUnit working with our testing code structure. Our project directories are similar to the following: Application1/ CREDIT_CARD.class - Class naming convention for CREDIT_CARD CREDIT_CARD.class.test - Automated Tests for CREDIT_CARD.class File.php - Application File File.php.test - Automated

Laravel load settings from database

僤鯓⒐⒋嵵緔 提交于 2020-01-01 10:18:08
问题 I'm looking for an efficient way to load settings/configuration from the database with Laravel 5. Settings consist of a key and value column, the model class basically looks like this: <?php namespace App; use Illuminate\Database\Eloquent\Model; class Setting extends Model { protected $table = 'settings'; protected $fillable = ['key', 'value']; protected $primaryKey = 'key'; } At first I made a simple helper function which does the job. The problem is, this would lead to multiple calls per