Ard Schrijvers pushed to branch feature/wpm at cms-community / 
hippo-site-toolkit


Commits:
bd48e3ff by Ard Schrijvers at 2017-04-18T17:17:06+02:00
HSTTWO-3959 Load channel nodes from below the hst:configuration node instead of 
below hst:channels

Note : Unit and integration tests still need to be fixed

With this refactoring, channel nodes are from now on stored below the hst 
configuration, for example instead of
+ hst:hst
  + hst:channels
  | + myproject
  | |  + hst:channelinfo
  + hst:configurations
    + myproject

as

+ hst:hst
  + hst:channels
  + hst:configurations
    + myproject
      + hst:channel
        + hst:channelinfo

note that the /hst:hst/hst:channels node for now I kept, because based on this 
node,
a cms user is webmaster or admin on channels.

Next this, I also added support for hst:channel inheritance: Aka, if the 
hst:configuration
is inherited from another channel, the channel info is also inherited. In this 
case
the channel settings in the channel manager are not editable.

Also, the hst:channel node has to be in the hst:workspace to be editable! Thus 
even if the
hst:channel is not inherited, it's settings are only editable if the 
channel info node is
in the hst:workspace, thus as follows:

+ hst:hst
  + hst:channels
  + hst:configurations
    + myproject
      + hst:workspace
        + hst:channel
          + hst:channelinfo

Since the hst:channel loading has now been completely changed, also caching is 
fixed: Aka,
channel loading now piggy backs on the same caching and invalidation mechanism 
as other
hst configuration objects.

Another improvement that has been done is the general hst preview creation: 
When creating
a preview, we only copy the hst:workspace from now on to preview, and have the 
preview
extend the live. Thus for example before we had:
+ hst:hst
  + hst:configurations
    + common
    + myproject (hst:inheritsfrom = ../common)
    |  + hst:sitemap
    |  + hst:pages
    |  + hst:components
    |  + hst:templates
    |  + hst:workspace
    + myproject-preview (hst:inheritsfrom = ../common)
       + hst:sitemap
       + hst:pages
       + hst:components
       + hst:templates
       + hst:workspace

>From now on we have:

+ hst:hst
  + hst:configurations
    + common
    + myproject (hst:inheritsfrom = ../common)
    |  + hst:sitemap
    |  + hst:pages
    |  + hst:components
    |  + hst:templates
    |  + hst:workspace
    + myproject-preview (hst:inheritsfrom = ../myproject)
       + hst:workspace

Note the preview inheriting from ../myproject (thus live!)

- - - - -


30 changed files:

- api/src/main/java/org/hippoecm/hst/configuration/HstNodeTypes.java
- api/src/main/java/org/hippoecm/hst/configuration/channel/Channel.java
- api/src/main/java/org/hippoecm/hst/configuration/hosting/Mount.java
- api/src/main/java/org/hippoecm/hst/configuration/hosting/MutableMount.java
- 
api/src/main/java/org/hippoecm/hst/configuration/internal/ContextualizableMount.java
- api/src/main/java/org/hippoecm/hst/configuration/site/HstSite.java
- 
client-modules/cms-rest/src/main/java/org/hippoecm/hst/cmsrest/services/ChannelsResource.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/AbstractConfigResource.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/ChannelServiceImpl.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/MountResource.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/RootResource.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/helpers/AbstractHelper.java
- + 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/helpers/ChannelHelper.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/helpers/ContainerHelper.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/helpers/ContainerItemHelper.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/helpers/PagesHelper.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/helpers/SiteMapHelper.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/helpers/SiteMenuHelper.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/helpers/SiteMenuItemHelper.java
- 
client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/jaxrs/services/helpers/TemplateHelper.java
- 
client-modules/page-composer/src/main/resources/org/hippoecm/hst/pagecomposer/SpringComponentManager-pagecomposer.xml
- 
commons/src/main/java/org/hippoecm/hst/core/hosting/CustomMountAndVirtualCmsHostAugmenter.java
- 
commons/src/main/java/org/hippoecm/hst/core/hosting/CustomMountAndVirtualHostAugmenter.java
- 
components/core/src/main/java/org/hippoecm/hst/configuration/cache/HstConfigurationLoadingCache.java
- 
components/core/src/main/java/org/hippoecm/hst/configuration/channel/ChannelManagerImpl.java
- 
components/core/src/main/java/org/hippoecm/hst/configuration/channel/ChannelPropertyMapper.java
- 
components/core/src/main/java/org/hippoecm/hst/configuration/hosting/MountService.java
- 
components/core/src/main/java/org/hippoecm/hst/configuration/hosting/VirtualHostsService.java
- 
components/core/src/main/java/org/hippoecm/hst/configuration/site/HstSiteService.java
- 
components/core/src/main/java/org/hippoecm/hst/site/request/MountDecoratorImpl.java


The diff was not included because it is too large.


View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-site-toolkit/commit/bd48e3ff97c0bf4410b289a2341ebeff35d8e6e9
_______________________________________________
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn

Reply via email to