[jboss-jira] [JBoss JIRA] Updated: (JBRULES-3208) Benchmarker should support custom reading and writing of solutions (it should not enforce 1 specific xstream configuration)

Geoffrey De Smet (JIRA) jira-events at lists.jboss.org
Sun Oct 2 08:32:26 EDT 2011


     [ https://issues.jboss.org/browse/JBRULES-3208?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Geoffrey De Smet updated JBRULES-3208:
--------------------------------------

          Summary: Benchmarker should support custom reading and writing of solutions (it should not enforce 1 specific xstream configuration)  (was: Benchmark doesn't allow for de-serializing XMLs with references)
       Issue Type: Enhancement  (was: Bug)
    Fix Version/s: 5.4.0.Beta1
      Description: 
Title was: Benchmark doesn't allow for de-serializing XMLs with references

I have a solution configuration serialized via XStream [1]. When I'm attempting to benchmark [2] my solver with that solution, I get the following error:

[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2:java (default-cli) on project tournaments: An exception occured while executing the Java class. null: InvocationTargetException: Problem reading unsolvedSolutionFile: src/main/resources/input-tiny.xml: Invalid reference
[ERROR] ---- Debugging information ----
[ERROR] reference           : ../../group
[ERROR] class               : org.drools.planner.examples.tournaments.model.Team
[ERROR] required-type       : org.drools.planner.examples.tournaments.model.Team
[ERROR] converter-type      : com.thoughtworks.xstream.converters.reflection.ReflectionConverter
[ERROR] line number         : 22
[ERROR] class[1]            : org.drools.planner.examples.tournaments.TournamentsSolution
[ERROR] version             : null
[ERROR] -------------------------------

I can see two solutions:
a) Make it so that Planner benchmark does understand XStream's XML.
b) Provide a method inside Planner to serialize Solutions in a way that benchmark will understand them later.

References:
[1] https://github.com/triceo/Drooling-Tournaments/blob/master/src/main/resources/input-tiny.xml
[2] https://github.com/triceo/Drooling-Tournaments/blob/master/src/main/resources/benchmarkConfig.xml
[3] https://github.com/triceo/Drooling-Tournaments

  was:
I have a solution configuration serialized via XStream [1]. When I'm attempting to benchmark [2] my solver with that solution, I get the following error:

[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2:java (default-cli) on project tournaments: An exception occured while executing the Java class. null: InvocationTargetException: Problem reading unsolvedSolutionFile: src/main/resources/input-tiny.xml: Invalid reference
[ERROR] ---- Debugging information ----
[ERROR] reference           : ../../group
[ERROR] class               : org.drools.planner.examples.tournaments.model.Team
[ERROR] required-type       : org.drools.planner.examples.tournaments.model.Team
[ERROR] converter-type      : com.thoughtworks.xstream.converters.reflection.ReflectionConverter
[ERROR] line number         : 22
[ERROR] class[1]            : org.drools.planner.examples.tournaments.TournamentsSolution
[ERROR] version             : null
[ERROR] -------------------------------

I can see two solutions:
a) Make it so that Planner benchmark does understand XStream's XML.
b) Provide a method inside Planner to serialize Solutions in a way that benchmark will understand them later.

References:
[1] https://github.com/triceo/Drooling-Tournaments/blob/master/src/main/resources/input-tiny.xml
[2] https://github.com/triceo/Drooling-Tournaments/blob/master/src/main/resources/benchmarkConfig.xml
[3] https://github.com/triceo/Drooling-Tournaments



> Benchmarker should support custom reading and writing of solutions (it should not enforce 1 specific xstream configuration)
> ---------------------------------------------------------------------------------------------------------------------------
>
>                 Key: JBRULES-3208
>                 URL: https://issues.jboss.org/browse/JBRULES-3208
>             Project: Drools
>          Issue Type: Enhancement
>      Security Level: Public(Everyone can see) 
>          Components: drools-planner
>    Affects Versions: 5.2.0.Final, 5.3.0.Beta1
>         Environment: java version "1.6.0_22"
> OpenJDK Runtime Environment (IcedTea6 1.10.3) (fedora-59.1.10.3.fc15-x86_64)
> OpenJDK 64-Bit Server VM (build 20.0-b11, mixed mode)
>            Reporter: Lukáš Petrovický
>            Assignee: Geoffrey De Smet
>            Priority: Critical
>             Fix For: 5.4.0.Beta1
>
>
> Title was: Benchmark doesn't allow for de-serializing XMLs with references
> I have a solution configuration serialized via XStream [1]. When I'm attempting to benchmark [2] my solver with that solution, I get the following error:
> [ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2:java (default-cli) on project tournaments: An exception occured while executing the Java class. null: InvocationTargetException: Problem reading unsolvedSolutionFile: src/main/resources/input-tiny.xml: Invalid reference
> [ERROR] ---- Debugging information ----
> [ERROR] reference           : ../../group
> [ERROR] class               : org.drools.planner.examples.tournaments.model.Team
> [ERROR] required-type       : org.drools.planner.examples.tournaments.model.Team
> [ERROR] converter-type      : com.thoughtworks.xstream.converters.reflection.ReflectionConverter
> [ERROR] line number         : 22
> [ERROR] class[1]            : org.drools.planner.examples.tournaments.TournamentsSolution
> [ERROR] version             : null
> [ERROR] -------------------------------
> I can see two solutions:
> a) Make it so that Planner benchmark does understand XStream's XML.
> b) Provide a method inside Planner to serialize Solutions in a way that benchmark will understand them later.
> References:
> [1] https://github.com/triceo/Drooling-Tournaments/blob/master/src/main/resources/input-tiny.xml
> [2] https://github.com/triceo/Drooling-Tournaments/blob/master/src/main/resources/benchmarkConfig.xml
> [3] https://github.com/triceo/Drooling-Tournaments

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       



More information about the jboss-jira mailing list