2017-10-23 10 views
0

최근에 Google Java eclipse 플러그인을 사용하여 Google Cloud Dataflow 파이프 라인 프로젝트를 설정했습니다. 기본 SKD 버전은 2.1.0입니다.Google Cloud Dataflow 파이프 라인 프로젝트 pom에서 beam-sdks-java-core-2.2.0.jar을 사용하는 방법?

<dependencies> 
<dependency> 
    <groupId>com.google.cloud.dataflow</groupId> 
    <artifactId>google-cloud-dataflow-java-sdk-all</artifactId> 
    <version>2.1.0</version> 
</dependency> 
... ... 

그리고이 코드는 배포하지만 큰 쿼리에 데이터를 삽입 할 때 그것은 NullPointerException 예외가 될 수있다. 그리고 나서 다음 기사를 발견했습니다. 문제는 버전 2.2.0, https://issues.apache.org/jira/browse/BEAM-2834에서 수정 된 것입니다.

그러나 어떻게해야하는지 잘 모릅니다. pom 버전을 2.1.0에서 2.2.0으로 변경했으며 모든 종속성이 사라지고 오류는 Missing artifact com.google.cloud.dataflow:google-cloud-dataflow-java-sdk-all:jar:2.2.0이고 google-cloud-dataflow-java-sdk-all-2.1.0.jarbeam-sdks-java-core-2.1.0.jar 버전은 동일합니다. 변경할 수 없습니다 beam-sdks-java-core-2.1.0.jar 버전 2.2.0

누구든지 나에게 jar 버전을 업데이트하는 방법이나 NullPointerException 예외를 수정하는 방법에 대한 예제를 보여줄 수 있다면 큰 도움이 될 것입니다.

미리 감사드립니다.

===============================

이것은

<?xml version="1.0" encoding="UTF-8"?> 
<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 
    ~ Copyright (C) 2017 Google Inc. 
    ~ 
    ~ Licensed under the Apache License, Version 2.0 (the "License"); you may not 
    ~ use this file except in compliance with the License. You may obtain a copy of 
    ~ the License at 
    ~ 
    ~ http://www.apache.org/licenses/LICENSE-2.0 
    ~ 
    ~ Unless required by applicable law or agreed to in writing, software 
    ~ distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 
    ~ WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 
    ~ License for the specific language governing permissions and limitations under 
    ~ the License. 
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~--> 
<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 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 
    <modelVersion>4.0.0</modelVersion> 

    <groupId>com.company.product</groupId> 
    <artifactId>my-product</artifactId> 
    <version>0.0.1-SNAPSHOT</version> 

    <properties> 
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> 
    </properties> 

    <repositories> 
    <repository> 
     <id>ossrh.snapshots</id> 
     <name>Sonatype OSS Repository Hosting</name> 
     <url>https://oss.sonatype.org/content/repositories/snapshots/</url> 
     <releases> 
     <enabled>false</enabled> 
     </releases> 
     <snapshots> 
     <enabled>true</enabled> 
     </snapshots> 
    </repository> 
    </repositories> 

    <build> 
    <plugins> 
     <plugin> 
     <groupId>org.apache.maven.plugins</groupId> 
     <artifactId>maven-compiler-plugin</artifactId> 
     <version>3.6.1</version> 
     <configuration> 
      <source>1.8</source> 
      <target>1.8</target> 
     </configuration> 
     </plugin> 
    </plugins> 

    <pluginManagement> 
     <plugins> 
     <plugin> 
      <groupId>org.codehaus.mojo</groupId> 
      <artifactId>exec-maven-plugin</artifactId> 
      <version>1.5.0</version> 
      <configuration> 
      <cleanupDaemonThreads>false</cleanupDaemonThreads> 
      </configuration> 
     </plugin> 
     </plugins> 
    </pluginManagement> 
    </build> 

    <dependencies> 
    <dependency> 
     <groupId>com.google.cloud.dataflow</groupId> 
     <artifactId>google-cloud-dataflow-java-sdk-all</artifactId> 
     <version>2.1.0</version> 
    </dependency> 

    <!-- slf4j API frontend binding with JUL backend --> 
    <dependency> 
     <groupId>org.slf4j</groupId> 
     <artifactId>slf4j-api</artifactId> 
     <version>1.7.14</version> 
    </dependency> 
    <dependency> 
     <groupId>org.slf4j</groupId> 
     <artifactId>slf4j-jdk14</artifactId> 
     <version>1.7.14</version> 
    </dependency> 
    </dependencies> 
</project> 

답변

0

2.2.0 머리/마스터에서 잘라내어에게 새로운 2.2.0 빌드를하지 않았 메이븐 즉 구글에서 아직 사용할 수없는 내 치어입니다. AFAIK, 현재 진행 중입니다. 당신이 원하는 경우

https://github.com/GoogleCloudPlatform/DataflowJavaSDK/releases https://mvnrepository.com/artifact/com.google.cloud.dataflow/google-cloud-dataflow-java-sdk-all

, 당신은 최신 버전을 다운로드 및 구축/스스로를 사용할 수 있습니다 - 당신이 2.2.0 버전을 기다릴 수없는 경우.

+0

나 혼자서 만들어야 할 시간이라고 생각합니다. 당신의 도움을 주셔서 감사합니다. – Charles