How to debug a plugin?
Hi,
I am breaking my head for quite long to figure out how to write a simple plugin , deploy it and debug it.
Yes I have seen this one https://answers.nuxeo.com/general/q/0ebf800f33c944a99cb33f41c284f2fb/Using-an-external-sso-system-for-authentication
But it's outdated and its link does not work.
If Nuxeo is providing it as a development platform as well then they should also provide simple examples on how to do. Very poor documentation, is it done purposefully so that user go for your pricey support ?
I think the nuxeo-marketplace-sample is the most helpful code sample for learning this: https://github.com/nuxeo/nuxeo-marketplace-sample
Another, more minimal and more up-to-date place to start is Creating Nuxeo Packages.
In my experience, SSO authentication can be a little tricky because it often touches the servlet layer as well as the Nuxeo framework for things like JSESSIONID cookies.So you'll have to have a command of those technologies as well.
Fails with the error [ERROR] [ERROR] Some problems were encountered while processing the POMs: [FATAL] Non-resolvable parent POM for org.nuxeo.sample.project:my-project-package:[unknown-version]: Could not transfer artifact org.nuxeo.sample.project:my-project-parent:pom:1.0-SNAPSHOT from/to nuxeo-studio (https://connect.nuxeo.com/nuxeo/site/studio/maven): Not authorized , ReasonPhrase:Unauthorized. and 'parent.relativePath' points at wrong local POM @ line 3, column 11 @ [ERROR] The build could not read 1 project -> [Help 1] [ERROR] [ERROR] The project org.nuxeo.sample.project:my-project-package:unknown-version has 1 error [ERROR] Non-resolvable parent POM for org.nuxeo.sample.project:my-project-package:[unknown-version]: Could not transfer artifact org.nuxeo.sample.project:my-project-parent:pom:1.0-SNAPSHOT from/to nuxeo-studio (https://connect.nuxeo.com/nuxeo/site/studio/maven): Not authorized , ReasonPhrase:Unauthorized. and 'parent.relativePath' points at wrong local POM @ line 3, column 11 -> [Help 2] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException [ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableModelException
…sigh…
We're open to suggestions on how the documentation can be improved.
Without seeing exactly the code / files you have in your project it's hard for us to help.
Also it says to use .zip for pacakaging but somewhere else i read that package system uses .jar so i changed that too because it did not work for me.
Now i am trying to make the loginplugin like how its done here https://www.nuxeo.com/blog/guest-post-integrating-single-sign-sso-nuxeo-case-management/
But it says to update some manifest and other things which i did not find in the generated files by the CLI, so my struggle continues to figure out what are thes files and they have added two java files whether they are in diferent projects or part of same plugin I do not know either.
I consider myself an experienced .Net Developer and worked on lot of products and used various API and developer platform. so I am not so naive in development. So I can find stuffs by myself but here I am failing quite often which frustrates me.
And i completely understand documentation is a tough job for any company but it has to be done.