108a0c20eSJorgen Austvik<?xml version="1.0" encoding="UTF-8"?> 218446c8aSKnut Anders Hatlen<!-- 318446c8aSKnut Anders Hatlen 418446c8aSKnut Anders HatlenCDDL HEADER START 518446c8aSKnut Anders Hatlen 618446c8aSKnut Anders HatlenThe contents of this file are subject to the terms of the 718446c8aSKnut Anders HatlenCommon Development and Distribution License (the "License"). 818446c8aSKnut Anders HatlenYou may not use this file except in compliance with the License. 918446c8aSKnut Anders Hatlen 1018446c8aSKnut Anders HatlenSee LICENSE.txt included in this distribution for the specific 1118446c8aSKnut Anders Hatlenlanguage governing permissions and limitations under the License. 1218446c8aSKnut Anders Hatlen 1318446c8aSKnut Anders HatlenWhen distributing Covered Code, include this CDDL HEADER in each 1418446c8aSKnut Anders Hatlenfile and include the License file at LICENSE.txt. 1518446c8aSKnut Anders HatlenIf applicable, add the following below this CDDL HEADER, with the 1618446c8aSKnut Anders Hatlenfields enclosed by brackets "[]" replaced with your own identifying 1718446c8aSKnut Anders Hatleninformation: Portions Copyright [yyyy] [name of copyright owner] 1818446c8aSKnut Anders Hatlen 1918446c8aSKnut Anders HatlenCDDL HEADER END 2018446c8aSKnut Anders Hatlen 2156f072caSAdam HornáčekCopyright (c) 2010, 2018, Oracle and/or its affiliates. All rights reserved. 22431a6d7cSChris FrairePortions Copyright (c) 2017-2018, Chris Fraire <cfraire@me.com>. 2318446c8aSKnut Anders Hatlen 2418446c8aSKnut Anders Hatlen--> 250170aac5SAdam Hornáček<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> 2608a0c20eSJorgen Austvik <modelVersion>4.0.0</modelVersion> 2708a0c20eSJorgen Austvik 2808a0c20eSJorgen Austvik <parent> 2956f072caSAdam Hornáček <groupId>org.opengrok</groupId> 306ed99b2dSVladimir Kotal <artifactId>opengrok-top</artifactId> 31b1d98e1dSVladimir Kotal <version>1.1-rc34</version> 3208a0c20eSJorgen Austvik </parent> 3308a0c20eSJorgen Austvik 34bb76b0b8SAdam Hornáček <artifactId>opengrok</artifactId> 35*911e8af0SAdam Hornáček <version>1.1-rc34</version> 360170aac5SAdam Hornáček <packaging>jar</packaging> 370170aac5SAdam Hornáček 380170aac5SAdam Hornáček <name>OpenGrok Indexer</name> 390170aac5SAdam Hornáček 400170aac5SAdam Hornáček <dependencies> 410170aac5SAdam Hornáček <dependency> 420170aac5SAdam Hornáček <groupId>org.apache.bcel</groupId> 430170aac5SAdam Hornáček <artifactId>bcel</artifactId> 440170aac5SAdam Hornáček </dependency> 450170aac5SAdam Hornáček <dependency> 460170aac5SAdam Hornáček <groupId>org.apache.lucene</groupId> 470170aac5SAdam Hornáček <artifactId>lucene-core</artifactId> 480170aac5SAdam Hornáček </dependency> 490170aac5SAdam Hornáček <dependency> 500170aac5SAdam Hornáček <groupId>org.apache.lucene</groupId> 510170aac5SAdam Hornáček <artifactId>lucene-analyzers-common</artifactId> 520170aac5SAdam Hornáček </dependency> 530170aac5SAdam Hornáček <dependency> 540170aac5SAdam Hornáček <groupId>org.apache.lucene</groupId> 552cacd6e7SAdam Hornáček <artifactId>lucene-highlighter</artifactId> 562cacd6e7SAdam Hornáček </dependency> 572cacd6e7SAdam Hornáček <dependency> 582cacd6e7SAdam Hornáček <groupId>org.apache.lucene</groupId> 592cacd6e7SAdam Hornáček <artifactId>lucene-join</artifactId> 602cacd6e7SAdam Hornáček </dependency> 612cacd6e7SAdam Hornáček <dependency> 622cacd6e7SAdam Hornáček <groupId>org.apache.lucene</groupId> 632cacd6e7SAdam Hornáček <artifactId>lucene-memory</artifactId> 642cacd6e7SAdam Hornáček </dependency> 652cacd6e7SAdam Hornáček <dependency> 662cacd6e7SAdam Hornáček <groupId>org.apache.lucene</groupId> 672cacd6e7SAdam Hornáček <artifactId>lucene-queries</artifactId> 682cacd6e7SAdam Hornáček </dependency> 692cacd6e7SAdam Hornáček <dependency> 702cacd6e7SAdam Hornáček <groupId>org.apache.lucene</groupId> 710170aac5SAdam Hornáček <artifactId>lucene-queryparser</artifactId> 720170aac5SAdam Hornáček </dependency> 730170aac5SAdam Hornáček <dependency> 740170aac5SAdam Hornáček <groupId>org.apache.lucene</groupId> 75f11f248bSAdam Hornáček <artifactId>lucene-backward-codecs</artifactId> 76f11f248bSAdam Hornáček <version>${lucene.version}</version> 77f11f248bSAdam Hornáček </dependency> 78f11f248bSAdam Hornáček <dependency> 79f11f248bSAdam Hornáček <groupId>org.apache.lucene</groupId> 800170aac5SAdam Hornáček <artifactId>lucene-suggest</artifactId> 810170aac5SAdam Hornáček </dependency> 820170aac5SAdam Hornáček <dependency> 830170aac5SAdam Hornáček <groupId>javax.servlet</groupId> 84e393cb49SAdam Hornáček <artifactId>javax.servlet-api</artifactId> 850170aac5SAdam Hornáček </dependency> 860170aac5SAdam Hornáček <dependency> 870170aac5SAdam Hornáček <groupId>com.googlecode.json-simple</groupId> 880170aac5SAdam Hornáček <artifactId>json-simple</artifactId> 890170aac5SAdam Hornáček </dependency> 900170aac5SAdam Hornáček <dependency> 9156f072caSAdam Hornáček <groupId>org.opengrok</groupId> 920170aac5SAdam Hornáček <artifactId>jrcs</artifactId> 930170aac5SAdam Hornáček <version>${project.version}</version> 940170aac5SAdam Hornáček </dependency> 950170aac5SAdam Hornáček <dependency> 960170aac5SAdam Hornáček <groupId>org.apache.ant</groupId> 970170aac5SAdam Hornáček <artifactId>ant</artifactId> 980170aac5SAdam Hornáček </dependency> 991a2bb6b6SAdam Hornáček <dependency> <!-- TODO: remove! (moving Messages to web module) --> 1001a2bb6b6SAdam Hornáček <groupId>org.glassfish.jersey.ext</groupId> 1011a2bb6b6SAdam Hornáček <artifactId>jersey-bean-validation</artifactId> 1024ce4e2b9SAdam Hornáček <version>${jersey.version}</version> 1034ce4e2b9SAdam Hornáček </dependency> 1044ce4e2b9SAdam Hornáček <dependency> 1054ce4e2b9SAdam Hornáček <groupId>org.glassfish.jersey.media</groupId> 1064ce4e2b9SAdam Hornáček <artifactId>jersey-media-json-jackson</artifactId> 1074ce4e2b9SAdam Hornáček <version>${jersey.version}</version> 1084ce4e2b9SAdam Hornáček </dependency> 1094ce4e2b9SAdam Hornáček <dependency> 1101a2bb6b6SAdam Hornáček <groupId>org.glassfish.jersey.core</groupId> 1111a2bb6b6SAdam Hornáček <artifactId>jersey-client</artifactId> 1124ce4e2b9SAdam Hornáček <version>${jersey.version}</version> 1134ce4e2b9SAdam Hornáček </dependency> 1144ce4e2b9SAdam Hornáček <dependency> 1151a2bb6b6SAdam Hornáček <groupId>org.glassfish.jersey.inject</groupId> 1161a2bb6b6SAdam Hornáček <artifactId>jersey-hk2</artifactId> 1171a2bb6b6SAdam Hornáček <version>${jersey.version}</version> 1184ce4e2b9SAdam Hornáček </dependency> 1194ce4e2b9SAdam Hornáček <dependency> 1200170aac5SAdam Hornáček <groupId>junit</groupId> 1210170aac5SAdam Hornáček <artifactId>junit</artifactId> 1220170aac5SAdam Hornáček <scope>test</scope> 1230170aac5SAdam Hornáček </dependency> 1241a2bb6b6SAdam Hornáček <dependency> <!-- TODO: remove! (moving Messages to web module) --> 1254ce4e2b9SAdam Hornáček <groupId>org.awaitility</groupId> 1264ce4e2b9SAdam Hornáček <artifactId>awaitility</artifactId> 1274ce4e2b9SAdam Hornáček <version>3.1.0</version> 1284ce4e2b9SAdam Hornáček <scope>test</scope> 1294ce4e2b9SAdam Hornáček </dependency> 130*911e8af0SAdam Hornáček <dependency> 131*911e8af0SAdam Hornáček <groupId>org.glassfish.jersey.test-framework.providers</groupId> 132*911e8af0SAdam Hornáček <artifactId>jersey-test-framework-provider-grizzly2</artifactId> 133*911e8af0SAdam Hornáček <version>${jersey.version}</version> 134*911e8af0SAdam Hornáček <scope>test</scope> 135*911e8af0SAdam Hornáček </dependency> 136*911e8af0SAdam Hornáček <dependency> 137*911e8af0SAdam Hornáček <groupId>org.mockito</groupId> 138*911e8af0SAdam Hornáček <artifactId>mockito-core</artifactId> 139*911e8af0SAdam Hornáček <version>2.19.0</version> 140*911e8af0SAdam Hornáček <scope>test</scope> 141*911e8af0SAdam Hornáček </dependency> 1420170aac5SAdam Hornáček </dependencies> 1430170aac5SAdam Hornáček 14408a0c20eSJorgen Austvik <build> 145aa4907e2SLubos Kosco 14608a0c20eSJorgen Austvik <plugins> 147e0f7ec00SKnut Anders Hatlen 148e0f7ec00SKnut Anders Hatlen <plugin> 149e0f7ec00SKnut Anders Hatlen <groupId>org.apache.maven.plugins</groupId> 150e0f7ec00SKnut Anders Hatlen <artifactId>maven-jar-plugin</artifactId> 1519f619df4SLubos Kosco <version>3.0.2</version> 152e0f7ec00SKnut Anders Hatlen <configuration> 153e0f7ec00SKnut Anders Hatlen <archive> 154e0f7ec00SKnut Anders Hatlen <manifest> 155686556f2SAdam Hornáček <mainClass>org.opengrok.indexer.index.Indexer</mainClass> 156e0f7ec00SKnut Anders Hatlen <addClasspath>true</addClasspath> 157e0f7ec00SKnut Anders Hatlen <classpathPrefix>lib/</classpathPrefix> 158e0f7ec00SKnut Anders Hatlen </manifest> 159e0f7ec00SKnut Anders Hatlen <manifestEntries> 160e0f7ec00SKnut Anders Hatlen </manifestEntries> 161e0f7ec00SKnut Anders Hatlen </archive> 162e0f7ec00SKnut Anders Hatlen </configuration> 1631a2bb6b6SAdam Hornáček <executions> <!-- so the web module can use test classes from indexer module --> 1641a2bb6b6SAdam Hornáček <execution> 1651a2bb6b6SAdam Hornáček <goals> 1661a2bb6b6SAdam Hornáček <goal>test-jar</goal> 1671a2bb6b6SAdam Hornáček </goals> 1681a2bb6b6SAdam Hornáček </execution> 1691a2bb6b6SAdam Hornáček </executions> 170e0f7ec00SKnut Anders Hatlen </plugin> 171e0f7ec00SKnut Anders Hatlen 17208a0c20eSJorgen Austvik <plugin> 17308a0c20eSJorgen Austvik <groupId>de.jflex</groupId> 17445ec3841SLubos Kosco <artifactId>jflex-maven-plugin</artifactId> 1754e6518cbSLubos Kosco <version>1.6.1</version> 17608a0c20eSJorgen Austvik <executions> 17708a0c20eSJorgen Austvik <execution> 17808a0c20eSJorgen Austvik <goals> 17908a0c20eSJorgen Austvik <goal>generate</goal> 18008a0c20eSJorgen Austvik </goals> 18108a0c20eSJorgen Austvik <configuration> 18208a0c20eSJorgen Austvik <lexDefinitions> 18358f88ff1SChris Fraire <lexDefinition>${basedir}/target/jflex-sources</lexDefinition> 18408a0c20eSJorgen Austvik </lexDefinitions> 18545ec3841SLubos Kosco <inputStreamCtor>false</inputStreamCtor> 18608a0c20eSJorgen Austvik </configuration> 18708a0c20eSJorgen Austvik </execution> 18808a0c20eSJorgen Austvik </executions> 18908a0c20eSJorgen Austvik </plugin> 1909182cd30SLubos Kosco 191eeb7e5b3SAdam Hornáček <!-- patches jflex generated files to stop increasing buffer beyond token size that lucene accepts 192ff70ede8SLubos Kosco https://github.com/OpenGrok/OpenGrok/issues/1170 make parsers stop producing tokens > 32766 chars 193ba14bbd8SLubos Kosco at least for PlainFullTokenizer, PlainSymbolTokenizer, JavaScriptSymbolTokenizer, JavaSymbolTokenizer 1949182cd30SLubos Kosco use below 1959182cd30SLubos Kosco --> 1969182cd30SLubos Kosco 197ff70ede8SLubos Kosco <plugin> 198ff70ede8SLubos Kosco <groupId>com.google.code.maven-replacer-plugin</groupId> 199ff70ede8SLubos Kosco <artifactId>replacer</artifactId> 2009182cd30SLubos Kosco <version>1.5.3</version> 201ff70ede8SLubos Kosco <executions> 202ff70ede8SLubos Kosco <execution> 2039182cd30SLubos Kosco <phase>generate-sources</phase> 204ff70ede8SLubos Kosco <goals> 205ff70ede8SLubos Kosco <goal>replace</goal> 206ff70ede8SLubos Kosco </goals> 207ff70ede8SLubos Kosco </execution> 208ff70ede8SLubos Kosco </executions> 209ff70ede8SLubos Kosco <configuration> 2109182cd30SLubos Kosco <filesToInclude> 2119805b761SAdam Hornáček ${basedir}/target/generated-sources/jflex/org/opengrok/indexer/analysis/java/JavaSymbolTokenizer.java,${basedir}/target/generated-sources/jflex/org/opengrok/indexer/analysis/javascript/JavaScriptSymbolTokenizer.java,${basedir}/target/generated-sources/jflex/org/opengrok/indexer/analysis/plain/PlainFullTokenizer.java,${basedir}/target/generated-sources/jflex/org/opengrok/indexer/analysis/plain/PlainSymbolTokenizer.java 2129182cd30SLubos Kosco </filesToInclude> 2139182cd30SLubos Kosco <replacements> 2149182cd30SLubos Kosco <replacement> 2159182cd30SLubos Kosco <token>private static final int ZZ_BUFFERSIZE =</token> 2169182cd30SLubos Kosco <value>private int ZZ_BUFFERSIZE =</value> 2179182cd30SLubos Kosco </replacement> 2189182cd30SLubos Kosco <replacement> 2199182cd30SLubos Kosco <token>int requested = zzBuffer\.length - zzEndRead;</token> 2209182cd30SLubos Kosco <value>int requested = zzBuffer.length - zzEndRead - zzFinalHighSurrogate;</value> 2219182cd30SLubos Kosco </replacement> 2229182cd30SLubos Kosco <replacement> 2239182cd30SLubos Kosco <token>(zzFinalHighSurrogate = 1;)(\r?\n)</token> 2249182cd30SLubos Kosco <value>$1$2 if (numRead == 1) { return true; }$2</value> 2259182cd30SLubos Kosco </replacement> 2269182cd30SLubos Kosco 2279182cd30SLubos Kosco <replacement> 2289182cd30SLubos Kosco <token>[ \t]*/\* is the buffer big enough\? \*/\s+if \(zzCurrentPos >= zzBuffer\.length.*?\}[ \t]*\r?\n</token> 2299182cd30SLubos Kosco <value></value> 2309182cd30SLubos Kosco </replacement> 2319182cd30SLubos Kosco <!-- also revert 0 character check that got in with 1.6.1 : https://github.com/jflex-de/jflex/blob/master/jflex/examples/zero-reader/README.md --> 2329182cd30SLubos Kosco <replacement> 2339182cd30SLubos Kosco <token>[ \t]*/\* not supposed to occur according to specification of java\.io\.Reader \*/\s+if \(numRead == 0.*?\}[ \t]*\r?\n</token> 2349182cd30SLubos Kosco <value></value> 2359182cd30SLubos Kosco </replacement> 2369182cd30SLubos Kosco 2379182cd30SLubos Kosco </replacements> 238ff70ede8SLubos Kosco <regexFlags> 2399182cd30SLubos Kosco <regexFlag>DOTALL</regexFlag> 240ff70ede8SLubos Kosco </regexFlags> 241ff70ede8SLubos Kosco </configuration> 2429182cd30SLubos Kosco </plugin> 2432e3d7e6eSJorgen Austvik 2442e3d7e6eSJorgen Austvik <plugin> 24545ec3841SLubos Kosco <groupId>org.apache.maven.plugins</groupId> 2462e3d7e6eSJorgen Austvik <artifactId>maven-antrun-plugin</artifactId> 2479f619df4SLubos Kosco <version>1.8</version> 2482e3d7e6eSJorgen Austvik <executions> 2492e3d7e6eSJorgen Austvik <execution> 25058f88ff1SChris Fraire <id>collect-lex-lexh</id> 25158f88ff1SChris Fraire <phase>initialize</phase> 25258f88ff1SChris Fraire <configuration> 25358f88ff1SChris Fraire <target> 254eeb7e5b3SAdam Hornáček <property name="src.dir" value="src/main/resources"/> 25558f88ff1SChris Fraire <property name="tgt.dir" value="${basedir}/target/jflex-sources"/> 25658f88ff1SChris Fraire <ant target="-collect-lex-lexh"/> 25758f88ff1SChris Fraire </target> 25858f88ff1SChris Fraire </configuration> 25958f88ff1SChris Fraire <goals> 26058f88ff1SChris Fraire <goal>run</goal> 26158f88ff1SChris Fraire </goals> 26258f88ff1SChris Fraire </execution> 26358f88ff1SChris Fraire <execution> 26458f88ff1SChris Fraire <id>update-build-info</id> 26518446c8aSKnut Anders Hatlen <phase>generate-resources</phase> 26618446c8aSKnut Anders Hatlen <configuration> 26718446c8aSKnut Anders Hatlen <target> 26845ec3841SLubos Kosco <property name="version" value="${project.version}"/> 26918446c8aSKnut Anders Hatlen <ant target="-update-build-info"/> 27018446c8aSKnut Anders Hatlen </target> 27118446c8aSKnut Anders Hatlen </configuration> 27218446c8aSKnut Anders Hatlen <goals> 27318446c8aSKnut Anders Hatlen <goal>run</goal> 27418446c8aSKnut Anders Hatlen </goals> 27518446c8aSKnut Anders Hatlen </execution> 27618446c8aSKnut Anders Hatlen <execution> 2772e3d7e6eSJorgen Austvik <id>build-config-files</id> 2782e3d7e6eSJorgen Austvik <phase>process-test-classes</phase> 2792e3d7e6eSJorgen Austvik <goals> 2802e3d7e6eSJorgen Austvik <goal>run</goal> 2812e3d7e6eSJorgen Austvik </goals> 2822e3d7e6eSJorgen Austvik <configuration> 28318446c8aSKnut Anders Hatlen <target unless="maven.test.skip"> 28418446c8aSKnut Anders Hatlen <ant target="-post-compile-test"/> 28518446c8aSKnut Anders Hatlen </target> 2862e3d7e6eSJorgen Austvik </configuration> 2872e3d7e6eSJorgen Austvik </execution> 2882e3d7e6eSJorgen Austvik </executions> 2892e3d7e6eSJorgen Austvik </plugin> 2902e3d7e6eSJorgen Austvik 291aa4907e2SLubos Kosco <plugin> 292aa4907e2SLubos Kosco <groupId>org.apache.maven.plugins</groupId> 293aa4907e2SLubos Kosco <artifactId>maven-surefire-plugin</artifactId> 294aa4907e2SLubos Kosco <configuration> 295aa4907e2SLubos Kosco <excludes> 296aa4907e2SLubos Kosco <!-- Test helper class with name that confuses surefire --> 297aa4907e2SLubos Kosco <exclude>**/TestRepository.java</exclude> 298aa4907e2SLubos Kosco </excludes> 29934684d40SVladimir Kotal <argLine>${surefireArgLine}</argLine> 300aa4907e2SLubos Kosco </configuration> 301aa4907e2SLubos Kosco </plugin> 302aa4907e2SLubos Kosco 303bc6c8375SVladimir Kotal <plugin> 304bc6c8375SVladimir Kotal <groupId>org.codehaus.mojo</groupId> 305bc6c8375SVladimir Kotal <artifactId>exec-maven-plugin</artifactId> 306bc6c8375SVladimir Kotal <version>1.6.0</version> 307bc6c8375SVladimir Kotal <executions> 308bc6c8375SVladimir Kotal <execution> 309bc6c8375SVladimir Kotal <phase>verify</phase> 310bc6c8375SVladimir Kotal <goals> 311bc6c8375SVladimir Kotal <goal>exec</goal> 312bc6c8375SVladimir Kotal </goals> 313bc6c8375SVladimir Kotal </execution> 314bc6c8375SVladimir Kotal </executions> 315bc6c8375SVladimir Kotal <configuration> 316bc6c8375SVladimir Kotal <executable>pep8</executable> 317bc6c8375SVladimir Kotal <arguments> 318bc6c8375SVladimir Kotal <argument>-v</argument> 319873a5de8SVladimir Kotal <argument>--exclude=filelock.py,test_command.py,test_commands.py</argument> 320bc6c8375SVladimir Kotal <argument>${project.basedir}/../tools/sync</argument> 321bc6c8375SVladimir Kotal </arguments> 322bc6c8375SVladimir Kotal </configuration> 323bc6c8375SVladimir Kotal </plugin> 324aa4907e2SLubos Kosco 32508a0c20eSJorgen Austvik </plugins> 32608a0c20eSJorgen Austvik </build> 32708a0c20eSJorgen Austvik 328d47db168SAdam Hornáček <profiles> 329d47db168SAdam Hornáček <profile> 330d47db168SAdam Hornáček <id>java9plus</id> 331d47db168SAdam Hornáček <activation> 332d47db168SAdam Hornáček <jdk>[9,10]</jdk> 333d47db168SAdam Hornáček </activation> 334d47db168SAdam Hornáček <build> 335d47db168SAdam Hornáček <plugins> 336d47db168SAdam Hornáček <plugin> 337d47db168SAdam Hornáček <groupId>org.apache.maven.plugins</groupId> 338d47db168SAdam Hornáček <artifactId>maven-surefire-plugin</artifactId> 339d47db168SAdam Hornáček <configuration> 340d47db168SAdam Hornáček <argLine> 341d47db168SAdam Hornáček --add-exports java.base/jdk.internal.ref=ALL-UNNAMED 342d47db168SAdam Hornáček --add-exports java.base/jdk.internal.misc=ALL-UNNAMED 343d47db168SAdam Hornáček --add-exports java.base/sun.nio.ch=ALL-UNNAMED 344d47db168SAdam Hornáček </argLine> 345d47db168SAdam Hornáček </configuration> 346d47db168SAdam Hornáček </plugin> 347d47db168SAdam Hornáček </plugins> 348d47db168SAdam Hornáček </build> 349d47db168SAdam Hornáček </profile> 350d47db168SAdam Hornáček </profiles> 351d47db168SAdam Hornáček 35208a0c20eSJorgen Austvik</project> 353