You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by chandrika <ch...@gmail.com> on 2017/10/03 12:32:24 UTC

Re: Job Listeners

Hello Alexey,

Thanks for the valuable information, i hare tried executing a list of
dependent tasks using a DAG using session.setAttribute("COMPLETE",true), and
it is working fine as long as there are three nodes, cause there are 3 or
less parallel tasks to execute.

But when i run the same code of dependent tasks on a single node, then it
stops its execution after execution of few tasks in some time . There are no
exception as such. could u please let me know where i could have gone wrong.
Note : should i have to use waitForAttribute for the same if so could u
please guide me the usage of wiatForAttribute for completion of three
parallel tasks at every step.


thanks and regards,
chandrika



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Job Listeners

Posted by Alexey Kukushkin <ku...@gmail.com>.
Hi Chandrika,

I cannot reproduce the problem with the code you provided. I created a
public GIT repo with your code from the previous post and suggest this:

   1. You clone the repo: git clone
   https://github.com/kukushal/ignite-userlist-joblisteners.git
   2. Try to reproduce the problem with the code from the repo. If you can
   - let me know. To me that code runs only 2 tasks (12 and 11) and then
   finishes without any deadlocks on any number of nodes (I tried 1, 2, 3, 4
   and 5 nodes)
   3. If you cannot reproduce the problem, please check how your code is
   different. Please give me your github ID and I will add you as a
   collaborator. You modify the code to make sure it reproduce the problem and
   commit it to GIT.
   4. I will get your code and investigate.

Re: Job Listeners

Posted by chandrika <ch...@gmail.com>.
Hello Alexey,

could u please guide me with the above post . Thanks.




--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Job Listeners

Posted by chandrika <ch...@gmail.com>.
Hello Alexey,


on single node it is working fine till the job 8, from job7 there is no
execution as given in the below console logs: jobs getting executed are 12,
1, 11, 3, 2, 13, 9, 8..after that the jobs 7,4,5,6,10 are never getting
executed.




****************************executed the job **********  
12******15:59:11:012
incoming edgeeeeeeeeeeeeeeeeeeeeeeeeee******15:59:11:028
sourceVertex  incomingEdge is root******15:59:11:030
targetVertex incomingEdge is 1******15:59:11:035
15:59:11.038
[QuartzScheduler_DistributedNewScheduler123456-DESKTOP-DDN7SUT1507890505772_ClusterManager]
DEBUG org.quartz.impl.jdbcjobstore.JobStoreTX - ClusterManager: Check-in
complete.
outgoing edge(1 : 2) 15:59:11:048
sourceVertex is 1 15:59:11:049
targetVertex is 2 15:59:11:049
outgoing edge(1 : 3) 15:59:11:049
sourceVertex is 1 15:59:11:049
targetVertex is 3 15:59:11:049
****************************executed the job **********  
1******15:59:11:062
****************************executed the job **********  
11******15:59:11:091
****************************executed the job **********  
3******15:59:19:066
incoming edgeeeeeeeeeeeeeeeeeeeeeeeeee******15:59:19:079
sourceVertex  incomingEdge is root******15:59:19:080
targetVertex incomingEdge is 12******15:59:19:080
outgoing edge(12 : 13) 15:59:19:086
sourceVertex is 12 15:59:19:087
targetVertex is 13 15:59:19:087
****************************executed the job **********  
2******15:59:19:151
15:59:26.017
[QuartzScheduler_DistributedNewScheduler123456-DESKTOP-DDN7SUT1507890505772_MisfireHandler]
DEBUG org.quartz.impl.jdbcjobstore.JobStoreTX - MisfireHandler: scanning for
misfires...
15:59:26.032
[QuartzScheduler_DistributedNewScheduler123456-DESKTOP-DDN7SUT1507890505772_MisfireHandler]
DEBUG org.quartz.impl.jdbcjobstore.JobStoreTX - Found 0 triggers that missed
their scheduled fire-time.
15:59:26.046
[QuartzScheduler_DistributedNewScheduler123456-DESKTOP-DDN7SUT1507890505772_ClusterManager]
DEBUG org.quartz.impl.jdbcjobstore.JobStoreTX - ClusterManager: Check-in
complete.
****************************executed the job **********  
13******15:59:27:188
incoming edgeeeeeeeeeeeeeeeeeeeeeeeeee******15:59:27:201
sourceVertex  incomingEdge is root******15:59:27:202
targetVertex incomingEdge is 11******15:59:27:202
incoming edgeeeeeeeeeeeeeeeeeeeeeeeeee******15:59:27:219
sourceVertex  incomingEdge is 1******15:59:27:219
targetVertex incomingEdge is 2******15:59:27:219
outgoing edge(2 : 9) 15:59:27:222
sourceVertex is 2 15:59:27:223
targetVertex is 9 15:59:27:223
outgoing edge(2 : 8) 15:59:27:223
sourceVertex is 2 15:59:27:223
targetVertex is 8 15:59:27:224
outgoing edge(2 : 7) 15:59:27:224
sourceVertex is 2 15:59:27:224
targetVertex is 7 15:59:27:224
15:59:29.421 [DistributedNewScheduler123456_QuartzSchedulerThread] DEBUG
org.quartz.core.QuartzSchedulerThread - batch acquisition of 0 triggers
****************************executed the job **********  
9******15:59:35:253
incoming edgeeeeeeeeeeeeeeeeeeeeeeeeee******15:59:35:267
sourceVertex  incomingEdge is 1******15:59:35:267
targetVertex incomingEdge is 3******15:59:35:267
checkkk3
outgoing edge(3 : 6) 15:59:35:279
sourceVertex is 3 15:59:35:280
targetVertex is 6 15:59:35:280
outgoing edge(3 : 5) 15:59:35:282
sourceVertex is 3 15:59:35:282
targetVertex is 5 15:59:35:282
outgoing edge(3 : 4) 15:59:35:283
sourceVertex is 3 15:59:35:283
targetVertex is 4 15:59:35:283
****************************executed the job **********  
8******15:59:35:324
15:59:41.051
[QuartzScheduler_DistributedNewScheduler123456-DESKTOP-DDN7SUT1507890505772_ClusterManager]
DEBUG org.quartz.impl.jdbcjobstore.JobStoreTX - ClusterManager: Check-in
complete.
15:59:52.866 [DistributedNewScheduler123456_QuartzSchedulerThread] DEBUG
org.quartz.core.QuartzSchedulerThread - batch acquisition of 0 triggers




thanks,
chandrika



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Job Listeners

Posted by Alexey Kukushkin <ku...@gmail.com>.
Hi Chandrika,

I can run your task on 1 node OK (see the output below) and I really do not
see what might cause a deadlock in your code. You said "*with one node it
was always failing causing a deadlock*" - what do you mean by "failing"? Do
you see an exception? Can you reproduce the problem with verbose logging on
(start server node with -DIGNITE_QUIET=false) and share the output with us?

[15:47:07] Ignite node started OK (id=87591b77)
[15:47:07] Topology snapshot [ver=1, servers=1, clients=0, CPUs=8,
heap=3.6GB]
[15:47:20] Topology snapshot [ver=2, servers=1, clients=1, CPUs=8,
heap=7.1GB]
**************************** executed the job **********12 *
*****15:47:29:685
**************************** executed the job **********11 *
*****15:47:29:691
**************************** executed the job **********1 *
*****15:47:29:764
[15:47:29] Topology snapshot [ver=3, servers=1, clients=0, CPUs=8,
heap=3.6GB]

Re: Job Listeners

Posted by chandrika <ch...@gmail.com>.
Hello Alexey,

Even i could make my code work on three nodes even earlier, but with one
node it was always failing causing a deadlock, please let me know how to go
about it cause the issue was with one node.

thanks 
chandrika



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Job Listeners

Posted by Alexey Kukushkin <ku...@gmail.com>.
Hi, your jobs shall not cause any deadlocks since you have no
synchronisation inside execute(). I ran your job on 3 nodes on the same
machine OK - the job completed in about 9 seconds, which matches the random
delay inside execute(). I only had to replace executeAsync() with
execute(). The problem is you do executeAsync() and then leave the cluster.
The default deployment mode is SHARED and that causes your jobs to be
undeployed not waiting for completion. This is the output from your task on
a 3 nodes cluster on the same machine:

Server 1:
[16:27:28] Ignite node started OK (id=1c45f850)
[16:27:28] Topology snapshot [ver=1, servers=1, clients=0, CPUs=8,
heap=3.6GB]
[16:27:30] Topology snapshot [ver=2, servers=2, clients=0, CPUs=8,
heap=7.1GB]
[16:27:32] Topology snapshot [ver=3, servers=3, clients=0, CPUs=8,
heap=11.0GB]
[16:27:41] Topology snapshot [ver=4, servers=3, clients=1, CPUs=8,
heap=14.0GB]
**************************** executed the job **********1 *
*****16:27:50:919
[16:27:50] Topology snapshot [ver=5, servers=3, clients=0, CPUs=8,
heap=11.0GB]

Server 2:
[16:27:31] Ignite node started OK (id=fdecc05f)
[16:27:31] Topology snapshot [ver=2, servers=2, clients=0, CPUs=8,
heap=7.1GB]
[16:27:32] Topology snapshot [ver=3, servers=3, clients=0, CPUs=8,
heap=11.0GB]
[16:27:41] Topology snapshot [ver=4, servers=3, clients=1, CPUs=8,
heap=14.0GB]
**************************** executed the job **********12 *
*****16:27:50:877
[16:27:50] Topology snapshot [ver=5, servers=3, clients=0, CPUs=8,
heap=11.0GB]

Server 3:
[16:27:32] Ignite node started OK (id=34848c7b)
[16:27:32] Topology snapshot [ver=3, servers=3, clients=0, CPUs=8,
heap=11.0GB]
[16:27:41] Topology snapshot [ver=4, servers=3, clients=1, CPUs=8,
heap=14.0GB]
**************************** executed the job **********11 *
*****16:27:50:948
[16:27:50] Topology snapshot [ver=5, servers=3, clients=0, CPUs=8,
heap=11.0GB]

Client:
[16:27:41] Ignite node started OK (id=efb93a25)
[16:27:41] Topology snapshot [ver=4, servers=3, clients=1, CPUs=8,
heap=14.0GB]
[16:27:51] Ignite node stopped OK [uptime=00:00:09.344]


On Tue, Oct 10, 2017 at 3:33 PM, chandrika <ch...@gmail.com> wrote:

> Hello Alexey,
>
>
> the sample code is as given below:
>
> @ComputeTaskSessionFullSupport
> public class SplitExampleJgraphWithComplexDAGIgniteCachesample extends
> ComputeTaskSplitAdapter<CustomDirectedAcyclicGraph&lt;String,
> DefaultEdge> ,
> Integer> {
>
>
>         // Auto-injected task session.
>     @TaskSessionResource
>     private ComputeTaskSession ses;
>
>
>     private static final Random random = new Random();
>     static int noOftasksExecutedSuccess = 0;
>
>     SimpleDateFormat dateFormat = new SimpleDateFormat("HH:mm:ss:SSS");
>
>
>
>
>     @Override protected Collection<? extends ComputeJob> split(int
> clusterSize, CustomDirectedAcyclicGraph<String, DefaultEdge> graph) {
>         Collection<ComputeJob> jobs = new LinkedList<>();
>
>         IgniteCache<String, Object> cacheUp =
> Ignition.ignite().getOrCreateCache("cacheNameNew");
>         ses.addAttributeListener((key, val) -> {
>             if ("COMPLETE".compareTo(key.toString()) == 0) {
>                 nextTaskToExecute(graph, cacheUp);
>                 }
>         }, false);
>
>         String task = null;
>         if (cacheUp.get("CurrentVertex") != null)
>                 task = (String) cacheUp.get("CurrentVertex");
>         for (DefaultEdge outgoingEdge : graph.outgoingEdgesOf(task)) {
>                 String sourceVertex = graph.getEdgeSource(outgoingEdge);
>             String targetVertex = graph.getEdgeTarget(outgoingEdge);
>             graph.setTargetVertex(targetVertex);
>             executingJobsBuilt(graph, jobs);
>         } if (task != null && graph.outgoingEdgesOf(task).size() == 0) {
>                 if (cacheUp.get(task) != null &&
> (Boolean)cacheUp.get(task)) {
>                         String targetVertex = setNextVertexInCache(graph,
> cacheUp);
>                         graph.setTargetVertex(targetVertex);
>                         nextTaskToExecute(graph, cacheUp);
>                 } else {
>                         System.out.println("else parttttt");
>                 }
>         }
>         return jobs;
>     }
>
>
>
>         private void nextTaskToExecute(CustomDirectedAcyclicGraph<String,
> DefaultEdge> graph,
>                         IgniteCache<String, Object> cacheUp) {
>                 Ignite ignite = Ignition.ignite();
>                 if (cacheUp.get("NextVertex") != null) {
>                         String processingVertex = (String)
> cacheUp.get("NextVertex");
>                         if (processingVertex != null &&
> areParentVerticesProcessed(graph,
> processingVertex, cacheUp)) {
>                                 cacheUp.put("CurrentVertex",
> processingVertex);
>                                 // Execute task on the cluster and wait
> for its completion.
>
> ignite.compute().execute(SplitExampleJgraphWithComplexD
> AGIgniteCachesample.class,
> graph);
>                         }
>                 }
>         }
>
>     private void executingJobsBuilt(CustomDirectedAcyclicGraph<String,
> DefaultEdge> graph, Collection<ComputeJob> jobs) {
>         String targetVertex = graph.getTargetVertex();
>         IgniteCache<String, Object> cacheNew =
> Ignition.ignite().getOrCreateCache("cacheNameNew");
>        if (targetVertex != null && !cacheNew.containsKey(targetVertex)) {
>            jobs.add(new ComputeJobAdapter() {
>                    // Auto-injected job context.
>                     @JobContextResource
>                     private ComputeJobContext jobCtx;
>
>                @Nullable @Override public Object execute() {
>                    int duration1 = 8000 + random.nextInt(100);
>                    SimpleDateFormat dateFormatNew = new
> SimpleDateFormat("HH:mm:ss:SSS");
>                    String task = (String) targetVertex;
>                    try {
>                            Thread.sleep(duration1);
>
> System.out.println("****************************executed the job
> **********
> " + task +  "******" + dateFormatNew.format(new Date()));
>                         cacheNew.put(task, true);
>                        } catch (Exception e1) {
>                                                 e1.printStackTrace();
>                                         }
>                                         ses.setAttribute("NEXTVERTEX",
> setNextVertexInCache(graph, cacheNew));
>                                         ses.setAttribute("COMPLETE",
> duration1);
>                    return duration1;
>                }
>
>            });
>
>            }
>
>    }
>
>
>         private String setNextVertexInCache(CustomDirectedAcyclicGraph<
> String,
> DefaultEdge> graph, IgniteCache<String, Object> cache) {
>                 String task = null;
>                 Set<String> dagSourceVertex = graph.vertexSet();
>             Iterator itr = dagSourceVertex.iterator();
>               while (itr.hasNext()) {
>                 task = (String)itr.next();
>                         if(cache.get("CurrentVertex") != null &&
> !task.equalsIgnoreCase((String)cache.get("CurrentVertex")))
>                                         continue;
>                         else {
>                                 task = (String)itr.next();
>                                 cache.put("NextVertex", task);
>                                 break;
>                         }
>                 }
>                 return task;
>         }
>
>
>
>         private Boolean
> areParentVerticesProcessed(CustomDirectedAcyclicGraph<String, DefaultEdge>
> graph, String task, IgniteCache<String, Object> cache) {
>                 Boolean processed = false;
>                 for (DefaultEdge incomingEdge :
> graph.incomingEdgesOf(task)) {
> //graph.outgoingEdgesOf(dagSourceVertex)
>                 String sourceVertex = graph.getEdgeSource(incomingEdge);
>             String targetVertex = graph.getEdgeTarget(incomingEdge);
>             if (cache!= null && cache.get(sourceVertex) != null) {
>                 processed = true;
>             }
>                 }
>                 return processed;
>         }
>
>     /** {@inheritDoc} */
>     @Nullable @Override public Integer reduce(List<ComputeJobResult>
> results) {
>         int sum = 0;
>
>         for (ComputeJobResult res : results) {
>                 sum += res.<Integer>getData();
>         }
>
>
>         return sum;
>     }
> }
>
>
> ******************************************************************
> the call for the same is as given below:
> ignite.compute().executeAsync(SplitExampleJgraphWithComplexD
> AGIgniteCache.class,
> buildGraph());
>
> buildGraph is as given below:
>
> private CustomDirectedAcyclicGraph<String, DefaultEdge> buildGraph() {
>
>                 CustomDirectedAcyclicGraph<String, DefaultEdge> graph =
>                             new CustomDirectedAcyclicGraph<String,
> DefaultEdge>(DefaultEdge.class);
>
>                                 String root = "root";
>                         String a = "1";
>                         String b = "2";
>                         String c = "3";
>                         String d = "4";
>                         String e = "5";
>                         String f = "6";
>                         String g = "7";
>                         String h = "8";
>                         String i = "9";
>                         String j = "10";
>                         String k = "11";
>                         String l = "12";
>                         String m = "13";
>                         String n = "14";
>
>                         graph.addVertex(root);
>                         graph.addVertex(a);
>                         graph.addVertex(l);
>                         graph.addVertex(k);
>
>                         graph.addVertex(b);
>                         graph.addVertex(c);
>                         graph.addVertex(m);
>
>                         graph.addVertex(i);
>                         graph.addVertex(h);
>                         graph.addVertex(g);
>
>                         graph.addVertex(f);
>                         graph.addVertex(e);
>                         graph.addVertex(d);
>                         graph.addVertex(n);
>                         graph.addVertex(j);
>
>                         DefaultEdge edg = graph.addEdge(root, a);
>                         graph.addEdge(root, l);
>                         graph.addEdge(root, k);
>
>                         graph.addEdge(a, b);
>                         graph.addEdge(a, c);
>                         graph.addEdge(l, m);
>
>                         graph.addEdge(b, i);
>                         graph.addEdge(b, h);
>                         graph.addEdge(b, g);
>
>                         graph.addEdge(c, f);
>                         graph.addEdge(c, e);
>                         graph.addEdge(c, d);
>
>                         graph.addEdge(m, d);
>                         graph.addEdge(m, n);
>
>                         graph.addEdge(i, j);
>
>                         graph.setCurrentVertex(root);
>
>
>
>                         return graph;
>         }
>
>
> hope that is sufficient for u to test the same at ur end on a single node,
> as it is working fine on three nodes.
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>



-- 
Best regards,
Alexey

Re: Job Listeners

Posted by chandrika <ch...@gmail.com>.
Hello Alexey,


the sample code is as given below:

@ComputeTaskSessionFullSupport
public class SplitExampleJgraphWithComplexDAGIgniteCachesample extends
ComputeTaskSplitAdapter<CustomDirectedAcyclicGraph&lt;String, DefaultEdge> ,
Integer> {
	
   
	// Auto-injected task session.
    @TaskSessionResource 
    private ComputeTaskSession ses;
    
    
    private static final Random random = new Random();
    static int noOftasksExecutedSuccess = 0;
    
    SimpleDateFormat dateFormat = new SimpleDateFormat("HH:mm:ss:SSS");

    

    
    @Override protected Collection<? extends ComputeJob> split(int
clusterSize, CustomDirectedAcyclicGraph<String, DefaultEdge> graph) {
        Collection<ComputeJob> jobs = new LinkedList<>();
        
        IgniteCache<String, Object> cacheUp = 
Ignition.ignite().getOrCreateCache("cacheNameNew");
        ses.addAttributeListener((key, val) -> {
            if ("COMPLETE".compareTo(key.toString()) == 0) {
            	nextTaskToExecute(graph, cacheUp);
                }
        }, false);
        
        String task = null;
        if (cacheUp.get("CurrentVertex") != null)
        	task = (String) cacheUp.get("CurrentVertex");
        for (DefaultEdge outgoingEdge : graph.outgoingEdgesOf(task)) {
        	String sourceVertex = graph.getEdgeSource(outgoingEdge);
            String targetVertex = graph.getEdgeTarget(outgoingEdge);
            graph.setTargetVertex(targetVertex);
            executingJobsBuilt(graph, jobs);
        } if (task != null && graph.outgoingEdgesOf(task).size() == 0) {
        	if (cacheUp.get(task) != null && (Boolean)cacheUp.get(task)) {
        		String targetVertex = setNextVertexInCache(graph, cacheUp);
        		graph.setTargetVertex(targetVertex);
        		nextTaskToExecute(graph, cacheUp);
        	} else {
        		System.out.println("else parttttt");
        	}
        }
        return jobs;
    }

    
    
	private void nextTaskToExecute(CustomDirectedAcyclicGraph<String,
DefaultEdge> graph,
			IgniteCache<String, Object> cacheUp) {
		Ignite ignite = Ignition.ignite();
		if (cacheUp.get("NextVertex") != null) {
			String processingVertex = (String) cacheUp.get("NextVertex");
			if (processingVertex != null && areParentVerticesProcessed(graph,
processingVertex, cacheUp)) {
				cacheUp.put("CurrentVertex", processingVertex);
				// Execute task on the cluster and wait for its completion.
			
ignite.compute().execute(SplitExampleJgraphWithComplexDAGIgniteCachesample.class,
graph);
			}
		}
	}
    
    private void executingJobsBuilt(CustomDirectedAcyclicGraph<String,
DefaultEdge> graph, Collection<ComputeJob> jobs) {
   	String targetVertex = graph.getTargetVertex();
   	IgniteCache<String, Object> cacheNew = 
Ignition.ignite().getOrCreateCache("cacheNameNew");
       if (targetVertex != null && !cacheNew.containsKey(targetVertex)) {
           jobs.add(new ComputeJobAdapter() {
        	   // Auto-injected job context.
        	    @JobContextResource
        	    private ComputeJobContext jobCtx;
        	    
               @Nullable @Override public Object execute() {
            	   int duration1 = 8000 + random.nextInt(100);
            	   SimpleDateFormat dateFormatNew = new
SimpleDateFormat("HH:mm:ss:SSS");
                   String task = (String) targetVertex;
                   try {
                	   Thread.sleep(duration1);
                       
System.out.println("****************************executed the job **********  
" + task +  "******" + dateFormatNew.format(new Date()));
                       	cacheNew.put(task, true);
	               } catch (Exception e1) {
						e1.printStackTrace();
					} 
					ses.setAttribute("NEXTVERTEX", setNextVertexInCache(graph, cacheNew));
					ses.setAttribute("COMPLETE", duration1);
            	   return duration1;
               }
               
           });
           
           }
       
   }
    

	private String setNextVertexInCache(CustomDirectedAcyclicGraph<String,
DefaultEdge> graph, IgniteCache<String, Object> cache) {
		String task = null; 
		Set<String> dagSourceVertex = graph.vertexSet();
	    Iterator itr = dagSourceVertex.iterator();
	      while (itr.hasNext()) {
	      	task = (String)itr.next();
		      	if(cache.get("CurrentVertex") != null &&
!task.equalsIgnoreCase((String)cache.get("CurrentVertex")))
		      			continue;
		      	else {
		      		task = (String)itr.next();
		      		cache.put("NextVertex", task);
		      		break;
		      	}
	        }
		return task;
	}
	
	
	
	private Boolean
areParentVerticesProcessed(CustomDirectedAcyclicGraph<String, DefaultEdge>
graph, String task, IgniteCache<String, Object> cache) {
		Boolean processed = false;
		for (DefaultEdge incomingEdge : graph.incomingEdgesOf(task)) {
//graph.outgoingEdgesOf(dagSourceVertex)
        	String sourceVertex = graph.getEdgeSource(incomingEdge);
            String targetVertex = graph.getEdgeTarget(incomingEdge);
            if (cache!= null && cache.get(sourceVertex) != null) {
            	processed = true;
            }
		}
		return processed;
	}
	
    /** {@inheritDoc} */
    @Nullable @Override public Integer reduce(List<ComputeJobResult>
results) {
        int sum = 0;

        for (ComputeJobResult res : results) {
        	sum += res.<Integer>getData();
        }
            

        return sum;
    }
}


******************************************************************
the call for the same is as given below:
ignite.compute().executeAsync(SplitExampleJgraphWithComplexDAGIgniteCache.class,
buildGraph());

buildGraph is as given below:

private CustomDirectedAcyclicGraph<String, DefaultEdge> buildGraph() {
		
		CustomDirectedAcyclicGraph<String, DefaultEdge> graph =
		            new CustomDirectedAcyclicGraph<String,
DefaultEdge>(DefaultEdge.class);

				String root = "root";
		        String a = "1";
		        String b = "2";
		        String c = "3";
		        String d = "4";
		        String e = "5";
		        String f = "6";
		        String g = "7";
		        String h = "8";
		        String i = "9";
		        String j = "10";
		        String k = "11";
		        String l = "12";
		        String m = "13";
		        String n = "14";

		        graph.addVertex(root);
		        graph.addVertex(a);
		        graph.addVertex(l);
		        graph.addVertex(k);
	        
		        graph.addVertex(b);
		        graph.addVertex(c);
		        graph.addVertex(m);
		        
		        graph.addVertex(i);
		        graph.addVertex(h);
		        graph.addVertex(g);
		        		        
		        graph.addVertex(f);
		        graph.addVertex(e);
		        graph.addVertex(d);
		        graph.addVertex(n);
		        graph.addVertex(j);
		        
		        DefaultEdge edg = graph.addEdge(root, a);
		        graph.addEdge(root, l);
		        graph.addEdge(root, k);
		        
		        graph.addEdge(a, b);
		        graph.addEdge(a, c);
		        graph.addEdge(l, m);
		       
		        graph.addEdge(b, i);
		        graph.addEdge(b, h);
		        graph.addEdge(b, g);
		        
		        graph.addEdge(c, f);
		        graph.addEdge(c, e);
		        graph.addEdge(c, d);
		        
		        graph.addEdge(m, d);
		        graph.addEdge(m, n);
		        
		        graph.addEdge(i, j);
		        
		        graph.setCurrentVertex(root);
		        
		        
		        
		        return graph;
	}


hope that is sufficient for u to test the same at ur end on a single node,
as it is working fine on three nodes.



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Job Listeners

Posted by Alexey Kukushkin <ku...@gmail.com>.
Hi Chandrika,

Is it possible for you to share your Ignite task implementation? Or are you
just running the above example I created? It looks you have some deadlock
and it is hard to guess without having the code.