Re: Drools can't be activated after pushing policies from PAP to PDP-D. #policy #controlloop


Sandeep Sharma
 

Hi Charlton,
One work around worked for me. So this is the flow I performed,
1. On the policy nexus http://<ONAP node>:30236/nexus/#, create a proxy repository pointing to https://nexus.onap.org/content/repositories/releases/
2. On the drools pod, update the settings.xml to have a pointer to the proxy repository created. Following is how my settings.xml looks,
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
          xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
 
<profiles>
 
<profile>
<id>policy-releases</id>
 
<repositories>
<repository>
<id>policy-nexus-releases</id>
<url>http://nexus:8081/nexus/content/repositories/releases/</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
<repository>
<id>policy-nexus-releases</id>
<url>http://nexus:8081/nexus/content/repositories/proxy/</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
 
</profile>
 
<profile>
<id>policy-snapshots</id>
 
<repositories>
<repository>
<id>policy-nexus-snapshots</id>
<url>http://nexus:8081/nexus/content/repositories/snapshots/</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</snapshots>
</repository>
</repositories>
 
</profile>
 
<profile>
<id>onap-releases</id>
 
<repositories>
<repository>
<id>onap-releases</id>
<name>onap-releases</name>
<url>https://nexus.onap.org/content/repositories/releases/</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
 
</profile>
 
<profile>
<id>onap-staging</id>
 
<repositories>
<repository>
<id>onap-staging</id>
<name>onap-staging</name>
<url>https://nexus.onap.org/content/repositories/staging/</url>
<releases>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
 
</profile>
 
<profile>
 
<id>onap-snapshots</id>
 
<repositories>
<repository>
<id>onap-snapshots</id>
<name>onap-snapshots</name>
<url>https://nexus.onap.org/content/repositories/snapshots/</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</snapshots>
</repository>
</repositories>
 
</profile>
 
</profiles>
 
<activeProfiles>
<activeProfile>policy-releases</activeProfile>
<activeProfile>policy-snapshots</activeProfile>
</activeProfiles>
 
<servers>
<server>
<id>policy-nexus-snapshots</id>
<username>admin</username>
<password>admin123</password>
</server>
<server>
<id>policy-nexus-releases</id>
<username>admin</username>
<password>admin123</password>
</server>
</servers>
 
</settings>

3. Execute the push_policies.sh on the pap pod. 

This should resolve the amsterdam rules dependencies in the drools.
-Sandeep

Join onap-discuss@lists.onap.org to automatically receive all group messages.