Return-Path: X-Original-To: apmail-felix-dev-archive@www.apache.org Delivered-To: apmail-felix-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 23305105B7 for ; Tue, 17 Mar 2015 10:05:45 +0000 (UTC) Received: (qmail 49075 invoked by uid 500); 17 Mar 2015 10:05:38 -0000 Delivered-To: apmail-felix-dev-archive@felix.apache.org Received: (qmail 49002 invoked by uid 500); 17 Mar 2015 10:05:38 -0000 Mailing-List: contact dev-help@felix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@felix.apache.org Delivered-To: mailing list dev@felix.apache.org Received: (qmail 48989 invoked by uid 99); 17 Mar 2015 10:05:38 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 17 Mar 2015 10:05:38 +0000 Date: Tue, 17 Mar 2015 10:05:38 +0000 (UTC) From: "Jan Winter (JIRA)" To: dev@felix.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (FELIX-4640) missing (&(osgi.ee=JavaSE)(version=1.8)) when embedding in org.apache.felix.framework MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/FELIX-4640?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14364858#comment-14364858 ] Jan Winter commented on FELIX-4640: ----------------------------------- Where can I download a jar with fix? > missing (&(osgi.ee=JavaSE)(version=1.8)) when embedding in org.apache.felix.framework > ------------------------------------------------------------------------------------- > > Key: FELIX-4640 > URL: https://issues.apache.org/jira/browse/FELIX-4640 > Project: Felix > Issue Type: Bug > Components: Bundle Repository (OBR), Framework > Environment: any > Reporter: Jan Winter > Assignee: David Bosschaert > Fix For: bundlerepository-2.0.4 > > Attachments: cap.diff > > > When I try to deploy a bundle from a OBRepo occur the below error 'Unsatisfied requirement'. > g! obr:deploy any.bundle > Unsatisfied requirement(s): > --------------------------- > (&(osgi.ee=JavaSE)(version=1.8)) > I would expect that this capability will be provided by system-bundle. > g! felix:inspect capability osgi.ee > org.apache.felix.framework [0] provides: > ---------------------------------------- > osgi.ee; OSGi/Minimum [1.0.0, 1.1.0, 1.2.0] [UNUSED] > osgi.ee; JavaSE [1.0.0, 1.1.0, 1.2.0, 1.3.0, 1.4.0, 1.5.0, 1.6.0, 1.7.0, 1.8.0] > *My full runtime environment is.* > g! lb > START LEVEL 1 > ID|State |Level|Name > 0|Active | 0|System Bundle (4.4.0) > 1|Active | 1|Apache Felix Bundle Repository (2.0.2) > 2|Active | 1|bndlib (2.3.0.201405100607) > 3|Active | 1|biz.aQute.repository (2.1.0.062515_230REL) > 4|Active | 1|Java XML Streaming API (1.0.1.v201004272200) > 5|Active | 1|JAXP XML (1.3.4.v201005080400) > 6|Active | 1|Apache Felix Gogo Command (0.14.0) > 7|Active | 1|Apache Felix Gogo Runtime (0.12.1) > 8|Active | 1|Apache Felix Gogo Shell (0.10.0.v201212101605) > I found one related fact in 'org.apache.felix.bundlerepository-2.0.2/org.apache.felix.bundlerepository.impl.LocalResourceImpl.java'. > - declared 'osgi.ee' capabilities from framework-bundle will realized as 'ee=JavaSE-1.8' capability > - but the filter require 1 spitted capability ( and ) '(&(osgi.ee=JavaSE)(version=1.8))' > *Here the patch who works for me.* > 85c85,86 > < cap.addProperty(Capability.EXECUTIONENVIRONMENT, tokens.nextToken().trim()); > --- > > String eeValue = tokens.nextToken().trim(); > > cap.addProperty(Capability.EXECUTIONENVIRONMENT, eeValue); > 86a88,100 > > > > String[] split = eeValue.split("-"); > > switch (split.length) { > > case 2: > > String osgi_ee = "osgi." + Capability.EXECUTIONENVIRONMENT; > > CapabilityImpl cap2 = new CapabilityImpl(osgi_ee, new PropertyImpl[]{ > > new PropertyImpl(osgi_ee, null, split[0]), > > new PropertyImpl("version", null, split[1]) > > }); > > addCapability(cap2); > > break; > > } -- This message was sent by Atlassian JIRA (v6.3.4#6332)