Skip to content

Commit

Permalink
Merge pull request Netflix#716 from mattrjacobs/unfinal-execute-and-q…
Browse files Browse the repository at this point in the history
…ueue

Make HystrixCommand.execute()/queue() and AbstractCommand.observe()/toObservable() nonfinal
  • Loading branch information
mattrjacobs committed Mar 20, 2015
2 parents 05ea381 + a899696 commit 6920be4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@ protected AbstractCommand(HystrixCommandGroupKey group, HystrixCommandKey key, H
* @throws IllegalStateException
* if invoked more than once
*/
final public Observable<R> observe() {
public Observable<R> observe() {
// us a ReplaySubject to buffer the eagerly subscribed-to Observable
ReplaySubject<R> subject = ReplaySubject.create();
// eagerly kick off subscription
Expand Down Expand Up @@ -342,7 +342,7 @@ final public Observable<R> observe() {
* @throws IllegalStateException
* if invoked more than once
*/
final public Observable<R> toObservable() {
public Observable<R> toObservable() {
/* this is a stateful object so can only be used once */
if (!started.compareAndSet(false, true)) {
throw new IllegalStateException("This instance can only be executed once. Please instantiate a new instance.");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ public void call(Subscriber<? super R> s) {
* @throws IllegalStateException
* if invoked more than once
*/
final public R execute() {
public R execute() {
try {
return queue().get();
} catch (Exception e) {
Expand Down Expand Up @@ -360,7 +360,7 @@ final public R execute() {
* @throws IllegalStateException
* if invoked more than once
*/
final public Future<R> queue() {
public Future<R> queue() {
/*
* --- Schedulers.immediate()
*
Expand Down

0 comments on commit 6920be4

Please sign in to comment.