Custom validation rules plugin not loading

Hi.
I just created a plugin for a custom validation rule using the Tutorial at
https://wiki.eclipse.org/Capella/Tutorials/Extensibility/Validation_Rules
After meddling with the Capella Studio settings I was able to have a project free of errors and warnings and generate the .zip with the .jar plugin file.
I installed it in the Capella 1.4.0\eclipse\dropins\plugins folder as stated in the Tutorial.
Tried to check in Capella but it doesn’t load the plugin. I checked the Validation rules to see if the rule was added and it wasn’t there. I checked the Error log and couldn’t find anything related to the plugin. I searched for my plugin on the list in About Capella > Installation Details > Plug-ins tab and nothing. It seems to be completely ignored.
I’d like to know if there’s any way I can make Capella load (or try to load) the plug-in I created…

Hi.
I just created a plugin for a custom validation rule using the Tutorial at
https://wiki.eclipse.org/Capella/Tutorials/Extensibility/Validation_Rules
After meddling with the Capella Studio settings I was able to have a project free of errors and warnings and generate the .zip with the .jar plugin file.
I installed it in the Capella 1.4.0\eclipse\dropins\plugins folder as stated in the Tutorial.
Tried to check in Capella but it doesn’t load the plugin. I checked the Validation rules to see if the rule was added and it wasn’t there. I checked the Error log and couldn’t find anything related to the plugin. I searched for my plugin on the list in About Capella > Installation Details > Plug-ins tab and nothing. It seems to be completely ignored.
I’d like to know if there’s any way I can make Capella load (or try to load) the plug-in I created…

I’ll add more information to help people engage in this post :smiley:
About the project I built in Capella Studio (KitAlpha):
MANIFEST.MF file contents:
The CapellaTutorialValidationRule.java file contents:
My plugin.xml file contents:
My build.properties file contents:
Can anyone see a problem here? Using Capella [Studio] v1.4.0

I’ll add more information to help people engage in this post :smiley:
About the project I built in Capella Studio (KitAlpha):
MANIFEST.MF file contents:
The CapellaTutorialValidationRule.java file contents:
My plugin.xml file contents:
My build.properties file contents:
Can anyone see a problem here? Using Capella [Studio] v1.4.0

Hi Fabio,
I think the issue is in you MANIFEST.NF file. It is missing the dependency to org.eclipse.emf.validation. (and you have declared quite a few dependencies that are not required, but it should be blocking though).
Here is my MANIFEST.MF file, I did the same thing as you and it worked:
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: MyValidationRule
Bundle-SymbolicName: MyValidationRule;singleton:=true
Bundle-Version: 1.0.0.qualifier
Automatic-Module-Name: MyValidationRule
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
Require-Bundle: org.eclipse.emf.validation;bundle-version=“1.8.0”,
org.polarsys.capella.core.validation;bundle-version=“1.4.0”
Export-Package: myfirstvalidationrule

Hi Fabio,
I think the issue is in you MANIFEST.NF file. It is missing the dependency to org.eclipse.emf.validation. (and you have declared quite a few dependencies that are not required, but it should be blocking though).
Here is my MANIFEST.MF file, I did the same thing as you and it worked:
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: MyValidationRule
Bundle-SymbolicName: MyValidationRule;singleton:=true
Bundle-Version: 1.0.0.qualifier
Automatic-Module-Name: MyValidationRule
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
Require-Bundle: org.eclipse.emf.validation;bundle-version=“1.8.0”,
org.polarsys.capella.core.validation;bundle-version=“1.4.0”
Export-Package: myfirstvalidationrule

Hi Stephane, thanks for your response,
I added the ‘org.polarsys.capella.core.validation;bundle-version=“1.4.0”’ line to my MANIFEST.MF file but it still did not work.
Then I noticed the Require-Bundle header in my MANIFEST.MF file was different of yours:
Require-Bundle: org.polarsys.capella.core.validation;bundle-version=“1.4.0”,
I replaced with yours and it worked! Thanks a lot for the help!
Also, I noticed I posted this Capella-Studio related question in the Capella-General forum, if you are or know the moderator, I’d like to request this topic to be moved to the Capella-Studio forum, if possible.
Thanks again!

Hi Stephane, thanks for your response,
I added the ‘org.polarsys.capella.core.validation;bundle-version=“1.4.0”’ line to my MANIFEST.MF file but it still did not work.
Then I noticed the Require-Bundle header in my MANIFEST.MF file was different of yours:
Require-Bundle: org.polarsys.capella.core.validation;bundle-version=“1.4.0”,
I replaced with yours and it worked! Thanks a lot for the help!
Also, I noticed I posted this Capella-Studio related question in the Capella-General forum, if you are or know the moderator, I’d like to request this topic to be moved to the Capella-Studio forum, if possible.
Thanks again!

Well, I may be wrong, but your question is related to adding validation rules to Capella, I would see it in the Capella workbench forum :slight_smile:

Well, I may be wrong, but your question is related to adding validation rules to Capella, I would see it in the Capella workbench forum :slight_smile:

Hi,
Do you have exported your jar using “File > Export > Plugin Development > Deployable plug-ins and fragments” ?
The “File > Export > Java > JAR” doesn’t export a plugin that can be installed directly on Eclipse dropins folder.
I have updated the tutorial for this step.
https://github.com/eclipse/capella/wiki/Create-Addons#export-as-deployable-plugin
Regards
Philippe

Hi,
Do you have exported your jar using “File > Export > Plugin Development > Deployable plug-ins and fragments” ?
The “File > Export > Java > JAR” doesn’t export a plugin that can be installed directly on Eclipse dropins folder.
I have updated the tutorial for this step.
https://github.com/eclipse/capella/wiki/Create-Addons#export-as-deployable-plugin
Regards
Philippe

Hi Philippe, I used “File > Export > Plugin Development > Deployable plug-ins and fragments”, thanks for your answer and updating the tutorial!

Hi Philippe, I used “File > Export > Plugin Development > Deployable plug-ins and fragments”, thanks for your answer and updating the tutorial!

By the way,
I’ve already fixed the issue by following Stéphane’s directions. It works great!

By the way,
I’ve already fixed the issue by following Stéphane’s directions. It works great!