Hi Pierre, Thank you for the input. I'm not sure what is your suggestion? Are you recommending that we handle the plugins in the hot-deploy folder?
Taher Alkhateeb On Aug 2, 2016 7:28 PM, "Pierre Smits" <[email protected]> wrote: > Hi all, > > Thanks, Taher, for looking into the code. > > Deploying 'plugins' and/or external components in the hot-deploy folder > achieves the same result. And then we wouldn't need the whole code set to > take components in the specialpurpose folder into consideration when > building and running OFBiz. > > Best regards, > > > > Pierre Smits > > ORRTIZ.COM <http://www.orrtiz.com> > OFBiz based solutions & services > > OFBiz Extensions Marketplace > http://oem.ofbizci.net/oci-2/ > > On Tue, Aug 2, 2016 at 4:37 PM, Taher Alkhateeb < > [email protected]> > wrote: > > > Hi Pierre, All > > > > I was looking through the code and with a little bit of work on > > ComponentContainer, ComponentLoaderConfig I think we can fix this issue. > > > > So +1 for allowing zero components in specialpurpose. This is a good step > > towards implementing the plugins logic as you stated. > > > > Taher Alkhateeb > > > > On Tue, Aug 2, 2016 at 12:51 PM, Taher Alkhateeb < > > [email protected] > > > wrote: > > > > > Hi Pierre, > > > > > > This is a minor issue that we can fix easily by looking at the XML > > parsing > > > code I don't think it's a big deal. > > > > > > I am assuming you're working on the ecommerce demo data right? For > > testing > > > purposes for now I would suggest that you enable the example component, > > it > > > does not have anything required by the inner components. > > > > > > Taher Alkhateeb > > > > > > On Aug 2, 2016 12:30 PM, "Pierre Smits" <[email protected]> > wrote: > > > > > >> Hi all, > > >> > > >> While working on OFBIZ-7016 (removing dependencies on e-commerce), I > > >> tested > > >> also whether it was possible to do a deployment without any of the > > special > > >> purpose components activated. > > >> First, I tested this by commenting out all components in the > > >> component-load.xml file in the specialpurpose folder. > > >> > > >> This generated following error: > > >> > > >> 2016-08-02 11:18:38,224 |main |ComponentContainer > > >> |I| Auto-Loading component directory : > > >> [/Users/pierre/dev/ofbiz/ofbiz-gradle/specialpurpose] > > >> > > >> Exception in thread "main" java.lang.NullPointerException > > >> > > >> at > > >> > > > java.util.Collections$UnmodifiableCollection.<init>(Collections.java:1026) > > >> > > >> at > java.util.Collections$UnmodifiableList.<init>(Collections.java:1302) > > >> > > >> at java.util.Collections.unmodifiableList(Collections.java:1287) > > >> > > >> at > > >> > > >> > > > org.apache.ofbiz.base.component.ComponentLoaderConfig.getComponentsFromConfig(ComponentLoaderConfig.java:105) > > >> > > >> at > > >> > > >> > > > org.apache.ofbiz.base.container.ComponentContainer.loadComponentDirectory(ComponentContainer.java:144) > > >> > > >> at > > >> > > >> > > > org.apache.ofbiz.base.container.ComponentContainer.loadComponentFromConfig(ComponentContainer.java:129) > > >> > > >> at > > >> > > >> > > > org.apache.ofbiz.base.container.ComponentContainer.loadComponents(ComponentContainer.java:95) > > >> > > >> at > > >> > > >> > > > org.apache.ofbiz.base.container.ComponentContainer.init(ComponentContainer.java:73) > > >> > > >> at > > >> > > >> > > > org.apache.ofbiz.base.container.ContainerLoader.loadContainer(ContainerLoader.java:186) > > >> > > >> at > > >> > > >> > > > org.apache.ofbiz.base.container.ContainerLoader.load(ContainerLoader.java:98) > > >> > > >> at > > >> > > >> > > > org.apache.ofbiz.base.start.StartupControlPanel.loadStartupLoaders(StartupControlPanel.java:249) > > >> > > >> at > > >> > > >> > > > org.apache.ofbiz.base.start.StartupControlPanel.start(StartupControlPanel.java:72) > > >> > > >> at org.apache.ofbiz.base.start.Start.main(Start.java:84) > > >> > > >> I also tested with the component-load.xml file removed from the > > >> specialpurpose folder. > > >> > > >> This generated the following build error: > > >> > > >> FAILURE: Build failed with an exception. > > >> > > >> > > >> * Where: > > >> > > >> Script '/Users/pierre/dev/ofbiz/ofbiz-gradle/common.gradle' line: 22 > > >> > > >> > > >> * What went wrong: > > >> > > >> A problem occurred evaluating settings 'ofbiz'. > > >> > > >> > > /Users/pierre/dev/ofbiz/ofbiz-gradle/specialpurpose/component-load.xml > > >> (No such file or directory) > > >> > > >> It seems to me there is - currently - a hard coded requirement on > > >> > > >> 1. the existence of component-load.xml in the special purpose > folder, > > >> and > > >> 2. at least 1 special purpose component listed in the > > >> component-load.xml > > >> file > > >> > > >> However, it is very well possible that an adopter decides to *not* use > > any > > >> of the special purpose components. And also, the discussion of the > > 'plugin > > >> deployment/activation' solution seems to suggest that it is even > > possible > > >> to deactivate all special purpose components (remove from > > >> component-load.xml?). > > >> > > >> I believe we should more carefully look into this regarding how we > deal > > >> with this scenario. > > >> > > >> WDYT? > > >> > > >> Best regards, > > >> > > >> Pierre Smits > > >> > > >> ORRTIZ.COM <http://www.orrtiz.com> > > >> OFBiz based solutions & services > > >> > > >> OFBiz Extensions Marketplace > > >> http://oem.ofbizci.net/oci-2/ > > >> > > > > > >
