Compare commits

...

5 Commits

Author SHA1 Message Date
zshen-talend
ad16819ab2 feat(TDQ-19814): clear the code let it call adjustPomGeneration only to (#7132)
avoid some TDM regression
2022-01-17 19:44:08 +08:00
Abdulhamid Rashankar
66259dab9d APPINT-33784: Project analysis task - Warn about custom component dependencies risk (#7130) 2022-01-17 12:41:53 +01:00
Zhiwei Xue
98d1ecb17d fix(TUP-34469):fix comp cache path problem (#7122) 2022-01-14 19:45:45 +08:00
zyuan-talend
34a161f480 fix(TUP-27184):revert javajet change. (#7116) 2022-01-14 19:20:49 +08:00
Jill Yan
60f13d44c4 Revert "jill/fix/m80/APPINT-33992 (#7071)" (#7121)
This reverts commit 4c48cc91b3.
2022-01-14 17:33:10 +08:00
8 changed files with 38 additions and 26 deletions

View File

@@ -90,8 +90,11 @@ if((codePart.equals(ECodePart.END))&&(stat || logstashCurrent)){
INode source = con.getSource();
String sourceNodeId = source.getUniqueName();
String sourceNodeLabel = NodeUtil.getLabel(source);
String targetNodeLabel = NodeUtil.getLabel(node);
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel.trim());
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel.trim());
String sourceNodeComponent = source.getComponent().getName();
for (INode jobStructureCatcher : jobCatcherNodes) {
@@ -121,8 +124,11 @@ if((codePart.equals(ECodePart.END))&&(stat || logstashCurrent)){
INode source = con.getSource();
String sourceNodeId = source.getUniqueName();
String sourceNodeLabel = NodeUtil.getLabel(source);
String targetNodeLabel = NodeUtil.getLabel(node);
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel.trim());
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel.trim());
String sourceNodeComponent = source.getComponent().getName();
for (INode jobStructureCatcher : jobCatcherNodes) {

View File

@@ -196,8 +196,11 @@
INode source = con.getSource();
String sourceNodeId = source.getUniqueName();
String sourceNodeLabel = NodeUtil.getLabel(source);
String targetNodeLabel = NodeUtil.getLabel(node);
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel.trim());
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel.trim());
String sourceNodeComponent = source.getComponent().getName();
%>
@@ -229,8 +232,11 @@
INode source = con.getSource();
String sourceNodeId = source.getUniqueName();
String sourceNodeLabel = NodeUtil.getLabel(source);
String targetNodeLabel = NodeUtil.getLabel(node);
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel.trim());
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel.trim());
String sourceNodeComponent = source.getComponent().getName();
%>
@@ -253,8 +259,11 @@
INode source = con.getSource();
String sourceNodeId = source.getUniqueName();
String sourceNodeLabel = NodeUtil.getLabel(source);
String targetNodeLabel = NodeUtil.getLabel(node);
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel.trim());
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel.trim());
String sourceNodeComponent = source.getComponent().getName();
@@ -286,8 +295,11 @@
INode source = con.getSource();
String sourceNodeId = source.getUniqueName();
String sourceNodeLabel = NodeUtil.getLabel(source);
String targetNodeLabel = NodeUtil.getLabel(node);
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel.trim());
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel.trim());
String sourceNodeComponent = source.getComponent().getName();
@@ -422,7 +434,8 @@
if(logstashCurrent) {
for (INode jobStructureCatcher : jobCatcherNodes) {
String nodeLabel = NodeUtil.getLabel(node);
String label = ElementParameterParser.getValue(node, "__LABEL__");
String nodeLabel = ((label==null || "__UNIQUE_NAME__".equals(label) || label.contains("\"")) ? node.getUniqueName() : label.trim());
%>
if(enableLogStash) {
<%=jobStructureCatcher.getUniqueName() %>.addCM("<%=node.getUniqueName()%>", "<%=nodeLabel%>", "<%=node.getComponent().getName()%>");

View File

@@ -8,7 +8,7 @@ import java.util.Set;
import org.talend.analysistask.AbstractItemAnalysisTask;
import org.talend.analysistask.AnalysisReportRecorder;
import org.talend.analysistask.AnalysisReportRecorder.SeverityOption;
import org.talend.core.i18n.Messages;
import org.talend.designer.core.i18n.Messages;
import org.talend.core.model.components.IComponent;
import org.talend.core.model.properties.Item;
import org.talend.core.model.repository.ERepositoryObjectType;

View File

@@ -430,7 +430,7 @@ public class EmfComponent extends AbstractBasicComponent {
@SuppressWarnings("unchecked")
private void load() throws BusinessException {
if (!isLoaded) {
File file = new File(ComponentBundleToPath.getPathFromBundle(bundleName) + uriString);
File file = new File((ComponentBundleToPath.getPathFromBundle(bundleName) + uriString).replaceAll("\\\\", "/")); //$NON-NLS-1$ //$NON-NLS-2$
URI createURI = URI.createURI(file.toURI().toString());
Resource res = getComponentResourceFactoryImpl().createResource(createURI);
try {

View File

@@ -148,8 +148,6 @@ public class JavaProcessUtil {
List<IClasspathAdjuster> classPathAdjusters = ClasspathAdjusterProvider.getClasspathAdjuster();
// add for TDQ-19814 to add a runtime dependency when generate code and get the module in the javajet
for (IClasspathAdjuster adjuster : classPathAdjusters) {
adjuster.initialize();
adjuster.collectInfo(process, modulesNeededSet);
modulesNeededSet = adjuster.adjustPomGeneration(process, modulesNeededSet);
}
return modulesNeededSet;

View File

@@ -14,7 +14,6 @@ NewRouteResourceWizardPage.nameInvalid=The specified Name is invalid, please che
NewRouteResourceWizardPage.sourceFile=Source File
NewRouteResourceWizardPage.update.title=Create Resource
NewRouteResourceWizardPage.itemAlreadyExist=This item name already exists. Please Check!
NewRouteResourceWizardPage.NameFormatError=Name contains incorrect characters.
EditRouteResourcePropertiesWizard_itemLocked=Item is locked by user
EditRouteResourcePropertiesWizard_title=Edit Properties
OpenAnotherVersionResrouceWizard.Title=Open another version

View File

@@ -12,7 +12,6 @@ NewRouteResourceWizardPage.nameEmpty=Name is empty.
NewRouteResourceWizardPage.nameInvalid=The specified Name is invalid, please check.
NewRouteResourceWizardPage.sourceFile=Source File
NewRouteResourceWizardPage.itemAlreadyExist=This item name already exists. Please Check!
NewRouteResourceWizardPage.NameFormatError=Name contains incorrect characters.
EditRouteResourcePropertiesWizard_itemLocked=Item is locked by user
EditRouteResourcePropertiesWizard_title=Edit Properties
OpenAnotherVersionResrouceWizard.Title=Open another version

View File

@@ -18,8 +18,9 @@ import java.net.URL;
import java.util.Collections;
import java.util.Date;
import java.util.List;
import java.util.regex.Pattern;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.swt.SWT;
@@ -40,7 +41,6 @@ import org.talend.core.model.repository.ERepositoryObjectType;
import org.talend.core.model.repository.IRepositoryViewObject;
import org.talend.metadata.managment.ui.wizard.AbstractNamedWizardPage;
import org.talend.metadata.managment.ui.wizard.PropertiesWizardPage;
import org.talend.repository.model.RepositoryConstants;
import org.talend.repository.resource.i18n.Messages;
/**
@@ -152,11 +152,8 @@ public class NewRouteResourceWizardPage extends PropertiesWizardPage {
String trimName = nameText.getText().trim();
//Check name is a valid file name
if (nameText.getText().length() == 0) {
nameStatus = createStatus(IStatus.ERROR, Messages.getString("NewRouteResourceWizardPage.nameEmpty")); //$NON-NLS-1$
} else if (!Pattern.matches(RepositoryConstants.getPattern(getRepositoryObjectType()), trimName)
|| trimName.contains(" ")) { //$NON-NLS-1$
nameStatus = createStatus(IStatus.ERROR, Messages.getString("NewRouteResourceWizardPage.NameFormatError"));
nameStatus = ResourcesPlugin.getWorkspace().validateName(trimName, IResource.FILE);
if(!nameStatus.isOK()){
updatePageStatus();
return;
} else {