Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordonald.g.dunne2016-09-08 18:45:40 -0400
committerdonald.g.dunne2016-09-13 11:26:21 -0400
commita8d3649c5c8a376c4aa06702ab4e0020348c781d (patch)
tree6156841e702f9c9184a91c110a0dfec9eb62f84e
parent253868a3571e19665795215c1ebafc151740cdfd (diff)
downloadorg.eclipse.osee-a8d3649c5c8a376c4aa06702ab4e0020348c781d.tar.gz
org.eclipse.osee-a8d3649c5c8a376c4aa06702ab4e0020348c781d.tar.xz
org.eclipse.osee-a8d3649c5c8a376c4aa06702ab4e0020348c781d.zip
bug[ats_ATS303551]: NR Alpha - ATS Search is slower in Beta
-rw-r--r--plugins/org.eclipse.osee.ats.api/src/org/eclipse/osee/ats/api/workflow/IAtsTask.java4
-rw-r--r--plugins/org.eclipse.osee.ats.client.integration.tests/src/org/eclipse/osee/ats/client/integration/tests/ats/actions/OpenNewAtsTaskEditorActionTest.java5
-rw-r--r--plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/config/AtsBulkLoad.java41
-rw-r--r--plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/internal/query/AtsQueryImpl.java3
-rw-r--r--plugins/org.eclipse.osee.ats.core/src/org/eclipse/osee/ats/core/query/AbstractAtsQueryImpl.java15
-rw-r--r--plugins/org.eclipse.osee.ats.rest/src/org/eclipse/osee/ats/rest/internal/query/AtsQueryImpl.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/task/ITaskEditorProvider.java5
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/task/TaskEditorSimpleProvider.java5
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/IWorldEditorProvider.java7
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorProvider.java58
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorReloadProvider.java8
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorSimpleProvider.java13
12 files changed, 79 insertions, 87 deletions
diff --git a/plugins/org.eclipse.osee.ats.api/src/org/eclipse/osee/ats/api/workflow/IAtsTask.java b/plugins/org.eclipse.osee.ats.api/src/org/eclipse/osee/ats/api/workflow/IAtsTask.java
index 6dd0e44187d..53feb568ea7 100644
--- a/plugins/org.eclipse.osee.ats.api/src/org/eclipse/osee/ats/api/workflow/IAtsTask.java
+++ b/plugins/org.eclipse.osee.ats.api/src/org/eclipse/osee/ats/api/workflow/IAtsTask.java
@@ -17,5 +17,7 @@ import org.eclipse.osee.ats.api.IAtsWorkItem;
*/
public interface IAtsTask extends IAtsWorkItem {
- // do nothing
+ public static boolean isOfType(Object object) {
+ return object instanceof IAtsTask;
+ }
}
diff --git a/plugins/org.eclipse.osee.ats.client.integration.tests/src/org/eclipse/osee/ats/client/integration/tests/ats/actions/OpenNewAtsTaskEditorActionTest.java b/plugins/org.eclipse.osee.ats.client.integration.tests/src/org/eclipse/osee/ats/client/integration/tests/ats/actions/OpenNewAtsTaskEditorActionTest.java
index 642974c5625..149d4f14350 100644
--- a/plugins/org.eclipse.osee.ats.client.integration.tests/src/org/eclipse/osee/ats/client/integration/tests/ats/actions/OpenNewAtsTaskEditorActionTest.java
+++ b/plugins/org.eclipse.osee.ats.client.integration.tests/src/org/eclipse/osee/ats/client/integration/tests/ats/actions/OpenNewAtsTaskEditorActionTest.java
@@ -77,11 +77,6 @@ public class OpenNewAtsTaskEditorActionTest extends AbstractAtsActionRunTest {
}
@Override
- public Collection<? extends Artifact> getTaskEditorTaskArtifacts() throws OseeCoreException {
- return null;
- }
-
- @Override
public String getTaskEditorLabel(SearchType searchType) {
return null;
}
diff --git a/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/config/AtsBulkLoad.java b/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/config/AtsBulkLoad.java
index 90bdfa0abe2..340adc628ef 100644
--- a/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/config/AtsBulkLoad.java
+++ b/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/config/AtsBulkLoad.java
@@ -12,17 +12,17 @@ package org.eclipse.osee.ats.core.client.config;
import java.util.ArrayList;
import java.util.Collection;
+import java.util.HashSet;
import java.util.List;
import java.util.Set;
import java.util.concurrent.atomic.AtomicBoolean;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.osee.ats.api.data.AtsRelationTypes;
-import org.eclipse.osee.ats.core.client.action.ActionArtifact;
+import org.eclipse.osee.ats.api.workflow.IAtsAction;
+import org.eclipse.osee.ats.api.workflow.IAtsTask;
+import org.eclipse.osee.ats.api.workflow.IAtsTeamWorkflow;
import org.eclipse.osee.ats.core.client.internal.Activator;
import org.eclipse.osee.ats.core.client.internal.AtsClientService;
-import org.eclipse.osee.ats.core.client.review.AtsReviewCache;
-import org.eclipse.osee.ats.core.client.team.TeamWorkFlowArtifact;
-import org.eclipse.osee.ats.core.client.util.AtsTaskCache;
import org.eclipse.osee.framework.core.operation.AbstractOperation;
import org.eclipse.osee.framework.core.operation.IOperation;
import org.eclipse.osee.framework.core.operation.Operations;
@@ -65,26 +65,31 @@ public class AtsBulkLoad {
public static Set<Artifact> bulkLoadArtifacts(Collection<? extends Artifact> artifacts) throws OseeCoreException {
List<Artifact> actions = new ArrayList<>();
List<Artifact> teams = new ArrayList<>();
+ List<Artifact> tasks = new ArrayList<>();
for (Artifact art : artifacts) {
- if (art instanceof ActionArtifact) {
+ if (IAtsAction.isOfType(art)) {
actions.add(art);
- } else if (art instanceof TeamWorkFlowArtifact) {
+ } else if (IAtsTeamWorkflow.isOfType(art)) {
teams.add(art);
+ } else if (IAtsTask.isOfType(art)) {
+ tasks.add(art);
}
}
- Set<Artifact> arts = RelationManager.getRelatedArtifacts(actions, 3, AtsRelationTypes.TeamWfToTask_Task,
- AtsRelationTypes.TeamWorkflowToReview_Review, AtsRelationTypes.ActionToWorkflow_Action);
- arts.addAll(RelationManager.getRelatedArtifacts(teams, 4, AtsRelationTypes.TeamWfToTask_Task,
- AtsRelationTypes.ActionToWorkflow_WorkFlow, AtsRelationTypes.TeamWorkflowToReview_Review));
- arts.addAll(artifacts);
- for (Artifact art : arts) {
- if (art instanceof TeamWorkFlowArtifact) {
- AtsTaskCache.getTaskArtifacts((TeamWorkFlowArtifact) art);
- }
- if (art instanceof TeamWorkFlowArtifact) {
- AtsReviewCache.getReviewArtifacts((TeamWorkFlowArtifact) art);
- }
+ Set<Artifact> arts = new HashSet<Artifact>();
+ if (!actions.isEmpty()) {
+ arts.addAll(RelationManager.getRelatedArtifacts(actions, 3, AtsRelationTypes.TeamWfToTask_Task,
+ AtsRelationTypes.TeamWorkflowToReview_Review, AtsRelationTypes.ActionToWorkflow_Action));
}
+ if (!teams.isEmpty()) {
+ arts.addAll(RelationManager.getRelatedArtifacts(teams, 4, AtsRelationTypes.TeamWfToTask_Task,
+ AtsRelationTypes.ActionToWorkflow_WorkFlow, AtsRelationTypes.TeamWorkflowToReview_Review));
+ }
+ if (!tasks.isEmpty()) {
+ arts.addAll(RelationManager.getRelatedArtifacts(tasks, 2, AtsRelationTypes.TeamWfToTask_TeamWf,
+ AtsRelationTypes.ActionToWorkflow_WorkFlow));
+ }
+ arts.addAll(artifacts);
+ System.err.println("bulk loaded " + arts.size());
return arts;
}
}
diff --git a/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/internal/query/AtsQueryImpl.java b/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/internal/query/AtsQueryImpl.java
index 053ef21c032..6a0897704cf 100644
--- a/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/internal/query/AtsQueryImpl.java
+++ b/plugins/org.eclipse.osee.ats.core.client/src/org/eclipse/osee/ats/core/client/internal/query/AtsQueryImpl.java
@@ -27,7 +27,6 @@ import org.eclipse.osee.framework.core.data.IArtifactType;
import org.eclipse.osee.framework.core.data.IAttributeType;
import org.eclipse.osee.framework.core.data.IRelationTypeSide;
import org.eclipse.osee.framework.core.enums.QueryOption;
-import org.eclipse.osee.framework.jdk.core.util.ElapsedTime;
import org.eclipse.osee.framework.skynet.core.artifact.Artifact;
import org.eclipse.osee.framework.skynet.core.artifact.search.ArtifactQuery;
import org.eclipse.osee.framework.skynet.core.artifact.search.QueryBuilderArtifact;
@@ -74,7 +73,7 @@ public class AtsQueryImpl extends AbstractAtsQueryImpl {
}
@Override
- public void queryAndIsOfType(List<IArtifactType> artTypes) {
+ public void queryAndIsOfType(Collection<IArtifactType> artTypes) {
query.andIsOfType(artTypes);
}
diff --git a/plugins/org.eclipse.osee.ats.core/src/org/eclipse/osee/ats/core/query/AbstractAtsQueryImpl.java b/plugins/org.eclipse.osee.ats.core/src/org/eclipse/osee/ats/core/query/AbstractAtsQueryImpl.java
index bed73151749..4638e3fe8b7 100644
--- a/plugins/org.eclipse.osee.ats.core/src/org/eclipse/osee/ats/core/query/AbstractAtsQueryImpl.java
+++ b/plugins/org.eclipse.osee.ats.core/src/org/eclipse/osee/ats/core/query/AbstractAtsQueryImpl.java
@@ -114,6 +114,9 @@ public abstract class AbstractAtsQueryImpl implements IAtsQuery {
if (!teamWorkflowArtTypes.isEmpty()) {
teamWfs = getTeamWorkflows(teamWorkflowArtTypes, allResults, allArtTypes);
}
+ if (allArtTypes.contains(AtsArtifactTypes.AbstractWorkflowArtifact)) {
+ teamWfs = getTeamWorkflows(allArtTypes, allResults, allArtTypes);
+ }
/**
* If team workflow's searched by Team Definition, Actionable Item or Version were searched, then the child tasks
@@ -367,7 +370,7 @@ public abstract class AbstractAtsQueryImpl implements IAtsQuery {
}
}
- private <T extends IAtsWorkItem> Collection<T> getTeamWorkflows(List<IArtifactType> teamWorkflowArtTypes, Set<T> allResults, Set<IArtifactType> allArtTypes) {
+ private <T extends IAtsWorkItem> Collection<T> getTeamWorkflows(Collection<IArtifactType> teamWorkflowArtTypes, Set<T> allResults, Set<IArtifactType> allArtTypes) {
createQueryBuilder();
getBaseSearchCriteria(teamWorkflowArtTypes, true, allArtTypes);
@@ -422,7 +425,7 @@ public abstract class AbstractAtsQueryImpl implements IAtsQuery {
public abstract void createQueryBuilder();
- public abstract void queryAndIsOfType(IArtifactType teamworkflow);
+ public abstract void queryAndIsOfType(IArtifactType artifactType);
public boolean isOnlyIds() {
return onlyIds != null;
@@ -448,9 +451,7 @@ public abstract class AbstractAtsQueryImpl implements IAtsQuery {
private List<IArtifactType> getTeamWorkflowArtTypes(Set<IArtifactType> allArtTypes) {
List<IArtifactType> teamWorkflowArtTypes = new LinkedList<>();
for (IArtifactType artType : allArtTypes) {
- if (services.getArtifactResolver().inheritsFrom(artType,
- AtsArtifactTypes.TeamWorkflow) || services.getArtifactResolver().inheritsFrom(artType,
- AtsArtifactTypes.AbstractWorkflowArtifact)) {
+ if (services.getArtifactResolver().inheritsFrom(artType, AtsArtifactTypes.TeamWorkflow)) {
teamWorkflowArtTypes.add(artType);
}
}
@@ -732,7 +733,7 @@ public abstract class AbstractAtsQueryImpl implements IAtsQuery {
return guid;
}
- private void getBaseSearchCriteria(List<IArtifactType> artTypes, boolean withUuids, Set<IArtifactType> allArtTypes) {
+ private void getBaseSearchCriteria(Collection<IArtifactType> artTypes, boolean withUuids, Set<IArtifactType> allArtTypes) {
createQueryBuilder();
/**
@@ -751,7 +752,7 @@ public abstract class AbstractAtsQueryImpl implements IAtsQuery {
addStateTypeNameAndAttributeCriteria();
}
- public abstract void queryAndIsOfType(List<IArtifactType> artTypes);
+ public abstract void queryAndIsOfType(Collection<IArtifactType> artTypes);
/**
* Color Team is handled through workpackage, insertion, activity and program if specified. Otherwise, use color team
diff --git a/plugins/org.eclipse.osee.ats.rest/src/org/eclipse/osee/ats/rest/internal/query/AtsQueryImpl.java b/plugins/org.eclipse.osee.ats.rest/src/org/eclipse/osee/ats/rest/internal/query/AtsQueryImpl.java
index d44c9798f62..5a9c8bcbe75 100644
--- a/plugins/org.eclipse.osee.ats.rest/src/org/eclipse/osee/ats/rest/internal/query/AtsQueryImpl.java
+++ b/plugins/org.eclipse.osee.ats.rest/src/org/eclipse/osee/ats/rest/internal/query/AtsQueryImpl.java
@@ -80,7 +80,7 @@ public class AtsQueryImpl extends AbstractAtsQueryImpl {
}
@Override
- public void queryAndIsOfType(List<IArtifactType> artTypes) {
+ public void queryAndIsOfType(Collection<IArtifactType> artTypes) {
query.andIsOfType(artTypes);
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/task/ITaskEditorProvider.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/task/ITaskEditorProvider.java
index e7a1b8bbf9c..eeecc243f0f 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/task/ITaskEditorProvider.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/task/ITaskEditorProvider.java
@@ -5,16 +5,11 @@
*/
package org.eclipse.osee.ats.task;
-import java.util.Collection;
import org.eclipse.osee.ats.world.IWorldEditorProvider;
import org.eclipse.osee.ats.world.search.WorldSearchItem.SearchType;
-import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
-import org.eclipse.osee.framework.skynet.core.artifact.Artifact;
public interface ITaskEditorProvider extends IWorldEditorProvider {
- Collection<? extends Artifact> getTaskEditorTaskArtifacts() throws OseeCoreException;
-
String getTaskEditorLabel(SearchType searchType);
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/task/TaskEditorSimpleProvider.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/task/TaskEditorSimpleProvider.java
index 3975983a086..597efd319f0 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/task/TaskEditorSimpleProvider.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/task/TaskEditorSimpleProvider.java
@@ -62,11 +62,6 @@ public class TaskEditorSimpleProvider extends TaskEditorProvider {
}
@Override
- public Collection<? extends Artifact> getTaskEditorTaskArtifacts() throws OseeCoreException {
- return artifacts;
- }
-
- @Override
public String getTaskEditorLabel(SearchType searchType) {
return "Tasks";
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/IWorldEditorProvider.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/IWorldEditorProvider.java
index a613ccdc5a0..7ad82c15ba5 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/IWorldEditorProvider.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/IWorldEditorProvider.java
@@ -24,6 +24,9 @@ import org.eclipse.osee.framework.ui.plugin.xnavigate.XNavigateComposite.TableLo
*/
public interface IWorldEditorProvider {
+ /**
+ * Called to start the process of search and load.
+ */
public void run(WorldEditor worldEditor, SearchType searchType, boolean forcePend) throws OseeCoreException;
public String getSelectedName(SearchType searchType) throws OseeCoreException;
@@ -38,6 +41,10 @@ public interface IWorldEditorProvider {
public void setTableLoadOptions(TableLoadOption... tableLoadOptions);
+ /**
+ * Called in background during run process to perform the search. Implementers should perform new searches of the
+ * objects so they get loaded fresh. At this point, any items have already been de-cached.
+ */
Collection<Artifact> performSearch(SearchType searchType);
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorProvider.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorProvider.java
index b8dd75d9c6c..f7d066e5e9d 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorProvider.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorProvider.java
@@ -25,13 +25,14 @@ import org.eclipse.osee.framework.jdk.core.util.Collections;
import org.eclipse.osee.framework.jdk.core.util.Strings;
import org.eclipse.osee.framework.logging.OseeLog;
import org.eclipse.osee.framework.skynet.core.artifact.Artifact;
-import org.eclipse.osee.framework.skynet.core.artifact.search.ArtifactQuery;
+import org.eclipse.osee.framework.skynet.core.artifact.ArtifactCache;
import org.eclipse.osee.framework.ui.plugin.util.AWorkbench;
import org.eclipse.osee.framework.ui.plugin.xnavigate.XNavigateComposite.TableLoadOption;
import org.eclipse.osee.framework.ui.swt.CursorManager;
import org.eclipse.osee.framework.ui.swt.Displays;
import org.eclipse.osee.framework.ui.swt.Widgets;
import org.eclipse.swt.SWT;
+import org.eclipse.swt.widgets.TreeItem;
/**
* @author Donald G. Dunne
@@ -80,6 +81,11 @@ public abstract class WorldEditorProvider implements IWorldEditorProvider {
return;
}
+ // De-cache any object so they will be reloaded during search
+ for (TreeItem item : worldEditor.getWorldComposite().getXViewer().getVisibleItems()) {
+ ArtifactCache.deCache((Artifact) item.getData());
+ }
+
LoadTableJob job = null;
job = new LoadTableJob(worldEditor, this, searchType, tableLoadOptions, pend);
job.setUser(false);
@@ -124,8 +130,10 @@ public abstract class WorldEditorProvider implements IWorldEditorProvider {
selectedName = worldEditorProvider.getSelectedName(searchType);
worldEditor.setEditorTitle(selectedName != null ? selectedName : worldEditorProvider.getName());
worldEditor.setTableTitle("Loading \"" + (selectedName != null ? selectedName : "") + "\"...", false);
+
worldEditor.getWorldComposite().getXViewer().clear(forcePend);
+ // This will re-perform the search and since items are not cached, will load fresh
Collection<Artifact> artifacts = performSearch(searchType);
if (cancel) {
@@ -139,17 +147,14 @@ public abstract class WorldEditorProvider implements IWorldEditorProvider {
return Status.OK_STATUS;
}
- if (searchType == SearchType.ReSearch) {
- reload(worldEditor, selectedName, forcePend, artifacts);
- } else {
- Artifact expandToArtifact = null;
- if (worldEditorProvider instanceof WorldEditorSimpleProvider) {
- WorldEditorSimpleProvider provider = (WorldEditorSimpleProvider) worldEditorProvider;
- expandToArtifact = provider.getExpandToArtifact();
- }
- worldEditor.getWorldComposite().load(selectedName != null ? selectedName : "", artifacts, customizeData,
- expandToArtifact, tableLoadOptions);
+ Artifact expandToArtifact = null;
+ if (worldEditorProvider instanceof WorldEditorSimpleProvider) {
+ WorldEditorSimpleProvider provider = (WorldEditorSimpleProvider) worldEditorProvider;
+ expandToArtifact = provider.getExpandToArtifact();
}
+ worldEditor.getWorldComposite().load(selectedName != null ? selectedName : "", artifacts, customizeData,
+ expandToArtifact, tableLoadOptions);
+
} catch (final Exception ex) {
String str = "Exception occurred.";
if (Strings.isValid(ex.getLocalizedMessage())) {
@@ -167,37 +172,6 @@ public abstract class WorldEditorProvider implements IWorldEditorProvider {
}
}
- /**
- * Background job to reload artifacts and then reload viewer
- */
- public void reload(WorldEditor worldEditor, String name, boolean forcePend, Collection<Artifact> artifacts) {
-
- if (forcePend) {
- reload(worldEditor, name, artifacts);
- } else {
- Job job = new Job("Loading " + name) {
-
- @Override
- protected IStatus run(IProgressMonitor monitor) {
- reload(worldEditor, name, artifacts);
- return Status.OK_STATUS;
- }
-
- };
- job.setSystem(false);
- job.schedule();
- }
- }
-
- /**
- * Reload artifacts and then reload viewer
- */
- private void reload(WorldEditor worldEditor, String name, Collection<Artifact> artifacts) {
- ArtifactQuery.reloadArtifacts(artifacts);
- worldEditor.getWorldComposite().load(name != null ? name : "", artifacts, customizeData);
-
- }
-
public void setLoading(final boolean loading) {
this.loading = loading;
Displays.ensureInDisplayThread(new Runnable() {
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorReloadProvider.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorReloadProvider.java
index 8d4a20bc5eb..a4d31cab2b2 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorReloadProvider.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorReloadProvider.java
@@ -12,6 +12,7 @@ package org.eclipse.osee.ats.world;
import java.util.ArrayList;
import java.util.Collection;
+import java.util.LinkedList;
import java.util.List;
import org.eclipse.nebula.widgets.xviewer.core.model.CustomizeData;
import org.eclipse.osee.ats.core.client.config.AtsBulkLoad;
@@ -94,6 +95,13 @@ public class WorldEditorReloadProvider extends WorldEditorProvider {
@Override
public Collection<Artifact> performSearch(SearchType searchType) {
+ if (searchType == SearchType.ReSearch) {
+ List<Integer> ids = new LinkedList<>();
+ for (Artifact art : artifacts) {
+ ids.add(art.getArtId());
+ }
+ artifacts = ArtifactQuery.getArtifactListFromIds(ids, AtsUtilCore.getAtsBranch());
+ }
return artifacts;
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorSimpleProvider.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorSimpleProvider.java
index 254c75682b1..6b2ae18f209 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorSimpleProvider.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/WorldEditorSimpleProvider.java
@@ -11,10 +11,14 @@
package org.eclipse.osee.ats.world;
import java.util.Collection;
+import java.util.LinkedList;
+import java.util.List;
import org.eclipse.nebula.widgets.xviewer.core.model.CustomizeData;
+import org.eclipse.osee.ats.core.util.AtsUtilCore;
import org.eclipse.osee.ats.world.search.WorldSearchItem.SearchType;
import org.eclipse.osee.framework.jdk.core.util.Collections;
import org.eclipse.osee.framework.skynet.core.artifact.Artifact;
+import org.eclipse.osee.framework.skynet.core.artifact.search.ArtifactQuery;
import org.eclipse.osee.framework.ui.plugin.xnavigate.XNavigateComposite.TableLoadOption;
/**
@@ -23,7 +27,7 @@ import org.eclipse.osee.framework.ui.plugin.xnavigate.XNavigateComposite.TableLo
public class WorldEditorSimpleProvider extends WorldEditorProvider {
private final String name;
- private final Collection<Artifact> artifacts;
+ private Collection<Artifact> artifacts;
private final Artifact expandToArtifact;
public WorldEditorSimpleProvider(String name, Collection<? extends Artifact> artifacts) {
@@ -60,6 +64,13 @@ public class WorldEditorSimpleProvider extends WorldEditorProvider {
@Override
public Collection<Artifact> performSearch(SearchType searchType) {
+ if (searchType == SearchType.ReSearch) {
+ List<Integer> ids = new LinkedList<>();
+ for (Artifact art : artifacts) {
+ ids.add(art.getArtId());
+ }
+ artifacts = ArtifactQuery.getArtifactListFromIds(ids, AtsUtilCore.getAtsBranch());
+ }
return artifacts;
}
}

Back to the top