Skip to content

Commit

Permalink
Rename the package of controller and invoker
Browse files Browse the repository at this point in the history
  • Loading branch information
Vincent Hou committed Oct 18, 2018
1 parent 0d6c017 commit 6123d74
Show file tree
Hide file tree
Showing 342 changed files with 1,774 additions and 1,766 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package whisk.common
package org.apache.openwhisk.common

/**
* Helper to match on exceptions caused by other exceptions.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package whisk.common
package org.apache.openwhisk.common

import scala.util.Try

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

package whisk.common
package org.apache.openwhisk.common

import java.util.concurrent.atomic.AtomicLong

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

package whisk.common
package org.apache.openwhisk.common

import java.util.concurrent.locks.AbstractQueuedSynchronizer

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

package whisk.common
package org.apache.openwhisk.common

import java.io.{FileInputStream, InputStream}
import java.security.{KeyStore, SecureRandom}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@
* limitations under the License.
*/

package whisk.common
package org.apache.openwhisk.common

import java.io.PrintStream
import java.time.{Clock, Instant, ZoneId}
import java.time.format.DateTimeFormatter
import akka.event.Logging._
import akka.event.LoggingAdapter
import kamon.Kamon
import whisk.core.entity.ControllerInstanceId
import org.apache.openwhisk.core.entity.ControllerInstanceId

trait Logging {

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

package whisk.common
package org.apache.openwhisk.common

import org.apache.commons.collections.buffer.CircularFifoBuffer

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

package whisk.common
package org.apache.openwhisk.common

import scala.concurrent.Future
import scala.concurrent.duration._
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,17 @@
* limitations under the License.
*/

package whisk.common
package org.apache.openwhisk.common

import java.time.{Clock, Duration, Instant}

import akka.event.Logging.{DebugLevel, InfoLevel, LogLevel, WarningLevel}
import akka.http.scaladsl.model.headers.RawHeader
import pureconfig.loadConfigOrThrow
import spray.json._
import whisk.core.ConfigKeys
import org.apache.openwhisk.core.ConfigKeys
import pureconfig._
import whisk.common.tracing.WhiskTracerProvider
import org.apache.openwhisk.common.tracing.WhiskTracerProvider

import scala.util.Try

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

package whisk.common
package org.apache.openwhisk.common

import pureconfig.loadConfigOrThrow
import whisk.core.ConfigKeys
import whisk.core.connector.{EventMessage, MessageProducer}
import org.apache.openwhisk.core.ConfigKeys
import org.apache.openwhisk.core.connector.{EventMessage, MessageProducer}

object UserEvents {

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

package whisk.common.tracing
package org.apache.openwhisk.common.tracing

import java.util.concurrent.TimeUnit

Expand All @@ -27,8 +27,8 @@ import io.opentracing.propagation.{Format, TextMapExtractAdapter, TextMapInjectA
import io.opentracing.util.GlobalTracer
import io.opentracing.{Span, SpanContext, Tracer}
import pureconfig._
import whisk.common.{LogMarkerToken, TransactionId}
import whisk.core.ConfigKeys
import org.apache.openwhisk.common.{LogMarkerToken, TransactionId}
import org.apache.openwhisk.core.ConfigKeys
import zipkin2.reporter.okhttp3.OkHttpSender
import zipkin2.reporter.{AsyncReporter, Sender}

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

package whisk.connector.kafka
package org.apache.openwhisk.connector.kafka

import akka.actor.ActorSystem
import org.apache.kafka.clients.consumer.{ConsumerConfig, KafkaConsumer}
import org.apache.kafka.common.TopicPartition
import org.apache.kafka.common.errors.{RetriableException, WakeupException}
import org.apache.kafka.common.serialization.ByteArrayDeserializer
import pureconfig.loadConfigOrThrow
import whisk.common.{Logging, LoggingMarkers, MetricEmitter, Scheduler}
import whisk.connector.kafka.KafkaConfiguration._
import whisk.core.ConfigKeys
import whisk.core.connector.MessageConsumer
import whisk.utils.Exceptions
import whisk.utils.TimeHelpers._
import org.apache.openwhisk.common.{Logging, LoggingMarkers, MetricEmitter, Scheduler}
import org.apache.openwhisk.connector.kafka.KafkaConfiguration._
import org.apache.openwhisk.core.ConfigKeys
import org.apache.openwhisk.core.connector.MessageConsumer
import org.apache.openwhisk.utils.Exceptions
import org.apache.openwhisk.utils.TimeHelpers._

import scala.collection.JavaConverters._
import scala.concurrent.duration._
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,18 @@
* limitations under the License.
*/

package whisk.connector.kafka
package org.apache.openwhisk.connector.kafka

import java.util.Properties

import akka.actor.ActorSystem
import org.apache.kafka.clients.admin.{AdminClient, AdminClientConfig, NewTopic}
import org.apache.kafka.common.errors.{RetriableException, TopicExistsException}
import pureconfig._
import whisk.common.{CausedBy, Logging}
import whisk.core.{ConfigKeys, WhiskConfig}
import whisk.core.connector.{MessageConsumer, MessageProducer, MessagingProvider}
import whisk.core.entity.ByteSize
import org.apache.openwhisk.common.{CausedBy, Logging}
import org.apache.openwhisk.core.{ConfigKeys, WhiskConfig}
import org.apache.openwhisk.core.connector.{MessageConsumer, MessageProducer, MessagingProvider}
import org.apache.openwhisk.core.entity.ByteSize

import scala.collection.JavaConverters._
import scala.concurrent.duration._
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,20 @@
* limitations under the License.
*/

package whisk.connector.kafka
package org.apache.openwhisk.connector.kafka

import akka.actor.ActorSystem
import akka.pattern.after
import org.apache.kafka.clients.producer._
import org.apache.kafka.common.errors._
import org.apache.kafka.common.serialization.StringSerializer
import pureconfig._
import whisk.common.{Counter, Logging, TransactionId}
import whisk.connector.kafka.KafkaConfiguration._
import whisk.core.ConfigKeys
import whisk.core.connector.{Message, MessageProducer}
import whisk.core.entity.{ByteSize, UUIDs}
import whisk.utils.Exceptions
import org.apache.openwhisk.common.{Counter, Logging, TransactionId}
import org.apache.openwhisk.connector.kafka.KafkaConfiguration._
import org.apache.openwhisk.core.ConfigKeys
import org.apache.openwhisk.core.connector.{Message, MessageProducer}
import org.apache.openwhisk.core.entity.{ByteSize, UUIDs}
import org.apache.openwhisk.utils.Exceptions

import scala.collection.JavaConverters._
import scala.concurrent.duration._
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@
* limitations under the License.
*/

package whisk.core
package org.apache.openwhisk.core

import java.io.File

import scala.io.Source
import whisk.common.{Config, Logging}
import org.apache.openwhisk.common.{Config, Logging}

/**
* A set of properties which might be needed to run a whisk microservice implemented
Expand All @@ -30,7 +30,7 @@ import whisk.common.{Config, Logging}
* a value, and whose values are default values. A null value in the Map means there is
* no default value specified, so it must appear in the properties file.
* @param optionalProperties a set of optional properties (which may not be defined).
* @param propertiesFile a File object, the whisk.properties file, which if given contains the property values.
* @param propertiesFile a File object, the org.apache.openwhisk.properties file, which if given contains the property values.
* @param env an optional environment to initialize from.
*/
class WhiskConfig(requiredProperties: Map[String, String],
Expand Down Expand Up @@ -90,7 +90,7 @@ object WhiskConfig {
def propfile(dir: String, recurse: Boolean = false): File =
if (dir != null) {
val base = new File(dir)
val file = new File(base, "whisk.properties")
val file = new File(base, "org.apache.openwhisk.properties")
if (file.exists())
file
else if (recurse)
Expand Down Expand Up @@ -151,9 +151,9 @@ object WhiskConfig {
// passed to the user container)
val edgeHostName = "edge.host"

val wskApiProtocol = "whisk.api.host.proto"
val wskApiPort = "whisk.api.host.port"
val wskApiHostname = "whisk.api.host.name"
val wskApiProtocol = "org.apache.openwhisk.api.host.proto"
val wskApiPort = "org.apache.openwhisk.api.host.port"
val wskApiHostname = "org.apache.openwhisk.api.host.name"
val wskApiHost = Map(wskApiProtocol -> "https", wskApiPort -> 443.toString, wskApiHostname -> null)

val mainDockerEndpoint = "main.docker.endpoint"
Expand Down Expand Up @@ -186,56 +186,56 @@ object WhiskConfig {
}

object ConfigKeys {
val cluster = "whisk.cluster"
val loadbalancer = "whisk.loadbalancer"
val buildInformation = "whisk.info"
val cluster = "org.apache.openwhisk.cluster"
val loadbalancer = "org.apache.openwhisk.loadbalancer"
val buildInformation = "org.apache.openwhisk.info"

val couchdb = "whisk.couchdb"
val cosmosdb = "whisk.cosmosdb"
val kafka = "whisk.kafka"
val couchdb = "org.apache.openwhisk.couchdb"
val cosmosdb = "org.apache.openwhisk.cosmosdb"
val kafka = "org.apache.openwhisk.kafka"
val kafkaCommon = s"$kafka.common"
val kafkaProducer = s"$kafka.producer"
val kafkaConsumer = s"$kafka.consumer"
val kafkaTopics = s"$kafka.topics"

val memory = "whisk.memory"
val timeLimit = "whisk.time-limit"
val logLimit = "whisk.log-limit"
val activation = "whisk.activation"
val userEvents = "whisk.user-events"
val memory = "org.apache.openwhisk.memory"
val timeLimit = "org.apache.openwhisk.time-limit"
val logLimit = "org.apache.openwhisk.log-limit"
val activation = "org.apache.openwhisk.activation"
val userEvents = "org.apache.openwhisk.user-events"

val runtimes = "whisk.runtimes"
val runtimes = "org.apache.openwhisk.runtimes"
val runtimesWhitelists = s"$runtimes.whitelists"

val db = "whisk.db"
val db = "org.apache.openwhisk.db"

val docker = "whisk.docker"
val docker = "org.apache.openwhisk.docker"
val dockerClient = s"$docker.client"
val dockerContainerFactory = s"$docker.container-factory"
val runc = "whisk.runc"
val runc = "org.apache.openwhisk.runc"
val runcTimeouts = s"$runc.timeouts"

val tracing = "whisk.tracing"
val tracing = "org.apache.openwhisk.tracing"

val containerFactory = "whisk.container-factory"
val containerFactory = "org.apache.openwhisk.container-factory"
val containerArgs = s"$containerFactory.container-args"
val containerPool = "whisk.container-pool"
val blacklist = "whisk.blacklist"
val containerPool = "org.apache.openwhisk.container-pool"
val blacklist = "org.apache.openwhisk.blacklist"

val kubernetes = "whisk.kubernetes"
val kubernetes = "org.apache.openwhisk.kubernetes"
val kubernetesTimeouts = s"$kubernetes.timeouts"

val transactions = "whisk.transactions"
val transactions = "org.apache.openwhisk.transactions"

val logStore = "whisk.logstore"
val logStore = "org.apache.openwhisk.logstore"
val splunk = s"$logStore.splunk"
val logStoreElasticSearch = s"$logStore.elasticsearch"

val mesos = "whisk.mesos"
val mesos = "org.apache.openwhisk.mesos"

val containerProxy = "whisk.container-proxy"
val containerProxy = "org.apache.openwhisk.container-proxy"
val containerProxyTimeouts = s"$containerProxy.timeouts"

val s3 = "whisk.s3"
val s3 = "org.apache.openwhisk.s3"

}
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@
* limitations under the License.
*/

package whisk.core.connector
package org.apache.openwhisk.core.connector

import scala.util.Try
import spray.json._
import whisk.common.TransactionId
import whisk.core.entity._
import org.apache.openwhisk.common.TransactionId
import org.apache.openwhisk.core.entity._

/** Basic trait for messages that are sent on a message bus connector. */
trait Message {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package whisk.core.connector
package org.apache.openwhisk.core.connector

import scala.annotation.tailrec
import scala.collection.immutable
Expand All @@ -26,8 +26,8 @@ import scala.util.Failure
import org.apache.kafka.clients.consumer.CommitFailedException
import akka.actor.FSM
import akka.pattern.pipe
import whisk.common.Logging
import whisk.common.TransactionId
import org.apache.openwhisk.common.Logging
import org.apache.openwhisk.common.TransactionId

trait MessageConsumer {

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

package whisk.core.connector
package org.apache.openwhisk.core.connector

import scala.concurrent.Future

Expand Down
Loading

0 comments on commit 6123d74

Please sign in to comment.