GitHub user kaspersorensen opened a pull request:
https://github.com/apache/metamodel/pull/113
Dynamic DataContext factory (MM 1099)
This is my attempt at solving METAMODEL-1099. I've leveraged the standard
[ServiceLoader](https://docs.oracle.com/javase/7/docs/api/java/util/ServiceLoader.html)
for registering resource factories and data context factories. And I
implemented this pattern with the various standard resources as well as the CSV
data context. In my opinion this approach is pretty good, but I'd like to hear
your feedback!
If you think this approach is good, we should obviously expand it to fit
all the datacontext implementations. But that would be a rather trivial task I
think, once we agree on this.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/kaspersorensen/metamodel METAMODEL-1099
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/metamodel/pull/113.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #113
----
commit 2173aa362a64015878d309a5b661bd5867563ee5
Author: Kasper Sørensen <[email protected]>
Date: 2016-07-04T04:14:51Z
METAMODEL-1099: Added interfaces and registry for pluggable DC factory
commit 4b2e6a1f2e2daf1edeb4fd4c92d0daa873c697b9
Author: Kasper Sørensen <[email protected]>
Date: 2016-07-04T04:21:35Z
METAMODEL-1099: Created a CsvDataContextFactory implementation
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---