How to remove an unsupported module that still has usages ?
0
I am trying to convert an application from version 7 of mendix to 9 via 8 The RestServices Module is unsupported in version 8 and has around 73 usages in my app On compiling the app I am getting the following compilation errors : Buildfile: C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\deployment\build_core.xml compile: [javac] Compiling 304 source files to C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\deployment\run\bin [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\deeplink\actions\StartDeeplinkJava.java:137: error: method getUser in interface ISession cannot be applied to given types; [javac] if ( session == null || (session!=null && session.getUser().isAnonymous()) ) { [javac] ^ [javac] required: IContext [javac] found: no arguments [javac] reason: actual and formal argument lists differ in length [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\deeplink\actions\StartDeeplinkJava.java:170: error: method getUser in interface ISession cannot be applied to given types; [javac] serve404(request, response, session == null ? null : session.getUser().getName()); [javac] ^ [javac] required: IContext [javac] found: no arguments [javac] reason: actual and formal argument lists differ in length [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\deeplink\actions\StartDeeplinkJava.java:186: error: method getUser in interface ISession cannot be applied to given types; [javac] else if (!deeplink.getAllowGuests().booleanValue() && session.getUser().isAnonymous()) //guest session, which is not allowed [javac] ^ [javac] required: IContext [javac] found: no arguments [javac] reason: actual and formal argument lists differ in length [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\deeplink\actions\StartDeeplinkJava.java:199: error: method getUser in interface ISession cannot be applied to given types; [javac] String user = session.getUser().getName(); [javac] ^ [javac] required: IContext [javac] found: no arguments [javac] reason: actual and formal argument lists differ in length [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\deeplink\actions\StartDeeplinkJava.java:204: error: cannot find symbol [javac] List<IMendixObject> pendinglinks = Core.retrieveXPathQueryEscaped(context, "//%s[%s='%s' and %s='%s']", [javac] ^ [javac] symbol: method retrieveXPathQueryEscaped(IContext,String,String,String,String,String,String) [javac] location: class Core [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\deeplink\actions\StartDeeplinkJava.java:237: error: method getUser in interface ISession cannot be applied to given types; [javac] link.setUser(session.getUser().getName()); [javac] ^ [javac] required: IContext [javac] found: no arguments [javac] reason: actual and formal argument lists differ in length [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\deeplink\actions\StartDeeplinkJava.java:389: error: cannot find symbol [javac] List<IMendixObject> result = Core.retrieveXPathQueryEscaped(context, "//%s[%s='%s']", [javac] ^ [javac] symbol: method retrieveXPathQueryEscaped(IContext,String,String,String,String) [javac] location: class Core [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\publish\RestServiceRequest.java:115: error: method getUser in interface ISession cannot be applied to given types; [javac] if (existingSession != null && session.getId().equals(existingSession.getId()) && existingSession.getUser().getName().equals(session.getUser().getName())) { [javac] ^ [javac] required: IContext [javac] found: no arguments [javac] reason: actual and formal argument lists differ in length [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\publish\RestServiceRequest.java:115: error: method getUser in interface ISession cannot be applied to given types; [javac] if (existingSession != null && session.getId().equals(existingSession.getId()) && existingSession.getUser().getName().equals(session.getUser().getName())) { [javac] ^ [javac] required: IContext [javac] found: no arguments [javac] reason: actual and formal argument lists differ in length [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\publish\RestServiceRequest.java:128: error: method getUser in interface ISession cannot be applied to given types; [javac] if (session != null && session.getUser() != null && session.getUser().getUserRoleNames().contains(role)) { [javac] ^ [javac] required: IContext [javac] found: no arguments [javac] reason: actual and formal argument lists differ in length [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\publish\RestServiceRequest.java:128: error: method getUser in interface ISession cannot be applied to given types; [javac] if (session != null && session.getUser() != null && session.getUser().getUserRoleNames().contains(role)) { [javac] ^ [javac] required: IContext [javac] found: no arguments [javac] reason: actual and formal argument lists differ in length [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\publish\RestServiceRequest.java:305: error: method getUser in interface ISession cannot be applied to given types; [javac] return activeSession.getUser(); [javac] ^ [javac] required: IContext [javac] found: no arguments [javac] reason: actual and formal argument lists differ in length [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\publish\DataService.java:61: error: method getUser in interface ISession cannot be applied to given types; [javac] constraint = constraint.replace(RestServices.CURRENTUSER_TOKEN, "'" + context.getSession().getUser().getMendixObject().getId() + "'"); [javac] ^ [javac] required: IContext [javac] found: no arguments [javac] reason: actual and formal argument lists differ in length [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\util\JSONSchemaBuilder.java:134: error: an enum switch case label must be the unqualified name of an enumeration constant [javac] case Currency: [javac] ^ [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\util\JSONSchemaBuilder.java:135: error: an enum switch case label must be the unqualified name of an enumeration constant [javac] case Float: [javac] ^ [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\util\JsonDeserializer.java:171: error: an enum switch case label must be the unqualified name of an enumeration constant [javac] case Currency: [javac] ^ [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\util\JsonDeserializer.java:172: error: an enum switch case label must be the unqualified name of an enumeration constant [javac] case Float: [javac] ^ [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\util\JsonSerializer.java:161: error: an enum switch case label must be the unqualified name of an enumeration constant [javac] case Currency: [javac] ^ [javac] C:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\javasource\restservices\util\JsonSerializer.java:162: error: an enum switch case label must be the unqualified name of an enumeration constant [javac] case Float: [javac] ^ [javac] Note: Some input files use or override a deprecated API. [javac] Note: Recompile with -Xlint:deprecation for details. [javac] 19 errors BUILD FAILEDC:\Users\vijayavarthinit\Documents\Mendix\GlobalOpportunities-Nordics_Analysis\deployment\build_core.xml:29: Compile failed; see the compiler error output for details. Total time: 8 seconds How can I remove/replace this module to remove these errors
You do not need this module in Mendix 8. All of its features are built into the platform. Because of this, this module is no longer platform supported for Mendix 8 onwards.
Remove the module and fix all the errors one by one with the new built-in functionality.