Make java8 API generic (based on DataAst) so XML and JSON API could use it.
Pros: java8 API module doesn't depend on XML or JSON module.
Cons: can't use XML and JSON backends (AST) simultaneously (in a single context) with java8 module. Because of ambiguous implicits.
Make java8 module depends on xml & json module, and divide API in 2 part: (rapture.xml.java8.time._ & rapture.json.java8.time._).
Pros: fix first solution issue
Cons: java8 module depends on JSON & XML modules.
For example, a user adds a java8 module for JSON serialization, but it also gets XML module in the classpath. (Bad practice. IMHO)
Make 2 modules: json-java8 & xml-java8.
Pros: fix first two solutions issues
Cons: Code duplication.
Implementing #257
There are few API design options I see:
Make java8 API generic (based on DataAst) so XML and JSON API could use it. Pros: java8 API module doesn't depend on XML or JSON module. Cons: can't use XML and JSON backends (AST) simultaneously (in a single context) with java8 module. Because of ambiguous implicits.
Make java8 module depends on xml & json module, and divide API in 2 part: (
rapture.xml.java8.time._
&rapture.json.java8.time._
). Pros: fix first solution issue Cons: java8 module depends on JSON & XML modules. For example, a user adds a java8 module for JSON serialization, but it also gets XML module in the classpath. (Bad practice. IMHO)Make 2 modules: json-java8 & xml-java8. Pros: fix first two solutions issues Cons: Code duplication.
Currently, I have implemented the 3rd option.
@propensive What do you think?