2016-07-11 2 views
1

플러그인을 jarfile로 만듭니다. 그리고 나는 dropin 폴더에있는 jarfile에 복사한다. (참조 https://docs.wso2.com/display/CEP410/Building+Custom+Event+Receivers)wso2 cep의 사용자 정의 이벤트 어댑터 4.1.0

나는 wso2 cep를 실행한다. 명령은 './wso2server.sh -DosgiConsole'. and 'osgi > ss event-adaptor-name'입니다. ACITVE!

하지만 WSO2 관리 웹 페이지가 존재하지 않습니다. 내 이벤트의 '입력 이벤트 어댑터 유형'이 존재하지 않습니다.

나는 'osgi > bundle event-adaptor-id' 에 결과는

등록 된 서비스입니다 확인.

WSO2 CEP에 서비스를 등록하는 방법은 무엇입니까?

maven을 사용하지 않고 Eclipse를 사용합니다. 나는 플러그인 프로젝트를 사용한다.

답변

0

Exposing Custom Event Receiver as an OSGI Service WSO2 CEP 4.1.0 문서의 섹션에서는 사용자 지정 어댑터를 OSGI 서비스로 등록하는 방법에 대한 예제를 제공합니다.

위의 동일한 문서를 참조하면 다음은 사용자 지정 어댑터가 OutputEventAdapterFactory 서비스하에 등록되는 지점입니다.

context.getBundleContext().registerService(OutputEventAdapterFactory.class.getName(), 
        emailEventAdaptorFactory, null); 

이 성공적으로 등록되어있는 경우, 당신은 "osgi > bundle event-adaptor-id는"비슷한 같은 결과를 볼 수 있습니다 :

osgi> bundle org.wso2.carbon.event.output.adapter.email 
org.wso2.carbon.event.output.adapter.email_5.0.10 [215] 
    Id=215, Status=ACTIVE  Data Root=/home/userx/wso2cep-4.1.0/repository/components/default/configuration/org.eclipse.osgi/bundles/215/data 
    "Registered Services" 
    {org.wso2.carbon.event.output.adapter.core.OutputEventAdapterFactory}={service.id=117} 

(나는 명확하게하기 위해, 위의 전체 출력을 게시하지 않은 점에 유의하시기 바랍니다 답변의)

관련 문제