@@ -0,0 +1,1377 @@
+/*%0A * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one%0A * or more contributor license agreements. Licensed under the Elastic License;%0A * you may not use this file except in compliance with the Elastic License.%0A */%0Apackage org.elasticsearch.watcher;%0A%0Aimport org.elasticsearch.bootstrap.ElasticsearchF;%0Aimport org.elasticsearch.license.plugin.LicensePlugin;%0A%0A/**%0A * Main class to easily run Watcher from a IDE.%0A * It sets all the options to run the Watcher plugin and access it from Sense, but doesn't run with Shield.%0A *%0A * During startup an error will be printed that the config directory can't be found, to fix this:%0A * 1) Add a config directly to the top level project directory%0A * 2) or set %60-Des.path.conf=%60 to a location where there is a config directory on your machine.%0A */%0Apublic class WatcherF %7B%0A%0A    public static void main(String%5B%5D args) %7B%0A        System.setProperty(%22es.http.cors.enabled%22, %22true%22);%0A        System.setProperty(%22es.script.disable_dynamic%22, %22false%22);%0A        System.setProperty(%22es.shield.enabled%22, %22false%22);%0A        System.setProperty(%22es.plugins.load_classpath_plugins%22, %22false%22);%0A        System.setProperty(%22es.plugin.types%22, WatcherPlugin.class.getName() + %22,%22 + LicensePlugin.class.getName());%0A        System.setProperty(%22es.cluster.name%22, WatcherF.class.getSimpleName());%0A%0A        ElasticsearchF.main(args);%0A    %7D%0A%0A%7D%0A

Add a simple runner that allows to run Watcher from the IDE and work out of the box with Sense.