Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 365469 - H2 support for Gemini DBACCESS
Summary: H2 support for Gemini DBACCESS
Status: RESOLVED FIXED
Alias: None
Product: Gemini.DBaccess
Classification: RT
Component: Core (show other bugs)
Version: 1.1.0.M2   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: 1.1.0.M3   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-12-02 14:07 EST by Gernot Kvas CLA
Modified: 2012-09-23 16:14 EDT (History)
3 users (show)

See Also:


Attachments
Patch for H2 (1.80 MB, patch)
2011-12-02 14:14 EST, Gernot Kvas CLA
gernot: review?
Details | Diff
A minimalist patch for H2 support (12.82 KB, patch)
2011-12-11 13:21 EST, Gernot Kvas CLA
gernot: review?
Details | Diff
H2 Mock plugin (36.88 KB, patch)
2011-12-11 13:58 EST, Gernot Kvas CLA
gernot: review?
Details | Diff
H2 feature (45.29 KB, patch)
2011-12-11 14:15 EST, Gernot Kvas CLA
gernot: review?
Details | Diff
H2 bare patch (9.30 KB, patch)
2012-08-10 11:46 EDT, Nepomuk Seiler CLA
juergen.kissner: iplog+
nepomuk.seiler: review?
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Gernot Kvas CLA 2011-12-02 14:07:05 EST
Build Identifier: 20110916-0149

Gemini DBACCESS currently only supports Derby. Add H2.

Reproducible: Always
Comment 1 Gernot Kvas CLA 2011-12-02 14:14:38 EST
Created attachment 207860 [details]
Patch for H2

A patch with support for H2.
Comment 2 Gernot Kvas CLA 2011-12-02 14:28:08 EST
Please note. The above patch contains H2 wrapped in a separate plug-in, similar to the Derby support. This can theoretically and practically be omitted, as the H2 plugin is already OSGi-ified. The reason I did this so you have some H2 version to build against.
Comment 3 Juergen Kissner CLA 2011-12-04 18:14:58 EST
Hi Gernot,

Thanks for your interest in the DBAccess project and thank your for your contribution.

Right now, I have problems applying the patch; the root of the directories in you patch seem to be "a" and "b". Could you please re-check you upload?

Please also note that the Eclipse Foundation has a strict legal process to ensure IP cleanliness. For further referece, please see 
http://wiki.eclipse.org/Development_Resources#Everyone:_IP_Cleanliness and
http://www.eclipse.org/legal/committerguidelines.php.

It has to be clear, which parts of the contribution is your own work, and which part comes from other sources. Please also see http://www.eclipse.org/tm/development/committer_howto.php#external_contrib. It contains  questions that will have to be answered in the IP process.

For example, I wonder, if the files in b/h2/org.h2/license_files are necessary:
ga.js
index.js
navigatioin.js
search.js

Are these files necessary?

I would prefer an initial contribution that is kept to a minimum (and can then be extended). For the database software, we presumably need a separate CQ (contributors questionaire). Maybe we could first aim for a solution similar to the the one for MySQL that does nor require the database software for H2?

-- Juergen
Comment 4 Gernot Kvas CLA 2011-12-11 13:21:36 EST
Created attachment 208227 [details]
A minimalist patch for H2 support
Comment 5 Gernot Kvas CLA 2011-12-11 13:23:23 EST
Hi Juergen,

The attached patch only contains minimal initial contribution as requested: a single plugin for H2. It applies with

gemini.dbaccess.orig/trunk$ patch -p2 < ../../h2.patch

It is missing the feature and the H2 wrapper plugin. As I stated in comment 2, we wouldn't need H2 to come with DBaccess. Just add the latest H2 jar to the target platform in order to make the plugin in the patch compile.

I'm not too firm with regard to the IP/license related stuff. Any help is highly appreciated. 

Gernot
Comment 6 Gernot Kvas CLA 2011-12-11 13:58:14 EST
Created attachment 208228 [details]
H2 Mock plugin
Comment 7 Gernot Kvas CLA 2011-12-11 14:15:20 EST
Created attachment 208230 [details]
H2 feature
Comment 8 Juergen Kissner CLA 2012-01-16 17:06:37 EST
Hi Gernot,

I had a look at your uploads and managed to assemble the H2 feature with some minor modifications (I wouldn't like to include the H2 API in the feature). It looks good to me.
Let us now see how to proceed with your changes, to make sure we meet the legal requirements.

We will have a Gemini conf-call tomorrow, and I will bring up the subject there.

Thanks a lot,
  Jürgen
Comment 9 Juergen Kissner CLA 2012-01-22 15:23:39 EST
Hi Gernot,
in the meanwhile we had a thorough discussion within the Gemini umbrella project about the best way of integrating your contributions. The goal is to comply with the legal requirements of the Eclipse Foundation and at the same time to minimize the administrative overhead such that the changes can be incorporated as soon as possible. 

This is what we came up with:
The best and easiest way is to minimize the amount of contributed code to the necessary minimum. That is, we would like our contributors to submit the support for a new database platform such that it does not contain any boilerplate stuff such as licenses, auto-generated Eclipse project meta data,...

Applied to your contribution, that means  please re-submit the extract that contains the genuine part. This is everything in the 
h2/org.eclipse.gemini.dbaccess.h2/src directory, To be more specific, it is the contents of the following folders and subfolders:
src/
METAINF/
org/eclipse/gemini/dbaccess/h2/
src/org/eclipse/gemini/dbaccess/h2/service/

With that we stay well below the 250 lines barrier, beyond which a much higher administrative effort would be required.

I think this strategy helps you as contributors and us as committers.

What do you think?

Best Regards,
  Jürgen
Comment 10 Gernot Kvas CLA 2012-01-24 15:35:51 EST
Thanks for the effort.  I'll prepare a bare bones version on the weekend
Comment 11 Nepomuk Seiler CLA 2012-06-05 06:27:19 EDT
Will this enhancement be targeted in the next milestone?
Comment 12 Juergen Kissner CLA 2012-08-08 10:37:13 EDT
(In reply to comment #10)
> Thanks for the effort.  I'll prepare a bare bones version on the weekend

Hi Gernot,

any news on the stripped down version of your contribution? If possible, I would like to include H2 support with the next milestone.

- Juergen
Comment 13 Nepomuk Seiler CLA 2012-08-10 11:46:12 EDT
Created attachment 219761 [details]
H2 bare patch

As I also interessted in this patch I stripped down Gernots implementation to this one patch.

The h2 feature, parent pom.xml changes and the org.h2 plugin are missing. So this patch will add nothing to the build at first glance.
Comment 14 Gernot Kvas CLA 2012-08-10 12:15:57 EDT
Apologies for not following up on this bug. I had to switch priorities after the loss of a close family member.

Anyhow, I'm picking up my OS activities again and with reference to my comment from 24-01-2012, I now _really_ could prepare the stripped down patch, given the one Nepomuk provided is not sufficient (which looks OK to me). As it happens, I've some days off work next week.
Comment 15 Juergen Kissner CLA 2012-08-15 05:34:08 EDT
(In reply to comment #14)
> Apologies for not following up on this bug. I had to switch priorities after
> the loss of a close family member.
> 
> Anyhow, I'm picking up my OS activities again and with reference to my
> comment from 24-01-2012, I now _really_ could prepare the stripped down
> patch, given the one Nepomuk provided is not sufficient (which looks OK to
> me). As it happens, I've some days off work next week.

Hi Gernot, Nepomuk,
I would like to have something that I could mark for the IP log, such that Gernot's contribution apprears there. I do not have problems giving credit to both of you. So, if there is something below the magic 250 lines I could "tick", I would be happy to do that. Alternatively, Gernot could provide the patch for HSQL. 

- Juergen
Comment 16 Nepomuk Seiler CLA 2012-08-15 07:59:57 EDT
Hi Juergen,

The patch has 240 lines so there are 10 lines for some other stuff ;-)
However I have left Gernots source code comment in the file

org.eclipse.gemini.dbaccess.h2/src/org/eclipse/gemini/dbaccess/h2/H2DataSourceFactory.java

which states:

/*******************************************************************************
 * Copyright (c) 2011 Gernot Kvas
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *    Gernot Kvas - initial API and implementation and/or initial documentation
 *******************************************************************************/

I am perfectly fine with that.
Comment 17 Juergen Kissner CLA 2012-08-15 12:33:51 EDT
I have created the follwing change in Gerrit:

https://git.eclipse.org/r/#/c/7237/

You can review an comment on it using your browser. You can also easily sync and try it locally (in your IDE and with mvn clean install in your parent project).

To do that, please refer to the documentation on DBAccess with Gerrit:

http://wiki.eclipse.org/Gemini/DBAccess/CommitterGuide/HowToUseGerrit

Best Regards,
  Juergen
Comment 18 Juergen Kissner CLA 2012-08-16 17:45:57 EDT
Hi,

here is update site of the snapshot build result:

https://hudson.eclipse.org/hudson/job/gemini-dbaccess/lastSuccessfulBuild/artifact/gemini.dbaccess.updatesite/target/site/

As an interesting fact when defining your target platform:
If you use for example the update site 
http://download.eclipse.org/releases/indigo/  
for your OSGi runtime and include the Gemini DBAccess feature for H2,
then the H2 driver comes from the indigo update site automatically (you have to tick "Include required software" when selecting the H2 feature). Until now, I was not aware of the fact that the H2 JDBC driver is part of Indigo...

Just an additional note: I will have very limited internet access for the next three weeks, so please be patient I I cannot answer your requests/questions

Best Regards,
  Juergen
Comment 19 Nepomuk Seiler CLA 2012-08-17 06:13:16 EDT
Hi,

So there's actually no need to provide a org.h2 bundle in the dbaccess repository?

Enjoy your "less internet" time,
Muki
Comment 20 Juergen Kissner CLA 2012-09-07 12:08:07 EDT
(In reply to comment #19)
> Hi,
> 
> So there's actually no need to provide a org.h2 bundle in the dbaccess
> repository?
> 
> Enjoy your "less internet" time,
> Muki

Hi Muki,
thanks for you comment!

Immediately after I merged the change into git, I noticed that too and fixed it. So you presumably synched (or looked at) an outdated change. The latest one is:
https://git.eclipse.org/r/#/c/7261/

Juergen
Comment 23 Juergen Kissner CLA 2012-09-19 10:01:49 EDT
For 1.1.0 M3
Comment 24 Juergen Kissner CLA 2012-09-23 16:14:47 EDT
Hi Gernot, Nepomuk,
thanks a lot for your contributions!

Regards,
  Juergen