You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by jl...@apache.org on 2013/11/11 20:22:58 UTC
svn commit: r1540814 - in
/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23: ./
applications/content/src/org/ofbiz/content/data/ applications/party/config/
framework/base/src/org/ofbiz/base/component/
framework/service/src/org/ofbiz/service/ fr...
Author: jleroux
Date: Mon Nov 11 19:22:58 2013
New Revision: 1540814
URL: http://svn.apache.org/r1540814
Log:
Merges trunk HEAD
Modified:
ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/ (props changed)
ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/content/src/org/ofbiz/content/data/DataServices.java
ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/party/config/PartyUiLabels.xml
ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/base/src/org/ofbiz/base/component/ComponentConfig.java
ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/ServiceXaWrapper.java
ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/eca/ServiceEcaAction.java
ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/engine/GenericAsyncEngine.java
ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/webapp/src/org/ofbiz/webapp/website/WebSiteProperties.java
ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/webtools/webapp/webtools/entity/ModelInduceFromDb.jsp
ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/specialpurpose/ecommerce/data/DemoProduct.xml
ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/specialpurpose/lucene/webapp/content/WEB-INF/actions/Search.groovy
Propchange: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/
------------------------------------------------------------------------------
Merged /ofbiz/trunk:r1539532-1540788
Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/content/src/org/ofbiz/content/data/DataServices.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/content/src/org/ofbiz/content/data/DataServices.java?rev=1540814&r1=1540813&r2=1540814&view=diff
==============================================================================
--- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/content/src/org/ofbiz/content/data/DataServices.java (original)
+++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/content/src/org/ofbiz/content/data/DataServices.java Mon Nov 11 19:22:58 2013
@@ -414,9 +414,6 @@ public class DataServices {
if (UtilValidate.isEmpty(dataResourceTypeId) || dataResourceTypeId.startsWith("LOCAL_FILE")) {
fileName = prefix + sep + objectInfo;
file = new File(fileName);
- if (file == null) {
- throw new GenericServiceException("File: " + fileName + " is null.");
- }
if (!file.isAbsolute()) {
throw new GenericServiceException("File: " + fileName + " is not absolute.");
}
Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/party/config/PartyUiLabels.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/party/config/PartyUiLabels.xml?rev=1540814&r1=1540813&r2=1540814&view=diff
==============================================================================
--- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/party/config/PartyUiLabels.xml (original)
+++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/party/config/PartyUiLabels.xml Mon Nov 11 19:22:58 2013
@@ -2198,7 +2198,7 @@
<property key="PageTitleEditPartyInvitationGroupAssoc">
<value xml:lang="en">Edit Party Invitation GroupAssoc</value>
<value xml:lang="es">Editar asociación de grupo de invitación de participante</value>
- <value xml:lang="fr">Modifier l'association groupe invitation de l'acteurs</value>
+ <value xml:lang="fr">Modifier le groupe d'association d'invitation de l'acteur</value>
<value xml:lang="hi_IN">पारà¥à¤à¥ निमà¤à¤¤à¥à¤°à¤£ समà¥à¤¹à¤à¤¸à¥à¤¸à¤¿à¤à¤¶à¤¨(GroupAssoc) à¤à¥ सà¤à¤ªà¤¾à¤¦à¤¿à¤¤ à¤à¤°à¥à¤</value>
<value xml:lang="it">Aggiorna soggetti associati all'invito</value>
<value xml:lang="ja">åå¼å
æå¾
ã°ã«ã¼ãé¢é£ä»ããç·¨é</value>
@@ -2213,7 +2213,7 @@
<value xml:lang="de">Verbindung Rolle Einladung Akteur bearbeiten</value>
<value xml:lang="en">Edit Party Invitation RoleAssoc</value>
<value xml:lang="es">Editar asociación de rol de invitación de participante</value>
- <value xml:lang="fr">Modifier l'association de rôle d'invitation de l'acteur</value>
+ <value xml:lang="fr">Modifier l'association du rôle d'invitation de l'acteur</value>
<value xml:lang="hi_IN">पारà¥à¤à¥ निमà¤à¤¤à¥à¤°à¤£ à¤à¥à¤®à¤¿à¤à¤¾ à¤à¤¸à¥à¤¸à¤¿à¤à¤¶à¤¨ à¤à¥ सà¤à¤ªà¤¾à¤¦à¤¿à¤¤ à¤à¤°à¥à¤</value>
<value xml:lang="it">Aggiorna associazione ruolo invito</value>
<value xml:lang="ja">åå¼å
æå¾
ãã¼ã«é¢é£ä»ããç·¨é</value>
Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/base/src/org/ofbiz/base/component/ComponentConfig.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/base/src/org/ofbiz/base/component/ComponentConfig.java?rev=1540814&r1=1540813&r2=1540814&view=diff
==============================================================================
--- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/base/src/org/ofbiz/base/component/ComponentConfig.java (original)
+++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/base/src/org/ofbiz/base/component/ComponentConfig.java Mon Nov 11 19:22:58 2013
@@ -873,7 +873,7 @@ public final class ComponentConfig {
this.sessionCookieAccepted = !"false".equals(element.getAttribute("session-cookie-accepted"));
this.privileged = !"false".equals(element.getAttribute("privileged"));
String basePermStr = element.getAttribute("base-permission");
- if (basePermStr.isEmpty()) {
+ if (!basePermStr.isEmpty()) {
this.basePermission = basePermStr.split(",");
} else {
// default base permission is NONE
Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/ServiceXaWrapper.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/ServiceXaWrapper.java?rev=1540814&r1=1540813&r2=1540814&view=diff
==============================================================================
--- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/ServiceXaWrapper.java (original)
+++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/ServiceXaWrapper.java Mon Nov 11 19:22:58 2013
@@ -60,7 +60,7 @@ public class ServiceXaWrapper extends Ge
}
/**
- * Sets the service to run on rollback()
+ * Sets the service to run on commit()
* @param serviceName Name of service to run
* @param context Context to use when running
*/
@@ -69,7 +69,7 @@ public class ServiceXaWrapper extends Ge
}
/**
- * Sets the service to run on rollback()
+ * Sets the service to run on commit()
* @param serviceName Name of service to run
* @param context Context to use when running
* @param async override default async behavior
@@ -79,7 +79,7 @@ public class ServiceXaWrapper extends Ge
}
/**
- * Sets the service to run on rollback()
+ * Sets the service to run on commit()
* @param serviceName Name of service to run
* @param runAsUser UserLoginID to run as
* @param context Context to use when running
@@ -95,14 +95,14 @@ public class ServiceXaWrapper extends Ge
/**
- * @return The name of the service to run on rollback()
+ * @return The name of the service to run on commit()
*/
public String getCommitService() {
return this.commitService;
}
/**
- * @return The context used when running the rollback() service
+ * @return The context used when running the commit() service
*/
public Map<String, ? extends Object> getCommitContext() {
return this.commitContext;
@@ -124,7 +124,19 @@ public class ServiceXaWrapper extends Ge
* @param async override default async behavior
*/
public void setRollbackService(String serviceName, Map<String, ? extends Object> context, boolean async, boolean persist) {
+ this.setRollbackService(serviceName, null, context, async, persist);
+ }
+
+ /**
+ * Sets the service to run on rollback()
+ * @param serviceName Name of service to run
+ * @param runAsUser userLoginId to run the service as
+ * @param context Context to use when running
+ * @param async override default async behavior
+ */
+ public void setRollbackService(String serviceName, String runAsUser, Map<String, ? extends Object> context, boolean async, boolean persist) {
this.rollbackService = serviceName;
+ this.runAsUser = runAsUser;
this.rollbackContext = context;
this.rollbackAsync = async;
this.rollbackAsyncPersist = persist;
Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/eca/ServiceEcaAction.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/eca/ServiceEcaAction.java?rev=1540814&r1=1540813&r2=1540814&view=diff
==============================================================================
--- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/eca/ServiceEcaAction.java (original)
+++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/eca/ServiceEcaAction.java Mon Nov 11 19:22:58 2013
@@ -118,11 +118,11 @@ public class ServiceEcaAction implements
// XA resource ECA
ServiceXaWrapper xaw = new ServiceXaWrapper(dctx);
if (eventName.equals("global-rollback")) {
- xaw.setRollbackService(serviceName, context, "async".equals(serviceMode), persist); // using the actual context so we get updates
+ xaw.setRollbackService(serviceName, runAsUser, context, "async".equals(serviceMode), persist); // using the actual context so we get updates
} else if (eventName.equals("global-commit")) {
- xaw.setCommitService(serviceName, context, "async".equals(serviceMode), persist); // using the actual context so we get updates
+ xaw.setCommitService(serviceName, runAsUser, context, "async".equals(serviceMode), persist); // using the actual context so we get updates
} else if (eventName.equals("global-commit-post-run")) {
- xaw.setCommitService(serviceName, context, "async".equals(serviceMode), persist); // using the actual context so we get updates
+ xaw.setCommitService(serviceName, runAsUser, context, "async".equals(serviceMode), persist); // using the actual context so we get updates
}
try {
xaw.enlist();
Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/engine/GenericAsyncEngine.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/engine/GenericAsyncEngine.java?rev=1540814&r1=1540813&r2=1540814&view=diff
==============================================================================
--- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/engine/GenericAsyncEngine.java (original)
+++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/service/src/org/ofbiz/service/engine/GenericAsyncEngine.java Mon Nov 11 19:22:58 2013
@@ -130,12 +130,7 @@ public abstract class GenericAsyncEngine
throw new GenericServiceException("Problem serializing service attributes", e);
}
- // make sure we stored okay
- if (jobV == null) {
- throw new GenericServiceException("Persisted job not created");
- } else {
- Debug.logInfo("Persisted job queued : " + jobV.getString("jobName"), module);
- }
+ Debug.logInfo("Persisted job queued : " + jobV.getString("jobName"), module);
} else {
JobManager jMgr = dispatcher.getJobManager();
if (jMgr != null) {
Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/webapp/src/org/ofbiz/webapp/website/WebSiteProperties.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/webapp/src/org/ofbiz/webapp/website/WebSiteProperties.java?rev=1540814&r1=1540813&r2=1540814&view=diff
==============================================================================
--- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/webapp/src/org/ofbiz/webapp/website/WebSiteProperties.java (original)
+++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/webapp/src/org/ofbiz/webapp/website/WebSiteProperties.java Mon Nov 11 19:22:58 2013
@@ -34,6 +34,7 @@ import org.ofbiz.entity.GenericValue;
@ThreadSafe
public final class WebSiteProperties {
+
/**
* Returns a <code>WebSiteProperties</code> instance initialized to the settings found
* in the <code>url.properties</code> file.
@@ -88,13 +89,13 @@ public final class WebSiteProperties {
if (httpPort.isEmpty() && !request.isSecure()) {
httpPort = String.valueOf(request.getServerPort());
}
- if (httpHost.isEmpty() && !request.isSecure()) {
+ if (httpHost.isEmpty()) {
httpHost = request.getServerName();
}
if (httpsPort.isEmpty() && request.isSecure()) {
httpsPort = String.valueOf(request.getServerPort());
}
- if (httpsHost.isEmpty() && request.isSecure()) {
+ if (httpsHost.isEmpty()) {
httpsHost = request.getServerName();
}
webSiteProps = new WebSiteProperties(httpPort, httpHost, httpsPort, httpsHost, enableHttps);
@@ -179,4 +180,15 @@ public final class WebSiteProperties {
public boolean getEnableHttps() {
return enableHttps;
}
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder("{httpPort=");
+ sb.append(httpPort).append(", ");
+ sb.append("httpHost=").append(httpHost).append(", ");
+ sb.append("httpsPort=").append(httpsPort).append(", ");
+ sb.append("httpsHost=").append(httpsHost).append(", ");
+ sb.append("enableHttps=").append(enableHttps).append("}");
+ return sb.toString();
+ }
}
Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/webtools/webapp/webtools/entity/ModelInduceFromDb.jsp
URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/webtools/webapp/webtools/entity/ModelInduceFromDb.jsp?rev=1540814&r1=1540813&r2=1540814&view=diff
==============================================================================
--- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/webtools/webapp/webtools/entity/ModelInduceFromDb.jsp (original)
+++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/framework/webtools/webapp/webtools/entity/ModelInduceFromDb.jsp Mon Nov 11 19:22:58 2013
@@ -66,7 +66,6 @@ ERRORS:
String author = "None";
String version = "1.0";
%><?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE entitymodel PUBLIC "-//OFBiz//DTD Entity Model//EN" "http://ofbiz.apache.org/dtds/entitymodel.dtd">
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
@@ -86,7 +85,8 @@ specific language governing permissions
under the License.
-->
-<entitymodel>
+<entitymodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/entitymodel.xsd">
<!-- ========================================================= -->
<!-- ======================== Defaults ======================= -->
<!-- ========================================================= -->
@@ -123,8 +123,7 @@ under the License.
ModelField field = fieldIterator.next();%>
<field name="<%=field.getName()%>"<%if(!field.getColName().equals(ModelUtil.javaNameToDbName(field.getName()))){
%> col-name="<%=field.getColName()%>"<%}%> type="<%=field.getType()%>"><%
- for (int v = 0; v<field.getValidatorsSize(); v++) {
- String valName = (String) field.getValidator(v);
+ for (String valName : field.getValidators()) {
%><validate name="<%=valName%>"/><%
}%></field><%
}
@@ -137,7 +136,7 @@ under the License.
for (int r = 0; r < entity.getRelationsSize(); r++) {
ModelRelation relation = entity.getRelation(r);%>
<relation type="<%=relation.getType()%>"<%if(relation.getTitle().length() > 0){%> title="<%=relation.getTitle()%>"<%}
- %> rel-entity-name="<%=relation.getRelEntityName()%>"><%for(int km=0; km<relation.getKeyMapsSize(); km++){ ModelKeyMap keyMap = relation.getKeyMap(km);%>
+ %> rel-entity-name="<%=relation.getRelEntityName()%>"><%for(ModelKeyMap keyMap : relation.getKeyMaps()){ %>
<key-map field-name="<%=keyMap.getFieldName()%>"<%if(!keyMap.getFieldName().equals(keyMap.getRelFieldName())){%> rel-field-name="<%=keyMap.getRelFieldName()%>"<%}%> /><%}%>
</relation><%
}
Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/specialpurpose/ecommerce/data/DemoProduct.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/specialpurpose/ecommerce/data/DemoProduct.xml?rev=1540814&r1=1540813&r2=1540814&view=diff
==============================================================================
--- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/specialpurpose/ecommerce/data/DemoProduct.xml (original)
+++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/specialpurpose/ecommerce/data/DemoProduct.xml Mon Nov 11 19:22:58 2013
@@ -1124,8 +1124,8 @@ under the License.
<InventoryItemDetail inventoryItemId="9023" inventoryItemDetailSeqId="0001" effectiveDate="2001-05-13 12:00:00.0" availableToPromiseDiff="8" quantityOnHandDiff="8" accountingQuantityDiff="8"/>
<InventoryItem facilityId="WebStoreWarehouse" inventoryItemId="9024" inventoryItemTypeId="NON_SERIAL_INV_ITEM" datetimeReceived="2008-08-01 08:00:00.000" productId="GZ-1006-4" ownerPartyId="Company" currencyUomId="USD" unitCost="2.4"/>
<InventoryItemDetail inventoryItemId="9024" inventoryItemDetailSeqId="0001" effectiveDate="2001-05-13 12:00:00.0" availableToPromiseDiff="8" quantityOnHandDiff="8" accountingQuantityDiff="8"/>
- <InventoryItem facilityId="WebStoreWarehouse" inventoryItemId="9025" inventoryItemTypeId="NON_SERIAL_INV_ITEM" datetimeReceived="2008-08-01 08:00:00.000" productId="GZ-1006-5" ownerPartyId="Company" currencyUomId="USD" unitCost="2.4"/>
- <InventoryItemDetail inventoryItemId="9025" inventoryItemDetailSeqId="0001" effectiveDate="2001-05-13 12:00:00.0" availableToPromiseDiff="8" quantityOnHandDiff="8" accountingQuantityDiff="8"/>
+ <InventoryItem facilityId="WebStoreWarehouse" inventoryItemId="9031" inventoryItemTypeId="NON_SERIAL_INV_ITEM" datetimeReceived="2008-08-01 08:00:00.000" productId="GZ-1006-5" ownerPartyId="Company" currencyUomId="USD" unitCost="2.4"/>
+ <InventoryItemDetail inventoryItemId="9031" inventoryItemDetailSeqId="0001" effectiveDate="2001-05-13 12:00:00.0" availableToPromiseDiff="8" quantityOnHandDiff="8" accountingQuantityDiff="8"/>
<InventoryItem facilityId="WebStoreWarehouse" inventoryItemId="9026" inventoryItemTypeId="NON_SERIAL_INV_ITEM" datetimeReceived="2008-08-01 08:00:00.000" productId="GZ-1000" ownerPartyId="Company" currencyUomId="USD" unitCost="2.4"/>
<InventoryItemDetail inventoryItemId="9026" inventoryItemDetailSeqId="0001" effectiveDate="2001-05-13 12:00:00.0" availableToPromiseDiff="8" quantityOnHandDiff="8" accountingQuantityDiff="8"/>
Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/specialpurpose/lucene/webapp/content/WEB-INF/actions/Search.groovy
URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/specialpurpose/lucene/webapp/content/WEB-INF/actions/Search.groovy?rev=1540814&r1=1540813&r2=1540814&view=diff
==============================================================================
--- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/specialpurpose/lucene/webapp/content/WEB-INF/actions/Search.groovy (original)
+++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/specialpurpose/lucene/webapp/content/WEB-INF/actions/Search.groovy Mon Nov 11 19:22:58 2013
@@ -22,7 +22,6 @@ import org.apache.lucene.document.Docume
import org.apache.lucene.index.Term
import org.apache.lucene.queryparser.classic.QueryParser
import org.apache.lucene.store.FSDirectory
-import org.ofbiz.base.util.Debug
import org.ofbiz.base.util.UtilHttp
import org.ofbiz.content.search.SearchWorker
import org.ofbiz.product.feature.ParametricSearch
@@ -57,14 +56,10 @@ if (queryLine || siteId) {
query = parser.parse(queryLine);
combQuery.add(query, BooleanClause.Occur.MUST);
}
- Debug.logInfo("in search, combQuery(0):" + combQuery, "");
-
if (siteId) {
termQuery = new TermQuery(new Term("site", siteId.toString()));
combQuery.add(termQuery, BooleanClause.Occur.MUST);
- Debug.logInfo("in search, termQuery:" + termQuery.toString(), "");
}
- Debug.logInfo("in search, combQuery(1):" + combQuery, "");
}
if (searchFeature1 || searchFeature2 || searchFeature3 || !featureIdByType.isEmpty()) {
@@ -77,26 +72,22 @@ if (searchFeature1 || searchFeature2 ||
if (searchFeature1) {
termQuery = new TermQuery(new Term("feature", searchFeature1));
featureQuery.add(termQuery, featuresRequired);
- Debug.logInfo("in search searchFeature1, termQuery:" + termQuery.toString(), "");
}
if (searchFeature2) {
termQuery = new TermQuery(new Term("feature", searchFeature2));
featureQuery.add(termQuery, featuresRequired);
- Debug.logInfo("in search searchFeature2, termQuery:" + termQuery.toString(), "");
}
if (searchFeature3) {
termQuery = new TermQuery(new Term("feature", searchFeature3));
featureQuery.add(termQuery, featuresRequired);
- Debug.logInfo("in search searchFeature3, termQuery:" + termQuery.toString(), "");
}
if (featureIdByType) {
featureIdByType.each { key, value ->
termQuery = new TermQuery(new Term("feature", value));
featureQuery.add(termQuery, featuresRequired);
- Debug.logInfo("in search searchFeature3, termQuery:" + termQuery.toString(), "");
}
combQuery.add(featureQuery, featuresRequired);
}