R2dbc 和 Jdbc Probelm Spring Boot

如何解决R2dbc 和 Jdbc Probelm Spring Boot

大家好,我使用 Spring Boot Webflux 编写了一个 rest api

标签控制器

@RestController
@RequestMapping("/api/label")
@RequiredArgsConstructor
public class LabelController {

  private final LabelService labelService;

@GetMapping
public Flux<LabelEntity> getAllLabels(){
    return labelService.getAll();
}

标签服务

  @Service
  @RequiredArgsConstructor
  public class LabelService {

   private final LabelRepository labelRepository;


   public Flux<LabelEntity> getAll() {
     return labelRepository.findAll();
   }

LabelRespository

 @Repository
 public interface LabelRepository extends ReactiveCrudRepository<LabelEntity,Integer> {
 }

应用程序.yml 由于我在应用yml部分使用了liquebase,所以添加了jdbc和r2dbc。

 spring:
   liquibase:
     enabled: true
     url: jdbc:postgresql://localhost:5432/liquebase
     user: postgres
     password: 12345
     change-log: classpath:db/liquibase/db.changelog-master-main.yml
  datasource:
    driver-class-name: org.postgresql.Driver
  r2dbc:
    url: r2dbc:postgresql://localhost:5432/liquebase
    username: postgres
    password: 12345
    pool:
      initial-size: 100
      max-size: 500
      max-idle-time: 30m
      validation-query: SELECT 1


server:
    port: 8085

pom.xml

 <?xml version="1.0" encoding="UTF-8"?>
  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema- 
instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-parent</artifactId>
    <version>2.4.3</version>
    <relativePath/> <!-- lookup parent from repository -->
</parent>
<groupId>com.WebFluxTestCodes</groupId>
<artifactId>WebFluxTestCodes</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>WebFluxTestCodes</name>
<description>Demo project for Spring Boot</description>
<properties>
    <java.version>11</java.version>
</properties>

<dependencies>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-data-r2dbc</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-data-jdbc</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-webflux</artifactId>
    </dependency>

    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-devtools</artifactId>
        <scope>runtime</scope>
        <optional>true</optional>
    </dependency>
    <dependency>
        <groupId>org.liquibase</groupId>
        <artifactId>liquibase-core</artifactId>
        <version>3.10.3</version>
    </dependency>
    <dependency>
        <groupId>io.r2dbc</groupId>
        <artifactId>r2dbc-postgresql</artifactId>
        <scope>runtime</scope>
    </dependency>
    <dependency>
        <groupId>org.liquibase</groupId>
        <artifactId>liquibase-maven-plugin</artifactId>
        <version>4.3.1</version>
    </dependency>
    <dependency>
        <groupId>org.postgresql</groupId>
        <artifactId>postgresql</artifactId>
        <scope>runtime</scope>
    </dependency>

    <dependency>
        <groupId>org.projectlombok</groupId>
        <artifactId>lombok</artifactId>
        <optional>true</optional>
    </dependency>

    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-test</artifactId>
        <scope>test</scope>
    </dependency>
    <dependency>
        <groupId>io.projectreactor</groupId>
        <artifactId>reactor-test</artifactId>
        <scope>test</scope>
    </dependency>

    <dependency>
        <groupId>javax.persistence</groupId>
        <artifactId>javax.persistence-api</artifactId>
        <version>2.2</version>
    </dependency>

</dependencies>
<build>
    <pluginManagement>
        <plugins>

            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
                <configuration>
                    <excludes>
                        <exclude>
                            <groupId>org.projectlombok</groupId>
                            <artifactId>lombok</artifactId>
                        </exclude>
                    </excludes>
                </configuration>
            </plugin>
        </plugins>
    </pluginManagement>
</build>

我的 RestApi 主类

 @SpringBootApplication
 @EnableR2dbcRepositories
 @ComponentScan("com.WebFluxTestCodes.WebFluxTestCodes.business.*")
 public class WebFluxTestCodesApplication {

    public static void main(String[] args) {
       SpringApplication.run(WebFluxTestCodesApplication.class,args);
    }

  }

在项目启动时记录我的项目没有问题

    2021-03-15 20:38:12.375  INFO 8692 --- [  restartedMain] c.W.W.WebFluxTestCodesApplication        : 
    Starting WebFluxTestCodesApplication using Java 15.0.1 on WIN-3QMQSJHKUBK with PID 8692 
   (C:\Users\user\Desktop\TestWebService\WebFluxTestCodes\target\classes started by user in 
     C:\Users\user\Desktop\TestWebService\WebFluxTestCodes)
  2021-03-15 20:38:12.375  INFO 8692 --- [  restartedMain] c.W.W.WebFluxTestCodesApplication        : 
  No active profile set,falling back to default profiles: default
  2021-03-15 20:38:13.266  INFO 8692 --- [  restartedMain] o.s.b.devtools.restart.ChangeableUrls    : 
  The Class-Path manifest attribute in C:\Users\user\.m2\repository\org\liquibase\liquibase- 
   core\3.10.3\liquibase-core-3.10.3.jar referenced one or more files that do not exist: 
  file:/C:/Users/user/.m2/repository/org/liquibase/liquibase-core/3.10.3/commons-cli- 
 1.4.jar,file:/C:/Users/user/.m2/repository/org/liquibase/liquibase-core/3.10.3/snakeyaml- 
  1.24.jar,file:/C:/Users/user/.m2/repository/org/liquibase/liquibase-core/3.10.3/slf4j-api- 
  1.7.28.jar,file:/C:/Users/user/.m2/repository/org/liquibase/liquibase-core/3.10.3/logback-classic- 
  1.2.3.jar,file:/C:/Users/user/.m2/repository/org/liquibase/liquibase-core/3.10.3/logback-core- 
   1.2.3.jar
  2021-03-15 20:38:13.266  INFO 8692 --- [  restartedMain] .e.DevToolsPropertyDefaultsPostProcessor : 
    Devtools property defaults active! Set 'spring.devtools.add-properties' to 'false' to disable
  2021-03-15 20:38:13.266  INFO 8692 --- [  restartedMain] .e.DevToolsPropertyDefaultsPostProcessor : 
  For additional web related logging consider setting the 'logging.level.web' property to 'DEBUG'
  2021-03-15 20:38:16.782  INFO 8692 --- [  restartedMain] .s.d.r.c.RepositoryConfigurationDelegate : 
    Multiple Spring Data modules found,entering strict repository configuration mode!
    2021-03-15 20:38:16.782  INFO 8692 --- [  restartedMain] .s.d.r.c.RepositoryConfigurationDelegate 
   : Bootstrapping Spring Data R2DBC repositories in DEFAULT mode.
    2021-03-15 20:38:17.264  INFO 8692 --- [  restartedMain] .RepositoryConfigurationExtensionSupport 
   : Spring Data R2DBC - Could not safely identify store assignment for repository candidate 
    interface com.WebFluxTestCodes.WebFluxTestCodes.repository.LabelRepository. If you want this 
     repository to be a R2DBC repository,consider annotating your entities with one of these 
     annotations: org.springframework.data.relational.core.mapping.Table (preferred),or consider 
     extending one of the following types with your repository: 
     org.springframework.data.r2dbc.repository.R2dbcRepository.
     2021-03-15 20:38:17.276  INFO 8692 --- [  restartedMain] 
    .RepositoryConfigurationExtensionSupport : Spring Data R2DBC - Could not safely identify store 
    assignment for repository candidate interface 
     com.WebFluxTestCodes.WebFluxTestCodes.repository.ProjectRepository. If you want this repository 
    to be a R2DBC repository,consider annotating your entities with one of these annotations: 
     org.springframework.data.relational.core.mapping.Table (preferred),or consider extending one of 
    the following types with your repository: 
    org.springframework.data.r2dbc.repository.R2dbcRepository.
    2021-03-15 20:38:17.280  INFO 8692 --- [  restartedMain] .RepositoryConfigurationExtensionSupport 
    : Spring Data R2DBC - Could not safely identify store assignment for repository candidate 
    interface com.WebFluxTestCodes.WebFluxTestCodes.repository.TasksRepository. If you want this 
    repository to be a R2DBC repository,consider annotating your entities with one of these 
    annotations: org.springframework.data.relational.core.mapping.Table (preferred),or consider 
    extending one of the following types with your repository: 
     org.springframework.data.r2dbc.repository.R2dbcRepository.
    2021-03-15 20:38:17.284  INFO 8692 --- [  restartedMain] .s.d.r.c.RepositoryConfigurationDelegate 
    : Finished Spring Data repository scanning in 452 ms. Found 0 R2DBC repository interfaces.
    2021-03-15 20:38:18.522  INFO 8692 --- [  restartedMain] .s.d.r.c.RepositoryConfigurationDelegate 
     : Multiple Spring Data modules found,entering strict repository configuration mode!
    2021-03-15 20:38:18.624  INFO 8692 --- [  restartedMain] .s.d.r.c.RepositoryConfigurationDelegate 
    : Bootstrapping Spring Data R2DBC repositories in DEFAULT mode.
    2021-03-15 20:38:18.714  INFO 8692 --- [  restartedMain] .RepositoryConfigurationExtensionSupport 
    : Spring Data R2DBC - Could not safely identify store assignment for repository candidate 
     interface com.WebFluxTestCodes.WebFluxTestCodes.repository.LabelRepository. If you want this 
    repository to be a R2DBC repository,or consider 
     extending one of the following types with your repository: 
       org.springframework.data.r2dbc.repository.R2dbcRepository.
     2021-03-15 20:38:18.718  INFO 8692 --- [  restartedMain] 
     .RepositoryConfigurationExtensionSupport : Spring Data R2DBC - Could not safely identify store 
     assignment for repository candidate interface 
      com.WebFluxTestCodes.WebFluxTestCodes.repository.ProjectRepository. If you want this repository 
      to be a R2DBC repository,consider annotating your entities with one of these annotations: 
      org.springframework.data.relational.core.mapping.Table (preferred),or consider extending one 
        of the following types with your repository: 
     org.springframework.data.r2dbc.repository.R2dbcRepository.
    2021-03-15 20:38:18.723  INFO 8692 --- [  restartedMain] .RepositoryConfigurationExtensionSupport 
     : Spring Data R2DBC - Could not safely identify store assignment for repository candidate 
    interface com.WebFluxTestCodes.WebFluxTestCodes.repository.TasksRepository. If you want this 
     repository to be a R2DBC repository,or consider 
    extending one of the following types with your repository: 
    org.springframework.data.r2dbc.repository.R2dbcRepository.
    2021-03-15 20:38:18.724  INFO 8692 --- [  restartedMain] .s.d.r.c.RepositoryConfigurationDelegate 
     : Finished Spring Data repository scanning in 97 ms. Found 0 R2DBC repository interfaces.
     2021-03-15 20:38:26.847  INFO 8692 --- [  restartedMain] com.zaxxer.hikari.HikariDataSource       
     : HikariPool-1 - Starting...
     2021-03-15 20:38:28.550  INFO 8692 --- [  restartedMain] com.zaxxer.hikari.HikariDataSource       
    : HikariPool-1 - Start completed.
     2021-03-15 20:38:42.546  INFO 8692 --- [  restartedMain] l.lockservice.StandardLockService        
   : Successfully acquired change log lock
    2021-03-15 20:38:44.908  INFO 8692 --- [  restartedMain] l.c.StandardChangeLogHistoryService      
  : Reading from public.databasechangelog
  2021-03-15 20:38:45.635  INFO 8692 --- [  restartedMain] l.lockservice.StandardLockService        : 
    Successfully released change log lock
 2021-03-15 20:38:45.651  INFO 8692 --- [  restartedMain] com.zaxxer.hikari.HikariDataSource       : 
  HikariPool-1 - Shutdown initiated...
    2021-03-15 20:38:45.698  INFO 8692 --- [  restartedMain] com.zaxxer.hikari.HikariDataSource       
    : HikariPool-1 - Shutdown completed.
   2021-03-15 20:38:46.773  INFO 8692 --- [  restartedMain] o.s.b.d.a.OptionalLiveReloadServer       
  : LiveReload server is running on port 35729
  2021-03-15 20:38:47.884  INFO 8692 --- [  restartedMain] o.s.b.web.embedded.netty.NettyWebServer  : 
   Netty started on port 8085
    2021-03-15 20:38:47.915  INFO 8692 --- [  restartedMain] c.W.W.WebFluxTestCodesApplication        
   : Started WebFluxTestCodesApplication in 39.523 seconds (JVM running for 45.043)

但是,当我使用浏览器发送请求时,没有请求到达控制器,浏览器中出现以下错误。

   This application has no configured error view,so you are seeing this as a fallback.

   Mon Mar 15 20:38:51 AZT 2021
   [005bd2a6-1] There was an unexpected error (type=Not Found,status=404).
    org.springframework.web.server.ResponseStatusException: 404 NOT_FOUND
    at 
   org.springframework.web.reactive.resource.ResourceWebHandler
  .lambda$handle$1(ResourceWebHandler.java:378)
   Suppressed: reactor.core.publisher.FluxOnAssembly$OnAssemblyException: 
   Error has been observed at the following site(s):
  |_ checkpoint ⇢ HTTP GET "/all" [ExceptionHandlingWebHandler]
   Stack trace:
    at 
    org.springframework.web.reactive.resource
   .ResourceWebHandler.lambda$handle$1(ResourceWebHandler.java:378)
    at reactor.core.publisher.MonoDefer.subscribe(MonoDefer.java:44)
    at reactor.core.publisher.Mono.subscribe(Mono.java:4046)
    at reactor.core.publisher.FluxSwitchIfEmpty$SwitchIfEmptySubscriber
    .onComplete(FluxSwitchIfEmpty.java:81)
    at reactor.core.publisher.MonoFlatMap$FlatMapMain.onComplete(MonoFlatMap.java:181)
    at reactor.core.publisher.MonoNext$NextSubscriber.onComplete(MonoNext.java:102)
    at reactor.core.publisher.FluxConcatMap$ConcatMapImmediate.drain(FluxConcatMap.java:366)
    at reactor.core.publisher.FluxConcatMap$ConcatMapImmediate.onSubscribe(FluxConcatMap.java:218)
    at reactor.core.publisher.FluxIterable.subscribe(FluxIterable.java:164)
    at reactor.core.publisher.FluxIterable.subscribe(FluxIterable.java:86)
    at reactor.core.publisher.Mono.subscribe(Mono.java:4046)
    at reactor.core.publisher.MonoIgnoreThen$ThenIgnoreMain.drain(MonoIgnoreThen.java:173)
    at reactor.core.publisher.MonoIgnoreThen.subscribe(MonoIgnoreThen.java:56)
    at reactor.core.publisher.MonoFlatMap$FlatMapMain.onNext(MonoFlatMap.java:157)
    at reactor.core.publisher.FluxSwitchIfEmpty$SwitchIfEmptySubscriber
    .onNext(FluxSwitchIfEmpty.java:73)
    at reactor.core.publisher.MonoNext$NextSubscriber.onNext(MonoNext.java:82)
    at reactor.core.publisher.FluxConcatMap$ConcatMapImmediate.innerNext(FluxConcatMap.java:281)
    at reactor.core.publisher.FluxConcatMap$ConcatMapInner.onNext(FluxConcatMap.java:860)
    at reactor.core.publisher.FluxMapFuseable$MapFuseableSubscriber.onNext(FluxMapFuseable.java:127)
    at reactor.core.publisher.Operators$ScalarSubscription.request(Operators.java:2397)
    at reactor.core.publisher.FluxMapFuseable$MapFuseableSubscriber.request(FluxMapFuseable.java:169)
    at reactor.core.publisher.Operators$MultiSubscriptionSubscriber.set(Operators.java:2193)
    at reactor.core.publisher.Operators$MultiSubscriptionSubscriber.onSubscribe(Operators.java:2067)
    at reactor.core.publisher.FluxMapFuseable$MapFuseableSubscriber
    .onSubscribe(FluxMapFuseable.java:96)
    at reactor.core.publisher.MonoJust.subscribe(MonoJust.java:54)
    at reactor.core.publisher.Mono.subscribe(Mono.java:4046)
    at reactor.core.publisher.FluxConcatMap$ConcatMapImmediate.drain(FluxConcatMap.java:448)
    at reactor.core.publisher.FluxConcatMap$ConcatMapImmediate.onSubscribe(FluxConcatMap.java:218)
    at reactor.core.publisher.FluxIterable.subscribe(FluxIterable.java:164)
    at reactor.core.publisher.FluxIterable.subscribe(FluxIterable.java:86)
    at reactor.core.publisher.InternalMonoOperator.subscribe(InternalMonoOperator.java:64)
    at reactor.core.publisher.MonoDefer.subscribe(MonoDefer.java:52)
    at reactor.core.publisher.Mono.subscribe(Mono.java:4046)
    at reactor.core.publisher.MonoIgnoreThen$ThenIgnoreMain.drain(MonoIgnoreThen.java:173)
    at reactor.core.publisher.MonoIgnoreThen.subscribe(MonoIgnoreThen.java:56)
    at reactor.core.publisher.InternalMonoOperator.subscribe(InternalMonoOperator.java:64)
    at reactor.netty.http.server.HttpServer$HttpServerHandle.onStateChange(HttpServer.java:860)
    at reactor.netty.ReactorNetty$CompositeConnectionObserver.onStateChange(ReactorNetty.java:638)
    at reactor.netty.transport.ServerTransport$ChildObserver.onStateChange(ServerTransport.java:478)
    at reactor.netty.http.server.HttpServerOperations.onInboundNext(HttpServerOperations.java:525)
    at reactor.netty.channel.ChannelOperationsHandler.channelRead(ChannelOperationsHandler.java:94)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
    at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
    at reactor.netty.http.server.HttpTrafficHandler.channelRead(HttpTrafficHandler.java:209)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
    at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
    at io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:436)
    at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:324)
    at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:296)
    at io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:251)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
    at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
    at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
    at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919)
    at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166)
    at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:719)
    at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:655)
    at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:581)
    at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:493)
    at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989)
    at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
    at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
    at java.base/java.lang.Thread.run(Thread.java:832)

请求控制器项目不工作 有什么问题?这对我很重要请帮助我

我的项目github链接 --https://github.com/Z-Farrukzada/Webflux-Reactive-Programming-example

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐


使用本地python环境可以成功执行 import pandas as pd import matplotlib.pyplot as plt # 设置字体 plt.rcParams[&#39;font.sans-serif&#39;] = [&#39;SimHei&#39;] # 能正确显示负号 p
错误1:Request method ‘DELETE‘ not supported 错误还原:controller层有一个接口,访问该接口时报错:Request method ‘DELETE‘ not supported 错误原因:没有接收到前端传入的参数,修改为如下 参考 错误2:cannot r
错误1:启动docker镜像时报错:Error response from daemon: driver failed programming external connectivity on endpoint quirky_allen 解决方法:重启docker -&gt; systemctl r
错误1:private field ‘xxx‘ is never assigned 按Altʾnter快捷键,选择第2项 参考:https://blog.csdn.net/shi_hong_fei_hei/article/details/88814070 错误2:启动时报错,不能找到主启动类 #
报错如下,通过源不能下载,最后警告pip需升级版本 Requirement already satisfied: pip in c:\users\ychen\appdata\local\programs\python\python310\lib\site-packages (22.0.4) Coll
错误1:maven打包报错 错误还原:使用maven打包项目时报错如下 [ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.2.0:resources (default-resources)
错误1:服务调用时报错 服务消费者模块assess通过openFeign调用服务提供者模块hires 如下为服务提供者模块hires的控制层接口 @RestController @RequestMapping(&quot;/hires&quot;) public class FeignControl
错误1:运行项目后报如下错误 解决方案 报错2:Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project sb 解决方案:在pom.
参考 错误原因 过滤器或拦截器在生效时,redisTemplate还没有注入 解决方案:在注入容器时就生效 @Component //项目运行时就注入Spring容器 public class RedisBean { @Resource private RedisTemplate&lt;String
使用vite构建项目报错 C:\Users\ychen\work&gt;npm init @vitejs/app @vitejs/create-app is deprecated, use npm init vite instead C:\Users\ychen\AppData\Local\npm-
参考1 参考2 解决方案 # 点击安装源 协议选择 http:// 路径填写 mirrors.aliyun.com/centos/8.3.2011/BaseOS/x86_64/os URL类型 软件库URL 其他路径 # 版本 7 mirrors.aliyun.com/centos/7/os/x86
报错1 [root@slave1 data_mocker]# kafka-console-consumer.sh --bootstrap-server slave1:9092 --topic topic_db [2023-12-19 18:31:12,770] WARN [Consumer clie
错误1 # 重写数据 hive (edu)&gt; insert overwrite table dwd_trade_cart_add_inc &gt; select data.id, &gt; data.user_id, &gt; data.course_id, &gt; date_format(
错误1 hive (edu)&gt; insert into huanhuan values(1,&#39;haoge&#39;); Query ID = root_20240110071417_fe1517ad-3607-41f4-bdcf-d00b98ac443e Total jobs = 1
报错1:执行到如下就不执行了,没有显示Successfully registered new MBean. [root@slave1 bin]# /usr/local/software/flume-1.9.0/bin/flume-ng agent -n a1 -c /usr/local/softwa
虚拟及没有启动任何服务器查看jps会显示jps,如果没有显示任何东西 [root@slave2 ~]# jps 9647 Jps 解决方案 # 进入/tmp查看 [root@slave1 dfs]# cd /tmp [root@slave1 tmp]# ll 总用量 48 drwxr-xr-x. 2
报错1 hive&gt; show databases; OK Failed with exception java.io.IOException:java.lang.RuntimeException: Error in configuring object Time taken: 0.474 se
报错1 [root@localhost ~]# vim -bash: vim: 未找到命令 安装vim yum -y install vim* # 查看是否安装成功 [root@hadoop01 hadoop]# rpm -qa |grep vim vim-X11-7.4.629-8.el7_9.x
修改hadoop配置 vi /usr/local/software/hadoop-2.9.2/etc/hadoop/yarn-site.xml # 添加如下 &lt;configuration&gt; &lt;property&gt; &lt;name&gt;yarn.nodemanager.res