Introduction Java 9 has been finally released on 21 September 2017. Among its features one in particular has represented for a long time a clear lack in the Java platform: modularization. Modularization is a matter of code organization at a different scale than Java packages. Java packages allow us to organize our classes and grouping them by functionalities, with the desired … [Read more...] about Java 9 Module System
Dynamic Spring Security Sample
Introduction We have seen in the previous article Dynamically Securing Method Execution with Spring Security how it is possible to exploit the nature of Spring Security ACL module to dinamically secure methods access. Here we detail this solution with a working example. The example source code is available in SpringDynamicSecurityExample. It is based on the Spring Security … [Read more...] about Dynamic Spring Security Sample
How to load Tiles definitions programmatically
Introduction When implementing some sort of web application’s plugin architecture in which the layout is based on the Tiles framework (https://tiles.apache.org/) there could be the need to reload new tiles definitions on the fly. How to load Tiles definitions programmatically To load new tiles definitions first of all we get the Tiles container passing the servlet context to … [Read more...] about How to load Tiles definitions programmatically
How to dynamically load Resource Bundles in Struts 2
Introduction Resource bundles are objects that are characterized by a specific ‘Local’, i.e. are specific to particular geographical areas in terms of language, date format and other standards. Usually they are represented by simple properties files in the classpath with a suffix that indicates the targeted local and the application can load the appropriate resource bundle … [Read more...] about How to dynamically load Resource Bundles in Struts 2
How to customize the StrutsSpringObjectFactory
Introduction Spring can use its own MVC or integrate other MVC frameworks. It can for instance integrate with Struts2 by a specific plugin. The plugin overrides the Struts Object Factory providing a way to configure struts actions as beans in the Spring Context. Sometimes some customized behaviour is needed and the spring plugin as it is is not enough. In this case the … [Read more...] about How to customize the StrutsSpringObjectFactory