Fuse: org.osgi.service.blueprint.container.ComponentDefinitionException: Unable to find a matching constructor on class

Solution Verified - Updated -

Issue

  • After migrating from spring-dm to blueprint, the bundle is throwing following exception:
org.osgi.service.blueprint.container.ComponentDefinitionException: Unable to find a matching constructor on class org.example.TestClass for arguments [] when instanciating bean XSDDateTimeFormatter
        at org.apache.aries.blueprint.container.BeanRecipe.getInstanceFromType(BeanRecipe.java:355) ~[!/:1.10.3]
        at org.apache.aries.blueprint.container.BeanRecipe.getInstance(BeanRecipe.java:283) ~[!/:1.10.3]
        at org.apache.aries.blueprint.container.BeanRecipe.internalCreate2(BeanRecipe.java:685) ~[!/:1.10.3]
        at org.apache.aries.blueprint.container.BeanRecipe.internalCreate(BeanRecipe.java:666) ~[!/:1.10.3]
        at org.apache.aries.blueprint.di.AbstractRecipe$1.call(AbstractRecipe.java:81) ~[!/:1.10.3]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_332]

Environment

  • Red Hat Fuse
    • 6.x (Karaf)
    • 7.x (Karaf)

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content