Uploaded image for project: 'TinkerPop'
  1. TinkerPop
  2. TINKERPOP-690

Be able to OPT_OUT for Standard, but not Computer

    Details

      Description

      HadoopGraph currently have this:

      @Graph.OptOut(
              test = "org.apache.tinkerpop.gremlin.process.traversal.step.map.CountTest$Traversals",
              method = "g_V_repeatXoutX_timesX8X_count",
              reason = "Hadoop-Gremlin is OLAP-oriented and for OLTP operations, linear-scan joins are required. This particular tests takes many minutes to execute.")
      

      However, I only want to OPT_OUT for Standard, not for Computer. It would be good to be able to make OPT_OUT for particular engines.

      Next, and more to the point, see this:

      @Graph.OptOut(
              test = "org.apache.tinkerpop.gremlin.process.computer.GraphComputerTest",
              method = "shouldHaveConsistentMemoryVertexPropertiesAndExceptions",
              reason = "Giraph does a hard kill on failure and stops threads which stops test cases. Exception handling semantics are correct though.")
      

      SparkGraphComputer does this fine, its only GiraphGraphComputer that fails the entire JVM. Again, be nice to say OPT_OUT for Giraph, but not for Spark.

        Activity

        Hide
        spmallette stephen mallette added a comment -

        I'm going to make the "breaking" comment here a little more clear. This change should only be a problem for those who run GraphComputer tests (e.g. ProcessComputerSuite). If you do run these tests, then you need to edit your GraphProvider implementation for those suites to include the aforementioned GraphProvider.Descriptor annotation.

        Here's an example with from the HadoopGiraphGraphProvider:

        https://github.com/apache/incubator-tinkerpop/blob/04ba481facf9234669092467b73c05eb9b4c0301/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/giraph/HadoopGiraphGraphProvider.java#L30

        Show
        spmallette stephen mallette added a comment - I'm going to make the "breaking" comment here a little more clear. This change should only be a problem for those who run GraphComputer tests (e.g. ProcessComputerSuite ). If you do run these tests, then you need to edit your GraphProvider implementation for those suites to include the aforementioned GraphProvider.Descriptor annotation. Here's an example with from the HadoopGiraphGraphProvider : https://github.com/apache/incubator-tinkerpop/blob/04ba481facf9234669092467b73c05eb9b4c0301/hadoop-gremlin/src/test/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/giraph/HadoopGiraphGraphProvider.java#L30
        Hide
        spmallette stephen mallette added a comment -

        Adding "breaking" label as there potential for a "break" for vendors implementing the gremlin test suite that they should be aware of. There is also a test name change that might cause a failure if a graph opted out of it, but that error should be clear when the vendor runs the test suite against this version.

        Show
        spmallette stephen mallette added a comment - Adding "breaking" label as there potential for a "break" for vendors implementing the gremlin test suite that they should be aware of. There is also a test name change that might cause a failure if a graph opted out of it, but that error should be clear when the vendor runs the test suite against this version.
        Hide
        spmallette stephen mallette added a comment -

        introduced a few new things to get this working....

        First, there is a new GraphProvider.Descriptor annotation that lets you specify which GraphComputer is going to be used in construction of a Traversal. Errors get generated if a GraphProvider does not have this for a run of a test suite that uses a COMPUTER traversal engine.

        Second, OptOut has a new attribute called computers which specifies the GraphComputer implementations that this opt-out should apply to.

        Show
        spmallette stephen mallette added a comment - introduced a few new things to get this working.... First, there is a new GraphProvider.Descriptor annotation that lets you specify which GraphComputer is going to be used in construction of a Traversal . Errors get generated if a GraphProvider does not have this for a run of a test suite that uses a COMPUTER traversal engine. Second, OptOut has a new attribute called computers which specifies the GraphComputer implementations that this opt-out should apply to.
        Hide
        okram Marko A. Rodriguez added a comment -

        Question: what is the "standard engine" .class ?

        Show
        okram Marko A. Rodriguez added a comment - Question: what is the "standard engine" .class ?
        Hide
        okram Marko A. Rodriguez added a comment -

        That will work great. Thanks.

        Show
        okram Marko A. Rodriguez added a comment - That will work great. Thanks.
        Hide
        spmallette stephen mallette added a comment -

        Could we implement this as:

        @Graph.OptOut(
                test = "org.apache.tinkerpop.gremlin.process.computer.GraphComputerTest",
                method = "shouldHaveConsistentMemoryVertexPropertiesAndExceptions",
                reason = "Giraph does a hard kill on failure and stops threads which stops test cases. Exception handling semantics are correct though.",
                engines = { GiraphGraphComputer.class })
        

        I guess if you want to omit a test for all graph computers, you'd just have to list all the ones you were testing. does that work?

        Show
        spmallette stephen mallette added a comment - Could we implement this as: @Graph.OptOut( test = "org.apache.tinkerpop.gremlin.process.computer.GraphComputerTest" , method = "shouldHaveConsistentMemoryVertexPropertiesAndExceptions" , reason = "Giraph does a hard kill on failure and stops threads which stops test cases. Exception handling semantics are correct though." , engines = { GiraphGraphComputer.class }) I guess if you want to omit a test for all graph computers, you'd just have to list all the ones you were testing. does that work?

          People

          • Assignee:
            spmallette stephen mallette
            Reporter:
            okram Marko A. Rodriguez
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development