Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/eclipse build #6

Open
wants to merge 14 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
classes/

/.metadata/
34 changes: 34 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,36 @@
# openEQUELLA Reporting Plugin

## Report Designers
Details for this project can be found in the openEQUELLA [docs repo](https://equella.github.io/), specifically, the [reporting tutorials](https://github.com/equella/equella.github.io/tree/master/tutorials/reporting).

## Developers
Follow these steps to build the openEQUELLA BIRT plugins.

1. Download the BIRT "All-in-One" package from https://download.eclipse.org/birt/downloads/ and unzip it into a permanent directory, i.e. this "installing" it. Don't get the Framework or Runtime downloads; the reason being is that the version of Eclipse you develop with is likely to be a different version to the BIRT downloads (the latest build of BIRT is from 2018, using Eclipse Neon) and you don't want to rely on your development Eclipse's plugins to fill the voids of the BIRT Framework. Besides, it will also be beneficial to actually be able to design and run reports in the "All-in-One" report designer.

2. Download and install the "Eclipse IDE for RCP and RAP Developers" from https://www.eclipse.org/downloads/packages/. It probably doesn't matter much which Eclipse package you download. E.g. "Eclipse IDE for Enterprise Java Developers" is probably another good, and more general purpose, choice. Any missing functionality can be added to Elipse via "Help->Install New Software..." menu.

3. Launch "Eclipse IDE for RCP and RAP Developers" and create a workspace. (Wherever you like. It seems appropriate to create the workspace in the openEQUELLA-reporting-plugin directory. Note that the workspace .metadata directory is already included in the .gitignore file)

4. In the Project Explorer window, select "Import projects..." -> "General" -> "Existing Projects into Workspace". Browse to the root of openEQUELLA-reporting-plugin repository and select that folder. Make sure all the discovered projects are selected and then click Finish.

5. At this point, you will be seeing compilation errors (missing imports), so we need to add a "Target Platform". Go to Window->Preferences->Plug-in Development->Target Platform. You will note that it currently says "Running Platform (Active)". This means you are using the current development Eclipse's plugins as dependencies, which doesn't include the BIRT plugins.

6. From the screen in step 5, click the "Add..." button, choose "Nothing" as the base, and click "Next". Name the Target Platform "BIRT" (or "Mr. T", whatever, it doesn't matter) and click "Add..." on the Locations tab.

7. From the "Add Content" dialog that comes up, choose "Installation" and browse to the root of the BIRT folder (the folder that includes the eclipse.ini and executable). Click "Finish", but remain in the "New Target Definition" dialog.

8. If we were to finish creating the Target Platform now, our plugins would mostly build, but would still be missing XStream dependencies. From the "New Target Definition" dialog, click "Add..." again, but this time choose "Software Site". Click "Add..." and an "Add Repository" dialog comes up. Enter "Orbit"* in the Name field, and paste https://download.eclipse.org/tools/orbit/downloads/drops/R20200224183213/repository into the Location field. Once you click "Add", wait for the list of plugins to download and display.

9. In the "type filter text" box, enter "xstream", and tick the box next to XStream that displays in the tree below. Now click "Finish".

10. From the "Edit Target Definition" dialog, click "Finish" again. Now click the checkbox against your newly added Target definition. Click "Apply and Close". After a short build time, your compilation errors should disappear.

11. Right click on the "openEQUELLA Reporting Plugins" project and choose "Export..."->"Plug-in Development"->"Deployable features". Select a destination directory and click Finish.

12. The contents of the "plugins" sub-directory of the export directory in the previous step are deployable to BIRT. Copy all of these jar files into the "dropins" directory of you BIRT designer installation.

13. Start the BIRT designer and follow the section at the top of this document titled "Report Designers".

* *Orbit is kind-of the equivalent of a Maven Central for Eclipse plugins, however they have a strict policy on what gets into the repository. Luckily for us they have an XStream plugin (this is actually just a plain XStream jar that has been modified to contain OSGI plugin information). If we needed a dependency that didn't already exist as an OSGI plugin, you'd probably have to manually create one and commit it into the openEQUELLA-reporting-plugin repository. (But there may be a better way)*

2 changes: 1 addition & 1 deletion com.tle.reporting.common/.classpath
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry excluding="**/.svn/*|**/_svn/*" kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="output" path="classes"/>
</classpath>
7 changes: 7 additions & 0 deletions com.tle.reporting.common/.settings/org.eclipse.jdt.core.prefs
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
org.eclipse.jdt.core.compiler.compliance=1.7
org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning
org.eclipse.jdt.core.compiler.problem.deadCode=warning
Expand All @@ -8,6 +12,7 @@ org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
org.eclipse.jdt.core.compiler.problem.emptyStatement=warning
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore
org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
org.eclipse.jdt.core.compiler.problem.fieldHiding=warning
Expand Down Expand Up @@ -68,3 +73,5 @@ org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disa
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
org.eclipse.jdt.core.compiler.release=disabled
org.eclipse.jdt.core.compiler.source=1.7
9 changes: 5 additions & 4 deletions com.tle.reporting.common/META-INF/MANIFEST.MF
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: TLE Reporting Common
Bundle-Name: openEQUELLA Reporting Common
Bundle-SymbolicName: com.tle.reporting.common
Bundle-Version: 6.3.0.20141006
Export-Package: com.tle.reporting,
Bundle-Version: 2020.2.0.2020052901
Export-Package: com.tle.reporting;uses:="org.eclipse.datatools.connectivity.oda",
com.tle.reporting.schema
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
Bundle-ClassPath: .
Require-Bundle: org.eclipse.datatools.connectivity.oda
Bundle-Vendor: Apereo
2 changes: 1 addition & 1 deletion com.tle.reporting.oda.connectors/.classpath
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry excluding="**/.svn/*|**/_svn/*" kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
<classpathentry kind="output" path="classes"/>
</classpath>
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#Wed Dec 21 16:01:56 EST 2011
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
org.eclipse.jdt.core.compiler.compliance=1.5
org.eclipse.jdt.core.compiler.compliance=1.7
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.source=1.5
org.eclipse.jdt.core.compiler.release=disabled
org.eclipse.jdt.core.compiler.source=1.7
7 changes: 4 additions & 3 deletions com.tle.reporting.oda.connectors/META-INF/MANIFEST.MF
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: TLE Connectors ODA Plug-in
Bundle-Name: openEQUELLA Connectors ODA Plug-in
Bundle-SymbolicName: com.tle.reporting.oda.connectors;singleton:=true
Bundle-Version: 6.3.0.20141006
Bundle-Version: 2020.2.0.2020052901
Require-Bundle: org.eclipse.ui;resolution:=optional,
org.eclipse.datatools.connectivity.oda.design.ui;resolution:=optional,
org.eclipse.birt.report.engine;bundle-version="2.3.1",
Expand All @@ -11,8 +11,9 @@ Require-Bundle: org.eclipse.ui;resolution:=optional,
Bundle-ClassPath: .
Bundle-ActivationPolicy: lazy
Bundle-Activator: com.tle.reporting.oda.connectors.ui.TLEConnectorsOdaPlugin
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
Export-Package: com.tle.reporting.oda.connectors,
com.tle.reporting.oda.connectors.i18n,
com.tle.reporting.oda.connectors.ui,
org.eclipse.birt.report.data.oda.jdbc.ui.nls
Bundle-Vendor: Apereo
6 changes: 5 additions & 1 deletion com.tle.reporting.oda/.classpath
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7">
<attributes>
<attribute name="module" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry excluding="**/.svn/*|**/_svn/*" kind="src" path="src"/>
<classpathentry kind="output" path="classes"/>
Expand Down
8 changes: 4 additions & 4 deletions com.tle.reporting.oda/.settings/org.eclipse.jdt.core.prefs
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#Wed Dec 21 16:01:47 EST 2011
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
org.eclipse.jdt.core.compiler.compliance=1.5
org.eclipse.jdt.core.compiler.compliance=1.7
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.source=1.5
org.eclipse.jdt.core.compiler.release=disabled
org.eclipse.jdt.core.compiler.source=1.7
54 changes: 43 additions & 11 deletions com.tle.reporting.oda/META-INF/MANIFEST.MF
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: TLE ODA Plug-in
Bundle-Name: openEQUELLA ODA Plug-in
Bundle-SymbolicName: com.tle.reporting.oda;singleton:=true
Bundle-Version: 6.3.0.20141006
Bundle-Version: 2020.2.0.2020052901
Require-Bundle: org.eclipse.ui;resolution:=optional,
org.eclipse.datatools.connectivity.oda.design.ui;resolution:=optional,
org.eclipse.jface.text;resolution:=optional,
Expand All @@ -13,21 +13,53 @@ Require-Bundle: org.eclipse.ui;resolution:=optional,
Bundle-ClassPath: .
Bundle-ActivationPolicy: lazy
Bundle-Activator: com.tle.reporting.oda.ui.TLEOdaPlugin
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Export-Package: com.tle.reporting.oda,
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
Export-Package: com.tle.reporting.oda;
uses:="com.tle.reporting,
org.apache.commons.httpclient,
org.apache.commons.httpclient.methods,
com.ibm.icu.util,
org.eclipse.datatools.connectivity.oda,
com.thoughtworks.xstream,
javax.net,
javax.net.ssl,
org.eclipse.datatools.connectivity.oda.spec",
com.tle.reporting.oda.i18n,
com.tle.reporting.oda.ui,
com.tle.reporting.oda.ui;
uses:="org.osgi.framework,
org.eclipse.datatools.connectivity.oda.design,
org.eclipse.datatools.connectivity.oda.design.ui.wizards,
org.eclipse.core.runtime,
org.eclipse.jface.resource,
com.tle.reporting.oda.ui.jdbc.ui.editors,
org.eclipse.swt.widgets,
org.eclipse.jface.viewers",
com.tle.reporting.oda.ui.icons,
com.tle.reporting.oda.ui.jdbc.ui.editors,
com.tle.reporting.oda.ui.jdbc.ui.model,
com.tle.reporting.oda.ui.jdbc.ui.preference,
com.tle.reporting.oda.ui.jdbc.ui.provider,
com.tle.reporting.oda.ui.jdbc.ui.util,
com.tle.reporting.oda.webservice,
com.tle.reporting.oda.ui.jdbc.ui.editors;
uses:="org.eclipse.jface.text.contentassist,
org.eclipse.datatools.connectivity.oda.design,
org.eclipse.datatools.connectivity.oda.design.ui.wizards,
org.eclipse.jface.action,
org.eclipse.jface.text.source,
org.eclipse.jface.text.presentation,
org.eclipse.jface.text,
org.eclipse.swt.widgets,
org.eclipse.datatools.connectivity.oda,
org.eclipse.jface.text.rules",
com.tle.reporting.oda.ui.jdbc.ui.model;uses:="org.eclipse.swt.graphics,org.eclipse.swt.widgets",
com.tle.reporting.oda.ui.jdbc.ui.preference;uses:="org.eclipse.ui,org.eclipse.swt.widgets,org.eclipse.jface.preference",
com.tle.reporting.oda.ui.jdbc.ui.provider;uses:="org.eclipse.datatools.connectivity.oda.design",
com.tle.reporting.oda.ui.jdbc.ui.util;uses:="org.eclipse.swt.graphics,org.eclipse.swt.widgets,org.eclipse.jface.dialogs",
com.tle.reporting.oda.webservice;
uses:="org.eclipse.datatools.connectivity.oda.design.ui.wizards,
org.eclipse.jface.preference,
org.eclipse.swt.widgets,
org.eclipse.jface.wizard",
org.eclipse.birt.report.data.oda.jdbc.ui.nls
Import-Package: com.thoughtworks.xstream,
org.apache.commons.codec.binary;version="1.3.0",
org.apache.commons.httpclient,
org.apache.commons.httpclient.methods,
org.apache.commons.httpclient.params,
org.apache.commons.httpclient.protocol
Bundle-Vendor: Apereo
17 changes: 17 additions & 0 deletions openEQUELLA Reporting Plugins/.project
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>openEQUELLA Reporting Plugins</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.pde.FeatureBuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.pde.FeatureNature</nature>
</natures>
</projectDescription>
1 change: 1 addition & 0 deletions openEQUELLA Reporting Plugins/build.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
bin.includes = feature.xml
62 changes: 62 additions & 0 deletions openEQUELLA Reporting Plugins/feature.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
<?xml version="1.0" encoding="UTF-8"?>
<feature
id="openEQUELLA_Reporting_Plugins"
label="OpenEQUELLA_Reporting_Plugins"
version="2020.2.0.2020052901"
provider-name="Apereo">

<description url="http://www.example.com/description">
[Enter Feature Description here.]
</description>

<copyright url="http://www.example.com/copyright">
[Enter Copyright Description here.]
</copyright>

<license url="http://www.example.com/license">
[Enter License Description here.]
</license>
Comment on lines +8 to +18
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should fill all these in.


<requires>
<import plugin="org.eclipse.datatools.connectivity.oda"/>
<import plugin="org.apache.commons.codec"/>
<import plugin="org.apache.commons.httpclient"/>
<import plugin="org.eclipse.birt.report.engine" version="2.3.1" match="greaterOrEqual"/>
</requires>

<plugin
id="com.tle.reporting.common"
download-size="0"
install-size="0"
version="0.0.0"
unpack="false"/>

<plugin
id="com.tle.reporting.oda"
download-size="0"
install-size="0"
version="0.0.0"
unpack="false"/>

<plugin
id="com.tle.reporting.oda.connectors"
download-size="0"
install-size="0"
version="0.0.0"
unpack="false"/>

<plugin
id="com.thoughtworks.xstream"
download-size="0"
install-size="0"
version="0.0.0"
unpack="false"/>

<plugin
id="org.xmlpull"
download-size="0"
install-size="0"
version="0.0.0"
unpack="false"/>

</feature>
17 changes: 17 additions & 0 deletions update/.project
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>update</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.pde.UpdateSiteBuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.pde.UpdateSiteNature</nature>
</natures>
</projectDescription>
Binary file added update/artifacts.jar
Binary file not shown.
45 changes: 45 additions & 0 deletions update/artifacts.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
<?xml version='1.0' encoding='UTF-8'?>
<?artifactRepository version='1.1.0'?>
<repository name='Update Site' type='org.eclipse.equinox.p2.artifact.repository.simpleRepository' version='1'>
<properties size='2'>
<property name='p2.timestamp' value='1590129212760'/>
<property name='p2.compressed' value='true'/>
</properties>
<mappings size='3'>
<rule filter='(&amp; (classifier=osgi.bundle))' output='${repoUrl}/plugins/${id}_${version}.jar'/>
<rule filter='(&amp; (classifier=binary))' output='${repoUrl}/binary/${id}_${version}'/>
<rule filter='(&amp; (classifier=org.eclipse.update.feature))' output='${repoUrl}/features/${id}_${version}.jar'/>
</mappings>
<artifacts size='5'>
<artifact classifier='org.eclipse.update.feature' id='openEQUELLA_Reporting_Plugins' version='1.0.0.alpha'>
<properties size='2'>
<property name='download.contentType' value='application/zip'/>
<property name='download.size' value='485'/>
</properties>
</artifact>
<artifact classifier='osgi.bundle' id='com.thoughtworks.xstream' version='1.3.1.v201111240924'>
<properties size='5'>
<property name='artifact.size' value='480105'/>
<property name='download.size' value='480105'/>
<property name='download.md5' value='62938d6a658a2ecfd8d0e0f88221e589'/>
<property name='download.checksum.md5' value='62938d6a658a2ecfd8d0e0f88221e589'/>
<property name='download.checksum.sha-256' value='168c0e43f11ad7fc133af938d465c23464b981420f255ed56a7434fc9b75a43f'/>
</properties>
</artifact>
<artifact classifier='osgi.bundle' id='com.tle.reporting.common' version='6.3.0.20141006'>
<properties size='1'>
<property name='download.size' value='6647'/>
</properties>
</artifact>
<artifact classifier='osgi.bundle' id='com.tle.reporting.oda' version='6.3.0.20141006'>
<properties size='1'>
<property name='download.size' value='165311'/>
</properties>
</artifact>
<artifact classifier='osgi.bundle' id='com.tle.reporting.oda.connectors' version='6.3.0.20141006'>
<properties size='1'>
<property name='download.size' value='14700'/>
</properties>
</artifact>
</artifacts>
</repository>
Binary file added update/content.jar
Binary file not shown.
Binary file not shown.
Loading