diff --git a/buildcallbacks.xml b/buildcallbacks.xml index 134e055..1277ff2 100644 --- a/buildcallbacks.xml +++ b/buildcallbacks.xml @@ -1,39 +1,38 @@ - - + - - + - + - + + + + + + + + + + + + - diff --git a/extensioninfo.xml b/extensioninfo.xml index 07459e1..7d73ee8 100644 --- a/extensioninfo.xml +++ b/extensioninfo.xml @@ -1,20 +1,7 @@ - + - - - + - - diff --git a/external-dependencies.xml b/external-dependencies.xml index 7d7a355..74db22f 100644 --- a/external-dependencies.xml +++ b/external-dependencies.xml @@ -1,22 +1,10 @@ - 4.0.0 de.hybris.platform hacvcsinfo 18.08.0-RC16 - jar - diff --git a/hac/resources/jsp/vcsinfo.jsp b/hac/resources/jsp/vcsinfo.jsp index 3169237..afb8aed 100644 --- a/hac/resources/jsp/vcsinfo.jsp +++ b/hac/resources/jsp/vcsinfo.jsp @@ -3,34 +3,34 @@ <% pageContext.setAttribute("newLineChar", "\n"); %> - VCS Info - " type="text/css" media="screen, projection"/> - - - + VCS Info + " type="text/css" media="screen, projection"/> + + +
- -
-

VCS Info

- - - - - - - - - - - - - - - -
PropertyValue
${item.key}${item.value}
-
+ +
+

VCS Info

+ + + + + + + + + + + + + + + +
PropertyValue
${item.key}${item.value}
+
diff --git a/hac/src/de/hybris/platform/hac/controller/HacVCSInfoController.java b/hac/src/de/hybris/platform/hac/controller/HacVCSInfoController.java index a96e6ca..c58e4c0 100644 --- a/hac/src/de/hybris/platform/hac/controller/HacVCSInfoController.java +++ b/hac/src/de/hybris/platform/hac/controller/HacVCSInfoController.java @@ -1,13 +1,3 @@ -/* - * [y] hybris Platform - * - * Copyright (c) 2018 SAP SE or an SAP affiliate company. All rights reserved. - * - * This software is the confidential and proprietary information of SAP - * ("Confidential Information"). You shall not disclose such Confidential - * Information and shall use it only in accordance with the terms of the - * license agreement you entered into with SAP. - */ package de.hybris.platform.hac.controller; import org.springframework.stereotype.Controller; @@ -20,10 +10,6 @@ import java.util.Map; import java.util.Properties; - -/** - * - */ @Controller @RequestMapping("/hacvcsinfo/**") public class HacVCSInfoController diff --git a/project.properties b/project.properties index be93a68..6b85e47 100644 --- a/project.properties +++ b/project.properties @@ -1,19 +1,2 @@ -# ----------------------------------------------------------------------- -# [y] hybris Platform -# -# Copyright (c) 2018 SAP SE or an SAP affiliate company. All rights reserved. -# -# This software is the confidential and proprietary information of SAP -# ("Confidential Information"). You shall not disclose such Confidential -# Information and shall use it only in accordance with the terms of the -# license agreement you entered into with SAP. -# ----------------------------------------------------------------------- - -hacvcsinfo.key=value - # Specifies the location of the spring context file putted automatically to the global platform application context. hacvcsinfo.application-context=hacvcsinfo-spring.xml - -# https://jira.hybris.com/browse/ECP-2832 -hac.tomcat.tld.scan=displaytag*.jar,jstl*.jar,jstl-impl*.jar,*_hac.jar -hac.tomcat.pluggability.scan=displaytag*.jar,jstl*.jar,jstl-impl*.jar,*_hac.jar \ No newline at end of file diff --git a/resources/hacvcsinfo-beans.xml b/resources/hacvcsinfo-beans.xml index 2a5aa09..7ee7bd0 100644 --- a/resources/hacvcsinfo-beans.xml +++ b/resources/hacvcsinfo-beans.xml @@ -1,18 +1,3 @@ - - - - diff --git a/resources/hacvcsinfo-items.xml b/resources/hacvcsinfo-items.xml index e4903b2..33d9ac1 100644 --- a/resources/hacvcsinfo-items.xml +++ b/resources/hacvcsinfo-items.xml @@ -1,22 +1,6 @@ - - - - + xsi:noNamespaceSchemaLocation="items.xsd"> - diff --git a/resources/hacvcsinfo-spring.xml b/resources/hacvcsinfo-spring.xml index 565ef42..0eef019 100644 --- a/resources/hacvcsinfo-spring.xml +++ b/resources/hacvcsinfo-spring.xml @@ -1,27 +1,15 @@ - + http://www.springframework.org/schema/beans/spring-beans.xsd + http://www.springframework.org/schema/aop + http://www.springframework.org/schema/aop/spring-aop.xsd"> - - diff --git a/src/hacvcsinfo/YhacextStandalone.java b/src/hacvcsinfo/YhacextStandalone.java deleted file mode 100644 index 48a1eff..0000000 --- a/src/hacvcsinfo/YhacextStandalone.java +++ /dev/null @@ -1,53 +0,0 @@ -/* - * [y] hybris Platform - * - * Copyright (c) 2018 SAP SE or an SAP affiliate company. All rights reserved. - * - * This software is the confidential and proprietary information of SAP - * ("Confidential Information"). You shall not disclose such Confidential - * Information and shall use it only in accordance with the terms of the - * license agreement you entered into with SAP. - */ -package hacvcsinfo; - -import de.hybris.platform.core.Registry; -import de.hybris.platform.jalo.JaloSession; -import de.hybris.platform.util.RedeployUtilities; -import de.hybris.platform.util.Utilities; - - -/** - * Demonstration of how to write a standalone application that can be run directly from within eclipse or from the - * commandline.
- * To run this from commandline, just use the following command:
- * - * java -jar bootstrap/bin/ybootstrap.jar "new hacvcsinfo.YhacextStandalone().run();" - * From eclipse, just run as Java Application. Note that you maybe need to add all other projects like - * ext-commerce, ext-pim to the Launch configuration classpath. - */ -public class YhacextStandalone -{ - /** - * Main class to be able to run it directly as a java program. - * - * @param args - * the arguments from commandline - */ - public static void main(final String[] args) - { - new YhacextStandalone().run(); - } - - public void run() - { - Registry.activateStandaloneMode(); - Registry.activateMasterTenant(); - - final JaloSession jaloSession = JaloSession.getCurrentSession(); - System.out.println("Session ID: " + jaloSession.getSessionID()); //NOPMD - System.out.println("User: " + jaloSession.getUser()); //NOPMD - Utilities.printAppInfo(); - - RedeployUtilities.shutdown(); - } -} diff --git a/src/hacvcsinfo/constants/YhacextConstants.java b/src/hacvcsinfo/constants/YhacextConstants.java index 2844e65..07662bd 100644 --- a/src/hacvcsinfo/constants/YhacextConstants.java +++ b/src/hacvcsinfo/constants/YhacextConstants.java @@ -1,26 +1,11 @@ -/* - * [y] hybris Platform - * - * Copyright (c) 2018 SAP SE or an SAP affiliate company. All rights reserved. - * - * This software is the confidential and proprietary information of SAP - * ("Confidential Information"). You shall not disclose such Confidential - * Information and shall use it only in accordance with the terms of the - * license agreement you entered into with SAP. - */ -package hacvcsinfo.constants; - -/** - * Global class for all Yhacext constants. You can add global constants for your extension into this class. - */ -public final class YhacextConstants extends GeneratedYhacextConstants -{ - public static final String EXTENSIONNAME = "hacvcsinfo"; - - private YhacextConstants() - { - //empty to avoid instantiating this constant class - } - - // implement here constants used by this extension -} +package hacvcsinfo.constants; + +@SuppressWarnings({"deprecation","squid:CallToDeprecatedMethod"}) +public class YhacextConstants extends GeneratedYhacextConstants +{ + public static final String EXTENSIONNAME = "hacvcsinfo"; + private YhacextConstants() + { + //empty + } +} diff --git a/src/hacvcsinfo/jalo/YhacextManager.java b/src/hacvcsinfo/jalo/YhacextManager.java deleted file mode 100644 index 5821182..0000000 --- a/src/hacvcsinfo/jalo/YhacextManager.java +++ /dev/null @@ -1,129 +0,0 @@ -/* - * [y] hybris Platform - * - * Copyright (c) 2018 SAP SE or an SAP affiliate company. All rights reserved. - * - * This software is the confidential and proprietary information of SAP - * ("Confidential Information"). You shall not disclose such Confidential - * Information and shall use it only in accordance with the terms of the - * license agreement you entered into with SAP. - */ -package hacvcsinfo.jalo; - -import de.hybris.platform.core.Registry; -import de.hybris.platform.util.JspContext; - -import java.util.Map; - -import org.apache.log4j.Logger; - -import hacvcsinfo.constants.YhacextConstants; - - - -/** - * This is the extension manager of the Yhacext extension. - */ -public class YhacextManager extends GeneratedYhacextManager -{ - /** Edit the local|project.properties to change logging behavior (properties 'log4j.*'). */ - private static final Logger LOG = Logger.getLogger(YhacextManager.class.getName()); - - /* - * Some important tips for development: - * - * Do NEVER use the default constructor of manager's or items. => If you want to do something whenever the manger is - * created use the init() or destroy() methods described below - * - * Do NEVER use STATIC fields in your manager or items! => If you want to cache anything in a "static" way, use an - * instance variable in your manager, the manager is created only once in the lifetime of a "deployment" or tenant. - */ - - - /** - * Get the valid instance of this manager. - * - * @return the current instance of this manager - */ - public static YhacextManager getInstance() - { - return (YhacextManager) Registry.getCurrentTenant().getJaloConnection().getExtensionManager().getExtension( - YhacextConstants.EXTENSIONNAME); - } - - - /** - * Never call the constructor of any manager directly, call getInstance() You can place your business logic here - - * like registering a jalo session listener. Each manager is created once for each tenant. - */ - public YhacextManager() // NOPMD - { - if (LOG.isDebugEnabled()) - { - LOG.debug("constructor of YhacextManager called."); - } - } - - /** - * Use this method to do some basic work only ONCE in the lifetime of a tenant resp. "deployment". This method is - * called after manager creation (for example within startup of a tenant). Note that if you have more than one tenant - * you have a manager instance for each tenant. - */ - @Override - public void init() - { - if (LOG.isDebugEnabled()) - { - LOG.debug("init() of YhacextManager called. " + getTenant().getTenantID()); - } - } - - /** - * Use this method as a callback when the manager instance is being destroyed (this happens before system - * initialization, at redeployment or if you shutdown your VM). Note that if you have more than one tenant you have a - * manager instance for each tenant. - */ - @Override - public void destroy() - { - if (LOG.isDebugEnabled()) - { - LOG.debug("destroy() of YhacextManager called, current tenant: " + getTenant().getTenantID()); - } - } - - /** - * Implement this method to create initial objects. This method will be called by system creator during - * initialization and system update. Be sure that this method can be called repeatedly. - * - * An example usage of this method is to create required cronjobs or modifying the type system (setting e.g some - * default values) - * - * @param params - * the parameters provided by user for creation of objects for the extension - * @param jspc - * the jsp context; you can use it to write progress information to the jsp page during creation - */ - @Override - public void createEssentialData(final Map params, final JspContext jspc) - { - // implement here code creating essential data - } - - /** - * Implement this method to create data that is used in your project. This method will be called during the system - * initialization. - * - * An example use is to import initial data like currencies or languages for your project from an csv file. - * - * @param params - * the parameters provided by user for creation of objects for the extension - * @param jspc - * the jsp context; you can use it to write progress information to the jsp page during creation - */ - @Override - public void createProjectData(final Map params, final JspContext jspc) - { - // implement here code creating project data - } -}