You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@streampipes.apache.org by bo...@apache.org on 2024/03/28 12:49:46 UTC
(streampipes) 01/01: refactor: remove dead data lake model classes
This is an automated email from the ASF dual-hosted git repository.
bossenti pushed a commit to branch remove-data-lake
in repository https://gitbox.apache.org/repos/asf/streampipes.git
commit 70fa5ac86c8a102437f3ad3ff96aa46db157c318
Author: Tim Bossenmaier <ti...@bytefabrik.ai>
AuthorDate: Thu Mar 28 13:49:35 2024 +0100
refactor: remove dead data lake model classes
---
.../model/datalake/DataLakeConfiguration.java | 79 ----------------------
.../model/datalake/DataLakeRetentionPolicy.java | 77 ---------------------
.../model/datalake/LabelDefinition.java | 46 -------------
.../model/datalake/PersistedDataStream.java | 71 -------------------
4 files changed, 273 deletions(-)
diff --git a/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/DataLakeConfiguration.java b/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/DataLakeConfiguration.java
deleted file mode 100644
index a36e057884..0000000000
--- a/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/DataLakeConfiguration.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You 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.
- *
- */
-
-package org.apache.streampipes.model.datalake;
-
-import java.util.ArrayList;
-import java.util.List;
-
-public class DataLakeConfiguration {
-
- private Integer batchSize;
- private Integer flushDuration;
-
- private List<DataLakeRetentionPolicy> retentionPolicies;
-
- public DataLakeConfiguration() {
- this.batchSize = 2000;
- this.flushDuration = 500;
- this.retentionPolicies = new ArrayList<DataLakeRetentionPolicy>();
- }
-
- public DataLakeConfiguration(List<DataLakeRetentionPolicy> retentionPolicies) {
- this.batchSize = 2000;
- this.flushDuration = 500;
- this.retentionPolicies = retentionPolicies;
- }
-
- public DataLakeConfiguration(Integer batchSize, Integer flushDuration) {
- this.batchSize = batchSize;
- this.flushDuration = flushDuration;
- this.retentionPolicies = new ArrayList<DataLakeRetentionPolicy>();
- }
-
- public DataLakeConfiguration(Integer batchSize, Integer flushDuration,
- List<DataLakeRetentionPolicy> retentionPolicies) {
- this.batchSize = batchSize;
- this.flushDuration = flushDuration;
- this.retentionPolicies = retentionPolicies;
- }
-
- public List<DataLakeRetentionPolicy> getRetentionPolicies() {
- return retentionPolicies;
- }
-
- public void setRetentionPolicies(List<DataLakeRetentionPolicy> retentionPolicies) {
- this.retentionPolicies = retentionPolicies;
- }
-
- public Integer getBatchSize() {
- return batchSize;
- }
-
- public void setBatchSize(Integer batchSize) {
- this.batchSize = batchSize;
- }
-
- public Integer getFlushDuration() {
- return flushDuration;
- }
-
- public void setFlushDuration(Integer flushDuration) {
- this.flushDuration = flushDuration;
- }
-}
diff --git a/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/DataLakeRetentionPolicy.java b/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/DataLakeRetentionPolicy.java
deleted file mode 100644
index bcff21c9af..0000000000
--- a/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/DataLakeRetentionPolicy.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You 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.
- *
- */
-
-package org.apache.streampipes.model.datalake;
-
-public class DataLakeRetentionPolicy {
-
- private String name;
- private String durationLiteral;
- private boolean isDefault;
-
- public DataLakeRetentionPolicy(String name, int duration, String durationUnit, boolean isDefault) {
- this.name = name;
- this.durationLiteral = duration + durationUnit;
- this.isDefault = isDefault;
- }
-
- public DataLakeRetentionPolicy(String name) {
- this.name = name;
- this.isDefault = false;
- setDurationLiteralToInfinity();
- }
-
- public DataLakeRetentionPolicy(String name, String durationLiteral, boolean isDefault) {
- this.name = name;
- this.durationLiteral = durationLiteral;
- this.isDefault = isDefault;
- }
-
- public String getDurationLiteral() {
- return durationLiteral;
- }
-
- public void setDurationLiteral(int duration, String durationUnit) {
- this.durationLiteral = duration + durationUnit;
- }
-
- public void setDurationLiteralToInfinity() {
- this.durationLiteral = "INF";
- }
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public boolean isDefault() {
- return isDefault;
- }
-
- public void setDefault(boolean isDefault) {
- this.isDefault = isDefault;
- }
-
- @Override
- public String toString() {
- return String.format("DataLakeRetentionPolicy{name='%s', durationLiteral='%s'}", name, durationLiteral);
- }
-}
diff --git a/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/LabelDefinition.java b/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/LabelDefinition.java
deleted file mode 100644
index 3f9dc9e976..0000000000
--- a/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/LabelDefinition.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You 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.
- *
- */
-
-package org.apache.streampipes.model.datalake;
-
-public class LabelDefinition {
-
- private String classLabel;
- private String labelColumn;
-
- public LabelDefinition(String classLabel, String labelColumn) {
- this.classLabel = classLabel;
- this.labelColumn = labelColumn;
- }
-
- public String getClassLabel() {
- return classLabel;
- }
-
- public void setClassLabel(String classLabel) {
- this.classLabel = classLabel;
- }
-
- public String getLabelColumn() {
- return labelColumn;
- }
-
- public void setLabelColumn(String labelColumn) {
- this.labelColumn = labelColumn;
- }
-}
diff --git a/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/PersistedDataStream.java b/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/PersistedDataStream.java
deleted file mode 100644
index 277732cd50..0000000000
--- a/streampipes-model/src/main/java/org/apache/streampipes/model/datalake/PersistedDataStream.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You 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.
- *
- */
-package org.apache.streampipes.model.datalake;
-
-import org.apache.streampipes.model.schema.EventSchema;
-import org.apache.streampipes.model.shared.annotation.TsModel;
-
-@TsModel
-public class PersistedDataStream {
-
- private String pipelineId;
- private String pipelineName;
- private EventSchema schema;
- private String measureName;
-
- public PersistedDataStream() {
- }
-
- public PersistedDataStream(String pipelineId, EventSchema schema, String measureName) {
- this.pipelineId = pipelineId;
- this.schema = schema;
- this.measureName = measureName;
- }
-
- public String getPipelineId() {
- return pipelineId;
- }
-
- public void setPipelineId(String pipelineId) {
- this.pipelineId = pipelineId;
- }
-
- public EventSchema getSchema() {
- return schema;
- }
-
- public void setSchema(EventSchema schema) {
- this.schema = schema;
- }
-
- public String getMeasureName() {
- return measureName;
- }
-
- public void setMeasureName(String measureName) {
- this.measureName = measureName;
- }
-
- public String getPipelineName() {
- return pipelineName;
- }
-
- public void setPipelineName(String pipelineName) {
- this.pipelineName = pipelineName;
- }
-}