auto-config.xml 3.03 KB
<?xml version="1.0" encoding="UTF-8"?>

<config>
    <group>
        <property name="yoho.search.service.env.namespace" defaultValue="yohosearch" description="namespace"/>
        <property name="yoho.search.service.env.serverport" defaultValue="0" description="port"/>
        <property name="yoho.search.service.env.webapphome" defaultValue="/home/dev/yoho-search-service/deploy" description="install path"/>

        <property name="search.es.cluster.name" defaultValue="yohosearch_test" description="" />
        <property name="search.es.servers" defaultValue="192.168.102.209:9300 192.168.102.216:9300" description="" />
        <property name="search.index.number_of_replicas" defaultValue="1" description="" />
        <property name="search.index.refresh_interval" defaultValue="1" description="" />
        <property name="search.index.translog.flush_threshold_ops" defaultValue="5000" description="" />
        <property name="search.index.batch.limit" defaultValue="5000" description="" />
        <property name="search.index.batch.limit.tbl" defaultValue="2000" description="" />
        <property name="search.index.batch.max.thread.size" defaultValue="10" description="" />
        <property name="search.minimum.should.match" defaultValue="75%" description="" />
        <property name="search.operator" defaultValue="and" description="" />
        <property name="search.default.field" defaultValue="productName_ansj^10,brandName^500,brandDomain^100,brandNameCn^100,brandNameEn^100,maxSort^300,middleSort^500,smallSort^1000,searchField_ansj,productSkn_ansj,brandNameCn_pinyin^100,maxSort_pinyin^300,middleSort_pinyin^500,smallSort_pinyin^1000,productKeyword^500,brandKeyword^500,searchField" description="" />
        <property name="search.script.score" defaultValue="_score+doc['sortWeight'].value*0.003+(100-doc['breakingRate'].value)/100 * doc['salesWithDateDiff'].value/pow((now-doc['shelveTime'].value)/3600+2,1.8)" description="" />
        <property name="search.script.lang" defaultValue="groovy" description="" />
        <property name="search.contain.global" defaultValue="true" description="搜索结果包含全球购是否生效" />

        <property name="jdbc.mysql.yhbsearch.datasources" defaultValue="yhb_search_2016" description="" />
        <property name="jdbc.mysql.yhbsearch.master" defaultValue="192.168.102.216:3306" description="" />
        <property name="jdbc.mysql.yhbsearch.slave" defaultValue="192.168.102.216:3306" description="" />
        <property name="jdbc.mysql.yhbsearch.username" defaultValue="yh_test" description="" />
        <property name="jdbc.mysql.yhbsearch.password" defaultValue="9nm0icOwt6bMHjMusIfMLw==" description="" />

    </group>
    <script>
        <generate template="META-INF/autoconf/databases.yml" destfile="WEB-INF/classes/databases.yml"/>
        <generate template="META-INF/autoconf/logback.xml" destfile="WEB-INF/classes/logback.xml"/>
        <generate template="META-INF/autoconf/config.properties" destfile="WEB-INF/classes/config.properties"/>
    </script>
</config>