title: how to set system property in spring boot application
body: <p>I have a requirement to set system property in spring boot application.
  I don't want to set it from command line.</p>
  
  <p>My concern is what is the best practice to do it.
  Either from constructor 
  Or inside main method. Below is sample for setting it from constructor </p>
  
  <pre><code>@SpringBootApplication
  class Sample{
  @Autowired
  protected TempInfoDao tempInfoDao;
  
  public Sample{
     //Setting System property inside constructor
      System.setProperty("vertx.hazelcast.config","./config/cluster.xml");
  }
  
  /**
   * @param args
   */
  public static void main(String[] args) {
      SpringApplication.run(Sample.class, args);
  }
  </code></pre>
  
  <p>}</p>
  
  <p>What is best approach ? </p>