Just a heads up: On March 24, 2025, starting at 4:30pm CDT / 19:30 UTC, the site will be undergoing scheduled maintenance for a few hours. During this time, the site might be unavailable for a short while. Thanks for your patience.
×I am trying to compile my plugin. But plugin is not getting enabled and i have this error:
Unresolved constraint in bundle com.atlassian.pl.jgit [114]: Unable to resolve 114.0: missing requirement [114.0] osgi.wiring.package; (osgi.wiring.package=com.atlassian.inject)
I tried other answers from here, but it doesn't work for me.
My pom:
<?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>com.atlassian.pl</groupId> <artifactId>jgit</artifactId> <version>1.0.0-SNAPSHOT</version> <organization> <name>Example Company</name> <url>http://www.example.com/</url> </organization> <name>jgit</name> <description>This is the com.atlassian.pl:jgit plugin for Atlassian JIRA.</description> <packaging>atlassian-plugin</packaging> <properties> <jira.version>7.1.0-QR20151229171111</jira.version> <amps.version>6.2.11</amps.version> <plugin.testrunner.version>2.0.0</plugin.testrunner.version> <atlassian.spring.scanner.version>1.2.13</atlassian.spring.scanner.version> <atlassian.plugin.key>${project.groupId}.${project.artifactId}</atlassian.plugin.key> <testkit.version>6.3.11</testkit.version> </properties> <repositories> <repository> <id>com.atlassian</id> <name>Atlassian Repo</name> <url>https://maven.atlassian.com/content/repositories/atlassian-public/</url> </repository> </repositories> <dependencies> <dependency> <groupId>com.atlassian.jira</groupId> <artifactId>jira-api</artifactId> <version>${jira.version}</version> <scope>provided</scope> </dependency> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>4.12</version> <scope>test</scope> </dependency> <dependency> <groupId>com.atlassian.plugin</groupId> <artifactId>atlassian-spring-scanner-annotation</artifactId> <version>${atlassian.spring.scanner.version}</version> <scope>compile</scope> </dependency> <dependency> <groupId>com.atlassian.plugin</groupId> <artifactId>atlassian-spring-scanner-runtime</artifactId> <version>${atlassian.spring.scanner.version}</version> <scope>runtime</scope> </dependency> <dependency> <groupId>javax.inject</groupId> <artifactId>javax.inject</artifactId> <version>1</version> <scope>provided</scope> </dependency> <!--Для работы с гитлабом--> <dependency> <groupId>org.gitlab</groupId> <artifactId>java-gitlab-api</artifactId> <version>1.2.8</version> <scope>compile</scope> </dependency> <!--Для мерджинатора--> <dependency> <groupId>com.atlassian.jira</groupId> <artifactId>jira-rest-java-client-api</artifactId> <version>4.0.0</version> <scope>compile</scope> </dependency> <dependency> <groupId>com.atlassian.jira</groupId> <artifactId>jira-rest-java-client-core</artifactId> <version>4.0.0</version> <scope>compile</scope> </dependency> <dependency> <groupId>com.atlassian.fugue</groupId> <artifactId>fugue</artifactId> <version>2.6.0</version> <scope>compile</scope> </dependency> <!--Для настройки и работы с базой--> <dependency> <groupId>com.atlassian.activeobjects</groupId> <artifactId>activeobjects-plugin</artifactId> <version>1.2.3</version> <scope>provided</scope> </dependency> <!--Ключик--> <dependency> <groupId>com.atlassian.sal</groupId> <artifactId>sal-api</artifactId> <scope>provided</scope> </dependency> <dependency> <groupId>com.atlassian.templaterenderer</groupId> <artifactId>atlassian-template-renderer-api</artifactId> <scope>provided</scope> </dependency> <!--<dependency>--> <!--<groupId>org.springframework</groupId>--> <!--<artifactId>spring-context</artifactId>--> <!--<version>4.1.6.RELEASE</version>--> <!--<scope>provided</scope>--> <!--</dependency>--> </dependencies> <dependencyManagement> <dependencies> <dependency> <groupId>com.atlassian.platform</groupId> <artifactId>platform</artifactId> <version>3.0.0</version> <type>pom</type> <scope>import</scope> </dependency> <dependency> <groupId>com.atlassian.platform</groupId> <artifactId>third-party</artifactId> <version>3.0.0</version> <type>pom</type> <scope>import</scope> </dependency> </dependencies> </dependencyManagement> <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>3.6.1</version> <configuration> <source>1.8</source> <target>1.8</target> </configuration> </plugin> <plugin> <groupId>com.atlassian.maven.plugins</groupId> <artifactId>maven-jira-plugin</artifactId> <version>${amps.version}</version> <extensions>true</extensions> <configuration> <productVersion>${jira.version}</productVersion> <productDataVersion>${jira.version}</productDataVersion> <enableQuickReload>true</enableQuickReload> <enableFastdev>false</enableFastdev> <instructions> <Export-Package> com.atlassian.pl.jgit.api, </Export-Package> <Import-Package> org.springframework.osgi.*;resolution:="optional", org.eclipse.gemini.blueprint.*;resolution:="optional", * <!--*;version="0";resolution:="optional"--> <!--!org.springframework.osgi.service.exporter.support,--> <!--!org.springframework.osgi.service.importer.support,--> <!--org.eclipse.gemini.blueprint.*;resolution:="optional",--> <!--*--> <!--org.springframework.osgi.*;resolution:="optional",--> <!--org.eclipse.gemini.blueprint.*;resolution:="optional",--> <!--com.atlassian.inject;resolution:="optional",--> <!--com.sun.xml.fastinfoset.sax;resolution:="optional",--> <!--com.sun.xml.fastinfoset.stax;resolution:="optional",--> <!--groovy.lang;resolution:="optional",--> <!--groovy.xml;resolution:="optional",--> <!--joptsimple;resolution:="optional",--> <!--net.*;resolution:="optional",--> <!--org.apache.tools.ant;resolution:="optional",--> <!--org.apache.tools.ant.types;resolution:="optional",--> <!--*--> </Import-Package> <Spring-Context>*</Spring-Context> <!--<Embed-Dependency>jira-rest-java-client-core</Embed-Dependency>--> </instructions> </configuration> </plugin> <plugin> <groupId>com.atlassian.plugin</groupId> <artifactId>atlassian-spring-scanner-maven-plugin</artifactId> <version>${atlassian.spring.scanner.version}</version> <executions> <execution> <goals> <goal>atlassian-spring-scanner</goal> </goals> <phase>process-classes</phase> </execution> </executions> <configuration> <scannedDependencies> <dependency> <groupId>com.atlassian.plugin</groupId> <artifactId>atlassian-spring-scanner-external-jar</artifactId> </dependency> </scannedDependencies> <verbose>false</verbose> </configuration> </plugin> </plugins> </build> </project>
If i change import-package to
org.springframework.osgi.*;resolution:="optional", org.eclipse.gemini.blueprint.*;resolution:="optional", *;version="0";resolution:="optional"
I have the 50! errors and Jira startup failed
Hi Александр,
Please add this in all our dependencies.
<scope>provided</scope>
It may resolve your problem.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.