// vi: set smarttab et sw=4 tabstop=4: module threadpool-impl { yang-version 1; namespace "urn:opendaylight:params:xml:ns:yang:controller:threadpool:impl"; prefix "th-java"; import threadpool { prefix th; revision-date 2013-04-09; } import config { prefix config; revision-date 2013-04-05; } import rpc-context { prefix rpcx; revision-date 2013-06-17; } organization "Cisco Systems, Inc."; contact "Robert Varga "; description "This module contains the base YANG definitions for thread services pure Java implementation. Copyright (c)2013 Cisco Systems, Inc. All rights reserved.; This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html"; revision "2013-04-05" { description "Updated to work with new anchors."; } revision "2013-04-03" { description "Initial revision by Anton Tkacik, Tomas Olvecky and Robert Varga."; } identity eventbus { base config:module-type; config:provided-service th:eventbus; config:java-name-prefix EventBus; } augment "/config:modules/config:module/config:configuration" { case eventbus { when "/config:modules/config:module/config:type = 'eventbus'"; // No real configuration } } augment "/config:modules/config:module/config:state" { case eventbus { when "/config:modules/config:module/config:type = 'eventbus'"; rpcx:rpc-context-instance "event-bus-rpc"; } } identity event-bus-rpc; identity async-eventbus { base config:module-type; config:provided-service th:eventbus; config:java-name-prefix AsyncEventBus; } augment "/config:modules/config:module/config:configuration" { case async-eventbus { when "/config:modules/config:module/config:type = 'async-eventbus'"; container threadpool { uses config:service-ref { refine type { //mandatory true; config:required-identity th:threadpool; } } } } } augment "/config:modules/config:module/config:state" { case async-eventbus { when "/config:modules/config:module/config:type = 'async-eventbus'"; rpcx:rpc-context-instance "event-bus-rpc"; } } rpc get-dead-events-count { config:java-name-prefix countDeadEvents; input { uses rpcx:rpc-context-ref { refine context-instance { rpcx:rpc-context-instance event-bus-rpc; } } } output { leaf result { type uint32; } } } }