arquivo / pwa-technologies

Arquivo.pt main goal is the preservation and access of web contents that are no longer available online. During the developing of the PWA IR (information retrieval) system we faced limitations in searching speed, quality of results, scalability and usability. To cope with this, we modified the archive-access project (http://archive-access.sourceforge.net/) to support our web archive IR requirements. Nutchwax, Nutch and Wayback’s code were adapted to meet the requirements. Several optimizations were added, such as simplifications in the way document versions are searched and several bottlenecks were resolved. The PWA search engine is a public service at http://archive.pt and a research platform for web archiving. As it predecessor Nutch, it runs over Hadoop clusters for distributed computing following the map-reduce paradigm. Its major features include fast full-text search, URL search, phrase search, faceted search (date, format, site), and sorting by relevance and date. The PWA search engine is highly scalable and its architecture is flexible enough to enable the deployment of different configurations to respond to the different needs. Currently, it serves an archive collection searchable by full-text with 180 million documents ranging between 1996 and 2010.
http://www.arquivo.pt
GNU General Public License v3.0
39 stars 7 forks source link

Use indexOf(Char) instead of indexOf(String) #54

Closed arquivo closed 9 years ago

arquivo commented 9 years ago

Originally reported on Google Code with ID 55

As reported by PMD:
"Use String.indexOf(char) when checking for the index of a single character; it executes
faster."

Seeing the source code from the String class, one can see the difference in code complexity.

Classes with the reported issue:
* org.archive.wayback.accesscontrol.robotstxt.RobotRules
* org.archive.wayback.requestparser.OpenSearchRequestParser
* org.archive.wayback.resourcestore.WARCRecordToSearchResultAdapter
* org.archive.wayback.resourceindex.indexer.RemoteSubmitFilter
* org.archive.wayback.util.url.AggressiveUrlCanonicalizer
* org.archive.wayback.webapp.AccessPoint
* org.archive.wayback.webapp.RequestMapper

Reported by devel.david@vcruz.net on 2012-09-24 10:31:36

arquivo commented 9 years ago
Other classes with the reported issue:
* PwaArchive-access/projects/access-control/access-control/src/main/java/org/archive/accesscontrol/AccessControlClient.java
* PwaArchive-access/projects/access-control/oracle/src/main/java/org/archive/accesscontrol/oracle/RulesController.java
* PwaArchive-access/projects/access-control/oracle/src/main/java/org/archive/accesscontrol/webui/AdminController.java
* PwaArchive-access/projects/nutchwax/nutchwax-thirdparty/nutch/contrib/web2/plugins/web-query-propose-spellcheck/src/java/org/apache/nutch/spell/NGramSpeller.java
* PwaArchive-access/projects/nutchwax/nutchwax-thirdparty/nutch/contrib/web2/src/main/java/org/apache/nutch/webapp/servlet/NutchHttpServlet.java
* PwaArchive-access/projects/nutchwax/nutchwax-thirdparty/nutch/contrib/web2/src/main/java/org/apache/nutch/webapp/servlet/ResourceServlet.java
* PwaArchive-access/projects/nutchwax/nutchwax-thirdparty/nutch/src/plugin/lib-http/src/java/org/apache/nutch/protocol/http/api/RobotRulesParser.java
* PwaArchive-access/projects/nutchwax/nutchwax-thirdparty/nutch/src/plugin/protocol-http/src/java/org/apache/nutch/protocol/http/HttpResponse.java
* PwaArchive-access/projects/wayback/wayback-core/src/main/java/org/archive/wayback/resourceindex/indexer/RemoteSubmitFilter.java
* PwaLogsMiner/src/main/java/pt/arquivo/logs/arquivo/LogAnalyzer.java
* PwaLogsMiner/src/main/java/pt/arquivo/logs/arquivo/UrlDepth.java
* PwaLogsMiner/src/main/java/pt/arquivo/logs/tumba/LogAnalyzer.java
* PwaLucene/src/main/java/org/apache/lucene/search/features/queryindependent/PwaUrlDepth.java
* PwaSpellchecker/src/main/java/pt/arquivo/spellchecker/SpellChecker.java

Reported by devel.david@vcruz.net on 2012-09-24 11:20:20

arquivo commented 9 years ago
Added patch.

Reported by devel.david@vcruz.net on 2012-09-24 14:15:27


arquivo commented 9 years ago
This issue was closed by revision r450.

Reported by devel.david@vcruz.net on 2012-12-21 15:42:23