Tuscany
  1. Tuscany
  2. TUSCANY-3569

PolicyConfigurationException: The are unfulfilled intents for binding in reference

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: Java-SCA-1.6
    • Fix Version/s: Java-SCA-1.x
    • Component/s: Java SCA Policy
    • Labels:
      None
    • Environment:
      Windows

      Description

      I am tryng to run policy-security-token itest with little modification atcreation of Node. Originally this testcase creates SCA node with composite loading from file and it has definitions.xml. I made modification to create Node with coposite as String and haven't modified anything else.

      But, while running testcase with my change, it is throwing following exception. I have attached source that I am working with. could you help me out finding out the problem.

      May 24, 2010 6:33:26 PM org.apache.tuscany.sca.node.impl.NodeImpl <init>
      INFO: Creating node: HelloWorldService
      May 24, 2010 6:33:26 PM org.apache.tuscany.sca.node.impl.NodeImpl <init>
      INFO: Loading composite: HelloWorldService
      May 24, 2010 6:33:27 PM org.apache.tuscany.sca.node.impl.NodeImpl configureNode
      INFO: Loading contribution: file:/C:/development/source/tuscany-sca-1.6-src/itest/policy-security-token/
      May 24, 2010 6:33:27 PM org.apache.tuscany.sca.assembly.builder.impl.CompositePolicyBuilderImpl
      SEVERE: Policy Related Exception occured due to : org.apache.tuscany.sca.assembly.builder.impl.PolicyConfigurationException: The are unfulfilled intents for binding in reference - helloworldWS
      Unfulfilled Intents = [

      {http://www.osoa.org/xmlns/sca/1.0}

      authentication]
      May 24, 2010 6:33:27 PM org.apache.tuscany.sca.assembly.builder.impl.CompositePolicyBuilderImpl
      SEVERE: Policy Related Exception occured due to : org.apache.tuscany.sca.assembly.builder.impl.PolicyConfigurationException: The are unfulfilled intents for binding in reference - helloworldJMS
      Unfulfilled Intents = [

      {http://www.osoa.org/xmlns/sca/1.0}

      authentication]
      May 24, 2010 6:33:27 PM org.apache.tuscany.sca.assembly.builder.impl.CompositePolicyBuilderImpl
      SEVERE: Policy Related Exception occured due to : org.apache.tuscany.sca.assembly.builder.impl.PolicyConfigurationException: The following are unfulfilled intents for binding in service - HelloWorldService
      Unfulfilled Intents = [

      {http://www.osoa.org/xmlns/sca/1.0}

      authentication]
      May 24, 2010 6:33:27 PM org.apache.tuscany.sca.assembly.builder.impl.CompositePolicyBuilderImpl
      SEVERE: Policy Related Exception occured due to : org.apache.tuscany.sca.assembly.builder.impl.PolicyConfigurationException: The following are unfulfilled intents for binding in service - HelloWorldService
      Unfulfilled Intents = [

      {http://www.osoa.org/xmlns/sca/1.0}

      authentication]
      May 24, 2010 6:33:27 PM org.apache.tuscany.sca.assembly.builder.DefaultEndpointBuilder
      SEVERE: Policy Related Exception occured due to : org.apache.tuscany.sca.assembly.builder.impl.PolicyConfigurationException: The are unfulfilled intents for binding in reference - helloworldWS
      Unfulfilled Intents = [

      {http://www.osoa.org/xmlns/sca/1.0}

      authentication]
      org.osoa.sca.ServiceRuntimeException: org.apache.tuscany.sca.monitor.MonitorRuntimeException: org.apache.tuscany.sca.assembly.builder.impl.PolicyConfigurationException: The are unfulfilled intents for binding in reference - helloworldWS
      Unfulfilled Intents = [

      {http://www.osoa.org/xmlns/sca/1.0}

      authentication]
      at org.apache.tuscany.sca.node.impl.NodeImpl.analyzeProblems(NodeImpl.java:711)
      at org.apache.tuscany.sca.node.impl.NodeImpl.configureNode(NodeImpl.java:634)
      at org.apache.tuscany.sca.node.impl.NodeImpl.<init>(NodeImpl.java:447)
      at org.apache.tuscany.sca.node.impl.NodeFactoryImpl.createSCANode(NodeFactoryImpl.java:52)
      at org.apache.tuscany.sca.itest.TokenAuthTestCase.init(TokenAuthTestCase.java:99)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
      at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
      at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
      at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:27)
      at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31)
      at org.junit.runners.ParentRunner.run(ParentRunner.java:220)
      at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:46)
      at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
      at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
      at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
      at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
      at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
      Caused by: org.apache.tuscany.sca.monitor.MonitorRuntimeException: org.apache.tuscany.sca.assembly.builder.impl.PolicyConfigurationException: The are unfulfilled intents for binding in reference - helloworldWS
      Unfulfilled Intents = [

      {http://www.osoa.org/xmlns/sca/1.0}

      authentication]
      ... 21 more
      Caused by: org.apache.tuscany.sca.assembly.builder.impl.PolicyConfigurationException: The are unfulfilled intents for binding in reference - helloworldWS
      Unfulfilled Intents = [

      {http://www.osoa.org/xmlns/sca/1.0}

      authentication]
      at org.apache.tuscany.sca.assembly.builder.impl.PolicyConfigurationUtil.determineApplicableDomainPolicySets(PolicyConfigurationUtil.java:550)
      at org.apache.tuscany.sca.assembly.builder.impl.PolicyConfigurationUtil.determineApplicableBindingPolicySets(PolicyConfigurationUtil.java:525)
      at org.apache.tuscany.sca.assembly.builder.impl.BaseWireBuilderImpl.computePolicies(BaseWireBuilderImpl.java:1064)
      at org.apache.tuscany.sca.assembly.builder.impl.CompositePolicyBuilderImpl.build(CompositePolicyBuilderImpl.java:45)
      at org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl.build(CompositeBuilderImpl.java:241)
      at org.apache.tuscany.sca.node.impl.RuntimeBootStrapper.buildComposite(RuntimeBootStrapper.java:255)
      at org.apache.tuscany.sca.node.impl.NodeImpl.configureNode(NodeImpl.java:632)
      ... 19 more

      1. policy-security-token.zip
        36 kB
        Ramanjaneyulu Malisetti

        Activity

        Hide
        Mike Edwards added a comment -

        This problem is caused by invalid use of the SCAContribution class in the createSCANode method used to start the application:

        node = scaNodeFactory.createSCANode("HelloWorldService", composite1,new SCAContribution(contribName1,""));

        Note that the second parameter is "" - this should be the URL of the Contribution containing the artifacts needed by the supplied composite, but it is blank, so artifacts such as the definitions.xml file are not going to be found.

        The URL should be filled in with the location of the directory containing the Contribution (or alternative a ZIP containing the Contribution files)

        Show
        Mike Edwards added a comment - This problem is caused by invalid use of the SCAContribution class in the createSCANode method used to start the application: node = scaNodeFactory.createSCANode("HelloWorldService", composite1,new SCAContribution(contribName1,"")); Note that the second parameter is "" - this should be the URL of the Contribution containing the artifacts needed by the supplied composite, but it is blank, so artifacts such as the definitions.xml file are not going to be found. The URL should be filled in with the location of the directory containing the Contribution (or alternative a ZIP containing the Contribution files)
        Hide
        Simon Nash added a comment -

        There is a real issue here. I tried fixing the test case in the way that Mike has suggested but this didn't resolve the problem. I will investigate further and post more information when I have it.

        Show
        Simon Nash added a comment - There is a real issue here. I tried fixing the test case in the way that Mike has suggested but this didn't resolve the problem. I will investigate further and post more information when I have it.
        Hide
        Simon Nash added a comment -

        The problem was caused because NodeImpl was reading the composite content before the contributions had been loaded. This meant that the policySet definitions from the contribution weren't available for use by the composite.

        The test case also needs to be modified to load a contribution containing a definitions.xml file with the required policySet definitions, as Mike has pointed out.

        Fixed under revision r952186.

        Show
        Simon Nash added a comment - The problem was caused because NodeImpl was reading the composite content before the contributions had been loaded. This meant that the policySet definitions from the contribution weren't available for use by the composite. The test case also needs to be modified to load a contribution containing a definitions.xml file with the required policySet definitions, as Mike has pointed out. Fixed under revision r952186.

          People

          • Assignee:
            Simon Nash
            Reporter:
            Ramanjaneyulu Malisetti
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development