����   =O  Forg/apache/kafka/connect/runtime/licensing/ConnectWorkerLicenseManager  <org/apache/kafka/connect/runtime/licensing/LicenseConfigUtil  ,org/apache/kafka/clients/CommonClientConfigs
  	 
   java/lang/Object <init> ()V  (org/apache/kafka/common/config/ConfigDef
 
    -(Lorg/apache/kafka/common/config/ConfigDef;)V
 
    
configKeys ()Ljava/util/Map;      
java/util/Map keySet ()Ljava/util/Set;      ! 
java/util/Set iterator ()Ljava/util/Iterator; # $ % & ' java/util/Iterator hasNext ()Z # ) * + next ()Ljava/lang/Object; - java/lang/String / confluent.topic.
 , 1 2 3 
startsWith (Ljava/lang/String;)Z 5 confluent.license 7 Confluent Licensing
  9 : ; addToConfigDef h(Lorg/apache/kafka/common/config/ConfigDef;Ljava/lang/String;)Lorg/apache/kafka/common/config/ConfigDef;
  = > ? keysInGroup ?(Lorg/apache/kafka/common/config/ConfigDef;Ljava/lang/String;)I	 A B C D E -org/apache/kafka/common/config/ConfigDef$Type PASSWORD /Lorg/apache/kafka/common/config/ConfigDef$Type; G  	 I J K L M 3org/apache/kafka/common/config/ConfigDef$Importance HIGH 5Lorg/apache/kafka/common/config/ConfigDef$Importance; O!Confluent will issue a license key to each subscriber. The license key will be a short snippet of text that you can copy and paste. Without the license key, you can use the connector for a 30-day trial period. If you are a subscriber, please contact Confluent Support for more information.	 Q R S T U .org/apache/kafka/common/config/ConfigDef$Width NONE 0Lorg/apache/kafka/common/config/ConfigDef$Width; W License
 
 Y Z [ define(Ljava/lang/String;Lorg/apache/kafka/common/config/ConfigDef$Type;Ljava/lang/Object;Lorg/apache/kafka/common/config/ConfigDef$Importance;Ljava/lang/String;Ljava/lang/String;ILorg/apache/kafka/common/config/ConfigDef$Width;Ljava/lang/String;)Lorg/apache/kafka/common/config/ConfigDef; ] !confluent.topic.bootstrap.servers	 A _ ` E LIST	 
 b c d NO_DEFAULT_VALUE Ljava/lang/Object; f�A list of host/port pairs to use for establishing the initial connection to the Kafka cluster used for licensing. All servers in the cluster will be discovered from the initial connection. This list should be in the form ``host1:port1,host2:port2,...``. These servers are used only for the initial connection to discover the full cluster membership, which may change dynamically, so this list need not contain the full set of servers. You may want more than one, in case a server is down.	 Q h i U LONG k Confluent Topic Servers m confluent.topic	 A o p E STRING r _confluent-command	 I t u M LOW w cName of the Kafka topic used for Confluent Platform configuration, including licensing information.	 Q y z U MEDIUM | Confluent Topic ~ "confluent.topic.replication.factor	 A � � E INT
 � � � � � java/lang/Integer valueOf (I)Ljava/lang/Integer; �`The replication factor for the Kafka topic used for Confluent Platform configuration, including licensing information. This is used only if the topic does not already exist, and the default of 3 is appropriate for production use. If you are using a development environment with less than 3 brokers, you must set this to the number of brokers (often 1). � "Confluent Topic Replication Factor  � � � values ()Ljava/util/Collection; �  � java/util/Collection � 2org/apache/kafka/common/config/ConfigDef$ConfigKey	 � � � � group Ljava/lang/String;
 , � � � equals (Ljava/lang/Object;)Z
 
 	
  � : � V(Lorg/apache/kafka/common/config/ConfigDef;)Lorg/apache/kafka/common/config/ConfigDef; � -org/apache/kafka/common/config/AbstractConfig
 � �  � <(Lorg/apache/kafka/common/config/ConfigDef;Ljava/util/Map;)V
  � � � create R()Lorg/apache/kafka/connect/runtime/licensing/ConnectWorkerLicenseManager$Builder;
  � � � extractLicense C(Lorg/apache/kafka/common/config/AbstractConfig;)Ljava/lang/String;
 � � � � � Norg/apache/kafka/connect/runtime/licensing/ConnectWorkerLicenseManager$Builder 
useLicense d(Ljava/lang/String;)Lorg/apache/kafka/connect/runtime/licensing/ConnectWorkerLicenseManager$Builder;
 � � � � useBrokerDetectorConsumerConfig a(Ljava/util/Map;)Lorg/apache/kafka/connect/runtime/licensing/ConnectWorkerLicenseManager$Builder;
  � � � extractLicenseTopicName
 � � � � useTopicName
  � � � extractLicenseDefaultClientId
 � � � � useDefaultClientId
  � � � extractLicenseProducerConfig @(Lorg/apache/kafka/common/config/AbstractConfig;)Ljava/util/Map;
 � � � � useProducerConfig
  � � � extractLicenseConsumerConfig
 � � � � useConsumerConfig
  � � � extractLicenseTopicAdminConfig
 � � � � useAdminConfig
 � � � � build J()Lorg/apache/kafka/connect/runtime/licensing/ConnectWorkerLicenseManager;
 � � �  originalsStrings � name  � � � get &(Ljava/lang/Object;)Ljava/lang/Object;   � � � makeConcatWithConstants &(Ljava/lang/String;)Ljava/lang/String; � java/util/HashMap
 � 	
 � � � � originalsWithPrefix #(Ljava/lang/String;)Ljava/util/Map;  � � � putAll (Ljava/util/Map;)V � confluent.topic.producer. � confluent.topic.consumer.
 � � � � 	getString
 � � � � getPassword C(Ljava/lang/String;)Lorg/apache/kafka/common/config/types/Password;
 �  -org/apache/kafka/common/config/types/Password value ()Ljava/lang/String; CONFLUENT_LICENSE_CONFIG 
ConstantValue CONFLUENT_LICENSE_DISPLAY CONFLUENT_LICENSE_DEFAULT CONFLUENT_LICENSE_DOC CONFLUENT_TOPIC_CONFIG CONFLUENT_TOPIC_DISPLAY CONFLUENT_TOPIC_DEFAULT CONFLUENT_TOPIC_DOC CONFLUENT_TOPIC_PREFIX CONFLUENT_TOPIC_PRODUCER_PREFIX CONFLUENT_TOPIC_CONSUMER_PREFIX (CONFLUENT_TOPIC_BOOTSTRAP_SERVERS_CONFIG )CONFLUENT_TOPIC_BOOTSTRAP_SERVERS_DISPLAY %CONFLUENT_TOPIC_BOOTSTRAP_SERVERS_DOC )CONFLUENT_TOPIC_REPLICATION_FACTOR_CONFIG *CONFLUENT_TOPIC_REPLICATION_FACTOR_DISPLAY *CONFLUENT_TOPIC_REPLICATION_FACTOR_DEFAULT I    &CONFLUENT_TOPIC_REPLICATION_FACTOR_DOC CONFLUENT_GROUP Code LineNumberTable LocalVariableTable this >Lorg/apache/kafka/connect/runtime/licensing/LicenseConfigUtil; key base *Lorg/apache/kafka/common/config/ConfigDef; 
licensingDefs 
StackMapTable MethodParameters orderInGroup 4Lorg/apache/kafka/common/config/ConfigDef$ConfigKey; 	configDef 	groupName numKeys createLicenseManager h(Ljava/util/Map;Ljava/util/Map;)Lorg/apache/kafka/connect/runtime/licensing/ConnectWorkerLicenseManager; 	originals Ljava/util/Map; detectorConfigs config /Lorg/apache/kafka/common/config/AbstractConfig; LocalVariableTypeTable Ljava/util/Map<**>; 5Ljava/util/Map<Ljava/lang/String;Ljava/lang/Object;>; 	Signature �(Ljava/util/Map<**>;Ljava/util/Map<Ljava/lang/String;Ljava/lang/Object;>;)Lorg/apache/kafka/connect/runtime/licensing/ConnectWorkerLicenseManager; 
connectorName 
unifiedConfig f(Lorg/apache/kafka/common/config/AbstractConfig;)Ljava/util/Map<Ljava/lang/String;Ljava/lang/Object;>; 
SourceFile LicenseConfigUtil.java BootstrapMethods= -license-manager?
@AB �C $java/lang/invoke/StringConcatFactory �(Ljava/lang/invoke/MethodHandles$Lookup;Ljava/lang/String;Ljava/lang/invoke/MethodType;Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/invoke/CallSite; InnerClasses Type 
Importance Width 	ConfigKey BuilderK %java/lang/invoke/MethodHandles$LookupM java/lang/invoke/MethodHandles Lookup !       �     4  �     V  �     F  �     N 	 �     l 
 �     {  �     q  �     v 
 �     .  �     �  �     �  �     \  �     j  �     e  �     }  �     �       �     �  �     6        /     *� �          
          	 : �    �     I� 
Y*� L+� �  �  M,� " � $,� ( � ,N-.� 0� -4� 0� +����+6� 8�          D 	 E + F = I ? K B L      +  �    I !   	 @"! #    �  
 #� $ ,� � $       	 : ;    � 
    o*+� <=*4� @F� HN+�� PV� X\� ^� a� He+�� gj� Xl� nq� sv+�� x{� X}� � �� s�+�� x�� X�          W  X 7 b P l Y y k v n X        o !     o � �   i% $   	    �   	 > ?    �     A=*� � � � � N-� " � (-� ( � �:� �� � �+� �� �����          �  � % � 9 � < � ? �   *  % &    A'!     A( �   ?) #   
 �  #*� $   	'  (   	*+    �     S� 
Y� �M,� �N� �Y-*� �:� �� �� �+� �� �� �� �� �� Ķ �� ˶ �� Ѷ Զ װ      6 
   �  � 
 �  �  � $ � ) � 1 � 9 � A � I � O � R �   4    S,-     S.-   K !  
 F"!   ;/0 1       S,2     S.3 $   	,  .  4   5  � �    h     *� �޹ � � ,L+� +� �  � �      
    �  �       /0    6 � #    �  ,@ ,$   /    � �    t     "� �Y� �L+*.� � � +*� � � +�          �  �  �   �       "/0    7- 1      73 $   /  4   8  � �    t     "� �Y� �L+*.� � � +*�� � � +�          �  �  �   �       "/0    7- 1      73 $   /  4   8  � �    �     .� �Y� �L+*.� � � +*� � � +*�� � � +�          �  �  �   � , �       ./0    &7- 1      &73 $   /  4   8  � �    1     *l� ��          �       /0  $   /    � �    4     
*4� �� ��          �       
/0  $   /   9   :;    > <D   2  A 
E@ I 
F@ Q 
G@ � 
H 	 � I 	JLN 