release candidate

This commit is contained in:
mimic
2019-09-06 18:41:04 +02:00
parent c9a54fb0e7
commit d0a632bfb0
108 changed files with 804 additions and 6178 deletions
-14
View File
@@ -6,22 +6,8 @@
<sourceOutputDir name="target/generated-sources/annotations" />
<sourceTestOutputDir name="target/generated-test-sources/test-annotations" />
<outputRelativeToContentRoot value="true" />
<module name="client" />
<module name="client.diff" />
<module name="core" />
<module name="FixPatternMiner" />
<module name="gen.jdt" />
<module name="simple-utils" />
</profile>
</annotationProcessing>
<bytecodeTargetLevel>
<module name="client" target="1.8" />
<module name="client.diff" target="1.8" />
<module name="core" target="1.8" />
<module name="FixPatternMiner" target="1.8" />
<module name="gen.jdt" target="1.8" />
<module name="gumtree" target="1.8" />
<module name="simple-utils" target="1.8" />
</bytecodeTargetLevel>
</component>
</project>
-6
View File
@@ -2,11 +2,5 @@
<project version="4">
<component name="Encoding" addBOMForNewFiles="with NO BOM">
<file url="file://$PROJECT_DIR$" charset="UTF-8" />
<file url="file://$PROJECT_DIR$/../gumtree" charset="UTF-8" />
<file url="file://$PROJECT_DIR$/../gumtree/client" charset="UTF-8" />
<file url="file://$PROJECT_DIR$/../gumtree/client.diff" charset="UTF-8" />
<file url="file://$PROJECT_DIR$/../gumtree/core" charset="UTF-8" />
<file url="file://$PROJECT_DIR$/../gumtree/gen.jdt" charset="UTF-8" />
<file url="file://$PROJECT_DIR$/../simple-utils" charset="UTF-8" />
</component>
</project>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: ch.qos.logback:logback-classic:1.1.2">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.1.2/logback-classic-1.1.2.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.1.2/logback-classic-1.1.2-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.1.2/logback-classic-1.1.2-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: ch.qos.logback:logback-classic:1.1.7">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.1.7/logback-classic-1.1.7.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.1.7/logback-classic-1.1.7-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.1.7/logback-classic-1.1.7-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: ch.qos.logback:logback-classic:1.2.3">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.2.3/logback-classic-1.2.3.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.2.3/logback-classic-1.2.3-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.2.3/logback-classic-1.2.3-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: ch.qos.logback:logback-core:1.1.2">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.1.2/logback-core-1.1.2.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.1.2/logback-core-1.1.2-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.1.2/logback-core-1.1.2-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: ch.qos.logback:logback-core:1.1.7">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.1.7/logback-core-1.1.7.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.1.7/logback-core-1.1.7-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.1.7/logback-core-1.1.7-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: ch.qos.logback:logback-core:1.2.3">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.2.3/logback-core-1.2.3.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.2.3/logback-core-1.2.3-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.2.3/logback-core-1.2.3-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: com.github.mpkorstanje:simmetrics-core:3.0.3">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/com/github/mpkorstanje/simmetrics-core/3.0.3/simmetrics-core-3.0.3.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/com/github/mpkorstanje/simmetrics-core/3.0.3/simmetrics-core-3.0.3-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/com/github/mpkorstanje/simmetrics-core/3.0.3/simmetrics-core-3.0.3-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: com.google.code.findbugs:jsr305:1.3.9">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/com/google/code/findbugs/jsr305/1.3.9/jsr305-1.3.9.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/com/google/code/findbugs/jsr305/1.3.9/jsr305-1.3.9-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/com/google/code/findbugs/jsr305/1.3.9/jsr305-1.3.9-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: com.google.code.gson:gson:2.3">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/com/google/code/gson/gson/2.3/gson-2.3.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/com/google/code/gson/gson/2.3/gson-2.3-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/com/google/code/gson/gson/2.3/gson-2.3-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: com.google.guava:guava:11.0.2">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/com/google/guava/guava/11.0.2/guava-11.0.2.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/com/google/guava/guava/11.0.2/guava-11.0.2-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/com/google/guava/guava/11.0.2/guava-11.0.2-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: com.google.guava:guava:18.0">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/com/google/guava/guava/18.0/guava-18.0.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/com/google/guava/guava/18.0/guava-18.0-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/com/google/guava/guava/18.0/guava-18.0-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: com.nanohttpd:nanohttpd:2.1.1">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/com/nanohttpd/nanohttpd/2.1.1/nanohttpd-2.1.1.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/com/nanohttpd/nanohttpd/2.1.1/nanohttpd-2.1.1-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/com/nanohttpd/nanohttpd/2.1.1/nanohttpd-2.1.1-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: com.nanohttpd:nanohttpd-webserver:2.1.1">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/com/nanohttpd/nanohttpd-webserver/2.1.1/nanohttpd-webserver-2.1.1.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/com/nanohttpd/nanohttpd-webserver/2.1.1/nanohttpd-webserver-2.1.1-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/com/nanohttpd/nanohttpd-webserver/2.1.1/nanohttpd-webserver-2.1.1-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: com.rabbitmq:amqp-client:4.0.0">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/com/rabbitmq/amqp-client/4.0.0/amqp-client-4.0.0.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/com/rabbitmq/amqp-client/4.0.0/amqp-client-4.0.0-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/com/rabbitmq/amqp-client/4.0.0/amqp-client-4.0.0-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: com.sparkjava:spark-core:2.6.0">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/com/sparkjava/spark-core/2.6.0/spark-core-2.6.0.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/com/sparkjava/spark-core/2.6.0/spark-core-2.6.0-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/com/sparkjava/spark-core/2.6.0/spark-core-2.6.0-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: com.typesafe.akka:akka-actor_2.11:2.4.11">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/com/typesafe/akka/akka-actor_2.11/2.4.11/akka-actor_2.11-2.4.11.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/com/typesafe/akka/akka-actor_2.11/2.4.11/akka-actor_2.11-2.4.11-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/com/typesafe/akka/akka-actor_2.11/2.4.11/akka-actor_2.11-2.4.11-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: com.typesafe:config:1.3.0">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/com/typesafe/config/1.3.0/config-1.3.0.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/com/typesafe/config/1.3.0/config-1.3.0-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/com/typesafe/config/1.3.0/config-1.3.0-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: commons-codec:commons-codec:1.10">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/commons-codec/commons-codec/1.10/commons-codec-1.10.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/commons-codec/commons-codec/1.10/commons-codec-1.10-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/commons-codec/commons-codec/1.10/commons-codec-1.10-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: commons-codec:commons-codec:1.9">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/commons-codec/commons-codec/1.9/commons-codec-1.9.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/commons-codec/commons-codec/1.9/commons-codec-1.9-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/commons-codec/commons-codec/1.9/commons-codec-1.9-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: dom4j:dom4j:1.6.1">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/dom4j/dom4j/1.6.1/dom4j-1.6.1.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/dom4j/dom4j/1.6.1/dom4j-1.6.1-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/dom4j/dom4j/1.6.1/dom4j-1.6.1-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: javax.servlet:javax.servlet-api:3.1.0">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/javax/servlet/javax.servlet-api/3.1.0/javax.servlet-api-3.1.0.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/javax/servlet/javax.servlet-api/3.1.0/javax.servlet-api-3.1.0-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/javax/servlet/javax.servlet-api/3.1.0/javax.servlet-api-3.1.0-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: junit:junit:3.8.1">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/junit/junit/3.8.1/junit-3.8.1.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/junit/junit/3.8.1/junit-3.8.1-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/junit/junit/3.8.1/junit-3.8.1-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: junit:junit:4.11">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/junit/junit/4.11/junit-4.11.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/junit/junit/4.11/junit-4.11-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/junit/junit/4.11/junit-4.11-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: junit:junit:4.12">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/junit/junit/4.12/junit-4.12.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/junit/junit/4.12/junit-4.12-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/junit/junit/4.12/junit-4.12-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: log4j:log4j:1.2.14">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/log4j/log4j/1.2.14/log4j-1.2.14.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/log4j/log4j/1.2.14/log4j-1.2.14-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/log4j/log4j/1.2.14/log4j-1.2.14-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: net.sf.trove4j:trove4j:3.0.3">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/net/sf/trove4j/trove4j/3.0.3/trove4j-3.0.3.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/net/sf/trove4j/trove4j/3.0.3/trove4j-3.0.3-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/net/sf/trove4j/trove4j/3.0.3/trove4j-3.0.3-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: net.sourceforge.jexcelapi:jxl:2.6.12">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/net/sourceforge/jexcelapi/jxl/2.6.12/jxl-2.6.12.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/net/sourceforge/jexcelapi/jxl/2.6.12/jxl-2.6.12-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/net/sourceforge/jexcelapi/jxl/2.6.12/jxl-2.6.12-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.apache.commons:commons-lang3:3.1">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-lang3/3.1/commons-lang3-3.1.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-lang3/3.1/commons-lang3-3.1-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-lang3/3.1/commons-lang3-3.1-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.apache.commons:commons-lang3:3.7">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-lang3/3.7/commons-lang3-3.7.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-lang3/3.7/commons-lang3-3.7-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-lang3/3.7/commons-lang3-3.7-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.apache.commons:commons-pool2:2.4.2">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-pool2/2.4.2/commons-pool2-2.4.2.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-pool2/2.4.2/commons-pool2-2.4.2-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-pool2/2.4.2/commons-pool2-2.4.2-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.apache.commons:commons-text:1.3">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-text/1.3/commons-text-1.3.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-text/1.3/commons-text-1.3-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/commons/commons-text/1.3/commons-text-1.3-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.apache.poi:poi:3.12">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/poi/poi/3.12/poi-3.12.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/poi/poi/3.12/poi-3.12-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/poi/poi/3.12/poi-3.12-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.apache.poi:poi-ooxml:3.12">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/poi/poi-ooxml/3.12/poi-ooxml-3.12.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/poi/poi-ooxml/3.12/poi-ooxml-3.12-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/poi/poi-ooxml/3.12/poi-ooxml-3.12-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.apache.poi:poi-ooxml-schemas:3.12">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/poi/poi-ooxml-schemas/3.12/poi-ooxml-schemas-3.12.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/poi/poi-ooxml-schemas/3.12/poi-ooxml-schemas-3.12-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/poi/poi-ooxml-schemas/3.12/poi-ooxml-schemas-3.12-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.apache.xmlbeans:xmlbeans:2.6.0">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/xmlbeans/xmlbeans/2.6.0/xmlbeans-2.6.0.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/xmlbeans/xmlbeans/2.6.0/xmlbeans-2.6.0-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/apache/xmlbeans/xmlbeans/2.6.0/xmlbeans-2.6.0-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.birt.runtime:org.eclipse.core.resources:3.10.0.v20150423-0755">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/birt/runtime/org.eclipse.core.resources/3.10.0.v20150423-0755/org.eclipse.core.resources-3.10.0.v20150423-0755.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/birt/runtime/org.eclipse.core.resources/3.10.0.v20150423-0755/org.eclipse.core.resources-3.10.0.v20150423-0755-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/birt/runtime/org.eclipse.core.resources/3.10.0.v20150423-0755/org.eclipse.core.resources-3.10.0.v20150423-0755-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.core:contenttype:3.4.200-v20140207-1251">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/core/contenttype/3.4.200-v20140207-1251/contenttype-3.4.200-v20140207-1251.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/core/contenttype/3.4.200-v20140207-1251/contenttype-3.4.200-v20140207-1251-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/core/contenttype/3.4.200-v20140207-1251/contenttype-3.4.200-v20140207-1251-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.core:jobs:3.6.0-v20140424-0053">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/core/jobs/3.6.0-v20140424-0053/jobs-3.6.0-v20140424-0053.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/core/jobs/3.6.0-v20140424-0053/jobs-3.6.0-v20140424-0053-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/core/jobs/3.6.0-v20140424-0053/jobs-3.6.0-v20140424-0053-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.core:runtime:3.10.0-v20140318-2214">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/core/runtime/3.10.0-v20140318-2214/runtime-3.10.0-v20140318-2214.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/core/runtime/3.10.0-v20140318-2214/runtime-3.10.0-v20140318-2214-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/core/runtime/3.10.0-v20140318-2214/runtime-3.10.0-v20140318-2214-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.equinox:app:1.3.200-v20130910-1609">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/app/1.3.200-v20130910-1609/app-1.3.200-v20130910-1609.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/app/1.3.200-v20130910-1609/app-1.3.200-v20130910-1609-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/app/1.3.200-v20130910-1609/app-1.3.200-v20130910-1609-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.equinox:common:3.6.200-v20130402-1505">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/common/3.6.200-v20130402-1505/common-3.6.200-v20130402-1505.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/common/3.6.200-v20130402-1505/common-3.6.200-v20130402-1505-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/common/3.6.200-v20130402-1505/common-3.6.200-v20130402-1505-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.equinox:preferences:3.5.200-v20140224-1527">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/preferences/3.5.200-v20140224-1527/preferences-3.5.200-v20140224-1527.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/preferences/3.5.200-v20140224-1527/preferences-3.5.200-v20140224-1527-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/preferences/3.5.200-v20140224-1527/preferences-3.5.200-v20140224-1527-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.equinox:registry:3.5.400-v20140428-1507">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/registry/3.5.400-v20140428-1507/registry-3.5.400-v20140428-1507.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/registry/3.5.400-v20140428-1507/registry-3.5.400-v20140428-1507-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/equinox/registry/3.5.400-v20140428-1507/registry-3.5.400-v20140428-1507-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty:jetty-client:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-client/9.4.4.v20170414/jetty-client-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-client/9.4.4.v20170414/jetty-client-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-client/9.4.4.v20170414/jetty-client-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty:jetty-http:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-http/9.4.4.v20170414/jetty-http-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-http/9.4.4.v20170414/jetty-http-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-http/9.4.4.v20170414/jetty-http-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty:jetty-io:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-io/9.4.4.v20170414/jetty-io-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-io/9.4.4.v20170414/jetty-io-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-io/9.4.4.v20170414/jetty-io-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty:jetty-security:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-security/9.4.4.v20170414/jetty-security-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-security/9.4.4.v20170414/jetty-security-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-security/9.4.4.v20170414/jetty-security-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty:jetty-server:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-server/9.4.4.v20170414/jetty-server-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-server/9.4.4.v20170414/jetty-server-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-server/9.4.4.v20170414/jetty-server-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty:jetty-servlet:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-servlet/9.4.4.v20170414/jetty-servlet-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-servlet/9.4.4.v20170414/jetty-servlet-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-servlet/9.4.4.v20170414/jetty-servlet-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty:jetty-util:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-util/9.4.4.v20170414/jetty-util-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-util/9.4.4.v20170414/jetty-util-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-util/9.4.4.v20170414/jetty-util-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty:jetty-webapp:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-webapp/9.4.4.v20170414/jetty-webapp-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-webapp/9.4.4.v20170414/jetty-webapp-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-webapp/9.4.4.v20170414/jetty-webapp-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty:jetty-xml:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-xml/9.4.4.v20170414/jetty-xml-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-xml/9.4.4.v20170414/jetty-xml-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/jetty-xml/9.4.4.v20170414/jetty-xml-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty.websocket:websocket-api:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-api/9.4.4.v20170414/websocket-api-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-api/9.4.4.v20170414/websocket-api-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-api/9.4.4.v20170414/websocket-api-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty.websocket:websocket-client:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-client/9.4.4.v20170414/websocket-client-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-client/9.4.4.v20170414/websocket-client-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-client/9.4.4.v20170414/websocket-client-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty.websocket:websocket-common:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-common/9.4.4.v20170414/websocket-common-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-common/9.4.4.v20170414/websocket-common-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-common/9.4.4.v20170414/websocket-common-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty.websocket:websocket-server:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-server/9.4.4.v20170414/websocket-server-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-server/9.4.4.v20170414/websocket-server-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-server/9.4.4.v20170414/websocket-server-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.jetty.websocket:websocket-servlet:9.4.4.v20170414">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-servlet/9.4.4.v20170414/websocket-servlet-9.4.4.v20170414.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-servlet/9.4.4.v20170414/websocket-servlet-9.4.4.v20170414-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/jetty/websocket/websocket-servlet/9.4.4.v20170414/websocket-servlet-9.4.4.v20170414-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse:osgi:3.10.0-v20140606-1445">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/osgi/3.10.0-v20140606-1445/osgi-3.10.0-v20140606-1445.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/osgi/3.10.0-v20140606-1445/osgi-3.10.0-v20140606-1445-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/osgi/3.10.0-v20140606-1445/osgi-3.10.0-v20140606-1445-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.eclipse.tycho:org.eclipse.jdt.core:3.12.2.v20161117-1814">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/tycho/org.eclipse.jdt.core/3.12.2.v20161117-1814/org.eclipse.jdt.core-3.12.2.v20161117-1814.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/tycho/org.eclipse.jdt.core/3.12.2.v20161117-1814/org.eclipse.jdt.core-3.12.2.v20161117-1814-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/eclipse/tycho/org.eclipse.jdt.core/3.12.2.v20161117-1814/org.eclipse.jdt.core-3.12.2.v20161117-1814-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.hamcrest:hamcrest-core:1.3">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/hamcrest/hamcrest-core/1.3/hamcrest-core-1.3.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/hamcrest/hamcrest-core/1.3/hamcrest-core-1.3-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/hamcrest/hamcrest-core/1.3/hamcrest-core-1.3-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.javassist:javassist:3.16.1-GA">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/javassist/javassist/3.16.1-GA/javassist-3.16.1-GA.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/javassist/javassist/3.16.1-GA/javassist-3.16.1-GA-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/javassist/javassist/3.16.1-GA/javassist-3.16.1-GA-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.javatuples:javatuples:1.2">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/javatuples/javatuples/1.2/javatuples-1.2.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/javatuples/javatuples/1.2/javatuples-1.2-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/javatuples/javatuples/1.2/javatuples-1.2-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.reflections:reflections:0.9.9-RC1">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/reflections/reflections/0.9.9-RC1/reflections-0.9.9-RC1.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/reflections/reflections/0.9.9-RC1/reflections-0.9.9-RC1-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/reflections/reflections/0.9.9-RC1/reflections-0.9.9-RC1-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.rendersnake:rendersnake:1.8">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/rendersnake/rendersnake/1.8/rendersnake-1.8.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/rendersnake/rendersnake/1.8/rendersnake-1.8-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/rendersnake/rendersnake/1.8/rendersnake-1.8-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.scala-lang.modules:scala-java8-compat_2.11:0.7.0">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/scala-lang/modules/scala-java8-compat_2.11/0.7.0/scala-java8-compat_2.11-0.7.0.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/scala-lang/modules/scala-java8-compat_2.11/0.7.0/scala-java8-compat_2.11-0.7.0-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/scala-lang/modules/scala-java8-compat_2.11/0.7.0/scala-java8-compat_2.11-0.7.0-sources.jar!/" />
</SOURCES>
</library>
</component>
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.scala-lang:scala-library:2.11.8">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/scala-lang/scala-library/2.11.8/scala-library-2.11.8.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/scala-lang/scala-library/2.11.8/scala-library-2.11.8-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/scala-lang/scala-library/2.11.8/scala-library-2.11.8-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.slf4j:slf4j-api:1.7.13">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.13/slf4j-api-1.7.13.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.13/slf4j-api-1.7.13-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.13/slf4j-api-1.7.13-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.slf4j:slf4j-api:1.7.21">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.21/slf4j-api-1.7.21.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.21/slf4j-api-1.7.21-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.21/slf4j-api-1.7.21-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.slf4j:slf4j-api:1.7.25">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.25/slf4j-api-1.7.25.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.25/slf4j-api-1.7.25-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.25/slf4j-api-1.7.25-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: org.slf4j:slf4j-api:1.7.7">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.7/slf4j-api-1.7.7.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.7/slf4j-api-1.7.7-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.7/slf4j-api-1.7.7-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: redis.clients:jedis:2.8.1">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/redis/clients/jedis/2.8.1/jedis-2.8.1.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/redis/clients/jedis/2.8.1/jedis-2.8.1-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/redis/clients/jedis/2.8.1/jedis-2.8.1-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: stax:stax-api:1.0.1">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/stax/stax-api/1.0.1/stax-api-1.0.1.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/stax/stax-api/1.0.1/stax-api-1.0.1-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/stax/stax-api/1.0.1/stax-api-1.0.1-sources.jar!/" />
</SOURCES>
</library>
</component>
-13
View File
@@ -1,13 +0,0 @@
<component name="libraryTable">
<library name="Maven: xml-apis:xml-apis:1.0.b2">
<CLASSES>
<root url="jar://$MAVEN_REPOSITORY$/xml-apis/xml-apis/1.0.b2/xml-apis-1.0.b2.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://$MAVEN_REPOSITORY$/xml-apis/xml-apis/1.0.b2/xml-apis-1.0.b2-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://$MAVEN_REPOSITORY$/xml-apis/xml-apis/1.0.b2/xml-apis-1.0.b2-sources.jar!/" />
</SOURCES>
</library>
</component>
+2 -3
View File
@@ -1,15 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ExternalStorageConfigurationManager" enabled="true" />
<component name="MavenProjectsManager">
<option name="originalFiles">
<list>
<option value="$PROJECT_DIR$/pom.xml" />
<option value="$PROJECT_DIR$/../gumtree/pom.xml" />
<option value="$PROJECT_DIR$/../simple-utils/pom.xml" />
</list>
</option>
</component>
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/classes" />
<output url="file://$PROJECT_DIR$/out" />
</component>
</project>
-14
View File
@@ -1,14 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/FixPatternMiner.iml" filepath="$PROJECT_DIR$/FixPatternMiner.iml" />
<module fileurl="file://$PROJECT_DIR$/../gumtree/client/client.iml" filepath="$PROJECT_DIR$/../gumtree/client/client.iml" />
<module fileurl="file://$PROJECT_DIR$/../gumtree/client.diff/client.diff.iml" filepath="$PROJECT_DIR$/../gumtree/client.diff/client.diff.iml" />
<module fileurl="file://$PROJECT_DIR$/../gumtree/core/core.iml" filepath="$PROJECT_DIR$/../gumtree/core/core.iml" />
<module fileurl="file://$PROJECT_DIR$/../gumtree/gen.jdt/gen.jdt.iml" filepath="$PROJECT_DIR$/../gumtree/gen.jdt/gen.jdt.iml" />
<module fileurl="file://$PROJECT_DIR$/../gumtree/gumtree.iml" filepath="$PROJECT_DIR$/../gumtree/gumtree.iml" />
<module fileurl="file://$PROJECT_DIR$/../simple-utils/simple-utils.iml" filepath="$PROJECT_DIR$/../simple-utils/simple-utils.iml" />
</modules>
</component>
</project>
Generated
-2
View File
@@ -2,7 +2,5 @@
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" />
<mapping directory="$PROJECT_DIR$/../gumtree" vcs="Git" />
<mapping directory="$PROJECT_DIR$/../simple-utils" vcs="Git" />
</component>
</project>
+483 -1083
View File
File diff suppressed because it is too large Load Diff
-61
View File
@@ -1,61 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<module org.jetbrains.idea.maven.project.MavenProjectsManager.isMavenModule="true" type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_8">
<output url="file://$MODULE_DIR$/target/classes" />
<output-test url="file://$MODULE_DIR$/target/test-classes" />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/test/java" isTestSource="true" />
<excludeFolder url="file://$MODULE_DIR$/target" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" name="Maven: edu.lu.uni:simple-utils:0.0.1-SNAPSHOT" level="project" />
<orderEntry type="library" name="Maven: org.javatuples:javatuples:1.2" level="project" />
<orderEntry type="module" module-name="simple-utils" />
<orderEntry type="library" name="Maven: org.apache.poi:poi:3.12" level="project" />
<orderEntry type="library" name="Maven: commons-codec:commons-codec:1.9" level="project" />
<orderEntry type="library" name="Maven: org.apache.poi:poi-ooxml:3.12" level="project" />
<orderEntry type="library" name="Maven: org.apache.poi:poi-ooxml-schemas:3.12" level="project" />
<orderEntry type="library" name="Maven: org.apache.xmlbeans:xmlbeans:2.6.0" level="project" />
<orderEntry type="library" name="Maven: stax:stax-api:1.0.1" level="project" />
<orderEntry type="library" name="Maven: net.sourceforge.jexcelapi:jxl:2.6.12" level="project" />
<orderEntry type="library" name="Maven: log4j:log4j:1.2.14" level="project" />
<orderEntry type="library" name="Maven: com.typesafe.akka:akka-actor_2.11:2.4.11" level="project" />
<orderEntry type="library" name="Maven: org.scala-lang:scala-library:2.11.8" level="project" />
<orderEntry type="library" name="Maven: com.typesafe:config:1.3.0" level="project" />
<orderEntry type="library" name="Maven: org.scala-lang.modules:scala-java8-compat_2.11:0.7.0" level="project" />
<orderEntry type="module" module-name="core" />
<orderEntry type="library" name="Maven: com.github.mpkorstanje:simmetrics-core:3.0.3" level="project" />
<orderEntry type="library" name="Maven: com.google.guava:guava:18.0" level="project" />
<orderEntry type="library" name="Maven: net.sf.trove4j:trove4j:3.0.3" level="project" />
<orderEntry type="library" name="Maven: com.google.code.gson:gson:2.3" level="project" />
<orderEntry type="module" module-name="gen.jdt" />
<orderEntry type="library" name="Maven: org.eclipse.core:runtime:3.10.0-v20140318-2214" level="project" />
<orderEntry type="library" name="Maven: org.eclipse:osgi:3.10.0-v20140606-1445" level="project" />
<orderEntry type="library" name="Maven: org.eclipse.equinox:common:3.6.200-v20130402-1505" level="project" />
<orderEntry type="library" name="Maven: org.eclipse.core:jobs:3.6.0-v20140424-0053" level="project" />
<orderEntry type="library" name="Maven: org.eclipse.equinox:registry:3.5.400-v20140428-1507" level="project" />
<orderEntry type="library" name="Maven: org.eclipse.equinox:preferences:3.5.200-v20140224-1527" level="project" />
<orderEntry type="library" name="Maven: org.eclipse.core:contenttype:3.4.200-v20140207-1251" level="project" />
<orderEntry type="library" name="Maven: org.eclipse.equinox:app:1.3.200-v20130910-1609" level="project" />
<orderEntry type="library" name="Maven: org.eclipse.birt.runtime:org.eclipse.core.resources:3.10.0.v20150423-0755" level="project" />
<orderEntry type="library" name="Maven: org.eclipse.tycho:org.eclipse.jdt.core:3.12.2.v20161117-1814" level="project" />
<orderEntry type="library" name="Maven: org.slf4j:slf4j-api:1.7.7" level="project" />
<orderEntry type="library" name="Maven: ch.qos.logback:logback-classic:1.1.2" level="project" />
<orderEntry type="library" name="Maven: ch.qos.logback:logback-core:1.1.2" level="project" />
<orderEntry type="library" name="Maven: junit:junit:4.11" level="project" />
<orderEntry type="library" name="Maven: org.hamcrest:hamcrest-core:1.3" level="project" />
<orderEntry type="library" name="Maven: redis.clients:jedis:2.8.1" level="project" />
<orderEntry type="library" name="Maven: org.apache.commons:commons-pool2:2.4.2" level="project" />
<orderEntry type="library" name="Maven: org.apache.commons:commons-text:1.3" level="project" />
<orderEntry type="library" name="Maven: org.apache.commons:commons-lang3:3.7" level="project" />
<orderEntry type="library" name="Maven: com.rabbitmq:amqp-client:4.0.0" level="project" />
<orderEntry type="library" name="Maven: org.apache.lucene:lucene-core:4.8.0" level="project" />
<orderEntry type="library" name="Maven: org.apache.lucene:lucene-analyzers-common:4.8.0" level="project" />
<orderEntry type="library" name="Maven: org.apache.commons:commons-math3:3.6.1" level="project" />
<orderEntry type="library" name="Maven: com.thoughtworks.xstream:xstream:1.3.1" level="project" />
<orderEntry type="library" name="Maven: xpp3:xpp3_min:1.1.4c" level="project" />
<orderEntry type="library" name="Maven: commons-io:commons-io:2.4" level="project" />
</component>
</module>
+14 -7
View File
@@ -4,7 +4,7 @@
<groupId>edu.lu.uni.serval</groupId>
<artifactId>FixPatternMiner</artifactId>
<version>0.0.1-SNAPSHOT</version>
<version>1.0.0</version>
<packaging>jar</packaging>
<name>FixPatternMiner</name>
@@ -25,11 +25,11 @@
<version>1.2</version>
</dependency>
<dependency>
<groupId>edu.lu.uni</groupId>
<artifactId>simple-utils</artifactId>
<version>0.0.1-SNAPSHOT</version>
</dependency>
<!--<dependency>-->
<!--<groupId>edu.lu.uni</groupId>-->
<!--<artifactId>simple-utils</artifactId>-->
<!--<version>0.0.1-SNAPSHOT</version>-->
<!--</dependency>-->
<!-- akka -->
<dependency>
@@ -150,6 +150,12 @@
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.esotericsoftware</groupId>
<artifactId>kryo</artifactId>
<version>4.0.2</version>
</dependency>
</dependencies>
@@ -178,7 +184,8 @@
<archive>
<manifest>
<mainClass>
edu.lu.uni.serval.fixminer.akka.compare.CompareTrees
<!--edu.lu.uni.serval.fixminer.akka.compare.CompareTrees-->
edu.lu.uni.serval.fixminer.Launcher
</mainClass>
</manifest>
</archive>
@@ -1,7 +1,8 @@
package edu.lu.uni.serval.fixminer;
import edu.lu.uni.serval.fixminer.jobs.*;
import edu.lu.uni.serval.utils.CallShell;
import edu.lu.uni.serval.fixminer.akka.compare.CompareTrees;
import edu.lu.uni.serval.fixminer.jobs.EnhancedASTDiff;
import edu.lu.uni.serval.utils.ClusterToPattern;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -21,157 +22,94 @@ public class Launcher {
Properties appProps = new Properties();
// String appConfigPath = "/Users/kui.liu/Downloads/app.properties";//args[0];
// String appConfigPath = "/Users/anilkoyuncu/bugStudy/release/code/app.properties";
String appConfigPath = args[0];
appProps.load(new FileInputStream(appConfigPath));
String portInner = appProps.getProperty("portInner","6380");
String numOfWorkers = appProps.getProperty("numOfWorkers", "10");
String jobType = appProps.getProperty("jobType","ALL");
String portDumps = appProps.getProperty("portDumps","6399");
String pythonPath = appProps.getProperty("pythonPath","/Users/anilkoyuncu/bugStudy/code/python");
String datasetPath = appProps.getProperty("datasetPath","/Users/anilkoyuncu/bugStudy/dataset");
String pjName = appProps.getProperty("pjName","allDataset");
String actionType = appProps.getProperty("actionType","ALL");
String threshold = appProps.getProperty("threshold","1");
String cursor = appProps.getProperty("cursor","10000000");
String chunk = appProps.getProperty("chunk","1.txt");
String eDiffTimeout = appProps.getProperty("eDiffTimeout","900");
String isBig = appProps.getProperty("isBigPair","true");
String parallelism = appProps.getProperty("parallelism","FORKJOIN");
boolean isBigPair = Boolean.parseBoolean(isBig);
String input = appProps.getProperty("inputPath","FORKJOIN");
String redisPath = appProps.getProperty("redisPath","FORKJOIN");
String parameters = String.format("\nportInner %s " +
"\nnumOfWorkers %s " +
"\njobType %s \nport %s " +
"\npythonPath %s \ndatasetPath %s" +
"\npjName %s \nactionType %s \nthreshold %s \ncursor %s \neDiffTimeout %s \nisBigPair %s \nparallelism %s"
, portInner, numOfWorkers, jobType, portDumps, pythonPath,datasetPath,pjName,actionType,threshold,cursor,eDiffTimeout,isBig,parallelism);
String parameter = args[2];
String jobType = args[1];
log.info(parameters);
// String parameters = String.format("\nportInner %s " +
// "\nnumOfWorkers %s " +
// "\njobType %s \nport %s " +
// "\npythonPath %s \ndatasetPath %s" +
// "\npjName %s \nactionType %s \nthreshold %s \ncursor %s \neDiffTimeout %s \nisBigPair %s \nparallelism %s"
// , portInner, numOfWorkers, jobType, portDumps, pythonPath,datasetPath,pjName,actionType,threshold,cursor,eDiffTimeout,isBig,parallelism);
//
// log.info(parameters);
mainLaunch(portInner, numOfWorkers, jobType, portDumps, pythonPath,datasetPath,pjName,actionType,threshold,cursor,chunk,eDiffTimeout,isBigPair,parallelism);
mainLaunch(portInner, numOfWorkers, jobType, portDumps, pjName,actionType,eDiffTimeout,parallelism,input,redisPath,parameter);
}
public static void mainLaunch(String portInner, String numOfWorkers, String jobType, String portDumps, String pythonPath, String datasetPath, String pjName, String actionType, String threshold, String cursor, String chunk, String eDiffTimeout, boolean isBigPair, String parallelism){
public static void mainLaunch(String portInner, String numOfWorkers, String jobType, String portDumps, String pjName, String actionType, String eDiffTimeout, String parallelism,String input, String redisPath,String parameter){
String dbDir;
String pairsPath;
String dumpsName;
String gumInput;
String gumOutput;
gumInput = datasetPath +"/"+pjName+"/";
gumOutput = datasetPath + "/EnhancedASTDiff" + pjName;
dbDir = datasetPath + "/redis";
pairsPath = datasetPath + "/pairs";
dumpsName = "dumps-"+pjName+".rdb";
int iCursor = Integer.valueOf(cursor);
// jobType = "CACHE";
gumInput = input;
dbDir = redisPath;
try {
switch (jobType) {
case "ENHANCEDASTDIFF":
EnhancedASTDiff.main(gumInput, gumOutput, numOfWorkers, pjName, eDiffTimeout,actionType,parallelism,portDumps, dbDir, actionType+dumpsName);
break;
case "CACHE":
StoreEDiffInCache.main(gumOutput, portDumps, dbDir, actionType+dumpsName);
break;
case "SI":
// CalculatePairs.main(dbDir, actionType+dumpsName, portDumps, pairsPath+actionType, pjName+actionType,isBigPair,iCursor);
ImportPairs2DB.main(pairsPath, portInner, dbDir,datasetPath,chunk);
break;
case "SIMI":
AkkaTreeLoader.main(portInner, dbDir, "pairs.rdb" , portDumps, actionType+dumpsName,pairsPath,numOfWorkers,iCursor,chunk,eDiffTimeout,parallelism);
case "RICHEDITSCRIPT":
EnhancedASTDiff.main(gumInput, numOfWorkers, pjName, eDiffTimeout,parallelism,portDumps, dbDir, actionType+dumpsName);
break;
case "LEVEL1":
String indexFile = pairsPath+actionType + "/" +pjName+actionType+".index";
level1(portInner, portDumps, pythonPath, datasetPath, pjName, actionType, threshold, dbDir, gumInput,iCursor,indexFile);
case "COMPARE":
String job;
String compareDBName;
switch (parameter){
case "L1":
job = "shape";
compareDBName = "clusterl0-gumInputALL.rdb";
break;
//CALC python abstractPatch.py to from cluster folder
case "LEVEL2":
level2(portDumps, pythonPath, datasetPath, pjName, actionType, threshold, dbDir, dumpsName, gumInput,iCursor);
case "L2":
job = "action";
compareDBName = "clusterl1-gumInputALL.rdb";
break;
//CALC via python
case "LEVEL3":
level3(portDumps, pythonPath, datasetPath, pjName, actionType, threshold, dbDir, dumpsName, gumInput,iCursor);
case "L3":
job = "token";
compareDBName = "clusterl2-gumInputALL.rdb";
break;
case "EXTRACTPATTERN":
PatternExtractor.mainLaunch(portInner,numOfWorkers,jobType,portDumps,pythonPath,datasetPath,pjName,actionType,threshold);
default:
throw new Error("unknown level please specify L1,L2,L3");
}
CompareTrees.main(redisPath, portInner,portDumps,actionType+dumpsName,compareDBName, job);
break;
case "GETPATTERN":
PatternExtractor.mainLaunch(portInner,numOfWorkers,jobType,portDumps,pythonPath,datasetPath,pjName,actionType,threshold);
case "PATTERN":
ClusterToPattern.main(portDumps,redisPath, actionType+dumpsName, parameter);
break;
default:
throw new Error("unknown Job");
}
} catch (Exception e) {
e.printStackTrace();
}
}
private static void level1(String portInner, String port, String pythonPath, String datasetPath, String pjName, String actionType, String threshold, String dbDir, String gumInput,int cursor,String indexFile) throws Exception {
TreeLoaderClusterL1.main(portInner, port, dbDir, "level1-"+pjName+ actionType+".rdb", dbDir ,pjName + actionType,cursor);
CallShell cs1 =new CallShell();
String db1 = "bash "+dbDir + "/" + "startServer.sh" +" %s %s %s";
String db11 = String.format(db1, dbDir,"level1-"+pjName+ actionType+".rdb" ,Integer.valueOf(port));
cs1.runShell(db11, port);
String runpy = "bash "+datasetPath + "/" + "launchPy.sh" +" %s %s %s %s %s %s %s";
String formatRunPy = String.format(runpy,pythonPath +"/abstractPatch.py", gumInput, datasetPath + "/cluster"+pjName+ actionType, port, "matches" + pjName + actionType, threshold,indexFile);
cs1.runShell(formatRunPy);
String stopServer = "bash "+dbDir + "/" + "stopServer.sh" +" %s";
stopServer = String.format(stopServer,Integer.valueOf(port));
cs1.runShell(stopServer, port);
}
private static void level2(String port, String pythonPath, String datasetPath, String pjName, String actionType, String threshold, String dbDir, String dumpsName, String gumInput,int cursor) throws Exception {
String stopServer;
// MultiThreadTreeLoaderCluster.calculatePairsOfClusters(datasetPath + "/cluster"+pjName+ actionType, datasetPath,actionType);
MultiThreadTreeLoaderCluster.mainCompare(port, datasetPath+"/pairsAction", datasetPath + "/redisSingleImport.sh", dbDir, "clusterl1-"+pjName+actionType+".rdb", actionType+dumpsName, "6380",actionType,cursor);
CallShell cs3 =new CallShell();
String db22 = "bash "+dbDir + "/" + "startServer.sh" +" %s %s %s";
String db1b = String.format(db22, dbDir,"clusterl1-"+pjName+actionType+".rdb",Integer.valueOf(port));
cs3.runShell(db1b, port);
String runpy2 = "bash "+datasetPath + "/" + "launchPy.sh" +" %s %s %s %s %s %s %s";
String formatRunPy1a = String.format(runpy2,pythonPath +"/abstractPatchCluster.py", gumInput, datasetPath + "/cluster"+pjName+ actionType, port, datasetPath + "/cluster-2l"+pjName+ actionType,threshold,"dummy");
cs3.runShell(formatRunPy1a);
String stopServer1a = "bash "+dbDir + "/" + "stopServer.sh" +" %s";
stopServer = String.format(stopServer1a,Integer.valueOf(port));
cs3.runShell(stopServer, port);
}
private static void level3(String port, String pythonPath, String datasetPath, String pjName, String actionType, String threshold, String dbDir, String dumpsName, String gumInput,int cursor) throws Exception {
String stopServer;
MultiThreadTreeLoaderCluster3.calculatePairsOfClusters(datasetPath + "/cluster-2l"+pjName+ actionType, datasetPath,actionType);
MultiThreadTreeLoaderCluster3.mainCompare("6300", datasetPath+"/pairs-2l"+actionType, datasetPath + "/redisSingleImport.sh", dbDir, "clusterl2-"+pjName+actionType+".rdb", actionType+dumpsName, "6301",actionType,cursor);
CallShell cs5 =new CallShell();
String dba = "bash "+dbDir + "/" + "startServer.sh" +" %s %s %s";
String dbaa = String.format(dba, dbDir,"clusterl2-"+pjName+actionType+".rdb",Integer.valueOf(port));
cs5.runShell(dbaa, port);
String runpya = "bash "+datasetPath + "/" + "launchPy.sh" +" %s %s %s %s %s %s %s";
String formatRunPya = String.format(runpya,pythonPath +"/abstractPatchClusterLevel3.py", gumInput, datasetPath + "/cluster-3l"+pjName+ actionType, port, datasetPath + "/cluster-2l"+pjName+ actionType,threshold,"dummy");
cs5.runShell(formatRunPya);
String stopServera = "bash "+dbDir + "/" + "stopServer.sh" +" %s";
stopServer = String.format(stopServera,Integer.valueOf(port));
cs5.runShell(stopServer, port);
return;
}
}
@@ -1,231 +0,0 @@
package edu.lu.uni.serval.fixminer;
import com.github.gumtreediff.actions.ActionGenerator;
import com.github.gumtreediff.actions.model.Action;
import com.github.gumtreediff.matchers.Matcher;
import com.github.gumtreediff.matchers.Matchers;
import com.github.gumtreediff.tree.ITree;
import java.io.*;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import java.util.stream.Collectors;
import java.util.stream.Stream;
/**
* Created by anilkoyuncu on 17/03/2018.
*/
public class TestTreeLoader {
public static void main(String[] args) {
// String inputPath = "/Users/anilkoyuncu/bugStudy/dataset/GumTreeOutput/ENTESB/ASTDumps";
// String inputPath = "/Users/anilkoyuncu/bugStudy/dataset/GumTreeOutput2/";
String inputPath ="/Users/anil.koyuncu/projects/fixminer-all/enhancedASTDiff/python/data/EnhancedASTDiffgumInput-old/AssertStatement";
File folder = new File(inputPath);
File[] listOfFiles = folder.listFiles();
Stream<File> stream = Arrays.stream(listOfFiles);
List<File> pjs = stream
.filter(x -> !x.getName().startsWith("."))
.collect(Collectors.toList());
List<File> fileToCompare = new ArrayList<>();
for(File pj:pjs){
File[] files = pj.listFiles(new FilenameFilter() {
public boolean accept(File dir, String name) {
return name.startsWith("ASTDumps");
}
});
Collections.addAll(fileToCompare, files[0].listFiles());
}
System.out.println("a");
// compareAll(fileToCompare);
memoryFriendlyCompare(fileToCompare);
}
public static ITree getSimpliedTree(String fn) {
ITree tree = null;
try {
FileInputStream fi = new FileInputStream(new File(fn));
ObjectInputStream oi = new ObjectInputStream(fi);
tree = (ITree) oi.readObject();
oi.close();
fi.close();
} catch (FileNotFoundException e) {
System.out.println("File not found");
} catch (IOException e) {
System.out.println("Error initializing stream");
} catch (ClassNotFoundException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
tree.setLabel("");
tree.setParent(null);
List<ITree> descendants = tree.getDescendants();
for (ITree descendant : descendants) {
descendant.setLabel("");
}
return tree;
}
public static void memoryFriendlyCompare(List<File> folders){
List<String> treesFileNames = new ArrayList<>();
// HashMap<Integer, String> hmap = new HashMap<Integer, String>();
for (File target : folders) {
// hmap.put(folders.indexOf(target), target.toString());
treesFileNames.add(target.toString());
}
for (int i = 0; i < treesFileNames.size(); i++) {
for (int j = i + 1; j < treesFileNames.size(); j++) {
// compare list.get(i) and list.get(j)
try {
BufferedWriter writer = new BufferedWriter(new FileWriter("output2.txt", true));
ITree oldTree = getSimpliedTree(treesFileNames.get(i));
ITree newTree = getSimpliedTree(treesFileNames.get(j));
Matcher m = Matchers.getInstance().getMatcher(oldTree, newTree);
m.match();
ActionGenerator ag = new ActionGenerator(oldTree, newTree, m.getMappings());
ag.generate();
List<Action> actions = ag.getActions();
writer.write(String.valueOf(i));
writer.write("\t");
writer.write(String.valueOf(j));
writer.write("\t");
writer.write(String.format("%1.2f", m.chawatheSimilarity(oldTree, newTree)));
writer.write("\t");
writer.write(String.format("%1.2f", m.diceSimilarity(oldTree, newTree)));
writer.write("\t");
writer.write(String.format("%1.2f", m.jaccardSimilarity(oldTree, newTree)));
writer.write("\t");
writer.write(String.valueOf(actions.size()));
writer.write("\t");
writer.write(treesFileNames.get(i));
writer.write("\t");
writer.write(treesFileNames.get(j));
writer.write("\n");
writer.close();
} catch (FileNotFoundException e) {
System.out.println("File not found");
} catch (IOException e) {
System.out.println("Error initializing stream");
}
}
}
}
// public static void compareAll(List<File> folders){
// List<ITree> trees = new ArrayList<>();
// HashMap<Integer, String> hmap = new HashMap<Integer, String>();
// for (File target : folders) {
//
// try {
// FileInputStream fi = new FileInputStream(new File(target.toString()));
// ObjectInputStream oi = new ObjectInputStream(fi);
// ITree pr1 = (ITree) oi.readObject();
// oi.close();
// fi.close();
// trees.add(pr1);
// hmap.put(folders.indexOf(target), target.toString());
//
// } catch (FileNotFoundException e) {
// System.out.println("File not found");
// } catch (IOException e) {
// System.out.println("Error initializing stream");
// } catch (ClassNotFoundException e) {
// // TODO Auto-generated catch block
// e.printStackTrace();
// }
// }
//
// for (ITree tree : trees) {
//// SimplifyTree simplifyTree = new SimplifyTree();
//// simplifyTree.canonicalizeSourceCodeTree(tree);
// tree.setLabel("");
// tree.setParent(null);
// List<ITree> descendants = tree.getDescendants();
// for (ITree descendant : descendants) {
// descendant.setLabel("");
// }
//
// }
// System.out.println("a");
//
// try {
//
//
//
// for (int i = 0; i < trees.size(); i++) {
// for (int j = i + 1; j < trees.size(); j++) {
// // compare list.get(i) and list.get(j)
// BufferedWriter writer = new BufferedWriter(new FileWriter("output.txt",true));
// ITree oldTree = trees.get(i);
//
// ITree newTree = trees.get(j);
//
// Matcher m = Matchers.getInstance().getMatcher(oldTree, newTree);
// m.match();
//
// ActionGenerator ag = new ActionGenerator(oldTree, newTree, m.getMappings());
// ag.generate();
// List<Action> actions = ag.getActions();
// writer.write(String.valueOf(i));
// writer.write("\t");
// writer.write(String.valueOf(j));
// writer.write("\t");
//
// writer.write(String.format("%1.2f", m.chawatheSimilarity(oldTree, newTree)));
// writer.write("\t");
// writer.write(String.format("%1.2f", m.diceSimilarity(oldTree, newTree)));
// writer.write("\t");
// writer.write(String.format("%1.2f", m.jaccardSimilarity(oldTree, newTree)));
// writer.write("\t");
// writer.write(String.valueOf(actions.size()));
// writer.write("\t");
// writer.write(hmap.get(i));
// writer.write("\t");
// writer.write(hmap.get(j));
// writer.write("\n");
//
// writer.close();
// }
// }
//
//
// } catch (FileNotFoundException e) {
// System.out.println("File not found");
// } catch (IOException e) {
// System.out.println("Error initializing stream");
//
// }
//
//
//// if (actions.size() > 1) {
//// Matcher m1 = Matchers.getInstance().getMatcher(actions.get(0).getNode(), actions.get(0).getNode());
//// m1.match();
//// Set<Mapping> mappingSet1 = m1.getMappingSet();
////
//// }
// }
}
@@ -1,601 +0,0 @@
package edu.lu.uni.serval.fixminer.akka;
//Import the Java utility classes
import java.io.BufferedReader;
import java.io.FileReader;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Map;
import java.util.Set;
//Import the Apache Commons Maths library classes to handle the term-vectors from Apache Lucene
import org.apache.commons.math3.linear.ArrayRealVector;
import org.apache.commons.math3.linear.RealVector;
//Import the Apache Lucene classes
import org.apache.lucene.analysis.Analyzer;
import org.apache.lucene.analysis.core.SimpleAnalyzer;
import org.apache.lucene.document.Document;
import org.apache.lucene.document.Field;
import org.apache.lucene.document.FieldType;
import org.apache.lucene.index.AtomicReader;
import org.apache.lucene.index.DirectoryReader;
import org.apache.lucene.index.DocsEnum;
import org.apache.lucene.index.IndexReader;
import org.apache.lucene.index.IndexWriter;
import org.apache.lucene.index.IndexWriterConfig;
import org.apache.lucene.index.MultiFields;
import org.apache.lucene.index.Term;
import org.apache.lucene.index.Terms;
import org.apache.lucene.index.TermsEnum;
import org.apache.lucene.search.similarities.DefaultSimilarity;
import org.apache.lucene.search.similarities.TFIDFSimilarity;
import org.apache.lucene.store.Directory;
import org.apache.lucene.store.RAMDirectory;
import org.apache.lucene.util.Bits;
import org.apache.lucene.util.BytesRef;
import org.apache.lucene.util.Version;
import com.thoughtworks.xstream.core.util.Fields;
//A class to find the similarity of all text documents referenced in a text file
public class DocumentSimilarity {
private static final String CONTENT = "Content"; /*the name of the field stored by Apache Lucene which includes the text from the
text documents.*/
private Set<String> terms = new HashSet<>(); //changed state with new terms after each call to getTermFrequencies() method
private ArrayList<Integer> directoryIndex; //The Apache Lucene index for documents to mine for similarities
/* Indexed, tokenized, stored. */
public final FieldType TYPE_STORED = new FieldType(); //This is the field profiled by Apache Lucene to collect its term frequencies
private HashMap<String,Integer> termsCount; //stores the counts of all terms found in the corpus
private ArrayList<Integer> scannedDocs; //stores the IDs of docs already scanned and stored in termsCount
DocumentSimilarity(String lookupFile) {
//Initialise the field to profile in each document
TYPE_STORED.setIndexed(true);
TYPE_STORED.setTokenized(true);
TYPE_STORED.setStored(true);
TYPE_STORED.setStoreTermVectors(true);
TYPE_STORED.setStoreTermVectorPositions(true);
TYPE_STORED.freeze();
termsCount = new HashMap<String,Integer>();
scannedDocs = new ArrayList<Integer>();
try {
//initialise an in-memory (RAM-based) index of the documents in the input folder using Apache Lucene
Directory directory = createIndex(lookupFile);
IndexReader reader = DirectoryReader.open(directory);
String outputFile = "C:/Users/default/test/docs_similarity.csv"; /* the output file where the document similarities will be stored */
PrintWriter writer;
writer = new PrintWriter(outputFile, "UTF-8");
writer.println("doc1,doc2,similarity");
//loop on the documents in the folder and compare them together
for (int i=0; i<directoryIndex.size(); i++) {
for (int j=i+1; j<directoryIndex.size(); j++) {
Map<String, Double> f1 = getTermFrequencies(reader, i); //get the term frequencies profile of the first document
RealVector v1 = toRealVector(f1); //convert term frequencies profile to a vector
Map<String, Double> f2 = getTermFrequencies2(reader, j); //get the term frequencies profile of the second document
RealVector v2 = toRealVector(f2); //convert term frequencies profile to a vector
double sim = getCosineSimilarity(v1, v2); //compute the cosine similarity of the documents pair using their terms frequencies profiles
writer.println(directoryIndex.get(i)+","+directoryIndex.get(j)+","+sim); //write the similarity to an output CSV file
}
terms = new HashSet<>();
}
reader.close();
writer.close();
} catch (Exception e) {
e.printStackTrace();
}
writeTermsCount();
}
//A method to initialise an in-memory (RAM-based) index of the documents in the input file using Apache Lucene
Directory createIndex(String lookupFile) {
try {
Directory directory = new RAMDirectory();
/* Initialize the analyzer which profiles the text inside the documents. This analyser does all the pre-processing of the
* text including stop-word removal, tokenization, etc. depending on the type of analyzer used.
* Check the reference website for different types of analyzers: https://www.tutorialspoint.com/lucene/lucene_analysis.htm
*/
Analyzer analyzer = new SimpleAnalyzer(Version.LUCENE_CURRENT); //create a new SimpleAnalyzer
IndexWriterConfig iwc = new IndexWriterConfig(Version.LUCENE_CURRENT,
analyzer);
IndexWriter writer = new IndexWriter(directory, iwc); //write the index of the documents with their analysis in-memory
int did=1; //documents are numbered by a document ID as 1,2,3...n in a lookup file of the documents to be indexed
BufferedReader dsLookup;
dsLookup = new BufferedReader(new FileReader(lookupFile));
String ds; //The document number in each line
ArrayList<Integer> directoryIndex = new ArrayList<Integer>();
while ((ds = dsLookup.readLine()) != null) {
//Set the document id to the string read from the line in lookup file
try {
String documentText = ""; //stores the text from the document
FileReader fr = new FileReader(did+".txt");
BufferedReader br = new BufferedReader(fr);
String sCurrentLine;
while ((sCurrentLine = br.readLine()) != null) {
documentText += (sCurrentLine);
}
//add the document to the index
addDocument(writer, documentText);
directoryIndex.add(did);
} catch (Exception e) {
System.out.println("!!! Document "+did+" has an error and was skipped !!!");
continue;
}
}
writer.close();
this.directoryIndex = directoryIndex;
return directory;
} catch (Exception e) {
e.printStackTrace();
}
return null;
}
//a method to add a document to the index by writing its text as a "content" field in Apache Lucene
void addDocument(IndexWriter writer, String content) {
try {
Document doc = new Document(); //create a new Apache Lucene document
Field field = new Field(CONTENT, content, TYPE_STORED); //Add the field with the text content to the index
doc.add(field);
writer.addDocument(doc);
} catch (Exception e) {
e.printStackTrace();
}
}
//a method to get the cosine similarity between two term-frequency vectors from a pair of documents
public double getCosineSimilarity(RealVector v1, RealVector v2) {
return (v1.dotProduct(v2)) / (v1.getNorm() * v2.getNorm());
}
//a method to get the term frequencies from a document
Map<String, Double> getTermFrequencies(IndexReader reader, int docId) {
try {
Terms vector = reader.getTermVector(docId, CONTENT);
TermsEnum termsEnum = null;
termsEnum = vector.iterator(termsEnum);
Map<String, Double> frequencies = new HashMap<>();
BytesRef text = null;
TFIDFSimilarity tfidfSim = new DefaultSimilarity();
boolean scannedDoc = scannedDocs.contains(docId);
while ((text = termsEnum.next()) != null) {
String term = text.utf8ToString();
org.apache.lucene.index.Fields fields = reader.getTermVectors(0);
Term termInstance = new Term("Content", term);
long indexDf = reader.docFreq(termInstance);
int docCount = reader.numDocs();
//increment the term count in the terms count lookup if doc not scanned before
if(!scannedDoc) {
if(termsCount.containsKey(termInstance.toString())) {
Integer cnt = termsCount.get(termInstance.toString());
cnt++;
termsCount.replace(termInstance.toString(), cnt);
} else {
termsCount.put(termInstance.toString(), 1);
}
}
DocsEnum docs = termsEnum.docs(MultiFields.getLiveDocs(reader),null,0);
//calculate the TF-IDF of the term, as compared to all documents in the corpus (the Apache Lucene Index)
double tfidf = 0.0;
while(docs.nextDoc() != DocsEnum.NO_MORE_DOCS) {
tfidf = tfidfSim.tf(docs.freq()) * tfidfSim.idf(docCount, indexDf);
}
frequencies.put(term, tfidf);
scannedDocs.add(docId);
terms.add(term);
}
return frequencies;
} catch (Exception e) {
e.printStackTrace();
}
return null;
}
Map<String, Double> getTermFrequencies2(IndexReader reader, int docId) {
try {
Terms vector = reader.getTermVector(docId, CONTENT);
TermsEnum termsEnum = null;
termsEnum = vector.iterator(termsEnum);
Map<String, Double> frequencies = new HashMap<>();
BytesRef text = null;
TFIDFSimilarity tfidfSim = new DefaultSimilarity();
boolean scannedDoc = scannedDocs.contains(docId);
int docCount = reader.numDocs();
while ((text = termsEnum.next()) != null) {
String term = text.utf8ToString();
Term termInstance = new Term("Content", term);
long indexDf = reader.docFreq(termInstance);
//increment the term count in the terms count lookup if doc not scanned before
if(!scannedDoc) {
if(termsCount.containsKey(termInstance.toString())) {
Integer cnt = termsCount.get(termInstance.toString());
cnt++;
termsCount.replace(termInstance.toString(), cnt);
} else {
termsCount.put(termInstance.toString(), 1);
}
}
DocsEnum docs = termsEnum.docs(MultiFields.getLiveDocs(reader),null,0);
double tfidf = 0.0;
while(docs.nextDoc() != DocsEnum.NO_MORE_DOCS) {
tfidf = tfidfSim.tf(docs.freq()) * tfidfSim.idf(docCount, indexDf);
}
frequencies.put(term, tfidf);
scannedDocs.add(docId);
}
return frequencies;
} catch (Exception e) {
e.printStackTrace();
}
return null;
}
//convert the term-frequencies extracted to a real vector
RealVector toRealVector(Map<String, Double> map) {
RealVector vector = new ArrayRealVector(terms.size());
int i = 0;
for (String term : terms) {
double value = map.containsKey(term) ? map.get(term) : 0.0;
vector.setEntry(i++, value);
}
return (RealVector) vector.mapDivide(vector.getL1Norm());
}
//Write the terms-frequencies from the documents to a CSV file
private void writeTermsCount() {
try {
String outputFile = "C:/Users/default/test/document_terms_count.csv";
PrintWriter writer;
writer = new PrintWriter(outputFile, "UTF-8");
writer.println("term,count");
for (String key : termsCount.keySet()) {
writer.println(key+","+termsCount.get(key));
}
writer.close();
} catch (Exception e) {
e.printStackTrace();
}
}
//MAIN class to execute with the .txt-file lookup of the documents to index
public static void main(String[] args) {
new DocumentSimilarity("documents_lookup.txt");
}
}
@@ -1,7 +1,5 @@
package edu.lu.uni.serval.fixminer.akka.compare;
import akka.actor.ActorRef;
import akka.actor.ActorSystem;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import redis.clients.jedis.Jedis;
@@ -9,7 +7,10 @@ import redis.clients.jedis.JedisPool;
import redis.clients.jedis.ScanParams;
import redis.clients.jedis.ScanResult;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
/**
* Created by anilkoyuncu on 12/09/2018.
@@ -18,69 +19,6 @@ public class AkkaTreeParser {
private static Logger log = LoggerFactory.getLogger(AkkaTreeParser.class);
public static void akkaCompare(JedisPool innerPool, JedisPool outerPool, String numOfWorkers, int cursor, String eDiffTimeout, String parallelism){
final List<String> listOfPairs = getMessages(innerPool,cursor); //"/Users/anilkoyuncu/bugStudy/code/python/GumTreeInput/Apache/CAMEL/"
switch (parallelism){
case "AKKA":
// ActorSystem system = null;
// ActorRef parsingActor = null;
// final TreeMessage msg = new TreeMessage(0,listOfPairs, innerPool,outerPool,eDiffTimeout);
// try {
// log.info("Akka begins...");
// system = ActorSystem.create("Compare-EnhancedDiff-System");
//
// parsingActor = system.actorOf(TreeActor.props(Integer.valueOf(numOfWorkers)), "mine-fix-pattern-actor");
// parsingActor.tell(msg, ActorRef.noSender());
// } catch (Exception e) {
// system.shutdown();
// e.printStackTrace();
// }
break;
case "FORKJOIN":
int counter = new Object() {
int counter = 0;
{
listOfPairs.stream().
parallel().
peek(x -> counter++).
forEach(m ->
{
Compare compare = new Compare();
compare.coreCompare(m, innerPool, outerPool);
if (counter % 10 == 0) {
log.info("Finalized parsing " + counter + " files... remaing " + (listOfPairs.size() - counter));
}
}
);
}
}.counter;
log.info("Finished parsing {} files",counter);
break;
default:
log.error("Unknown parallelism {}", parallelism);
break;
}
}
public static List<String> getRMessages(JedisPool innerPool, int cursor){
try (Jedis inner = innerPool.getResource()) {
while (!inner.ping().equals("PONG")){
log.info("wait");
}
List<String> pairs = inner.srandmember("pairs", cursor);
return pairs;
}
}
public static List<String> getMessages(JedisPool innerPool, int cursor){
@@ -102,36 +40,40 @@ public class AkkaTreeParser {
int size = scan.getResult().size();
log.info("Scanned " + String.valueOf(size));
}
List<String> result = scan.getResult();
log.info("Getting results");
return result;
}
public static String getMessage(JedisPool innerPool){
public static HashMap<String, String> filenames(JedisPool innerPool){
ScanResult<String> scan;
HashMap<String, String> fileMap =new HashMap<String, String>();
try (Jedis inner = innerPool.getResource()) {
while (!inner.ping().equals("PONG")){
log.info("wait");
}
String myset = inner.spop("pairs");
return myset;
inner.select(1);
Map<String, String> filenames = inner.hgetAll("filenames");
for (Map.Entry<String, String> stringStringEntry : filenames.entrySet().stream().collect(Collectors.toList())) {
fileMap.put(stringStringEntry.getKey(),stringStringEntry.getValue());
}
}
log.info("Getting results");
return fileMap;
}
}
@@ -1,98 +0,0 @@
package edu.lu.uni.serval.fixminer.akka.compare;
import com.github.gumtreediff.actions.ActionGenerator;
import com.github.gumtreediff.actions.model.Action;
import com.github.gumtreediff.matchers.Matcher;
import com.github.gumtreediff.matchers.Matchers;
import com.github.gumtreediff.tree.ITree;
import edu.lu.uni.serval.utils.EDiffHelper;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import redis.clients.jedis.Jedis;
import redis.clients.jedis.JedisPool;
import java.util.List;
import java.util.Map;
/**
* Created by anilkoyuncu on 03/04/2018.
*/
public class Compare {
private Logger log = LoggerFactory.getLogger(Compare.class);
public void coreCompare(String name, JedisPool innerPool, JedisPool outerPool) {
Map<String, String> resultMap;
Jedis jedis = null;
ITree oldTree = null;
ITree newTree = null;
try {
jedis = innerPool.getResource();
String[] split = name.split("_");
String i = split[1];
String j = split[2];
String keyName = split[0];
oldTree = EDiffHelper.getSimpliedTree(keyName,i,outerPool);
newTree = EDiffHelper.getSimpliedTree(keyName,j,outerPool);
Matcher m = Matchers.getInstance().getMatcher(oldTree, newTree);
m.match();
ActionGenerator ag = new ActionGenerator(oldTree, newTree, m.getMappings());
ag.generate();
List<Action> actions = ag.getActions();
double chawatheSimilarity1 = m.chawatheSimilarity(oldTree, newTree);
String chawatheSimilarity = String.format("%1.2f", chawatheSimilarity1);
double diceSimilarity1 = m.diceSimilarity(oldTree, newTree);
String diceSimilarity = String.format("%1.2f", diceSimilarity1);
double jaccardSimilarity1 = m.jaccardSimilarity(oldTree, newTree);
String jaccardSimilarity = String.format("%1.2f", jaccardSimilarity1);
String editDistance = String.valueOf(actions.size());
String result = i + "," + j + "," + chawatheSimilarity + "," + diceSimilarity + "," + jaccardSimilarity + "," + editDistance;
if (((Double) chawatheSimilarity1).equals(1.0) || ((Double) diceSimilarity1).equals(1.0)
|| ((Double) jaccardSimilarity1).equals(1.0) || actions.size() == 0) {
String matchKey = keyName+"_" + (String.valueOf(i)) + "_" + String.valueOf(j);
log.info("{} tagged to be similar" ,matchKey);
jedis.select(1);
jedis.set(matchKey, result);
}
jedis.select(0);
jedis.del(keyName+"_" + (String.valueOf(i)) + "_" + String.valueOf(j));
} catch (Exception e) {
log.debug("{} not comparable", name);
// e.printStackTrace();
}finally {
if (jedis != null) {
jedis.close();
}
}
}
}
@@ -1,14 +1,6 @@
package edu.lu.uni.serval.fixminer.akka.compare;
import akka.actor.ActorRef;
import akka.actor.ActorSystem;
import com.github.gumtreediff.actions.ActionGenerator;
import com.github.gumtreediff.actions.model.Action;
import com.github.gumtreediff.matchers.Matcher;
import com.github.gumtreediff.matchers.Matchers;
import com.github.gumtreediff.tree.ITree;
import com.typesafe.config.Config;
import com.typesafe.config.ConfigFactory;
import edu.lu.uni.serval.fixminer.akka.ediff.HierarchicalActionSet;
import edu.lu.uni.serval.utils.CallShell;
import edu.lu.uni.serval.utils.EDiffHelper;
@@ -21,11 +13,8 @@ import redis.clients.jedis.Jedis;
import redis.clients.jedis.JedisPool;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Set;
import static edu.lu.uni.serval.fixminer.jobs.MultiThreadTreeLoaderCluster3.getNames;
/**
@@ -36,20 +25,20 @@ public class CompareTrees {
private static Logger log = LoggerFactory.getLogger(CompareTrees.class);
public static void main(String[] args) throws Exception {
public static void main(String redisPath, String portInner, String portDumps, String dumpsName, String compareDBName, String job) throws Exception {
// shape /Users/anil.koyuncu/projects/test/fixminer-core/python/data/redis ALLdumps-gumInput.rdb clusterl0-gumInputALL.rdb /Users/anil.koyuncu/projects/test/fixminer-core/python/data/richEditScript
String portInner = "6380";
String port = "6399";
// String portInner = "6380";
String port = portDumps; //"6399";
CallShell cs = new CallShell();
String cmd = "bash "+args[1] + "/" + "startServer.sh" +" %s %s %s";
cmd = String.format(cmd, args[1],args[2],Integer.valueOf(port));
String cmd = "bash "+redisPath + "/" + "startServer.sh" +" %s %s %s";
cmd = String.format(cmd, redisPath,dumpsName,Integer.valueOf(port));
log.info(cmd);
cs.runShell(cmd, port);
String cmdInner = "bash "+args[1] + "/" + "startServer.sh" +" %s %s %s";
cmdInner = String.format(cmdInner, args[1],args[3],Integer.valueOf(portInner));
String cmdInner = "bash "+redisPath + "/" + "startServer.sh" +" %s %s %s";
cmdInner = String.format(cmdInner, redisPath,compareDBName,Integer.valueOf(portInner));
log.info(cmdInner);
cs.runShell(cmdInner, portInner);
@@ -62,48 +51,17 @@ public class CompareTrees {
final JedisPool outerPool = new JedisPool(PoolBuilder.getPoolConfig(), host,Integer.valueOf(port),20000000);
List<String> listOfPairs = AkkaTreeParser.getMessages(innerPool,Integer.valueOf(numOfWorkers));
// String pair = AkkaTreeParser.getMessage(innerPool);
HashMap<String, String> filenames = AkkaTreeParser.filenames(innerPool);
// ActorSystem system = null;
// ActorRef parsingActor = null;
// final TreeMessage msg = new TreeMessage(0,listOfPairs, innerPool,outerPool,timeout,args[0]);
// try {
// log.info("Akka begins...");
// Config load = ConfigFactory.load();
// system = ActorSystem.create("Compare-EnhancedDiff-System");
//
// parsingActor = system.actorOf(TreeActor.props(Integer.valueOf(numOfWorkers)), "mine-fix-pattern-actor");
// parsingActor.tell(msg, ActorRef.noSender());
// } catch (Exception e) {
// system.shutdown();
// e.printStackTrace();
// }
// try {
// coreCompare(pair, args[0], innerPool, outerPool);
// } catch (Exception e) {
// try (Jedis inner = innerPool.getResource()) {
//
// inner.sadd("pairs",pair);
//
//
// }
// }
ArrayList<String> samePairs = new ArrayList<>();
ArrayList<String> errorPairs = new ArrayList<>();
listOfPairs.stream().parallel().forEach(m->coreCompare(m, args[0],innerPool, outerPool,samePairs,errorPairs));
listOfPairs.stream().parallel().forEach(m->coreCompare(m, job,innerPool, samePairs,errorPairs,filenames,outerPool));
// int size = samePairs.size();
try (Jedis jedis = innerPool.getResource()) {
// jedis.select(2);
// for (String samePair : samePairs) {
// jedis.set(samePair,"1");
// }
jedis.select(0);
jedis.flushDB();
@@ -114,34 +72,8 @@ public class CompareTrees {
}
log.info("End process");
// listOfPairs.parallelStream().forEach(m->coreCompare(m, args[0],innerPool, outerPool));
// for (String listOfPair : listOfPairs) {
// coreCompare(listOfPair, args[0],innerPool, outerPool);
// }
// int counter = new Object() {
// int counter = 0;
//
// {
//
// listOfPairs.parallelStream().
// peek(x -> counter++).
// forEach(m ->
// {
//// Compare compare = new Compare();
// coreCompare(m, args[0],innerPool, outerPool);
// if (counter % 1000 == 0) {
// log.info("Finalized parsing " + counter + " files... remaing " + (listOfPairs.size() - counter));
// }
// }
// );
// }
// }.counter;
// coreCompare(args[0],args[1],args[2],args[3]);
}
public static void coreCompare(String pairName, String treeType,JedisPool innerPool,JedisPool outerPool,ArrayList<String> samePairs,ArrayList<String> errorPairs ) {
public static void coreCompare(String pairName, String treeType,JedisPool innerPool,ArrayList<String> samePairs,ArrayList<String> errorPairs, HashMap<String, String> filenames,JedisPool outerPool ) {
// if (samePairs.size() % 1000 == 0) {
// log.info("Same pairs size "+samePairs.size());
@@ -170,23 +102,24 @@ public class CompareTrees {
// return;
// }
// jedis.srem("pairs",matchKey);
// JedisPool outerPool = null;
switch (treeType) {
case "shape":
oldTree = EDiffHelper.getShapes(keyName, i, outerPool, innerPool);
newTree = EDiffHelper.getShapes(keyName, j, outerPool, innerPool);
oldTree = EDiffHelper.getShapes(keyName, i, outerPool,filenames);
newTree = EDiffHelper.getShapes(keyName, j, outerPool,filenames);
break;
case "action":
oldPair = EDiffHelper.getActions(keyName, i, outerPool, innerPool);
newPair = EDiffHelper.getActions(keyName, j, outerPool, innerPool);
oldPair = EDiffHelper.getActions(keyName, i, outerPool, filenames);
newPair = EDiffHelper.getActions(keyName, j, outerPool, filenames);
oldTree = oldPair.getValue0();
newTree = newPair.getValue0();
break;
case "token":
oldTree = EDiffHelper.getTokens(keyName, i, outerPool, innerPool);
newTree = EDiffHelper.getTokens(keyName, j, outerPool, innerPool);
oldTree = EDiffHelper.getTokens(keyName, i, outerPool, filenames);
newTree = EDiffHelper.getTokens(keyName, j, outerPool, filenames);
String oldTokens = EDiffHelper.getNames2(oldTree);
String newTokens = EDiffHelper.getNames2(newTree);
@@ -1,25 +0,0 @@
package edu.lu.uni.serval.fixminer.akka.compare;
import redis.clients.jedis.JedisPool;
public class RunnableCompare implements Runnable {
private String name;
private JedisPool innerPool;
private JedisPool outerPool;
private CompareTrees comparer;
private String type;
public RunnableCompare(String name , JedisPool innerPool, JedisPool outerPool,String type) {
this.name = name;
this.innerPool = innerPool;
this.outerPool = outerPool;
this.type = type;
}
@Override
public void run() {
// comparer.coreCompare(name,type, innerPool, outerPool);
}
}
@@ -1,84 +0,0 @@
package edu.lu.uni.serval.fixminer.akka.compare;
import akka.actor.ActorRef;
import akka.actor.Props;
import akka.actor.UntypedActor;
import akka.japi.Creator;
import akka.routing.BalancingPool;
import akka.routing.RoundRobinPool;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import redis.clients.jedis.JedisPool;
import java.util.List;
public class TreeActor extends UntypedActor {
private static Logger logger = LoggerFactory.getLogger(TreeActor.class);
private ActorRef mineRouter;
private final int numberOfWorkers;
private int counter = 0;
public TreeActor(int numberOfWorkers) {
mineRouter = this.getContext().actorOf(new BalancingPool(numberOfWorkers)
.props(TreeWorker.props()), "tree-router");
this.numberOfWorkers = numberOfWorkers;
}
public static Props props(final int numberOfWorkers) {
return Props.create(new Creator<TreeActor>() {
private static final long serialVersionUID = 9207427376110704705L;
@Override
public TreeActor create() throws Exception {
return new TreeActor(numberOfWorkers);
}
});
}
@SuppressWarnings("deprecation")
@Override
public void onReceive(Object message) throws Exception {
if (message instanceof TreeMessage) {
List<String> pairs = ((TreeMessage) message).getName();
JedisPool innerPool = ((TreeMessage) message).getInnerPool();
JedisPool outerPool = ((TreeMessage) message).getOuterPool();
String type = ((TreeMessage) message).getType();
int size = pairs.size();
int average = size / numberOfWorkers;
int reminder = size % numberOfWorkers;
int counter = 0;
for (int i = 0; i < numberOfWorkers; i ++) {
int fromIndex = i * average + counter;
if (counter < reminder) counter ++;
int toIndex = (i + 1) * average + counter;
List<String> pairsOfWorkers = pairs.subList(fromIndex, toIndex);
final TreeMessage workMsg = new TreeMessage(i + 1, pairsOfWorkers,innerPool,outerPool,((TreeMessage) message).getSECONDS_TO_WAIT(),type);
mineRouter.tell(workMsg, getSelf());
logger.info("Assign {} task to worker #" + (i + 1) + "...",pairsOfWorkers.size());
}
} else if ("STOP".equals(message.toString())) {
counter ++;
logger.info(counter + " workers finalized their work...");
if (counter >= numberOfWorkers) {
logger.info("All workers finalized their work...");
this.getContext().stop(mineRouter);
this.getContext().stop(getSelf());
this.getContext().system().shutdown();
}
} else {
unhandled(message);
}
}
}
@@ -1,68 +0,0 @@
package edu.lu.uni.serval.fixminer.akka.compare;
import edu.lu.uni.serval.fixminer.akka.BaseMessage;
import redis.clients.jedis.JedisPool;
import java.util.List;
/**
* Created by anilkoyuncu on 12/09/2018.
*/
public class TreeMessage extends BaseMessage{
private List<String> name;
private JedisPool innerPool;
private JedisPool outerPool;
public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
private String type;
public TreeMessage(int id, List<String> name, JedisPool innerPool, JedisPool outerPool,String eDiffTimeout,String treeType) {
super(id,new Long(eDiffTimeout));
this.name = name;
this.innerPool = innerPool;
this.outerPool = outerPool;
this.type = treeType;
}
public TreeMessage(int id, List<String> name, JedisPool innerPool, JedisPool outerPool,Long eDiffTimeout,String treeType) {
super(id,eDiffTimeout);
this.name = name;
this.innerPool = innerPool;
this.outerPool = outerPool;
this.type = treeType;
}
public List<String> getName() {
return name;
}
public void setName(List<String> name) {
this.name = name;
}
public JedisPool getInnerPool() {
return innerPool;
}
public void setInnerPool(JedisPool innerPool) {
this.innerPool = innerPool;
}
public JedisPool getOuterPool() {
return outerPool;
}
public void setOuterPool(JedisPool outerPool) {
this.outerPool = outerPool;
}
}
@@ -1,85 +0,0 @@
package edu.lu.uni.serval.fixminer.akka.compare;
import akka.actor.Props;
import akka.actor.UntypedActor;
import akka.japi.Creator;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import redis.clients.jedis.JedisPool;
import java.util.List;
import java.util.concurrent.*;
public class TreeWorker extends UntypedActor {
private static Logger log = LoggerFactory.getLogger(TreeWorker.class);
public TreeWorker() {
}
public static Props props() {
return Props.create(new Creator<TreeWorker>() {
private static final long serialVersionUID = -7615153844097275009L;
@Override
public TreeWorker create() throws Exception {
return new TreeWorker();
}
});
}
@Override
public void onReceive(Object message) throws Exception {
if(message instanceof TreeMessage) {
TreeMessage msg = (TreeMessage) message;
List<String> files = msg.getName();
JedisPool innerPool = msg.getInnerPool();
JedisPool outerPool = msg.getOuterPool();
String type = msg.getType();
int id = msg.getId();
int counter = 0;
for (String name : files)
{
final ExecutorService executor = Executors.newFixedThreadPool(1);
// // schedule the work
final Future<?> future = executor.submit(new RunnableCompare(name, innerPool, outerPool,type));
try {
// wait for task to complete
future.get(msg.getSECONDS_TO_WAIT(), TimeUnit.SECONDS);
counter++;
if (counter % 1000 == 0) {
log.info("Worker #" + id +" finalized parsing " + counter + " pairs... remaing "+ (files.size() - counter));
}
} catch (TimeoutException e) {
future.cancel(true);
System.err.println("#Timeout: " + name);
} catch (InterruptedException e) {
e.printStackTrace();
} catch (ExecutionException e) {
e.printStackTrace();
} finally {
executor.shutdownNow();
}
}
log.info("Worker #" + id + " finalized the work...");
this.getSender().tell("STOP", getSelf());
}else{
unhandled(message);
}
}
}
@@ -0,0 +1,84 @@
package edu.lu.uni.serval.fixminer.akka.ediff;
import java.io.ByteArrayOutputStream;
import com.esotericsoftware.kryo.Kryo;
import com.esotericsoftware.kryo.io.Input;
import com.esotericsoftware.kryo.io.Output;
import com.esotericsoftware.kryo.pool.KryoFactory;
import com.esotericsoftware.kryo.pool.KryoPool;
import org.objenesis.strategy.SerializingInstantiatorStrategy;
public class DefaultKryoContext implements KryoContext{
private static final int DEFAULT_BUFFER = 1024 * 100;
private KryoPool pool;
public static KryoContext newKryoContextFactory()
{
return new DefaultKryoContext();
}
private DefaultKryoContext()
{
KryoFactory factory = new KryoFactoryImpl();
pool = new KryoPool.Builder(factory).softReferences().build();
}
private static class KryoFactoryImpl implements KryoFactory
{
@Override
public Kryo create() {
Kryo kryo = new Kryo();
kryo.setInstantiatorStrategy(new Kryo.DefaultInstantiatorStrategy(new SerializingInstantiatorStrategy()));
return kryo;
}
}
@Override
public byte[] serialze(Object obj)
{
return serialze(obj, DEFAULT_BUFFER);
}
@Override
public byte[] serialze(Object obj, int bufferSize)
{
ByteArrayOutputStream base = new ByteArrayOutputStream();
Output output = new Output(base, bufferSize);
Kryo kryo = pool.borrow();
kryo.writeObject(output, obj);
output.flush();
byte[] serialized = base.toByteArray();
output.close();
// byte[] serialized = output.toBytes();
pool.release(kryo);
return serialized;
}
@Override
public Object deserialze(Class clazz, byte[] serialized)
{
Object obj;
Kryo kryo = pool.borrow();
Input input = new Input(serialized);
obj = kryo.readObject(input, clazz);
pool.release(kryo);
return obj;
}
}
@@ -1,16 +1,13 @@
package edu.lu.uni.serval.fixminer.akka.ediff;
import com.github.gumtreediff.actions.model.Delete;
import com.github.gumtreediff.actions.model.Insert;
import com.github.gumtreediff.actions.model.Move;
import com.github.gumtreediff.actions.model.Update;
import edu.lu.uni.serval.utils.EDiffHelper;
import edu.lu.uni.serval.utils.FileHelper;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import redis.clients.jedis.Jedis;
import redis.clients.jedis.JedisPool;
import java.io.*;
import java.util.ArrayList;
import java.io.File;
import java.io.FileOutputStream;
import java.util.List;
@@ -23,94 +20,40 @@ import java.util.List;
*/
public class EDiffHunkParser extends EDiffParser {
private static Logger logger = LoggerFactory.getLogger(EDiffHunkParser.class);
@Override
public void parseFixPatterns(File prevFile, File revFile, File diffentryFile, String project, JedisPool innerPool) {
List<HierarchicalActionSet> actionSets = parseChangedSourceCodeWithGumTree2(prevFile, revFile);
if (actionSets.size() != 0) {
// String folder= null;
boolean processActionSet = true;
// switch (actionType){
// case "ALL":
// if(actionType.equals("ALL")){
// folder = "/ALL/";
// processActionSet = true;
// }else if(actionType.equals("UPD") || actionType.equals("INS") || actionType.equals("DEL") || actionType.equals("MOV")|| actionType.equals("MIX")){
// boolean isUPD = actionSets.stream().allMatch(p -> p.getAction() instanceof Update);
// boolean isINS = actionSets.stream().allMatch(p -> p.getAction() instanceof Insert);
// boolean isDEL = actionSets.stream().allMatch(p -> p.getAction() instanceof Delete);
// boolean isMOV = actionSets.stream().allMatch(p -> p.getAction() instanceof Move);
// if(isUPD){
// folder = "/UPD/";
// processActionSet = true;
// }else if(isINS){
// folder = "/INS/";
// processActionSet = true;
// }else if(isDEL){
// folder = "/DEL/";
// processActionSet = true;
// }else if(isMOV){
// folder = "/MOV/";
// processActionSet = true;
// }else{
// folder = "/MIX/";
// processActionSet = true;
// }
// }else{
//
//
// processActionSet = false;
// System.err.print(actionType + "not known");
//
// }
boolean processActionSet = true;
int hunkSet = 0;
if(processActionSet){
for (HierarchicalActionSet actionSet : actionSets) {
FileOutputStream f = null;
try {
String astNodeType = actionSet.getAstNodeType();
// int size = actionSet.toString().split("\\n").length;
actionSet.toString();
int size = actionSet.getActionSize();
// int size = actionSet.strList.size();
String datasetName = project;
String[] split1 = diffentryFile.getParent().split(datasetName);
String root = split1[0];
String pj = split1[1].split("/")[1];
// File file = new File(root + "EnhancedASTDiff" + datasetName + "/"+astNodeType+"/"+String.valueOf(size)+"/");
// file.mkdirs();
// String hunkTreeFileName = root + "EnhancedASTDiff" + datasetName + "/"+astNodeType+"/"+String.valueOf(size)+"/" + pj +"_" + diffentryFile.getName() + "_" + String.valueOf(hunkSet);
// String hunkTreeFileName = root + "EnhancedASTDiff" + datasetName + "/" + pj + folder + diffentryFile.getName() + "_" + String.valueOf(hunkSet);
// f = new FileOutputStream(new File(hunkTreeFileName));
// ObjectOutputStream o = new ObjectOutputStream(f);
// o.writeObject(actionSet);
//
// o.close();
// f.close();
// String name = f.getName();
String key = astNodeType+"/"+String.valueOf(size)+"/" + pj +"_" + diffentryFile.getName() + "_" + String.valueOf(hunkSet);
try (Jedis inner = innerPool.getResource()) {
inner.set(key.getBytes(), EDiffHelper.toByteArray(actionSet));
inner.hset("dump".getBytes(),key.getBytes(),EDiffHelper.kryoSerialize(actionSet));
}
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (Exception e) {
logger.error("error",e);
e.printStackTrace();
}
hunkSet++;
@@ -10,10 +10,6 @@ public class EDiffMessage extends BaseMessage{
private List<MessageFile> msgFiles;
private String actionType;
public JedisPool getInnerPool() {
return innerPool;
}
@@ -31,25 +27,14 @@ public class EDiffMessage extends BaseMessage{
public EDiffMessage(int id, List<MessageFile> msgFiles,String eDiffTimeout,JedisPool pool) {
super(id,new Long(eDiffTimeout));
this.msgFiles = msgFiles;
this.actionType = actionType;
this.innerPool = pool;
}
public EDiffMessage(int id, List<MessageFile> msgFiles,Long eDiffTimeout,JedisPool pool) {
super(id,eDiffTimeout);
this.msgFiles = msgFiles;
this.actionType = actionType;
this.innerPool = pool;
}
public String getActionType() {
return actionType;
}
public void setActionType(String actionType) {
this.actionType = actionType;
}
public List<MessageFile> getMsgFiles() {
return msgFiles;
@@ -0,0 +1,10 @@
package edu.lu.uni.serval.fixminer.akka.ediff;
public interface KryoContext {
byte[] serialze(Object obj);
byte[] serialze(Object obj, int bufferSize);
Object deserialze(Class clazz, byte[] serialized);
}
@@ -1,149 +0,0 @@
package edu.lu.uni.serval.fixminer.jobs;
import edu.lu.uni.serval.utils.CallShell;
import edu.lu.uni.serval.utils.PoolBuilder;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import redis.clients.jedis.Jedis;
import redis.clients.jedis.JedisPool;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileReader;
import java.io.IOException;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.regex.Pattern;
import java.util.stream.Collectors;
import java.util.stream.Stream;
import static edu.lu.uni.serval.fixminer.akka.compare.AkkaTreeParser.akkaCompare;
/**
* Created by anilkoyuncu on 19/03/2018.
*/
public class AkkaTreeLoader {
private static Logger log = LoggerFactory.getLogger(AkkaTreeLoader.class);
public static void main(String portInner, String dbDir, String chunkName, String port, String dumpsName, String pairsPath, String numOfWorkers, int cursor, String chunk, String eDiffTimeout, String parallelism) throws Exception {
String parameters = String.format("\nportInner %s \nchunkName %s \ndbDir %s \ndumpsName %s",portInner,chunkName,dbDir,dumpsName);
log.info(parameters);
CallShell cs = new CallShell();
String cmd = "bash "+dbDir + "/" + "startServer.sh" +" %s %s %s";
String cmd1 = String.format(cmd, dbDir,dumpsName,Integer.valueOf(port));
//
cs.runShell(cmd1,port);
String cmdInner = "bash "+dbDir + "/" + "startServer.sh" +" %s %s %s";
String cmd2 = String.format(cmdInner, dbDir,chunkName,Integer.valueOf(portInner));
log.info(cmd1);
log.info(cmd2);
//
cs.runShell(cmd2, portInner);
JedisPool outerPool = new JedisPool(PoolBuilder.getPoolConfig(), "127.0.0.1",Integer.valueOf(port),20000000);
JedisPool innerPool = new JedisPool(PoolBuilder.getPoolConfig(), "127.0.0.1",Integer.valueOf(portInner),20000000);
// String pairsIndexFile = pairsPath + "/"+ chunkName;
//0.txt.rdb
// pairsIndexFile = pairsIndexFile.replace(chunk+".rdb",".index");
File folder = new File(pairsPath);
File[] rootsFolder = folder.listFiles();
Stream<File> stream = Arrays.stream(rootsFolder);
List<File> roots = stream
.filter(x -> !x.getName().startsWith("."))
.collect(Collectors.toList());
for(File root:roots) {
File[] files = root.listFiles();
Stream<File> fileStream = Arrays.stream(files);
List<File> pairsIndexFiles = fileStream
.filter(x -> !x.getName().startsWith("."))
.filter(x -> x.getName().endsWith(".index"))
.collect(Collectors.toList());
for (File pairsIndexFile : pairsIndexFiles) {
Pattern pattern = Pattern.compile(",");
String csvFile = pairsIndexFile.getPath();
try {
try (BufferedReader in = new BufferedReader(new FileReader(csvFile));) {
Map<String, String> namefreq = in
.lines()
.map(x -> pattern.split(x))
.collect(HashMap::new, (map, x) ->
map.put(root.getName()+"-"+pairsIndexFile.getName().split("\\.")[0]+"-"+x[0], x[1]),
Map::putAll);
Jedis inner = null;
try {
inner = outerPool.getResource();
for (Map.Entry<String, String> entry : namefreq.entrySet()) {
String key = entry.getKey();
String value = entry.getValue();
inner.select(1);
inner.set(key, value);
}
} finally {
if (inner != null) {
inner.close();
}
}
}
} catch (IOException e) {
e.printStackTrace();
}
}
}
akkaCompare(innerPool,outerPool,numOfWorkers,cursor,eDiffTimeout,parallelism);
// String stopServer = "bash "+dbDir + "/" + "stopServer.sh" +" %s";
// String stopServer2 = String.format(stopServer,Integer.valueOf(port));
//
// cs.runShell(stopServer2,port);
//
//
// String stopServer1 = String.format(stopServer,Integer.valueOf(portInner));
//
// cs.runShell(stopServer1,portInner);
}
}
@@ -1,157 +0,0 @@
package edu.lu.uni.serval.fixminer.jobs;
import edu.lu.uni.serval.utils.CallShell;
import edu.lu.uni.serval.utils.FileHelper;
import edu.lu.uni.serval.utils.PoolBuilder;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import redis.clients.jedis.Jedis;
import redis.clients.jedis.JedisPool;
import redis.clients.jedis.ScanParams;
import redis.clients.jedis.ScanResult;
import java.io.*;
import java.nio.ByteBuffer;
import java.nio.channels.FileChannel;
import java.util.List;
/**
* Created by anilkoyuncu on 05/04/2018.
*/
public class CalculatePairs {
private static Logger log = LoggerFactory.getLogger(CalculatePairs.class);
public static void main(String dbDir,String chunkName,String port,String outputPath,String pjName,boolean isBigPair,int cursor) throws Exception {
String parameters = String.format("\nport %s \nchunkName %s \ndbDir %s",port,chunkName,dbDir);
log.info(parameters);
CallShell cs =new CallShell();
String cmd = "bash "+dbDir + "/" + "startServer.sh" +" %s %s %s";
cmd = String.format(cmd, dbDir,chunkName,Integer.valueOf(port));
cs.runShell(cmd, port);
FileHelper.createDirectory(outputPath);
JedisPool outerPool = new JedisPool(PoolBuilder.getPoolConfig(), "127.0.0.1",Integer.valueOf(port),20000000);
ScanResult<String> scan;
try (Jedis outer = outerPool.getResource()) {
while (outer.ping()== "PONG"){
log.info("wait");
}
ScanParams sc = new ScanParams();
//150000000
sc.count(cursor);
sc.match("*");
scan = outer.scan("0", sc);
int size = scan.getResult().size();
log.info("Scanning " + String.valueOf(size));
}
List<String> result = scan.getResult();
byte [] buf = new byte[0];
String line = null;
if(isBigPair) {
bigPair(outputPath, pjName, result, buf, line);
}else{
smallPair(outputPath, pjName, result, buf, line);
}
// String stopServer = "bash "+dbDir + "/" + "stopServer.sh" +" %s";
// String stopServer2 = String.format(stopServer,Integer.valueOf(port));
//// loadRedis(stopServer2,serverWait);
// cs.runShell(stopServer2,serverWait);
log.info("Done pairs");
}
private static void smallPair(String outputPath, String pjName, List<String> result, byte[] buf, String line) {
try {
FileOutputStream fos = new FileOutputStream(outputPath + "/" +pjName+".csv");
DataOutputStream outStream = new DataOutputStream(new BufferedOutputStream(fos));
FileOutputStream fosIndex = new FileOutputStream(outputPath + "/" +pjName+".index");
DataOutputStream outStreamIndex = new DataOutputStream(new BufferedOutputStream(fosIndex));
for (int i = 0; i < result.size(); i++) {
line = String.valueOf(i) +"," + result.get(i)+"\n";
outStreamIndex.write(line.getBytes());
for (int j = i + 1; j < result.size(); j++) {
line = String.valueOf(i) +"," + String.valueOf(j)+"\n"; // + "," + result.get(i) + "," + result.get(j)+"\n";
outStream.write(line.getBytes());
}
}
outStream.close();
outStreamIndex.close();
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}catch (java.nio.BufferOverflowException e) {
log.error(line);
log.error(String.valueOf(buf.length));
e.printStackTrace();
}
}
private static void bigPair(String outputPath, String pjName, List<String> result, byte[] buf, String line) {
try {
FileOutputStream fosIndex = new FileOutputStream(outputPath + "/" +pjName+".index");
DataOutputStream outStreamIndex = new DataOutputStream(new BufferedOutputStream(fosIndex));
int fileCounter = 0;
FileChannel rwChannel = new RandomAccessFile(outputPath + "/" +pjName +String.valueOf(fileCounter)+".txt", "rw").getChannel();
int maxSize = 500*1000000;
ByteBuffer wrBuf = rwChannel.map(FileChannel.MapMode.READ_WRITE, 0, maxSize);
for (int i = 0; i < result.size(); i++) {
line = String.valueOf(i) +"," + result.get(i)+"\n";
outStreamIndex.write(line.getBytes());
for (int j = i + 1; j < result.size(); j++) {
line = String.valueOf(i) +"," + String.valueOf(j)+"\n"; // + "," + result.get(i) + "," + result.get(j)+"\n";
buf = line.getBytes();
if(wrBuf.remaining() > 500) {
wrBuf.put(buf);
}else{
log.info("Next pair dump");
fileCounter++;
rwChannel = new RandomAccessFile(outputPath+"/" +pjName+String.valueOf(fileCounter)+".txt", "rw").getChannel();
wrBuf = rwChannel.map(FileChannel.MapMode.READ_WRITE, 0, maxSize);
}
}
}
outStreamIndex.close();
rwChannel.close();
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}catch (java.nio.BufferOverflowException e) {
log.error(line);
log.error(String.valueOf(buf.length));
e.printStackTrace();
}
}
}
@@ -24,10 +24,10 @@ public class EnhancedASTDiff {
private static Logger log = LoggerFactory.getLogger(EnhancedASTDiff.class);
public static void main(String inputPath, String outputPath, String numOfWorkers, String project, String eDiffTimeout, String actionType, String parallelism, String portInner, String dbDir, String chunkName) throws Exception {
public static void main(String inputPath, String numOfWorkers, String project, String eDiffTimeout, String parallelism, String portInner, String dbDir, String chunkName) throws Exception {
String parameters = String.format("\nInput path %s \nOutput path %s",inputPath,outputPath);
String parameters = String.format("\nInput path %s",inputPath);
log.info(parameters);
CallShell cs = new CallShell();
@@ -48,29 +48,15 @@ public class EnhancedASTDiff {
List<MessageFile> allMessageFiles = new ArrayList<>();
for (File target : folders) {
String pjName = target.getName();
List<MessageFile> msgFiles = getMessageFiles(target.toString() + "/"); //"/Users/anilkoyuncu/bugStudy/code/python/GumTreeInput/Apache/CAMEL/"
// System.out.println(msgFiles.size());
if (msgFiles == null)
continue;
allMessageFiles.addAll(msgFiles);
String GUM_TREE_OUTPUT = outputPath + "/" + pjName + "/";
// a
// if (actionType.equals("ALL")) {
// FileHelper.createDirectory(GUM_TREE_OUTPUT + "/" + actionType);
// } else {
// FileHelper.createDirectory(GUM_TREE_OUTPUT + "/UPD");
// FileHelper.createDirectory(GUM_TREE_OUTPUT + "/INS");
// FileHelper.createDirectory(GUM_TREE_OUTPUT + "/DEL");
// FileHelper.createDirectory(GUM_TREE_OUTPUT + "/MOV");
// FileHelper.createDirectory(GUM_TREE_OUTPUT + "/MIX");
// }
}
switch (parallelism){
@@ -101,9 +87,9 @@ public class EnhancedASTDiff {
forEach(m ->
{
EDiffHunkParser parser = new EDiffHunkParser();
parser.parseFixPatterns(m.getPrevFile(),m.getRevFile(), m.getDiffEntryFile(),project,msg.getInnerPool());
parser.parseFixPatterns(m.getPrevFile(),m.getRevFile(), m.getDiffEntryFile(),project,innerPool);
if (counter % 10 == 0) {
log.info("Finalized parsing " + counter + " files... remaing " + (allMessageFiles.size() - counter));
log.info("Finalized parsing " + counter + " files... remaining " + (allMessageFiles.size() - counter));
}
}
);
@@ -111,6 +97,8 @@ public class EnhancedASTDiff {
}.counter;
log.info("Finished parsing {} files",counter);
break;
default:
log.error("Unknown parallelism {}", parallelism);
break;
@@ -1,80 +0,0 @@
package edu.lu.uni.serval.fixminer.jobs;
import edu.lu.uni.serval.utils.CallShell;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.io.File;
import java.util.Arrays;
import java.util.List;
import java.util.stream.Collectors;
import java.util.stream.Stream;
/**
* Created by anilkoyuncu on 05/04/2018.
*/
public class ImportPairs2DB {
private static Logger log = LoggerFactory.getLogger(ImportPairs2DB.class);
public static void main(String csvInputPath, String portInner, String dbDir, String datasetPath, String chunk) throws Exception {
String parameters = String.format("\nInput path %s \nportInner %s \ndbDir %s",csvInputPath,portInner,dbDir);
log.info(parameters);
String[] splits = chunk.split("\\.");
String chunkType = splits[splits.length-1];
log.info("Chunk type {}",chunkType);
File folder = new File(csvInputPath);
File[] subFolders = folder.listFiles();
Stream<File> stream = Arrays.stream(subFolders);
List<File> roots = stream
// .filter(x -> x.getName().endsWith(chunkType))
.collect(Collectors.toList());
Integer portInt = Integer.valueOf(portInner);
String cmd = "bash " + dbDir + "/" + "startServer.sh" + " %s %s %s";
cmd = String.format(cmd, dbDir,"pairs.rdb", portInt);
log.info(cmd);
CallShell cs = new CallShell();
cs.runShell(cmd, portInner);
for (File root : roots) {
File[] files = root.listFiles();
Stream<File> fileStream = Arrays.stream(files);
List<File> pairs = fileStream
.filter(x -> x.getName().endsWith(chunkType))
.collect(Collectors.toList());
for(File pj:pairs) {
cmd = "bash " + datasetPath + "/redisSingleImport.sh" + " %s %s %s";
cmd = String.format(cmd, pj.getPath(), portInt,root.getName()+"-"+pj.getName().split("\\.")[0]);
log.info(cmd);
cs.runShell(cmd,portInner);
}
}
String stopServer = "bash " + dbDir + "/" + "stopServer.sh" + " %s";
String stopServer2 = String.format(stopServer, portInt);
cs.runShell(stopServer2, portInner);
// portInt++;
log.info(parameters);
}
}
@@ -1,394 +0,0 @@
package edu.lu.uni.serval.fixminer.jobs;
import com.github.gumtreediff.actions.ActionGenerator;
import com.github.gumtreediff.actions.model.Action;
import com.github.gumtreediff.matchers.Matcher;
import com.github.gumtreediff.matchers.Matchers;
import com.github.gumtreediff.tree.ITree;
import com.github.gumtreediff.tree.TreeContext;
import edu.lu.uni.serval.fixminer.akka.ediff.HierarchicalActionSet;
import edu.lu.uni.serval.utils.CallShell;
import edu.lu.uni.serval.utils.EDiffHelper;
import edu.lu.uni.serval.utils.FileHelper;
import edu.lu.uni.serval.utils.PoolBuilder;
import org.javatuples.Pair;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import redis.clients.jedis.Jedis;
import redis.clients.jedis.JedisPool;
import redis.clients.jedis.ScanParams;
import redis.clients.jedis.ScanResult;
import java.io.*;
import java.util.*;
import java.util.regex.Pattern;
import java.util.stream.Collectors;
import java.util.stream.Stream;
/**
* Created by anilkoyuncu on 19/03/2018.
*/
public class MultiThreadTreeLoaderCluster {
private static Logger log = LoggerFactory.getLogger(MultiThreadTreeLoaderCluster.class);
public static void mainCompare(String port,String pairsCSVPath,String importScript,String dbDir,String chunkName,String dumpName,String portInner,String type,int cursor) throws Exception {
CallShell cs = new CallShell();
String cmd1 = "bash "+dbDir + "/" + "startServer.sh" +" %s %s %s";
cmd1 = String.format(cmd1, dbDir,chunkName,Integer.valueOf(portInner));
cs.runShell(cmd1, port);
String cmd2 = "bash "+dbDir + "/" + "startServer.sh" +" %s %s %s";
cmd2 = String.format(cmd2, dbDir,dumpName,Integer.valueOf(port));
cs.runShell(cmd2, port);
// String cmd3;
// cmd3 = "bash " + importScript +" %s %s";
JedisPool jedisPool = new JedisPool(PoolBuilder.getPoolConfig(), "127.0.0.1",Integer.valueOf(portInner),20000000);
JedisPool outerPool = new JedisPool(PoolBuilder.getPoolConfig(), "127.0.0.1",Integer.valueOf(port),20000000);
File folder = new File(pairsCSVPath);
File[] listOfFiles = folder.listFiles();
Stream<File> stream = Arrays.stream(listOfFiles);
List<File> folders = stream
.filter(x -> !x.getName().startsWith("."))
.collect(Collectors.toList());
for (File f:folders) {
// if(f.getName().startsWith("cluster0")) {
File[] files = f.listFiles();
Stream<File> fileStream = Arrays.stream(files);
List<File> pairs = fileStream
.filter(x -> !x.getName().startsWith("."))
.filter(x -> !x.getName().endsWith(".index"))
.collect(Collectors.toList());
for (File pair : pairs) {
try (Jedis jedis = jedisPool.getResource()) {
// do operations with jedis resource
ScanParams sc = new ScanParams();
sc.count(cursor);
sc.match(f.getName()+"*");
log.info("Scanning");
ScanResult<String> scan = jedis.scan("0", sc);
int size = scan.getResult().size();
if (size == 0) {
String cmd3 = "bash " + importScript + " %s %s %s";
cmd3 = String.format(cmd3, pair.getPath(), portInner,f.getName()+"-"+pair.getName().split("\\.")[0]);
// String comd = String.format(cmd3, f.getPath(), portInner);
// loadRedis(comd);
log.info("Importing {} pairs for cluster {}", size, f.getName());
cs.runShell(cmd3, portInner);
scan = jedis.scan("0", sc);
size = scan.getResult().size();
}
log.info("Scanned {} for cluster {}", String.valueOf(size), f.getName());
Pattern pattern = Pattern.compile(",");
String csvFile = pair.getPath();
csvFile = csvFile.replace("txt","index");
try (BufferedReader in = new BufferedReader(new FileReader(csvFile));) {
Map<String, String> namefreq = in
.lines()
.map(x -> pattern.split(x))
.collect(HashMap::new, (map, x) ->
map.put(f.getName()+"-"+pair.getName().split("\\.")[0]+"-"+x[0], x[1]),
Map::putAll);
for (Map.Entry<String, String> entry : namefreq.entrySet()) {
String key = entry.getKey();
String value = entry.getValue();
jedis.select(1);
jedis.set(key, value);
}
}
// String clusterName = f.getName().replaceAll("[^0-9]+", "");
//76
scan.getResult().parallelStream()
.forEach(m -> coreCompare(m, jedisPool, f.getName(), outerPool, type));
jedis.save();
}
// }
}
}
String stopServer = "bash "+dbDir + "/" + "stopServer.sh" +" %s";
String stopServer1 = String.format(stopServer,Integer.valueOf(portInner));
cs.runShell(stopServer1, port);
String stopServer2 = String.format(stopServer,Integer.valueOf(port));
cs.runShell(stopServer2, port);
}
public static Pair<ITree,String> getTree(String prefix,String firstValue, JedisPool outerPool,JedisPool innerPool){
ITree tree = null;
Jedis inner = null;
Jedis outer = null;
// String[] split2 = firstValue.split("/");
//
// String fullFileName = split2[split2.length-1];
// String[] split = fullFileName.split(".txt_");
// String pureFileName = split[0];
// String[] splitPJ = split[1].split("_");
// String project = splitPJ[1];
// String actionSetPosition = splitPJ[0];
try {
inner = innerPool.getResource();
inner.select(1);
String dist2load = inner.get(prefix+"-"+firstValue);
outer = outerPool.getResource();
outer.select(0);
String s = null;//inner.get(prefix.replace("-","/") +"/"+dist2load);
Set<String> keys = outer.keys(prefix.split("-")[0] + "/*/" + dist2load);
if(keys.size() == 1) {
s = (String) keys.toArray()[0];
}else{
throw new Error("cok key");
}
// String filename = project + "/"+type+"/" + pureFileName + ".txt_" + actionSetPosition;
String si= outer.get(s);
HierarchicalActionSet actionSet = (HierarchicalActionSet) EDiffHelper.fromString(si);
ITree parent = null;
ITree children =null;
TreeContext tc = new TreeContext();
tree = EDiffHelper.getActionTree(actionSet, parent, children,tc);
tree.setParent(null);
tc.validate();
} catch (IOException e) {
e.printStackTrace();
} catch (ClassNotFoundException e) {
e.printStackTrace();
}finally {
if (inner != null) {
inner.close();
}
if (outer != null) {
outer.close();
}
}
Pair<ITree, String> pair = new Pair<>(tree,null);
return pair;
}
private static void coreCompare(String name , JedisPool jedisPool,String clusterName,JedisPool outerPool,String type) {
try (Jedis jedis = jedisPool.getResource()) {
Map<String, String> resultMap = jedis.hgetAll(name);
resultMap.get("0");
String[] split = name.split("_");
String i = null;
String j =null;
try {
i = split[1];
j = split[2];
}
catch (Exception e){
e.printStackTrace();
}
// String firstValue = resultMap.get("0");
// String secondValue = resultMap.get("1");
try {
String keyName = split[0];
Pair<ITree, String> oldPair = getTree(keyName,i, outerPool,jedisPool);
Pair<ITree, String> newPair = getTree(keyName,j, outerPool,jedisPool);
ITree oldTree = oldPair.getValue0();
ITree newTree = newPair.getValue0();
// String oldProject = oldPair.getValue1();
// String newProject = newPair.getValue1();
Matcher m = Matchers.getInstance().getMatcher(oldTree, newTree);
m.match();
ActionGenerator ag = new ActionGenerator(oldTree, newTree, m.getMappings());
ag.generate();
List<Action> actions = ag.getActions();
String resultKey = "result_" + (String.valueOf(i)) + "_" + String.valueOf(j);
double chawatheSimilarity1 = m.chawatheSimilarity(oldTree, newTree);
String chawatheSimilarity = String.format("%1.2f", chawatheSimilarity1);
double diceSimilarity1 = m.diceSimilarity(oldTree, newTree);
String diceSimilarity = String.format("%1.2f", diceSimilarity1);
double jaccardSimilarity1 = m.jaccardSimilarity(oldTree, newTree);
String jaccardSimilarity = String.format("%1.2f", jaccardSimilarity1);
String editDistance = String.valueOf(actions.size());
// jedis.select(1);
String result = i+ "," + j + "," + chawatheSimilarity + "," + diceSimilarity + "," + jaccardSimilarity + "," + editDistance;
// jedis.set(resultKey, result);
String matchKey = keyName+"_" + (String.valueOf(i)) + "_" + String.valueOf(j);
if (((Double) chawatheSimilarity1).equals(1.0) || ((Double) diceSimilarity1).equals(1.0)
|| ((Double) jaccardSimilarity1).equals(1.0) || actions.size() == 0) {
jedis.select(2);
jedis.set(matchKey, result);
}
jedis.select(0);
jedis.del(matchKey);
// log.info("Completed " + resultKey);
}catch (Exception e){
log.debug(e.toString() + " {}",(name));
e.printStackTrace();
}
}
}
/*
pairs of each cluster
*/
public static void calculatePairsOfClusters(String inputPath, String outputPath,String type) {
File folder = new File(inputPath);
File[] listOfFiles = folder.listFiles();
Stream<File> stream = Arrays.stream(listOfFiles);
List<File> pjs = stream
.filter(x -> !x.getName().startsWith("."))
.filter(x-> x.isDirectory())
.collect(Collectors.toList());
FileHelper.createDirectory(outputPath + "/pairs"+type);
for (File pj : pjs) {
File[] files = pj.listFiles();
List<File> fileList = Arrays.asList(files);
readMessageFilesCluster(fileList, outputPath,inputPath,pj.getName(),type);
}
}
private static void readMessageFilesCluster(List<File> folders, String outputPath,String inputPath,String cluster,String type) {
List<String> treesFileNames = new ArrayList<>();
for (File target : folders) {
treesFileNames.add(target.toString());
}
log.info("Calculating pairs");
// treesFileNames = treesFileNames.subList(0,100);
String filename = "cluster" + cluster;
byte [] buf = new byte[0];
String line = null;
try {
FileOutputStream fos = new FileOutputStream(outputPath + "/pairs"+type+"/" +filename+".csv");
DataOutputStream outStream = new DataOutputStream(new BufferedOutputStream(fos));
for (int i = 0; i < treesFileNames.size(); i++) {
for (int j = i + 1; j < treesFileNames.size(); j++) {
line = String.valueOf(i) +"," + String.valueOf(j) + "," + treesFileNames.get(i).replace(inputPath,"") + "," + treesFileNames.get(j).replace(inputPath,"")+"\n";
outStream.write(line.getBytes());
}
}
outStream.close();
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}catch (java.nio.BufferOverflowException e) {
log.error(line);
log.error(String.valueOf(buf.length));
e.printStackTrace();
}
log.info("Done pairs of cluster {}",cluster);
}
// return msgFiles;
}

Some files were not shown because too many files have changed in this diff Show More