Failed to execute goal org.apache.felix:maven-scr-plugin:1.20.0:scr (generate-scr-scrdescriptor) on project | Community
Skip to main content
New Participant
August 28, 2017
Solved

Failed to execute goal org.apache.felix:maven-scr-plugin:1.20.0:scr (generate-scr-scrdescriptor) on project

  • August 28, 2017
  • 2 replies
  • 3893 views

Hi All,

I am trying to expose some RESTfull webservices on AEM. I have followed the instructions in this http://techagyan.blogspot.in/2015/02/be-restful-on-aem6.html

I'm getting following error:
"@Component : Service interface information is missing! (org.apache.felix:maven-scr-plugin:1.20.0:scr:generate-scr-scrdescriptor:process-classes)"

and

My Code is:

package com.nextrow.restservice.core;

import javax.ws.rs.GET;

import javax.ws.rs.Path;

import javax.ws.rs.Produces;

import javax.ws.rs.core.MediaType;

import org.apache.felix.scr.annotations.Component;

import org.apache.felix.scr.annotations.Service;

@Service

@Component(metatype = false)

@Path("/helloservice")

public class SampleResource {

  @GET

  @Path("/sayhi")

  public String helloWorld() {

  return "SampleResource says hi";

  }

  @GET

  @Path("/getoperation")

  @Produces({ MediaType.TEXT_PLAIN })

  public String getServiceOperation() {

  String status = "false";

  // service.dosomething return

  return status;

  }

}

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by smacdonald2008

To build AEM projects with Maven -- see this article --

Adobe Experience Manager Help | Creating your first Adobe Experience Manager 6.2 Project using Adobe Maven Archetype 10

Always check to see if a HELPX article exists for your use case. They all have been tested. You will see a Servlet is generated by default.

2 replies

smacdonald2008
New Participant
August 28, 2017

If you are building for AEM 6.3 - change the UBER file to 6.3.

smacdonald2008
smacdonald2008Accepted solution
New Participant
August 28, 2017

To build AEM projects with Maven -- see this article --

Adobe Experience Manager Help | Creating your first Adobe Experience Manager 6.2 Project using Adobe Maven Archetype 10

Always check to see if a HELPX article exists for your use case. They all have been tested. You will see a Servlet is generated by default.