Skip to content

Commit

Permalink
move classes from pubsub to pubsub/spi/v1 (#1530)
Browse files Browse the repository at this point in the history
  • Loading branch information
pongad authored Jan 13, 2017
1 parent 36bbe4c commit 19acb03
Show file tree
Hide file tree
Showing 21 changed files with 33 additions and 102 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -14,21 +14,10 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.api.gax.bundling.FlowController;
import com.google.auth.Credentials;
import com.google.auth.oauth2.GoogleCredentials;
import com.google.cloud.Clock;
import com.google.common.base.Optional;
import com.google.common.base.Preconditions;
import com.google.common.util.concurrent.ListenableFuture;
import com.google.common.util.concurrent.Service;
import com.google.pubsub.v1.PubsubMessage;
import io.grpc.ManagedChannelBuilder;
import java.io.IOException;
import java.util.concurrent.ScheduledExecutorService;
import org.joda.time.Duration;

/** Users of the {@link Subscriber} must implement this interface to receive messages. */
interface MessageReceiver {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.api.gax.bundling.FlowController;
import com.google.api.stats.Distribution;
import com.google.cloud.Clock;
import com.google.cloud.pubsub.MessageReceiver.AckReply;
import com.google.cloud.pubsub.spi.v1.MessageReceiver.AckReply;
import com.google.common.annotations.VisibleForTesting;
import com.google.common.collect.Lists;
import com.google.common.primitives.Ints;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.common.annotations.VisibleForTesting;
import java.util.concurrent.atomic.AtomicBoolean;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,16 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import static com.google.cloud.pubsub.StatusUtil.isRetryable;
import static com.google.cloud.pubsub.spi.v1.StatusUtil.isRetryable;

import com.google.api.gax.bundling.FlowController;
import com.google.api.stats.Distribution;
import com.google.auth.Credentials;
import com.google.cloud.Clock;
import com.google.cloud.pubsub.MessagesProcessor.AcksProcessor;
import com.google.cloud.pubsub.MessagesProcessor.PendingModifyAckDeadline;
import com.google.cloud.pubsub.spi.v1.MessagesProcessor.AcksProcessor;
import com.google.cloud.pubsub.spi.v1.MessagesProcessor.PendingModifyAckDeadline;
import com.google.common.collect.Lists;
import com.google.common.util.concurrent.AbstractService;
import com.google.common.util.concurrent.FutureCallback;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.api.gax.bundling.FlowController;
import com.google.api.gax.grpc.BundlingSettings;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,10 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.api.gax.bundling.FlowController;
import com.google.auth.oauth2.GoogleCredentials;
import com.google.cloud.pubsub.spi.v1.PublisherSettings;
import com.google.common.base.Optional;
import com.google.common.collect.ImmutableList;
import com.google.common.primitives.Ints;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.auto.value.AutoValue;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import io.grpc.Status;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,16 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import static com.google.cloud.pubsub.StatusUtil.isRetryable;
import static com.google.cloud.pubsub.spi.v1.StatusUtil.isRetryable;

import com.google.api.gax.bundling.FlowController;
import com.google.api.stats.Distribution;
import com.google.auth.Credentials;
import com.google.cloud.Clock;
import com.google.cloud.pubsub.MessagesProcessor.AcksProcessor;
import com.google.cloud.pubsub.MessagesProcessor.PendingModifyAckDeadline;
import com.google.cloud.pubsub.spi.v1.MessagesProcessor.AcksProcessor;
import com.google.cloud.pubsub.spi.v1.MessagesProcessor.PendingModifyAckDeadline;
import com.google.common.collect.Lists;
import com.google.common.util.concurrent.AbstractService;
import com.google.common.util.concurrent.FutureCallback;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.api.gax.bundling.FlowController;
import com.google.auth.Credentials;
import com.google.auth.oauth2.GoogleCredentials;
import com.google.cloud.Clock;
import com.google.cloud.pubsub.MessageReceiver.AckReply;
import com.google.cloud.pubsub.spi.v1.MessageReceiver.AckReply;
import com.google.common.base.Optional;
import com.google.common.base.Preconditions;
import com.google.common.util.concurrent.Service;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,13 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.api.gax.bundling.FlowController;
import com.google.api.stats.Distribution;
import com.google.auth.Credentials;
import com.google.auth.oauth2.GoogleCredentials;
import com.google.cloud.Clock;
import com.google.cloud.pubsub.spi.v1.SubscriberSettings;
import com.google.common.annotations.VisibleForTesting;
import com.google.common.base.Optional;
import com.google.common.primitives.Ints;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.auto.value.AutoValue;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.cloud.Clock;
import java.util.concurrent.TimeUnit;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.auth.Credentials;
import java.io.IOException;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.common.base.Optional;
import com.google.pubsub.v1.PublishRequest;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,9 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.cloud.Clock;
import com.google.cloud.pubsub.FakeClock;
import com.google.common.primitives.Ints;
import com.google.common.util.concurrent.SettableFuture;
import java.util.ArrayList;
Expand All @@ -34,7 +33,6 @@
import java.util.concurrent.atomic.AtomicBoolean;
import org.joda.time.DateTime;
import org.joda.time.Duration;
import org.joda.time.MutableDateTime;

/**
* Fake implementation of {@link ScheduledExecutorService} that allows tests control the reference
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import com.google.api.client.util.Preconditions;
import com.google.common.collect.ImmutableList;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import static org.junit.Assert.assertEquals;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
Expand All @@ -25,7 +25,7 @@

import com.google.api.gax.bundling.FlowController;
import com.google.api.gax.grpc.BundlingSettings;
import com.google.cloud.pubsub.Publisher.Builder;
import com.google.cloud.pubsub.spi.v1.Publisher.Builder;
import com.google.common.base.Optional;
import com.google.common.util.concurrent.ListenableFuture;
import com.google.protobuf.ByteString;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@
* limitations under the License.
*/

package com.google.cloud.pubsub;
package com.google.cloud.pubsub.spi.v1;

import static com.google.cloud.pubsub.MessagesProcessor.PENDING_ACKS_SEND_DELAY;
import static com.google.cloud.pubsub.spi.v1.MessagesProcessor.PENDING_ACKS_SEND_DELAY;
import static org.junit.Assert.assertEquals;

import com.google.cloud.pubsub.FakeSubscriberServiceImpl.ModifyAckDeadline;
import com.google.cloud.pubsub.MessageReceiver.AckReply;
import com.google.cloud.pubsub.Subscriber.Builder;
import com.google.cloud.pubsub.spi.v1.FakeSubscriberServiceImpl.ModifyAckDeadline;
import com.google.cloud.pubsub.spi.v1.MessageReceiver.AckReply;
import com.google.cloud.pubsub.spi.v1.Subscriber.Builder;
import com.google.common.base.Function;
import com.google.common.base.Optional;
import com.google.common.base.Preconditions;
Expand Down

0 comments on commit 19acb03

Please sign in to comment.