Details
-
Type: Task
-
Status: Closed (View Workflow)
-
Priority: Major
-
Resolution: Done
-
Affects Version/s: None
-
Fix Version/s: None
-
Labels:None
-
Story Points:0.5
-
Epic Link:
-
Sprint:Fall 8, Spring 1, Spring 2, Spring 3, Spring 4, Spring 5, Spring 6
Description
Task: Update ProtAnnot so that it can work with main-JDK21.
Attachments
Issue Links
Activity
I accepted the new branch and tried to build the jar.
Bitbucket pipeline failed to build the new ProtAnnot 10.0.0 with this error:
[ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/ProtAnnotAction.java:[23,34] package com.google.common.eventbus does not exist [ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/ProtAnnotAction.java:[24,34] package com.google.common.eventbus does not exist [ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/model/ProtannotParser.java:[31,30] package com.google.common.base does not exist [ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/model/ProtannotParser.java:[32,34] package com.google.common.eventbus does not exist [ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/ProtAnnotService.java:[13,33] package com.google.common.collect does not exist [ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/ProtAnnotService.java:[14,33] package com.google.common.collect does not exist [ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/ProtAnnotService.java:[15,34] package com.google.common.eventbus does not exist [ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/GenomeView.java:[38,30] package com.google.common.base does not exist [ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/GenomeView.java:[39,34] package com.google.common.eventbus does not exist [ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/GenomeView.java:[40,34] package com.google.common.eventbus does not exist [ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/ProtAnnotPreferencesService.java:[14,34] package com.google.common.eventbus does not exist [ERROR] /opt/atlassian/pipelines/agent/build/src/main/java/org/lorainelab/igb/protannot/ProtAnnotAction.java:[164,13] cannot find symbol symbol: class EventBus
See: https://bitbucket.org/lorainelab/protannot/pipelines/results/25
attn: Nowlan Freese
Merged. New jar is built. See: protannot-10.0.0.jar in:
Was able to test locally on Mac through the App Manager, ProtAnnot installed and ran correctly.
Note that the branch with the changes currently in bitbucket is IGB_10_Alignment (not master). The bitbucket-pipeline is also pointing at hillrunner2008/igb-maven-install4j:I4J10-jre-21.0.1 whereas we are now using lorainelab/igb-maven-install4j:I4J10-jre-21.0.1-21.0.0 to build IGB, though that may change depending on IGBF-3588.
PR is merged. Ready for next steps.
attn: Nowlan Freese
Tested on Mac, Windows, and Linux from https://bitbucket.org/lorainelab/protannot/downloads/
Final step: release to IGB App Store.
To do: remove upper bound on IGB version.
Commit: https://bitbucket.org/nfreese/protannot/commits/9d586e6980990e4a1176fa209b1dfc9eb192c2ab
PR: https://bitbucket.org/lorainelab/protannot/pull-requests/22
In order to remove the upper bound we have to explicitly declare IGB dependency versions within the Import-Package. This had been done as part of IGBF-1906 for some of the apps, though not all.
I tested by changing the IGB version to 11 and seeing if ProtAnnot would install and work. ProtAnnot did work and there were no errors in the log.
Before proceeding, could you paste (in here) the OSGI tag contents from the MANIFEST.mf file packaged in the ProtAnnot bundle? Please also specify the version of the felix plugin that we're actually using to make the bundle.
I'd like to see those OSGI tags before and after the commit.
It just really seems like a weird thing that specifying the required version of IGB platform bundles as 10.0.0 – with no modifiers – would then allow the framework to install and run the bundle in a platform where all the platform bundles declare themselves to be version 11.0.0.
However, the POM configuration is only for the felix plugin. Who knows how that plugin is going to translate that configuration into the OSGI meta information stored in the bundles' MANIFEST?
Thank you for taking such care with all this!
Before:
Created-By: Apache Maven Bundle Plugin 5.1.9
Import-Package: com.affymetrix.common;version="[10.0,11)",com.affymetr
ix.genometry;version="[10.0,11)",com.affymetrix.genometry.comparator;
version="[10.0,11)",com.affymetrix.genometry.event;version="[10.0,11)
",com.affymetrix.genometry.span;version="[10.0,11)",com.affymetrix.ge
nometry.symmetry;version="[10.0,11)",com.affymetrix.genometry.symmetr
y.impl;version="[10.0,11)",com.affymetrix.genometry.thread;version="[
10.0,11)",com.affymetrix.genometry.util;version="[10.0,11)",com.affym
etrix.genoviz.awt;version="[1.1,2)",com.affymetrix.genoviz.bioviews;v
ersion="[1.1,2)",com.affymetrix.genoviz.event;version="[1.1,2)",com.a
ffymetrix.genoviz.glyph;version="[1.1,2)",com.affymetrix.genoviz.swin
g;version="[1.1,2)",com.affymetrix.genoviz.util;version="[1.1,2)",com
.affymetrix.genoviz.widget;version="[1.1,2)",com.affymetrix.genoviz.w
idget.tieredmap;version="[1.1,2)",com.affymetrix.igb.shared;version="
[10.0,11)",com.affymetrix.igb.swing;version="[10.0,11)",com.affymetri
x.igb.swing.jide;version="[10.0,11)",com.google.common.base;version="
[32.1,33)",com.google.common.collect;version="[32.1,33)",com.google.c
ommon.eventbus;version="[32.1,33)",jakarta.xml.bind;version="[4.0,5)"
,jakarta.xml.bind.annotation;version="[4.0,5)",java.awt,java.awt.data
transfer,java.awt.event,java.awt.geom,java.io,java.lang,java.lang.inv
oke,java.lang.reflect,java.math,java.net,java.text,java.util,java.uti
l.function,java.util.prefs,java.util.regex,java.util.stream,javax.swi
ng,javax.swing.border,javax.swing.table,javax.xml.namespace,javax.xml
.parsers,javax.xml.xpath,net.miginfocom.layout,net.miginfocom.swing,o
rg.apache.commons.io;version="[1.4,2)",org.apache.commons.lang3.text;
version="[3.4,4)",org.lorainelab.igb.genoviz.extensions;version="[10.
0,11)",org.lorainelab.igb.genoviz.extensions.glyph;version="[10.0,11)
",org.lorainelab.igb.image.exporter.service;version="[10.0,11)",org.l
orainelab.igb.javafx;version="[10.0,11)",org.lorainelab.igb.menu.api;
version="[10.0,11)",org.lorainelab.igb.menu.api.model;version="[10.0,
11)",org.lorainelab.igb.services;version="[10.0,11)",org.osgi.service
.component;version="[1.2,2)",org.slf4j;version="[1.7,2)",org.w3c.dom,
org.xml.sax
Tool: Bnd-6.3.1.202206071316
After:
Created-By: Apache Maven Bundle Plugin 5.1.9
Import-Package: com.affymetrix.common;version="10.0.0",com.affymetrix.
genometry;version="10.0.0",com.affymetrix.genometry.comparator;versio
n="10.0.0",com.affymetrix.genometry.event;version="10.0.0",com.affyme
trix.genometry.span;version="10.0.0",com.affymetrix.genometry.symmetr
y;version="10.0.0",com.affymetrix.genometry.symmetry.impl;version="10
.0.0",com.affymetrix.genometry.thread;version="10.0.0",com.affymetrix
.genometry.util;version="10.0.0",com.affymetrix.igb.shared;version="1
0.0.0",com.affymetrix.igb.swing;version="10.0.0",com.affymetrix.igb.s
wing.jide;version="10.0.0",org.lorainelab.igb.genoviz.extensions;vers
ion="10.0.0",org.lorainelab.igb.genoviz.extensions.glyph;version="10.
0.0",org.lorainelab.igb.image.exporter.service;version="10.0.0",org.l
orainelab.igb.javafx;version="10.0.0",org.lorainelab.igb.menu.api;ver
sion="10.0.0",org.lorainelab.igb.menu.api.model;version="10.0.0",org.
lorainelab.igb.services;version="10.0.0",com.affymetrix.genoviz.awt;v
ersion="[1.1,2)",com.affymetrix.genoviz.bioviews;version="[1.1,2)",co
m.affymetrix.genoviz.event;version="[1.1,2)",com.affymetrix.genoviz.g
lyph;version="[1.1,2)",com.affymetrix.genoviz.swing;version="[1.1,2)"
,com.affymetrix.genoviz.util;version="[1.1,2)",com.affymetrix.genoviz
.widget;version="[1.1,2)",com.affymetrix.genoviz.widget.tieredmap;ver
sion="[1.1,2)",com.google.common.base;version="[32.1,33)",com.google.
common.collect;version="[32.1,33)",com.google.common.eventbus;version
="[32.1,33)",jakarta.xml.bind;version="[4.0,5)",jakarta.xml.bind.anno
tation;version="[4.0,5)",java.awt,java.awt.datatransfer,java.awt.even
t,java.awt.geom,java.io,java.lang,java.lang.invoke,java.lang.reflect,
java.math,java.net,java.text,java.util,java.util.function,java.util.p
refs,java.util.regex,java.util.stream,javax.swing,javax.swing.border,
javax.swing.table,javax.xml.namespace,javax.xml.parsers,javax.xml.xpa
th,net.miginfocom.layout,net.miginfocom.swing,org.apache.commons.io;v
ersion="[1.4,2)",org.apache.commons.lang3.text;version="[3.4,4)",org.
osgi.service.component;version="[1.2,2)",org.slf4j;version="[1.7,2)",
org.w3c.dom,org.xml.sax
Tool: Bnd-6.3.1.202206071316
I'm following the same logic discussed and applied in IGBF-1906. The changes made in IGBF-1906 were undone by David for ProtAnnot when we were refactoring the app for JDK 21. I am now re-implementing them for the IGB dependencies. By declaring an import-package in the maven-bundle-plugin for the IGB dependencies with just a single version(i.e. 10.0.0), it sets the manifest's import-package version for those IGB dependencies to anything 10.0.0 or greater. Compare this to the normal convention of not passing anything in to the import-package as part of maven-bundle-plugin, which leads to the manifest giving an upper bound of version="[10.0,11)". It would be more "correct" to have the upper bound, as the assumption is that by changing to a new major version we are indicating that there are new changes that would break backwards compatibility. However, it would mean that anytime we changed the major version of IGB, we would need to re-release all apps, whether or not they were compatible.
Yes, I think what you have said is correct. I just wanted to double-check.
IBM WebSphere Application server documentation writes:
...Import-Package: org.apache.commons.logging;version="1.0.4"
Import-Package
This header declares the external dependencies of the bundle that the OSGi Framework uses to resolve the bundle. Specific versions or version ranges for each package can be declared. In this example manifest file, the org.apache.commons.logging package is required at Version 1.0.4 or later.
Link: https://www.ibm.com/docs/en/was/9.0.5?topic=files-example-osgi-bundle-manifest-file
The authoritative answer is available from osgi.org:
If a version range is specified as a single version, it must be interpreted as the range [version, infinity)
See:
All ProtAnnot PR's are now merged.
ProtAnnot 10.0.1 has been released to the app store: https://apps.bioviz.org/apps/org.lorainelab.igb.protannot#
Tested on Mac on IGB 10.0.0 as well as a development version of IGB with the IGB version set to 11. I was able to install and run ProtAnnot from the app store or app manager. The ProtAnnot icon was also visible from either the Tools menu or the right-click menu.
Closing ticket.
Pull request: https://bitbucket.org/lorainelab/protannot/pull-requests/17
Note that the pull request is not aimed at the master branch, we will need to merge it to master.