2

I tried to remove Spring Roo in project with gvNIX, using the following steps:

  • Step 1: Push-In Refactor
  • Step 2: Annotation Source Code Removal
  • Step 3: Annotation JAR Removal

which are documented in: http://docs.spring.io/spring-roo/reference/html/removing.html

But I have found that the removal is completed with some errors:

  • The Java classes that using the utility "occ checksum" are with compilation errors (the method getMessageDigest(), its declare in .aj)
  • All files .aj are not deleted (EquipoController_Roo_GvNIXDatatables.aj, ApplicationConversionServiceFactoryBean_Roo_GvNIXGeoConversionService.aj)

If I delete the files .aj and utility "occ checksum" is not used, everything is correct.

It is a bug in gvNIX? Maybe it could fix for the next version

//Creating Petclinic project

project --topLevelPackage com.gvnix.gmt --projectName gmt

// Persistence

jpa setup --provider HIBERNATE --database HYPERSONIC_PERSISTENT

// Creating entitys and fields

entity jpa --class ~.domain.Equipo --sequenceName EQU_SEQ

field string --fieldName nombre --notNull --sizeMin 3 --sizeMax 30 --class ~.domain.Equipo

// Adding finders

finder add --finderName findEquiposByNombre --class ~.domain.Equipo

// Adding web layers

web mvc setup

web mvc all --package ~.web

web mvc finder all

web mvc language --code de

web mvc language --code es

// Enable gvNIX JPA utilities

jpa gvnix setup

// Creates a Spring @Service class with methods for entity batch updates

jpa batch all

// Enable gvNIX Web MVC Batch utilities

web mvc batch setup

// Add support for JPA batch operations in all controllers

web mvc batch all

// Adding JQuery, Datatables and Bootstrap

web mvc jquery setup

web mvc datatables setup

web mvc jquery all

web mvc bootstrap setup

// Creating master patterns

web mvc datatables add --type ~.web.EquipoController

// Setup menu

menu setup

// Adding Optimistic Concurrency Control

occ checksum set --entity ~.domain.Equipo

logging setup --level INFO

// Dynamic Configuration

configuration create --name local

configuration property add --name log4j.rootLogger

configuration property value --configuration local --property

log4j.rootLogger --value ERROR

configuration list

configuration export

// Modifying persistence to use POSTRGRES database with geo spatial support

jpa setup --provider HIBERNATE --database POSTGRES --userName gvnix --databaseName postgis_example --password gvnix --hostName localhost

// Adding spatial support to our project

jpa geo setup --provider HIBERNATE_SPATIAL

// Adding new geo fields to Owner entity

field geo --fieldName localizacion --type POINT --class ~.domain.Equipo

// Generating geo entity finders

finder geo all

// Modifying entity field to use Geo component

web mvc geo field --controller ~.web.EquipoController --field localizacion

// Creating different map views

web mvc geo controller --class ~.web.MapaEquipoController --preferredMapping mapequipos

web mvc geo entity add --controller ~.web.EquipoController --map mapequipos

web mvc geo controller --class ~.web.MapaGlobalController --preferredMapping mapaglobal

web mvc geo entity add --controller ~.web.EquipoController --map mapaglobal

//web mvc geo entity all

// Generating all entities geo web layer

// Adding base layers to our maps views

web mvc geo tilelayer --name satellit --url "http://maptile.maps.svc.ovi.com/maptiler/maptile/newest/satellite.day/{z}/{x}/{y}/256/png8"

web mvc geo wmslayer --name "geological map of valencia" --url "http://mapas.igme.es/gis/services/Cartografia_Geologica/IGME_GeologicoCValenciana_400/MapServer/WMSServer" --format "image/png" --transparent true --version "1.1.1" --crs EPSG4326 --layers "0,1,2,3"

// Adding tools to our maps views

web mvc geo tool measure --name measure

web mvc geo tool custom --name latlng --icon fa-location-arrow --activateFunction activateLatLngTool --deactivateFunction deactivateLatLngTool --iconLibrary fa

Cœur
  • 37,241
  • 25
  • 195
  • 267
jperez82
  • 21
  • 3
  • I don't understand what you are looking for. If you remove Spring Roo also must follow the same steps for all gvNIX artifact (annotations, *.aj files, etc). Take account that gvNIX are a collection of add-ons on the top of Spring Roo utilities. – jmvivo Feb 09 '15 at 16:58
  • Yes, I follow the same steps for all gvNIX artifact, but I found these errors. Specifically, performing Step 1: Push-In Refactor it does not work well with feature "occ checksum" and some files ".aj" are not automatically deleted. – jperez82 Feb 09 '15 at 17:09
  • What is the content of reminder _.aj_? I'm not sure that is a gvNIX matter but could be of AJDT plugin instead. Try to make the push-in by hand. – jmvivo Feb 09 '15 at 17:15
  • The class Equipo.java uses feature "occ checksum", but to performing "Step 1: Push-In Refactor" in method "String checksumDigest()" are with compilation errors (the method getMessageDigest() in undefined), due to is declared in Equipo_Roo_gvNIX_occChecksum. I can fix this by hand, but I thought it's something that ought to be automatically implemented by the add-on to remove Spring Roo. – jperez82 Feb 10 '15 at 09:23

1 Answers1

0

If you think it is possible bug, raise bug against gvNIX, reference this questions and give more details and how to reproduce bug.