Deploy Microsoft Azure API jar on karaf

ⅰ亾dé卋堺 提交于 2019-12-12 05:36:18

问题


i am new to Maven and OSGI, can anyone please help me knowing how to deploy Microsoft Azure API jar on karaf OSGI container? Following is pom content of my Maven project. com.microsoft.windowsazure microsoft-windowsazure-api 0.4.3

    <dependency>
        <groupId>org.apache.commons</groupId>
        <artifactId>commons-lang3</artifactId>
        <version>3.1</version>
    </dependency>
    <dependency>
        <groupId>commons-logging</groupId>
        <artifactId>commons-logging</artifactId>
        <version>1.1.1</version>
    </dependency>
    <dependency>
        <groupId>org.codehaus.jackson</groupId>
        <artifactId>jackson-core-asl</artifactId>
        <version>1.9.2</version>
    </dependency>
    <dependency>
        <groupId>org.codehaus.jackson</groupId>
        <artifactId>jackson-jaxrs</artifactId>
        <version>1.9.2</version>
    </dependency>
    <dependency>
        <groupId>org.codehaus.jackson</groupId>
        <artifactId>jackson-mapper-asl</artifactId>
        <version>1.9.2</version>
    </dependency>
    <dependency>
        <groupId>org.codehaus.jackson</groupId>
        <artifactId>jackson-xc</artifactId>
        <version>1.9.2</version>
    </dependency>
    <dependency>
        <groupId>javax.inject</groupId>
        <artifactId>javax.inject</artifactId>
        <version>1</version>
    </dependency>
    <dependency>
        <groupId>com.sun.xml.bind</groupId>
        <artifactId>jaxb-impl</artifactId>
        <version>2.2.3-1</version>
    </dependency>
    <dependency>
        <groupId>com.sun.jersey</groupId>
        <artifactId>jersey-client</artifactId>
        <version>1.13</version>
    </dependency>
    <dependency>
        <groupId>com.sun.jersey</groupId>
        <artifactId>jersey-core</artifactId>
        <version>1.13</version>
    </dependency>
    <dependency>
        <groupId>com.sun.jersey</groupId>
        <artifactId>jersey-json</artifactId>
        <version>1.13</version>
    </dependency>
    <dependency>
        <groupId>org.codehaus.jettison</groupId>
        <artifactId>jettison</artifactId>
        <version>1.1</version>
    </dependency>
    <dependency>
        <groupId>javax.mail</groupId>
        <artifactId>mail</artifactId>
        <version>1.4.5</version>
    </dependency>

i have embedded dependencies like following

                                         <Embed-Dependency>
                        microsoft-windowsazure-api,
                        commons-lang3,
                        commons-logging,
                        jackson-core-asl,
                        jackson-jaxrs,
                        jackson-mapper-asl,
                        jackson-xc,
                        javax.inject,
                        jaxb-impl,
                        jersey-client,
                        jersey-core,
                        jersey-json,
                        jettison,
                        mail
                    </Embed-Dependency>

When i do this it keeps showing missing dependencies for different packages. i have imported all packages (*) in pom.


回答1:


download bnd.jar (bundle tool)

keep azur and bnd both jar in a directory

go to that directory and run following command

java -jar bnd.jar wrap microsoft-windowsazure-api 0.4.3.jar

tada... your bundle is ready, just deploy it and continue your work :)




回答2:


Take a look at jcloud feature for Karaf it also contains some bundles for azure. I'm sure this will give you a list of bundles working.



来源:https://stackoverflow.com/questions/17725933/deploy-microsoft-azure-api-jar-on-karaf

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!