001/* 002 * Copyright (c) 2006-2011 Nuxeo SA (http://nuxeo.com/) and others. 003 * 004 * All rights reserved. This program and the accompanying materials 005 * are made available under the terms of the Eclipse Public License v1.0 006 * which accompanies this distribution, and is available at 007 * http://www.eclipse.org/legal/epl-v10.html 008 * 009 * Contributors: 010 * Nuxeo - initial API and implementation 011 */ 012 013package org.nuxeo.ecm.core.management.statuses; 014 015import org.nuxeo.runtime.api.Framework; 016import org.nuxeo.runtime.services.event.Event; 017import org.nuxeo.runtime.services.event.EventService; 018 019public class RuntimeEventNotifier implements Notifier { 020 021 public static final String RUNTIME_EVENT_TOPIC = "administrativeStatus"; 022 023 @Override 024 public void notifyEvent(String eventName, String instanceIdentifier, String serviceIdentifier) { 025 026 Event evnt = new Event(RUNTIME_EVENT_TOPIC, eventName, instanceIdentifier, serviceIdentifier); 027 EventService evtService = Framework.getLocalService(EventService.class); 028 evtService.sendEvent(evnt); 029 030 } 031 032}