Skip to content

Commit

Permalink
Use DataObjectIdentifier in aaa-password-service
Browse files Browse the repository at this point in the history
We have some deprecated use here, let's fix that up.

Change-Id: Iec75f7bc5dc6da3f3b23c1ea879bd5cb41dbf73c
Signed-off-by: Robert Varga <[email protected]>
  • Loading branch information
rovarga committed Aug 1, 2024
1 parent 25f2dbc commit 92e06aa
Showing 1 changed file with 3 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,11 @@
import com.google.common.annotations.Beta;
import org.opendaylight.mdsal.binding.api.DataBroker;
import org.opendaylight.mdsal.binding.api.DataListener;
import org.opendaylight.mdsal.binding.api.DataTreeIdentifier;
import org.opendaylight.mdsal.common.api.LogicalDatastoreType;
import org.opendaylight.yang.gen.v1.urn.opendaylight.aaa.password.service.config.rev170619.PasswordServiceConfig;
import org.opendaylight.yang.gen.v1.urn.opendaylight.aaa.password.service.config.rev170619.PasswordServiceConfigBuilder;
import org.opendaylight.yangtools.binding.DataObjectIdentifier;
import org.opendaylight.yangtools.concepts.Registration;
import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
import org.osgi.service.component.ComponentFactory;
import org.osgi.service.component.ComponentInstance;
import org.osgi.service.component.annotations.Activate;
Expand Down Expand Up @@ -48,9 +47,8 @@ public OSGiPasswordServiceConfigBootstrap(@Reference final DataBroker dataBroker
active = true;
}

registration = dataBroker.registerDataListener(
DataTreeIdentifier.of(LogicalDatastoreType.CONFIGURATION,
InstanceIdentifier.create(PasswordServiceConfig.class)), this);
registration = dataBroker.registerDataListener(LogicalDatastoreType.CONFIGURATION,
DataObjectIdentifier.builder(PasswordServiceConfig.class).build(), this);
LOG.info("Listening for password service configuration");
}

Expand Down

0 comments on commit 92e06aa

Please sign in to comment.