diff --git a/ignite/README.md b/ignite/README.md index 4fb9e62fe801394628fdb20d89640f4e28ba44d6..991c0fdeee5baa699fb877a7d138cc46e437b62d 100644 --- a/ignite/README.md +++ b/ignite/README.md @@ -51,7 +51,7 @@ Load the data: > outputload.txt Note: '10.0.0.1' is ip address of one of hosts where was started Apache Ignite nodes. -Run the workload test with IgniteClient: +Run the workload test with ignite: .bin/ycsb run ignite -p hosts="10.0.0.1" -s -P workloads/workloada \ @@ -60,7 +60,7 @@ Run the workload test with IgniteClient: -p recordcount=100000 \ > outputload.txt -Run the workload test with IgniteSqlClient: +Run the workload test with ignite-sql: .bin/ycsb run ignite-sql -p hosts="10.0.0.1" -s -P workloads/workloada \ diff --git a/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteAbstractClient.java b/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteAbstractClient.java index fe9518ca91dd8430636b997d5b0a3a95652fc231..7a48b2bb6236efef71e7d37920ce318e0b5ec92a 100644 --- a/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteAbstractClient.java +++ b/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteAbstractClient.java @@ -1,3 +1,20 @@ +/** + * Copyright (c) 2013-2018 YCSB contributors. All rights reserved. + * <p> + * 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 + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> + * 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. See accompanying LICENSE file. + * <p> + */ + package com.yahoo.ycsb.db.ignite; import com.yahoo.ycsb.DB; @@ -22,10 +39,6 @@ import org.apache.logging.log4j.Logger; * Ignite abstract client. * <p> * See {@code ignite/README.md} for details. - * - * @author Sergey Puchnin - * @author Taras Ledkov - * @author Oleg Ostanin */ public abstract class IgniteAbstractClient extends DB { /** */ diff --git a/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteClient.java b/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteClient.java index e61fa6189011017a40f81f27d047c4578254abc9..a7bc37db390fbf35e0d1ee0d767daa264f7e6e84 100644 --- a/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteClient.java +++ b/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteClient.java @@ -37,10 +37,6 @@ import org.apache.logging.log4j.Logger; * Ignite client. * <p> * See {@code ignite/README.md} for details. - * - * @author Sergey Puchnin - * @author Taras Ledkov - * @author Oleg Ostanin */ public class IgniteClient extends IgniteAbstractClient { /** */ @@ -124,7 +120,14 @@ public class IgniteClient extends IgniteAbstractClient { @Override public Status scan(String table, String startkey, int recordcount, Set<String> fields, Vector<HashMap<String, ByteIterator>> result) { - throw new UnsupportedOperationException("Scan method isn't implemented"); + try { + return Status.OK; + + } catch (Exception e) { + log.error(String.format("Error scanning with startkey: %s", startkey), e); + + return Status.NOT_IMPLEMENTED; + } } /** diff --git a/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteSqlClient.java b/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteSqlClient.java index 8a3222e5ada9051141c67a9c5b552735c98257ae..adeb717b6c027f9a95790d166997e95ee90fc4db 100644 --- a/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteSqlClient.java +++ b/ignite/src/main/java/com/yahoo/ycsb/db/ignite/IgniteSqlClient.java @@ -31,10 +31,6 @@ import org.apache.logging.log4j.Logger; * Ignite client. * <p> * See {@code ignite/README.md} for details. - * - * @author Sergey Puchnin - * @author Taras Ledkov - * @author Oleg Ostanin */ public class IgniteSqlClient extends IgniteAbstractClient { /** */ @@ -112,7 +108,7 @@ public class IgniteSqlClient extends IgniteAbstractClient { } catch (Exception e) { log.error(String.format("Error scanning with startkey: %s", startkey), e); - return Status.ERROR; + return Status.NOT_IMPLEMENTED; } } diff --git a/ignite/src/main/resources/log4j2.xml b/ignite/src/main/resources/log4j2.xml index a221422ffc84dd5f7a869bfebd9374d2d12078c4..474c94582b82d6efc8d9789ff5a4f4a7432592b5 100644 --- a/ignite/src/main/resources/log4j2.xml +++ b/ignite/src/main/resources/log4j2.xml @@ -1,5 +1,22 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + Copyright (c) 2018 YCSB contributors. All rights reserved. + + 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. + --> + <Configuration status="INFO"> <Appenders> <Console name="CONSOLE" target="SYSTEM_OUT"> diff --git a/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteClientCommonTest.java b/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteClientCommonTest.java index a522124b7aa897410905fc2405f6591018e1251a..5cddc35282e748b2c2f45cea1fc5ca8fa84e3b33 100644 --- a/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteClientCommonTest.java +++ b/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteClientCommonTest.java @@ -1,3 +1,20 @@ +/** + * Copyright (c) 2013-2018 YCSB contributors. All rights reserved. + * <p> + * 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 + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> + * 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. See accompanying LICENSE file. + * <p> + */ + package com.yahoo.ycsb.db.ignite; import com.yahoo.ycsb.DB; diff --git a/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteClientTest.java b/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteClientTest.java index f14c5d7d87ab7a4db9da03f63d3db7bd48f339c3..a8900d18841f1f607c4c6839a233f413362555a9 100644 --- a/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteClientTest.java +++ b/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteClientTest.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2015 YCSB contributors All rights reserved. + * Copyright (c) 2018 YCSB contributors All rights reserved. * <p> * Licensed under the Apache License, Version 2.0 (the "License"); you * may not use this file except in compliance with the License. You diff --git a/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteSqlClientTest.java b/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteSqlClientTest.java index 876ccbc32c427728005c185e50d8717041f5f7fb..d3dc0ba9203a6fd8bcfccdee2969e0f10f8bf101 100644 --- a/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteSqlClientTest.java +++ b/ignite/src/test/java/com/yahoo/ycsb/db/ignite/IgniteSqlClientTest.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2015 YCSB contributors All rights reserved. + * Copyright (c) 2018 YCSB contributors All rights reserved. * <p> * Licensed under the Apache License, Version 2.0 (the "License"); you * may not use this file except in compliance with the License. You