Skip to content

Commit

Permalink
register adaptor at init time
Browse files Browse the repository at this point in the history
in order to be usable from EnvironmentProviders
  • Loading branch information
ar committed Oct 2, 2024
1 parent 08bdb52 commit 5365f22
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions jpos/src/main/java/org/jpos/q2/security/SMAdaptor.java
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ protected void initService () throws Exception {
sm = (SMAdapter) factory.newInstance (getImpl ());
factory.setLogger (sm, e);
factory.setConfiguration (sm, e);
NameRegistrar.register (getName (), sm);
}

public void setImpl (String clazz) {
Expand All @@ -65,10 +66,6 @@ public void setImpl (String clazz) {
public String getImpl() {
return clazz;
}

protected void startService () throws Exception {
NameRegistrar.register (getName (), sm);
}
protected void stopService () throws Exception {
NameRegistrar.unregister (getName ());
}
Expand Down

0 comments on commit 5365f22

Please sign in to comment.