# Felix maven-bundle-plugin ServiceConfigurationError Completion50PostingsFormat does not exist

**URL:** <https://discuss.elastic.co/t/felix-maven-bundle-plugin-serviceconfigurationerror-completion50postingsformat-does-not-exist/147385>\
**Category:** Elasticsearch\
**Created:** [September 5, 2018, 11:22am UTC](https://discuss.elastic.co/t/felix-maven-bundle-plugin-serviceconfigurationerror-completion50postingsformat-does-not-exist/147385 "2018-09-05T11:22:44Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![abhiroyg](https://avatars.discourse-cdn.com/v4/letter/a/e9bcb4/32.png) [@abhiroyg](https://discuss.elastic.co/u/abhiroyg)\
**Post date:** [September 5, 2018, 11:22am UTC](https://discuss.elastic.co/t/felix-maven-bundle-plugin-serviceconfigurationerror-completion50postingsformat-does-not-exist/147385/1 "2018-09-05T11:22:44Z")

</div>

Hi,

I am facing the following exception with the following pom.xml, with commented portion in `maven-bundle-plugin` (with or without lucene dependency)

```
<dependency>
    <groupId>org.elasticsearch</groupId>
    <artifactId>elasticsearch</artifactId>
    <version>6.3.0</version>
</dependency>
<dependency>
    <groupId>org.elasticsearch.client</groupId>
    <artifactId>elasticsearch-rest-high-level-client</artifactId>
    <version>6.3.0</version>
</dependency>
<dependency>
    <groupId>org.elasticsearch.client</groupId>
    <artifactId>transport</artifactId>
    <version>6.3.0</version>
    <scope>provided</scope>
</dependency>
<dependency>
    <groupId>org.elasticsearch.plugin</groupId>
    <artifactId>parent-join-client</artifactId>
    <version>6.3.0</version>
</dependency>
<!-- <dependency>
        <groupId>org.apache.lucene</groupId>
        <artifactId>lucene-analyzers-common</artifactId>
        <version>7.3.1</version>
</dependency> -->

<plugin>
    <groupId>org.apache.felix</groupId>
    <artifactId>maven-bundle-plugin</artifactId>
    <version>2.5.4</version>
    <extensions>true</extensions>
    <configuration>
        <instructions>
            <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
            <Bundle-Version>${project.version}</Bundle-Version>
            <Private-Package>${bundle.namespace}.internal*</Private-Package>
            <Import-Package>!com.flipkart.zjsonpatch.*,*</Import-Package>
            <!-- <Embed-Transitive>true</Embed-Transitive>
            <Embed-Dependency>*;inline=META-INF/services/**</Embed-Dependency> -->
        </instructions>
    </configuration>
</plugin>

```

> java.lang.IllegalArgumentException: An SPI class of type org.apache.lucene.codecs.PostingsFormat with name 'Lucene50' does not exist. You need to add the corresponding JAR file supporting this SPI to your classpath. The current classpath supports the following names: [IDVersion]

And if I uncomment the portion in `maven-bundle-plugin`, I am getting the following portion

> java.util.ServiceConfigurationError: An SPI class of type org.apache.lucene.codecs.PostingsFormat with classname org.apache.lucene.search.suggest.document.Completion50PostingsFormat does not exist, please fix the file 'META-INF/services/org.apache.lucene.codecs.PostingsFormat' in your classpath.

Please help me in solving this issue. I have looked at other links where people recommended `maven-shade-plugin` in place of using `maven-assembly-plugin` but we are using OSGI in our company and would like to know a similar solution for Felix's `maven-bundle-plugin`

Thank you.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [October 3, 2018, 11:22am UTC](https://discuss.elastic.co/t/felix-maven-bundle-plugin-serviceconfigurationerror-completion50postingsformat-does-not-exist/147385/2 "2018-10-03T11:22:50Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
