Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 48481200CAE for ; Wed, 21 Jun 2017 22:53:37 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 47249160BD0; Wed, 21 Jun 2017 20:53:37 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id D9CEE160BD5 for ; Wed, 21 Jun 2017 22:53:35 +0200 (CEST) Received: (qmail 66130 invoked by uid 500); 21 Jun 2017 20:53:35 -0000 Mailing-List: contact commits-help@manifoldcf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@manifoldcf.apache.org Delivered-To: mailing list commits@manifoldcf.apache.org Received: (qmail 66121 invoked by uid 99); 21 Jun 2017 20:53:35 -0000 Received: from Unknown (HELO svn01-us-west.apache.org) (209.188.14.144) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 21 Jun 2017 20:53:35 +0000 Received: from svn01-us-west.apache.org (localhost [127.0.0.1]) by svn01-us-west.apache.org (ASF Mail Server at svn01-us-west.apache.org) with ESMTP id A2D5D3A1852 for ; Wed, 21 Jun 2017 20:53:32 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1799512 - in /manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main: java/org/apache/manifoldcf/agents/output/cmisoutput/ native2ascii/org/apache/manifoldcf/agents/output/cmisoutput/ resources/org/apache/manifoldcf/agents/... Date: Wed, 21 Jun 2017 20:53:30 -0000 To: commits@manifoldcf.apache.org From: piergiorgio@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20170621205333.A2D5D3A1852@svn01-us-west.apache.org> archived-at: Wed, 21 Jun 2017 20:53:37 -0000 Author: piergiorgio Date: Wed Jun 21 20:53:30 2017 New Revision: 1799512 URL: http://svn.apache.org/viewvc?rev=1799512&view=rev Log: CMIS Output Connector now migrate contents but we need more bugfixing (CONNECTORS-1356) Modified: manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConfig.java manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConnector.java manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConnectorUtils.java manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/Messages.java manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/cmisoutput/common_en_US.properties manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/editConfiguration.js manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/editConfiguration_Server.html manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/viewConfiguration.html Modified: manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConfig.java URL: http://svn.apache.org/viewvc/manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConfig.java?rev=1799512&r1=1799511&r2=1799512&view=diff ============================================================================== --- manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConfig.java (original) +++ manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConfig.java Wed Jun 21 20:53:30 2017 @@ -65,5 +65,6 @@ public class CmisOutputConfig { public static final String REPOSITORY_ID_DEFAULT_VALUE = StringUtils.EMPTY; public static final String BINDING_ATOM_VALUE = "atom"; public static final String BINDING_WS_VALUE = "ws"; + public static final String CMIS_QUERY_DEFAULT_VALUE = "SELECT * FROM cmis:folder WHERE cmis:name='Apache ManifoldCF'"; } \ No newline at end of file Modified: manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConnector.java URL: http://svn.apache.org/viewvc/manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConnector.java?rev=1799512&r1=1799511&r2=1799512&view=diff ============================================================================== --- manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConnector.java (original) +++ manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConnector.java Wed Jun 21 20:53:30 2017 @@ -49,6 +49,7 @@ import org.apache.chemistry.opencmis.com import org.apache.chemistry.opencmis.commons.enums.BindingType; import org.apache.chemistry.opencmis.commons.enums.VersioningState; import org.apache.chemistry.opencmis.commons.exceptions.CmisConnectionException; +import org.apache.chemistry.opencmis.commons.exceptions.CmisContentAlreadyExistsException; import org.apache.chemistry.opencmis.commons.exceptions.CmisPermissionDeniedException; import org.apache.chemistry.opencmis.commons.impl.dataobjects.ContentStreamImpl; import org.apache.commons.lang.StringUtils; @@ -63,8 +64,6 @@ import org.apache.manifoldcf.core.interf import org.apache.manifoldcf.core.interfaces.IPostParameters; import org.apache.manifoldcf.core.interfaces.IThreadContext; import org.apache.manifoldcf.core.interfaces.ManifoldCFException; -import org.apache.manifoldcf.core.interfaces.Specification; -import org.apache.manifoldcf.core.interfaces.SpecificationNode; import org.apache.manifoldcf.core.interfaces.VersionContext; import org.apache.manifoldcf.crawler.system.Logging; @@ -75,8 +74,6 @@ import org.apache.manifoldcf.crawler.sys */ public class CmisOutputConnector extends BaseOutputConnector { - private static final String JOB_STARTPOINT_NODE_TYPE = "startpoint"; - protected final static String ACTIVITY_READ = "read document"; protected static final String RELATIONSHIP_CHILD = "child"; @@ -85,7 +82,6 @@ public class CmisOutputConnector extends // Tab name properties private static final String CMIS_SERVER_TAB_PROPERTY = "CmisOutputConnector.Server"; - private static final String CMIS_QUERY_TAB_PROPERTY = "CmisOutputConnector.CMISQuery"; // Template names @@ -95,25 +91,10 @@ public class CmisOutputConnector extends /** Server tab template */ private static final String EDIT_CONFIG_FORWARD_SERVER = "editConfiguration_Server.html"; - /** - * Forward to the javascript to check the specification parameters for the job - */ - private static final String EDIT_SPEC_HEADER_FORWARD = "editSpecification.js"; - - /** - * Forward to the template to edit the configuration parameters for the job - */ - private static final String EDIT_SPEC_FORWARD_CMISQUERY = "editSpecification_CMISQuery.html"; - /** Forward to the HTML template to view the configuration parameters */ private static final String VIEW_CONFIG_FORWARD = "viewConfiguration.html"; /** - * Forward to the template to view the specification parameters for the job - */ - private static final String VIEW_SPEC_FORWARD = "viewSpecification.html"; - - /** * CMIS Session handle */ Session session = null; @@ -361,6 +342,7 @@ public class CmisOutputConnector extends path = null; binding = null; repositoryId = null; + cmisQuery = null; } @@ -386,6 +368,8 @@ public class CmisOutputConnector extends path = params.getParameter(CmisOutputConfig.PATH_PARAM); binding = params.getParameter(CmisOutputConfig.BINDING_PARAM); + cmisQuery = params.getParameter(CmisOutputConfig.CMIS_QUERY_PARAM); + if (StringUtils.isNotEmpty(params.getParameter(CmisOutputConfig.REPOSITORY_ID_PARAM))) repositoryId = params.getParameter(CmisOutputConfig.REPOSITORY_ID_PARAM); } @@ -437,6 +421,9 @@ public class CmisOutputConnector extends if (StringUtils.isEmpty(path)) throw new ManifoldCFException("Parameter " + CmisOutputConfig.PATH_PARAM + " required but not set"); + + if (StringUtils.isEmpty(cmisQuery)) + throw new ManifoldCFException("Parameter " + CmisOutputConfig.CMIS_QUERY_PARAM + " required but not set"); long currentTime; GetSessionThread t = new GetSessionThread(); @@ -643,6 +630,7 @@ public class CmisOutputConnector extends String path = parameters.getParameter(CmisOutputConfig.PATH_PARAM); String repositoryId = parameters.getParameter(CmisOutputConfig.REPOSITORY_ID_PARAM); String binding = parameters.getParameter(CmisOutputConfig.BINDING_PARAM); + String cmisQuery = parameters.getParameter(CmisOutputConfig.CMIS_QUERY_PARAM); if (username == null) username = StringUtils.EMPTY; @@ -662,6 +650,8 @@ public class CmisOutputConnector extends repositoryId = StringUtils.EMPTY; if (binding == null) binding = CmisOutputConfig.BINDING_ATOM_VALUE; + if (cmisQuery == null) + cmisQuery = CmisOutputConfig.CMIS_QUERY_DEFAULT_VALUE; newMap.put(CmisOutputConfig.USERNAME_PARAM, username); newMap.put(CmisOutputConfig.PASSWORD_PARAM, password); @@ -671,6 +661,7 @@ public class CmisOutputConnector extends newMap.put(CmisOutputConfig.PATH_PARAM, path); newMap.put(CmisOutputConfig.REPOSITORY_ID_PARAM, repositoryId); newMap.put(CmisOutputConfig.BINDING_PARAM, binding); + newMap.put(CmisOutputConfig.CMIS_QUERY_PARAM, cmisQuery); } /** @@ -807,6 +798,11 @@ public class CmisOutputConnector extends if (path != null) { parameters.setParameter(CmisOutputConfig.PATH_PARAM, path); } + + String cmisQuery = variableContext.getParameter(CmisOutputConfig.CMIS_QUERY_PARAM); + if (cmisQuery != null) { + parameters.setParameter(CmisOutputConfig.CMIS_QUERY_PARAM, cmisQuery); + } String repositoryId = variableContext.getParameter(CmisOutputConfig.REPOSITORY_ID_PARAM); if (repositoryId != null) { @@ -816,179 +812,6 @@ public class CmisOutputConnector extends return null; } - /** - * Fill in specification Velocity parameter map for CMISQuery tab. - */ - private static void fillInCMISQuerySpecificationMap(Map newMap, Specification ds) { - int i = 0; - String cmisQuery = StringUtils.EMPTY; - String createTimestampTree = StringUtils.EMPTY; - while (i < ds.getChildCount()) { - SpecificationNode sn = ds.getChild(i); - if (sn.getType().equals(JOB_STARTPOINT_NODE_TYPE)) { - cmisQuery = sn.getAttributeValue(CmisOutputConfig.CMIS_QUERY_PARAM); - createTimestampTree = sn.getAttributeValue(CmisOutputConfig.CREATE_TIMESTAMP_TREE_PARAM); - } - i++; - } - newMap.put(CmisOutputConfig.CMIS_QUERY_PARAM, cmisQuery); - newMap.put(CmisOutputConfig.CREATE_TIMESTAMP_TREE_PARAM, createTimestampTree); - } - - /** - * View specification. This method is called in the body section of a job's - * view page. Its purpose is to present the document specification information - * to the user. The coder can presume that the HTML that is output from this - * configuration will be within appropriate and tags. The - * connector will be connected before this method can be called. - * - * @param out - * is the output to which any HTML should be sent. - * @param locale - * is the locale the output is preferred to be in. - * @param ds - * is the current document specification for this job. - * @param connectionSequenceNumber - * is the unique number of this connection within the job. - */ - @Override - public void viewSpecification(IHTTPOutput out, Locale locale, Specification ds, int connectionSequenceNumber) - throws ManifoldCFException, IOException { - - Map paramMap = new HashMap(); - paramMap.put("SeqNum", Integer.toString(connectionSequenceNumber)); - - // Fill in the map with data from all tabs - fillInCMISQuerySpecificationMap(paramMap, ds); - - outputResource(VIEW_SPEC_FORWARD, out, locale, paramMap); - } - - /** - * Process a specification post. This method is called at the start of job's - * edit or view page, whenever there is a possibility that form data for a - * connection has been posted. Its purpose is to gather form information and - * modify the document specification accordingly. The name of the posted form - * is always "editjob". The connector will be connected before this method can - * be called. - * - * @param variableContext - * contains the post data, including binary file-upload information. - * @param locale - * is the locale the output is preferred to be in. - * @param ds - * is the current document specification for this job. - * @param connectionSequenceNumber - * is the unique number of this connection within the job. - * @return null if all is well, or a string error message if there is an error - * that should prevent saving of the job (and cause a redirection to - * an error page). - */ - @Override - public String processSpecificationPost(IPostParameters variableContext, Locale locale, Specification ds, - int connectionSequenceNumber) throws ManifoldCFException { - String seqPrefix = "s" + connectionSequenceNumber + "_"; - - String cmisQuery = variableContext.getParameter(seqPrefix + CmisOutputConfig.CMIS_QUERY_PARAM); - String createTimestampTree = variableContext.getParameter(seqPrefix + CmisOutputConfig.CREATE_TIMESTAMP_TREE_PARAM); - if (cmisQuery != null) { - int i = 0; - while (i < ds.getChildCount()) { - SpecificationNode oldNode = ds.getChild(i); - if (oldNode.getType().equals(JOB_STARTPOINT_NODE_TYPE)) { - ds.removeChild(i); - break; - } - i++; - } - SpecificationNode node = new SpecificationNode(JOB_STARTPOINT_NODE_TYPE); - - //cmisQuery - node.setAttribute(CmisOutputConfig.CMIS_QUERY_PARAM, cmisQuery); - variableContext.setParameter(CmisOutputConfig.CMIS_QUERY_PARAM, cmisQuery); - - //createTimestampTree - node.setAttribute(CmisOutputConfig.CREATE_TIMESTAMP_TREE_PARAM, createTimestampTree); - variableContext.setParameter(CmisOutputConfig.CREATE_TIMESTAMP_TREE_PARAM, createTimestampTree); - - ds.addChild(ds.getChildCount(), node); - - this.cmisQuery = cmisQuery; - this.createTimestampTree = Boolean.valueOf(createTimestampTree); - } - return null; - } - - /** - * Output the specification body section. This method is called in the body - * section of a job page which has selected a repository connection of the - * current type. Its purpose is to present the required form elements for - * editing. The coder can presume that the HTML that is output from this - * configuration will be within appropriate , , and
tags. - * The name of the form is always "editjob". The connector will be connected - * before this method can be called. - * - * @param out - * is the output to which any HTML should be sent. - * @param locale - * is the locale the output is preferred to be in. - * @param ds - * is the current document specification for this job. - * @param connectionSequenceNumber - * is the unique number of this connection within the job. - * @param actualSequenceNumber - * is the connection within the job that has currently been selected. - * @param tabName - * is the current tab name. (actualSequenceNumber, tabName) form a - * unique tuple within the job. - */ - @Override - public void outputSpecificationBody(IHTTPOutput out, Locale locale, Specification ds, int connectionSequenceNumber, - int actualSequenceNumber, String tabName) throws ManifoldCFException, IOException { - - // Output CMISQuery tab - Map paramMap = new HashMap(); - paramMap.put("TabName", tabName); - paramMap.put("SeqNum", Integer.toString(connectionSequenceNumber)); - paramMap.put("SelectedNum", Integer.toString(actualSequenceNumber)); - - fillInCMISQuerySpecificationMap(paramMap, ds); - outputResource(EDIT_SPEC_FORWARD_CMISQUERY, out, locale, paramMap); - } - - /** - * Output the specification header section. This method is called in the head - * section of a job page which has selected a repository connection of the - * current type. Its purpose is to add the required tabs to the list, and to - * output any javascript methods that might be needed by the job editing HTML. - * The connector will be connected before this method can be called. - * - * @param out - * is the output to which any HTML should be sent. - * @param locale - * is the locale the output is preferred to be in. - * @param ds - * is the current document specification for this job. - * @param connectionSequenceNumber - * is the unique number of this connection within the job. - * @param tabsArray - * is an array of tab names. Add to this array any tab names that are - * specific to the connector. - */ - @Override - public void outputSpecificationHeader(IHTTPOutput out, Locale locale, Specification ds, int connectionSequenceNumber, - List tabsArray) throws ManifoldCFException, IOException { - tabsArray.add(Messages.getString(locale, CMIS_QUERY_TAB_PROPERTY)); - - Map paramMap = new HashMap(); - paramMap.put("SeqNum", Integer.toString(connectionSequenceNumber)); - - // Fill in the specification header map, using data from all tabs. - fillInCMISQuerySpecificationMap(paramMap, ds); - - outputResource(EDIT_SPEC_HEADER_FORWARD, out, locale, paramMap); - } - protected static void handleIOException(IOException e, String context) throws ManifoldCFException, ServiceInterruption { if (e instanceof InterruptedIOException) { @@ -1035,6 +858,7 @@ public class CmisOutputConnector extends } return false; } + @Override public int addOrReplaceDocumentWithException(String documentURI, VersionContext pipelineDescription, @@ -1042,15 +866,19 @@ public class CmisOutputConnector extends throws ManifoldCFException, ServiceInterruption, IOException { getSession(); + boolean isDropZoneFolder = isDropZoneFolder(cmisQuery); long startTime = System.currentTimeMillis(); Document injectedDocument = null; String resultDescription = StringUtils.EMPTY; + Folder leafParent = null; + String fileName = StringUtils.EMPTY; + ContentStream contentStream = null; try { if (isDropZoneFolder) { // Creation of the new Repository Node - String fileName = document.getFileName(); + fileName = document.getFileName(); Date creationDate = document.getCreatedDate(); Date lastModificationDate = document.getModifiedDate(); String mimeType = document.getMimeType(); @@ -1075,11 +903,11 @@ public class CmisOutputConnector extends // Content Stream InputStream inputStream = document.getBinaryStream(); - ContentStream contentStream = new ContentStreamImpl(fileName, BigInteger.valueOf(binaryLength), mimeType, + contentStream = new ContentStreamImpl(fileName, BigInteger.valueOf(binaryLength), mimeType, inputStream); // create a major version - Folder leafParent = getOrCreateLeafParent(parentDropZoneFolder, creationDate, false); + leafParent = getOrCreateLeafParent(parentDropZoneFolder, creationDate, false); injectedDocument = leafParent.createDocument(properties, contentStream, VersioningState.MAJOR); resultDescription = DOCUMENT_STATUS_ACCEPTED_DESC; return DOCUMENT_STATUS_ACCEPTED; @@ -1089,6 +917,18 @@ public class CmisOutputConnector extends return DOCUMENT_STATUS_REJECTED; } + } catch (CmisContentAlreadyExistsException e) { + + String documentFullPath = leafParent.getPath() + CmisOutputConnectorUtils.SLASH + fileName; + injectedDocument = (Document) session.getObjectByPath(documentFullPath); + injectedDocument.setContentStream(contentStream, true); + + Logging.connectors.warn( + "CMIS: Document already exists: " + documentFullPath+ CmisOutputConnectorUtils.SEP + e.getMessage(), e); + + resultDescription = DOCUMENT_STATUS_ACCEPTED_DESC; + return DOCUMENT_STATUS_ACCEPTED; + } catch (Exception e) { resultDescription = DOCUMENT_STATUS_REJECTED_DESC; throw new ManifoldCFException(e.getMessage(), e); Modified: manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConnectorUtils.java URL: http://svn.apache.org/viewvc/manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConnectorUtils.java?rev=1799512&r1=1799511&r2=1799512&view=diff ============================================================================== --- manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConnectorUtils.java (original) +++ manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/CmisOutputConnectorUtils.java Wed Jun 21 20:53:30 2017 @@ -48,13 +48,14 @@ public class CmisOutputConnectorUtils { private static final String LOAD_LINK_METHOD_NAME = "loadLink"; private static final String FROM_TOKEN = "from"; - private static final String SEP = " "; + public static final String SEP = " "; private static final String SELECT_STAR_CLAUSE = "select *"; private static final String OBJECT_ID_PROPERTY = "cmis:objectId"; private static final String OBJECT_ID_TERM = OBJECT_ID_PROPERTY + ","; private static final String SELECT_CLAUSE_TERM_SEP = ","; private static final String SELECT_PREFIX = "select "; private final static String TOKENIZER_SEP = ",\n\t"; + public static final String SLASH = "/"; public static final String getDocumentURL(final Document document, final Session session) throws ManifoldCFException { Modified: manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/Messages.java URL: http://svn.apache.org/viewvc/manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/Messages.java?rev=1799512&r1=1799511&r2=1799512&view=diff ============================================================================== --- manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/Messages.java (original) +++ manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/java/org/apache/manifoldcf/agents/output/cmisoutput/Messages.java Wed Jun 21 20:53:30 2017 @@ -25,8 +25,8 @@ import org.apache.manifoldcf.core.interf public class Messages extends org.apache.manifoldcf.ui.i18n.Messages { - public static final String DEFAULT_BUNDLE_NAME="org.apache.manifoldcf.crawler.connectors.cmisoutput.common"; - public static final String DEFAULT_PATH_NAME="org.apache.manifoldcf.crawler.connectors.cmisoutput"; + public static final String DEFAULT_BUNDLE_NAME="org.apache.manifoldcf.agents.output.cmisoutput.common"; + public static final String DEFAULT_PATH_NAME="org.apache.manifoldcf.agents.output.cmisoutput"; /** Constructor - do no instantiate */ Modified: manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/cmisoutput/common_en_US.properties URL: http://svn.apache.org/viewvc/manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/cmisoutput/common_en_US.properties?rev=1799512&r1=1799511&r2=1799512&view=diff ============================================================================== --- manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/cmisoutput/common_en_US.properties (original) +++ manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/native2ascii/org/apache/manifoldcf/agents/output/cmisoutput/common_en_US.properties Wed Jun 21 20:53:30 2017 @@ -36,7 +36,7 @@ CmisOutputConnector.PathMustNotBeNull=Pa CmisOutputConnector.CMISQuery=CMIS Query -CmisOutputConnector.CMISQueryColon=CMIS Query: +CmisOutputConnector.CMISQueryColon=CMIS Query - Target folder: CmisOutputConnector.CreateTimestampTreeColon=Create Timestamp Tree: CmisOutputConnector.ParametersColon=Parameters: Modified: manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/editConfiguration.js URL: http://svn.apache.org/viewvc/manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/editConfiguration.js?rev=1799512&r1=1799511&r2=1799512&view=diff ============================================================================== --- manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/editConfiguration.js (original) +++ manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/editConfiguration.js Wed Jun 21 20:53:30 2017 @@ -76,6 +76,12 @@ function checkConfigForSave() editconnection.path.focus(); return false; } + if(editconnection.cmisQuery.value == ""){ + alert("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('CmisOutputConnector.CMISQueryMustNotBeNull'))"); + SelectTab("$Encoder.bodyJavascriptEscape($ResourceBundle.getString('CmisOutputConnector.Server'))"); + editconnection.cmisQuery.focus(); + return false; + } return true; } //--> Modified: manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/editConfiguration_Server.html URL: http://svn.apache.org/viewvc/manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/editConfiguration_Server.html?rev=1799512&r1=1799511&r2=1799512&view=diff ============================================================================== --- manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/editConfiguration_Server.html (original) +++ manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/editConfiguration_Server.html Wed Jun 21 20:53:30 2017 @@ -112,6 +112,16 @@ + $Encoder.bodyEscape($ResourceBundle.getString('CmisOutputConnector.CMISQueryColon')) + + + + + + + + + $Encoder.bodyEscape($ResourceBundle.getString('CmisOutputConnector.RepositoryIDColon')) @@ -133,6 +143,7 @@ + #end Modified: manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/viewConfiguration.html URL: http://svn.apache.org/viewvc/manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/viewConfiguration.html?rev=1799512&r1=1799511&r2=1799512&view=diff ============================================================================== --- manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/viewConfiguration.html (original) +++ manifoldcf/branches/CONNECTORS-1356/connectors/cmis/connector/src/main/resources/org/apache/manifoldcf/agents/output/cmisoutput/viewConfiguration.html Wed Jun 21 20:53:30 2017 @@ -52,6 +52,10 @@
+ $Encoder.bodyEscape($ResourceBundle.getString('CmisOutputConnector.CMISQueryEquals'))$Encoder.bodyEscape($CMISQUERY) + +
+ $Encoder.bodyEscape($ResourceBundle.getString('CmisOutputConnector.RepositoryIdEquals'))$Encoder.bodyEscape($REPOSITORYID)