WARNING : createConnector contains empty path annotation - apache-kafka

Using documentation of confluent for kafka_cluster
I got this error :
Jul 03, 2018 4:20:41 PM org.glassfish.jersey.internal.Errors logErrors
WARNING: The following warnings have been detected: WARNING: The (sub)resource method createConnector in org.apache.kafka.connect.runtime.rest.resources.ConnectorsResource contains empty path annotation.
I used docker-compose

Related

Confluent CLI - Connect failed to start

I downloaded Confluent-7.0.0 for local machine installed it. Tried to follow the Quick-start guide, I typed "confluent local services start" and got this error message "Error: Connect failed to start" Not sure what went wrong, it happens everytime even with old versions too.
I am using a ubuntu virtual machine.
Using CONFLUENT_CURRENT: /tmp/confluent.587467
Starting ZooKeeper
ZooKeeper is [UP]
Starting Kafka
Kafka is [UP]
Starting Schema Registry
Schema Registry is [UP]
Starting Kafka REST
Kafka REST is [UP]
Starting Connect
Error: Connect failed to start
When I run the kafka connect directly, it was able to start the service but there were a few error messages.
WARNING: A provider org.apache.kafka.connect.runtime.rest.resources.ConnectorPluginsResource registered in SERVER runtime does not implement any provider interfaces applicable in the SERVER runtime. Due to constraint configuration problems the provider org.apache.kafka.connect.runtime.rest.resources.ConnectorPluginsResource will be ignored.
Nov 14, 2021 4:13:28 PM org.glassfish.jersey.internal.inject.Providers checkProviderRuntime
WARNING: A provider org.apache.kafka.connect.runtime.rest.resources.ConfluentV1MetadataResource registered in SERVER runtime does not implement any provider interfaces applicable in the SERVER runtime. Due to constraint configuration problems the provider org.apache.kafka.connect.runtime.rest.resources.ConfluentV1MetadataResource will be ignored.
Nov 14, 2021 4:13:28 PM org.glassfish.jersey.internal.inject.Providers checkProviderRuntime
WARNING: A provider org.apache.kafka.connect.runtime.rest.resources.LoggingResource registered in SERVER runtime does not implement any provider interfaces applicable in the SERVER runtime. Due to constraint configuration problems the provider org.apache.kafka.connect.runtime.rest.resources.LoggingResource will be ignored.
ERROR StatusLogger No log4j2 configuration file found. Using default configuration: logging only errors to the console. Set system property 'log4j2.debug' to show Log4j2 internal initialization logging.
Nov 14, 2021 4:13:31 PM org.glassfish.jersey.internal.Errors logErrors
WARNING: The following warnings have been detected: WARNING: The (sub)resource method listLoggers in org.apache.kafka.connect.runtime.rest.resources.LoggingResource contains empty path annotation.
WARNING: The (sub)resource method createConnector in org.apache.kafka.connect.runtime.rest.resources.ConnectorsResource contains empty path annotation.
WARNING: The (sub)resource method listConnectors in org.apache.kafka.connect.runtime.rest.resources.ConnectorsResource contains empty path annotation.
WARNING: The (sub)resource method listConnectorPlugins in org.apache.kafka.connect.runtime.rest.resources.ConnectorPluginsResource contains empty path annotation.
WARNING: The (sub)resource method serverInfo in org.apache.kafka.connect.runtime.rest.resources.RootResource contains empty path annotation.
[2021-11-14 16:13:31,592] INFO Started o.e.j.s.ServletContextHandler#20a116a0{/,null,AVAILABLE} (org.eclipse.jetty.server.handler.ContextHandler:915)
[2021-11-14 16:13:31,608] INFO REST resources initialized; server is started and ready to handle requests (org.apache.kafka.connect.runtime.rest.RestServer:308)
[2021-11-14 16:13:31,608] INFO Kafka Connect started (org.apache.kafka.connect.runtime.Connect:57)

Confluent replicator issue

I am trying to push topic data from one Kafka cluster to another (Both on-prem linux). For this, I am using Confluent kafka-connect-replicator.
Using - confluent enterprise 5.0
Following this doc -
https://docs.confluent.io/current/connect/kafka-connect-replicator/index.html#replicator-as-a-connector
I have already changed ports of zookeeper and broker to 2171 and 9082 resp. at source Kafka cluster.
Destination Kafka cluster is running on default ports.
My configuration files are :
/etc/kafka-connect-replicator/quickstart-replicator.properties
name=replicator-source
connector.class=io.confluent.connect.replicator.ReplicatorSourceConnector
key.converter=io.confluent.connect.replicator.util.ByteArrayConverter
value.converter=io.confluent.connect.replicator.util.ByteArrayConverter
header.converter=io.confluent.connect.replicator.util.ByteArrayConverter
tasks.max=4
src.kafka.bootstrap.servers=X.X.X.X:9082
src.zookeeper.connect=X.X.X.X:2171
dest.kafka.bootstrap.servers=Y.Y.Y.Y:9092
dest.zookeeper.connect=Y.Y.Y.Y:2181
confluent.topic.replication.factor=1
topic.whitelist=test-topic
topic.rename.format=${topic}.replica
topic.create.backoff.ms=10000
/etc/schema-registry/connect-avro-standalone.properties
bootstrap.servers=localhost:9082
key.converter=io.confluent.connect.avro.AvroConverter
key.converter.schema.registry.url=http://localhost:8081
value.converter=io.confluent.connect.avro.AvroConverter
value.converter.schema.registry.url=http://localhost:8081
internal.key.converter=org.apache.kafka.connect.json.JsonConverter
internal.value.converter=org.apache.kafka.connect.json.JsonConverter
internal.key.converter.schemas.enable=false
internal.value.converter.schemas.enable=false
offset.storage.file.filename=/data/kafka/connect.offsets
plugin.path=/usr/share/java
Run the replicator connector -
/usr/bin/connect-standalone /etc/schema-registry/connect-avro-standalone.properties /etc/kafka-connect-replicator/quickstart-replicator.properties
But when I run the replicator, it creates replica topic at destination cluster but if I produce messages, it doesn't show in the consumer at the destination cluster.
It also throws WARNs at the command prompt.
Nov 28, 2018 2:22:26 PM org.glassfish.jersey.internal.inject.Providers checkProviderRuntime
WARNING: A provider org.apache.kafka.connect.runtime.rest.resources.ConnectorPluginsResource registered in SERVER runtime does not implement any provider interfaces applicable in the SERVER runtime. Due to constraint configuration problems the provider org.apache.kafka.connect.runtime.rest.resources.ConnectorPluginsResource will be ignored.
Nov 28, 2018 2:22:26 PM org.glassfish.jersey.internal.inject.Providers checkProviderRuntime
WARNING: A provider org.apache.kafka.connect.runtime.rest.resources.RootResource registered in SERVER runtime does not implement any provider interfaces applicable in the SERVER runtime. Due to constraint configuration problems the provider org.apache.kafka.connect.runtime.rest.resources.RootResource will be ignored.
Nov 28, 2018 2:22:26 PM org.glassfish.jersey.internal.inject.Providers checkProviderRuntime
WARNING: A provider org.apache.kafka.connect.runtime.rest.resources.ConnectorsResource registered in SERVER runtime does not implement any provider interfaces applicable in the SERVER runtime. Due to constraint configuration problems the provider org.apache.kafka.connect.runtime.rest.resources.ConnectorsResource will be ignored.
Nov 28, 2018 2:22:26 PM org.glassfish.jersey.internal.Errors logErrors
WARNING: The following warnings have been detected: WARNING: The (sub)resource method createConnector in org.apache.kafka.connect.runtime.rest.resources.ConnectorsResource contains empty path annotation.
WARNING: The (sub)resource method listConnectors in org.apache.kafka.connect.runtime.rest.resources.ConnectorsResource contains empty path annotation.
WARNING: The (sub)resource method listConnectorPlugins in org.apache.kafka.connect.runtime.rest.resources.ConnectorPluginsResource contains empty path annotation.
WARNING: The (sub)resource method serverInfo in org.apache.kafka.connect.runtime.rest.resources.RootResource contains empty path annotation.
connect.log
[2018-11-28 14:29:58,849] INFO WorkerSourceTask{id=replicator-source-3} Committing offsets (org.apache.kafka.connect.runtime.WorkerSourceTask:397)
[2018-11-28 14:29:58,849] INFO WorkerSourceTask{id=replicator-source-3} flushing 1 outstanding messages for offset commit (org.apache.kafka.connect.runtime.WorkerSourceTask:414)
[2018-11-28 14:30:03,850] ERROR WorkerSourceTask{id=replicator-source-3} Failed to flush, timed out while waiting for producer to flush outstanding 1 messages (org.apache.kafka.connect.runtime.WorkerSourceTask:419)
[2018-11-28 14:30:03,850] ERROR WorkerSourceTask{id=replicator-source-3} Failed to commit offsets (org.apache.kafka.connect.runtime.SourceTaskOffsetCommitter:111)
What am I missing? How can I replicate data to the other cluster broker?
thanks!

Tapestry AppModule not added by RegistryBuilder for one project, works fine for another

I'm using Eclipse Mars, Tomcat7, Java8, Sysdeo DevLoader and I followed a Tynamo tutorial to configure the tomcat plugin.
I have two almost identical Tapestry projects. One app works fine the other won't serve any pages, throwing:
SEVERE: Servlet.service() for servlet [default] in context with path [/admin] threw exception
java.lang.RuntimeException: Exception constructing service 'WebSecurityManager': Error invoking constructor public org.tynamo.security.services.TapestryRealmSecurityManager(org.tynamo.security.Authenticator,org.apache.shiro.mgt.SubjectFactory,org.apache.shiro.mgt.RememberMeManager,java.util.Collection): Realms collection argument cannot be empty.
at org.apache.tapestry5.ioc.internal.services.JustInTimeObjectCreator.obtainObjectFromCreator(JustInTimeObjectCreator.java:75)
...
Caused by: java.lang.IllegalArgumentException: Realms collection argument cannot be empty.
at org.apache.shiro.mgt.RealmSecurityManager.setRealms(RealmSecurityManager.java:78)
at org.tynamo.security.services.TapestryRealmSecurityManager.<init>(TapestryRealmSecurityManager.java:31)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:422)
at org.apache.tapestry5.ioc.internal.util.ConstructorInvoker.invoke(ConstructorInvoker.java:48)
... 50 more
The problem seems to stem from my AppModule.addRealms not being called in the problem app before the security manager tries to get the Subject. In fact it seems that one of the apps enjoys the 'Tapestry treatment' and the other does not. Here's the one that works:
Nov 05, 2015 11:45:53 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/bray.xml
Nov 05, 2015 11:45:53 AM org.apache.catalina.core.StandardContext setPath
WARNING: A context path must either be an empty string or start with a '/'. The path [bray] does not meet these criteria and has been changed to [/bray]
Nov 05, 2015 11:45:53 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Context/Loader} Setting property 'debug' to '1' did not find a matching property.
Nov 05, 2015 11:45:53 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Context/Loader} Setting property 'useSystemClassLoaderAsParent' to 'false' did not find a matching property.
[DevLoader] Starting DevLoader
[DevLoader] projectdir=/home/claude/git/bray/src/main/webapp
[DevLoader] added file:/home/claude/git/bray/target/classes/
...
[INFO] ioc.RegistryBuilder Adding module definition for class com.mydomain.services.AppModule
[INFO] TapestryModule.ComponentClassResolver Available pages (16):
(blank): com.mydomain.pages.Index
About: com.mydomain.pages.About
Then I see the nice "hello" from Tapestry and my other project (admin) comes up:
...
Application 'app' (version 1.0-SNAPSHOT) startup time: 172 ms to build IoC Registry, 541 ms overall.
______ __ ____
/_ __/__ ____ ___ ___ / /_______ __ / __/
/ / / _ `/ _ \/ -_|_-</ __/ __/ // / /__ \
/_/ \_,_/ .__/\__/___/\__/_/ \_, / /____/
/_/ /___/ 5.3.8 (development mode)
Nov 05, 2015 11:45:58 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/admin.xml
Nov 05, 2015 11:45:58 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Context/Loader} Setting property 'debug' to '1' did not find a matching property.
Nov 05, 2015 11:45:58 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Context/Loader} Setting property 'useSystemClassLoaderAsParent' to 'false' did not find a matching property.
[DevLoader] Starting DevLoader
[DevLoader] projectdir=/home/claude/git/tegu/admin/src/main/webapp
...
Nov 05, 2015 11:45:58 AM org.apache.catalina.deploy.WebXml setVersion
WARNING: Unknown version string [3.1]. Default version will be used.
log4j:WARN No appenders could be found for logger (org.apache.tapestry5.ioc.RegistryBuilder).
log4j:WARN Please initialize the log4j system properly.
Nov 05, 2015 11:46:02 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/manager.xml
Nov 05, 2015 11:46:02 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/docs.xml
Nov 05, 2015 11:46:02 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/host-manager.xml
Nov 05, 2015 11:46:02 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/examples.xml
I expected to see something like this after my admin.xml descriptor is deployed:
[INFO] ioc.RegistryBuilder Adding module definition for class com.myotherdomain.admin.services.AppModule
[INFO] TapestryModule.ComponentClassResolver Available pages (16):
...but instead there is silence. I can't see anything different in the two apps that would cause one to work and the other to fail. Where should I look?
The DevLoader Classpath was wrong. Fixing that fixed everything.
The DevLoader Classpath did not include the path /myapp/target/classes -- and that's where my app's AppModule was (/myapp/target/classes/com/mydomain/myapp/services/AppModule.class to be exact). This can be fixed in Project -> Properties -> Tomcat and checking the checkbox for the right path. The wrong configuration can also be seen in a file next to the project's WEB-INF called .#webclasspath which spells out the complete path (the relative path is shown in the config page). After fixing the setup, start Tomcat and .#webclasspath should be automatically updated.

Error creating bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]

hei i have spring 3 & hibernate 4, when running program i haven error like this, what must i do
Okt 17, 2014 6:30:45 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.j2ee.server:ZKBeanValidation' did not find a matching property.
Okt 17, 2014 6:30:45 AM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8089"]
Okt 17, 2014 6:30:46 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 1019 ms
Okt 17, 2014 6:30:46 AM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Okt 17, 2014 6:30:46 AM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.52 (Ubuntu)
Okt 17, 2014 6:30:52 AM org.apache.catalina.core.ApplicationContext log
INFO: No Spring WebApplicationInitializer types detected on classpath
Okt 17, 2014 6:30:52 AM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Spring root WebApplicationContext
log4j:WARN No appenders could be found for logger (org.springframework.web.context.ContextLoader).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
Okt 17, 2014 6:30:57 AM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Invocation of init method failed; nested exception is org.hibernate.HibernateException: Missing column: system in addressbook.userprofile
"nested exception is org.hibernate.HibernateException: Missing column: system in addressbook.userprofile"
Try checking for a missing column in addressbook.userprofile. It's looking for a column called "system". Or, try checking your relation annotations in your hibernate mapping file. It's difficult to say more with out seeing some code.
Here is a similar issue that may help you:
Hibernate Exception: Missing Column (column exists)

Tomcat v7.0 failed to start on Eclipse, Invalid <url-pattern> in servlet mapping

Whenever I am running a program on Eclipse, my tomcat is failing to start.
I get a dialog box stating this message
Server Tomcat v7.0 Server at localhost failed to start.
In the console, I am getting this messages
Nov 17, 2011 11:56:04 AM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Java\jre6\bin;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:/Program Files/Java/jre6/bin/client;C:/Program Files/Java/jre6/bin;C:/Program Files/Java/jre6/lib/i386;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Java\jdk1.6.0_01\bin;C:\Program Files\Java\jre1.6.0_01\bin;C:\ILOG\CPLEX_Studio_Preview122\opl\bin\x86_win32;C:\ILOG\CPLEX_Studio_Preview122\opl\oplide\;C:\ILOG\CPLEX_Studio_Preview122\cplex\bin\x86_win32;C:\ILOG\CPLEX_Studio_Preview122\cpoptimizer\bin\x86_win32;;D:\JSP_Setup\eclipse-jee-helios-SR2-win32\eclipse;;.
Nov 17, 2011 11:56:04 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:servletConfigTest' did not find a matching property.
Nov 17, 2011 11:56:04 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:BeerAdvice3' did not find a matching property.
Nov 17, 2011 11:56:04 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:BeerAdvice1' did not find a matching property.
Nov 17, 2011 11:56:05 AM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8080
Nov 17, 2011 11:56:05 AM org.apache.coyote.ajp.AjpProtocol init
INFO: Initializing Coyote AJP/1.3 on ajp-8009
Nov 17, 2011 11:56:05 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 682 ms
Nov 17, 2011 11:56:05 AM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Nov 17, 2011 11:56:05 AM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.2
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:415)
Caused by: java.lang.IllegalArgumentException: Invalid <url-pattern> entry_checking in servlet mapping
at org.apache.catalina.core.StandardContext.addServletMapping(StandardContext.java:2823)
at org.apache.catalina.core.StandardContext.addServletMapping(StandardContext.java:2799)
at org.apache.catalina.deploy.WebXml.configureContext(WebXml.java:1278)
at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1255)
at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:878)
at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:313)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:89)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:4667)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:139)
at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:988)
at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:771)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:139)
at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:988)
at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:275)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:139)
at org.apache.catalina.core.StandardService.startInternal(StandardService.java:427)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:139)
at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:649)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:139)
at org.apache.catalina.startup.Catalina.start(Catalina.java:585)
... 6 more
I had run the code previously, but now it is giving this problems.
Also, I went through this post
http://forums.opensuse.org/applications/391114-tomcat6-eclipse-not-working.html
But is not helping me.
Please help at the earliest.
Caused by: java.lang.IllegalArgumentException: Invalid <url-pattern>
entry_checking in servlet mapping
Find this mapping and make it correct.