From 1e6399f59d4fb2d122be0e5fa5cdd7c1c2fda04e Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Thu, 18 Aug 2016 16:47:05 -0700 Subject: [PATCH 01/12] Add apache license for build.sbt files in examples/ --- .../java-local-helloworld/build.sbt | 17 +++++++++++++++++ .../java-local-regression/build.sbt | 16 ++++++++++++++++ .../experimental/java-local-tutorial/build.sbt | 16 ++++++++++++++++ .../experimental/scala-cleanup-app/build.sbt | 17 +++++++++++++++++ .../scala-local-friend-recommendation/build.sbt | 17 +++++++++++++++++ .../scala-local-helloworld/build.sbt | 17 +++++++++++++++++ .../scala-local-movielens-evaluation/build.sbt | 16 ++++++++++++++++ .../scala-local-movielens-filtering/build.sbt | 16 ++++++++++++++++ .../scala-local-regression/build.sbt | 17 +++++++++++++++++ .../build.sbt | 17 +++++++++++++++++ .../scala-parallel-recommendation-cat/build.sbt | 17 +++++++++++++++++ .../build.sbt | 17 +++++++++++++++++ .../build.sbt | 17 +++++++++++++++++ .../build.sbt | 17 +++++++++++++++++ .../scala-parallel-regression/build.sbt | 16 ++++++++++++++++ .../build.sbt | 17 +++++++++++++++++ .../build.sbt | 17 +++++++++++++++++ .../scala-parallel-trim-app/build.sbt | 17 +++++++++++++++++ .../scala-recommendations/build.sbt | 17 +++++++++++++++++ .../experimental/scala-refactor-test/build.sbt | 17 +++++++++++++++++ examples/experimental/scala-stock/build.sbt | 17 +++++++++++++++++ 21 files changed, 352 insertions(+) diff --git a/examples/experimental/java-local-helloworld/build.sbt b/examples/experimental/java-local-helloworld/build.sbt index 198a6d986b..b246d7f850 100644 --- a/examples/experimental/java-local-helloworld/build.sbt +++ b/examples/experimental/java-local-helloworld/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/java-local-regression/build.sbt b/examples/experimental/java-local-regression/build.sbt index dc4100b4fe..92d74163b8 100644 --- a/examples/experimental/java-local-regression/build.sbt +++ b/examples/experimental/java-local-regression/build.sbt @@ -1,3 +1,19 @@ +/* + * 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. + */ import AssemblyKeys._ diff --git a/examples/experimental/java-local-tutorial/build.sbt b/examples/experimental/java-local-tutorial/build.sbt index b7a4ccd63c..077fa0c3a5 100644 --- a/examples/experimental/java-local-tutorial/build.sbt +++ b/examples/experimental/java-local-tutorial/build.sbt @@ -1,3 +1,19 @@ +/* + * 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. + */ import AssemblyKeys._ diff --git a/examples/experimental/scala-cleanup-app/build.sbt b/examples/experimental/scala-cleanup-app/build.sbt index 82ce614f62..d7ba8a6bee 100644 --- a/examples/experimental/scala-cleanup-app/build.sbt +++ b/examples/experimental/scala-cleanup-app/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-local-friend-recommendation/build.sbt b/examples/experimental/scala-local-friend-recommendation/build.sbt index 659f3453ed..63ff005b10 100644 --- a/examples/experimental/scala-local-friend-recommendation/build.sbt +++ b/examples/experimental/scala-local-friend-recommendation/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-local-helloworld/build.sbt b/examples/experimental/scala-local-helloworld/build.sbt index 579a8eed65..df7ba52ef1 100644 --- a/examples/experimental/scala-local-helloworld/build.sbt +++ b/examples/experimental/scala-local-helloworld/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-local-movielens-evaluation/build.sbt b/examples/experimental/scala-local-movielens-evaluation/build.sbt index 156bab7790..ea042358e3 100644 --- a/examples/experimental/scala-local-movielens-evaluation/build.sbt +++ b/examples/experimental/scala-local-movielens-evaluation/build.sbt @@ -1,3 +1,19 @@ +/* + * 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. + */ import AssemblyKeys._ diff --git a/examples/experimental/scala-local-movielens-filtering/build.sbt b/examples/experimental/scala-local-movielens-filtering/build.sbt index 04d59ad78c..699c90c180 100644 --- a/examples/experimental/scala-local-movielens-filtering/build.sbt +++ b/examples/experimental/scala-local-movielens-filtering/build.sbt @@ -1,3 +1,19 @@ +/* + * 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. + */ import AssemblyKeys._ diff --git a/examples/experimental/scala-local-regression/build.sbt b/examples/experimental/scala-local-regression/build.sbt index 67c1977a91..4db53c61ab 100644 --- a/examples/experimental/scala-local-regression/build.sbt +++ b/examples/experimental/scala-local-regression/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-parallel-friend-recommendation/build.sbt b/examples/experimental/scala-parallel-friend-recommendation/build.sbt index 63a173431c..57156cd504 100644 --- a/examples/experimental/scala-parallel-friend-recommendation/build.sbt +++ b/examples/experimental/scala-parallel-friend-recommendation/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-parallel-recommendation-cat/build.sbt b/examples/experimental/scala-parallel-recommendation-cat/build.sbt index c40295343a..3ff8d278c8 100644 --- a/examples/experimental/scala-parallel-recommendation-cat/build.sbt +++ b/examples/experimental/scala-parallel-recommendation-cat/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-parallel-recommendation-custom-datasource/build.sbt b/examples/experimental/scala-parallel-recommendation-custom-datasource/build.sbt index 5065433b6f..91e94f291a 100644 --- a/examples/experimental/scala-parallel-recommendation-custom-datasource/build.sbt +++ b/examples/experimental/scala-parallel-recommendation-custom-datasource/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-parallel-recommendation-entitymap/build.sbt b/examples/experimental/scala-parallel-recommendation-entitymap/build.sbt index 5065433b6f..91e94f291a 100644 --- a/examples/experimental/scala-parallel-recommendation-entitymap/build.sbt +++ b/examples/experimental/scala-parallel-recommendation-entitymap/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-parallel-recommendation-mongo-datasource/build.sbt b/examples/experimental/scala-parallel-recommendation-mongo-datasource/build.sbt index 5f173faffb..c2b4242870 100644 --- a/examples/experimental/scala-parallel-recommendation-mongo-datasource/build.sbt +++ b/examples/experimental/scala-parallel-recommendation-mongo-datasource/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-parallel-regression/build.sbt b/examples/experimental/scala-parallel-regression/build.sbt index 1fa54338e9..e053ba8b49 100644 --- a/examples/experimental/scala-parallel-regression/build.sbt +++ b/examples/experimental/scala-parallel-regression/build.sbt @@ -1,3 +1,19 @@ +/* + * 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. + */ import AssemblyKeys._ diff --git a/examples/experimental/scala-parallel-similarproduct-dimsum/build.sbt b/examples/experimental/scala-parallel-similarproduct-dimsum/build.sbt index 95c7280786..5ef8f87232 100644 --- a/examples/experimental/scala-parallel-similarproduct-dimsum/build.sbt +++ b/examples/experimental/scala-parallel-similarproduct-dimsum/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-parallel-similarproduct-localmodel/build.sbt b/examples/experimental/scala-parallel-similarproduct-localmodel/build.sbt index 2d8306e81a..87207e1572 100644 --- a/examples/experimental/scala-parallel-similarproduct-localmodel/build.sbt +++ b/examples/experimental/scala-parallel-similarproduct-localmodel/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-parallel-trim-app/build.sbt b/examples/experimental/scala-parallel-trim-app/build.sbt index 5ffa78fc73..fdce0d6efd 100644 --- a/examples/experimental/scala-parallel-trim-app/build.sbt +++ b/examples/experimental/scala-parallel-trim-app/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-recommendations/build.sbt b/examples/experimental/scala-recommendations/build.sbt index 4b067bf8a9..bda1930029 100644 --- a/examples/experimental/scala-recommendations/build.sbt +++ b/examples/experimental/scala-recommendations/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-refactor-test/build.sbt b/examples/experimental/scala-refactor-test/build.sbt index 8e2b24b5ab..c3935fe6bf 100644 --- a/examples/experimental/scala-refactor-test/build.sbt +++ b/examples/experimental/scala-refactor-test/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/scala-stock/build.sbt b/examples/experimental/scala-stock/build.sbt index cfc580f82e..d12157f936 100644 --- a/examples/experimental/scala-stock/build.sbt +++ b/examples/experimental/scala-stock/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings From b0a3d3c3310c1ae6c8b1f67d52f340e802f025ce Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Thu, 18 Aug 2016 16:57:46 -0700 Subject: [PATCH 02/12] Put file description before apache license --- conf/pio-env.sh.template | 5 ++--- conf/pio-env.sh.travis | 8 ++++---- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/conf/pio-env.sh.template b/conf/pio-env.sh.template index 5d2753c2d8..a06cd8efa7 100644 --- a/conf/pio-env.sh.template +++ b/conf/pio-env.sh.template @@ -1,5 +1,6 @@ #!/usr/bin/env bash - +# +# Copy this file as pio-env.sh and edit it for your site's configuration. # # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with @@ -17,8 +18,6 @@ # limitations under the License. # -# Copy this file as pio-env.sh and edit it for your site's configuration. - # PredictionIO Main Configuration # # This section controls core behavior of PredictionIO. It is very likely that diff --git a/conf/pio-env.sh.travis b/conf/pio-env.sh.travis index 7a5a2217bd..94b30cd4e5 100644 --- a/conf/pio-env.sh.travis +++ b/conf/pio-env.sh.travis @@ -1,6 +1,7 @@ #!/usr/bin/env bash - - +# +# Copy this file as pio-env.sh and edit it for your site's configuration. +# # 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. @@ -15,8 +16,7 @@ # 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. - -# Copy this file as pio-env.sh and edit it for your site's configuration. +# # PredictionIO Main Configuration # From a422c44d7ce315ce73a1d2ec3da4b0cd790e2bea Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Thu, 18 Aug 2016 17:05:40 -0700 Subject: [PATCH 03/12] Change indentation for bin/semver.sh --- bin/semver.sh | 189 ++++++++++++++++++++++++-------------------------- 1 file changed, 92 insertions(+), 97 deletions(-) diff --git a/bin/semver.sh b/bin/semver.sh index f6b0bd2e4b..2ea64a9be7 100644 --- a/bin/semver.sh +++ b/bin/semver.sh @@ -1,5 +1,4 @@ #!/usr/bin/env sh - # # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with @@ -18,130 +17,126 @@ # function semverParseInto() { - local RE='[^0-9]*\([0-9]*\)[.]\([0-9]*\)[.]\([0-9]*\)\([0-9A-Za-z-]*\)' - #MAJOR - eval $2=`echo $1 | sed -e "s#$RE#\1#"` - #MINOR - eval $3=`echo $1 | sed -e "s#$RE#\2#"` - #MINOR - eval $4=`echo $1 | sed -e "s#$RE#\3#"` - #SPECIAL - eval $5=`echo $1 | sed -e "s#$RE#\4#"` + local RE='[^0-9]*\([0-9]*\)[.]\([0-9]*\)[.]\([0-9]*\)\([0-9A-Za-z-]*\)' + #MAJOR + eval $2=`echo $1 | sed -e "s#$RE#\1#"` + #MINOR + eval $3=`echo $1 | sed -e "s#$RE#\2#"` + #MINOR + eval $4=`echo $1 | sed -e "s#$RE#\3#"` + #SPECIAL + eval $5=`echo $1 | sed -e "s#$RE#\4#"` } function semverEQ() { - local MAJOR_A=0 - local MINOR_A=0 - local PATCH_A=0 - local SPECIAL_A=0 + local MAJOR_A=0 + local MINOR_A=0 + local PATCH_A=0 + local SPECIAL_A=0 + + local MAJOR_B=0 + local MINOR_B=0 + local PATCH_B=0 + local SPECIAL_B=0 + + semverParseInto $1 MAJOR_A MINOR_A PATCH_A SPECIAL_A + semverParseInto $2 MAJOR_B MINOR_B PATCH_B SPECIAL_B - local MAJOR_B=0 - local MINOR_B=0 - local PATCH_B=0 - local SPECIAL_B=0 + if [ $MAJOR_A -ne $MAJOR_B ]; then + return 1 + fi + + if [ $MINOR_A -ne $MINOR_B ]; then + return 1 + fi - semverParseInto $1 MAJOR_A MINOR_A PATCH_A SPECIAL_A - semverParseInto $2 MAJOR_B MINOR_B PATCH_B SPECIAL_B + if [ $PATCH_A -ne $PATCH_B ]; then + return 1 + fi - if [ $MAJOR_A -ne $MAJOR_B ]; then - return 1 - fi + if [[ "_$SPECIAL_A" != "_$SPECIAL_B" ]]; then + return 1 + fi - if [ $MINOR_A -ne $MINOR_B ]; then - return 1 - fi + return 0 +} - if [ $PATCH_A -ne $PATCH_B ]; then - return 1 - fi +function semverLT() { + local MAJOR_A=0 + local MINOR_A=0 + local PATCH_A=0 + local SPECIAL_A=0 - if [[ "_$SPECIAL_A" != "_$SPECIAL_B" ]]; then - return 1 - fi + local MAJOR_B=0 + local MINOR_B=0 + local PATCH_B=0 + local SPECIAL_B=0 + semverParseInto $1 MAJOR_A MINOR_A PATCH_A SPECIAL_A + semverParseInto $2 MAJOR_B MINOR_B PATCH_B SPECIAL_B + if [ $MAJOR_A -lt $MAJOR_B ]; then return 0 + fi -} + if [[ $MAJOR_A -le $MAJOR_B && $MINOR_A -lt $MINOR_B ]]; then + return 0 + fi -function semverLT() { - local MAJOR_A=0 - local MINOR_A=0 - local PATCH_A=0 - local SPECIAL_A=0 - - local MAJOR_B=0 - local MINOR_B=0 - local PATCH_B=0 - local SPECIAL_B=0 - - semverParseInto $1 MAJOR_A MINOR_A PATCH_A SPECIAL_A - semverParseInto $2 MAJOR_B MINOR_B PATCH_B SPECIAL_B - - if [ $MAJOR_A -lt $MAJOR_B ]; then - return 0 - fi - - if [[ $MAJOR_A -le $MAJOR_B && $MINOR_A -lt $MINOR_B ]]; then - return 0 - fi - - if [[ $MAJOR_A -le $MAJOR_B && $MINOR_A -le $MINOR_B && $PATCH_A -lt $PATCH_B ]]; then - return 0 - fi - - if [[ "_$SPECIAL_A" == "_" ]] && [[ "_$SPECIAL_B" == "_" ]] ; then - return 1 - fi - if [[ "_$SPECIAL_A" == "_" ]] && [[ "_$SPECIAL_B" != "_" ]] ; then - return 1 - fi - if [[ "_$SPECIAL_A" != "_" ]] && [[ "_$SPECIAL_B" == "_" ]] ; then - return 0 - fi - - if [[ "_$SPECIAL_A" < "_$SPECIAL_B" ]]; then - return 0 - fi + if [[ $MAJOR_A -le $MAJOR_B && $MINOR_A -le $MINOR_B && $PATCH_A -lt $PATCH_B ]]; then + return 0 + fi + if [[ "_$SPECIAL_A" == "_" ]] && [[ "_$SPECIAL_B" == "_" ]] ; then + return 1 + fi + if [[ "_$SPECIAL_A" == "_" ]] && [[ "_$SPECIAL_B" != "_" ]] ; then return 1 + fi + if [[ "_$SPECIAL_A" != "_" ]] && [[ "_$SPECIAL_B" == "_" ]] ; then + return 0 + fi + + if [[ "_$SPECIAL_A" < "_$SPECIAL_B" ]]; then + return 0 + fi + + return 1 } function semverGT() { - semverEQ $1 $2 - local EQ=$? + semverEQ $1 $2 + local EQ=$? - semverLT $1 $2 - local LT=$? + semverLT $1 $2 + local LT=$? - if [ $EQ -ne 0 ] && [ $LT -ne 0 ]; then - return 0 - else - return 1 - fi + if [ $EQ -ne 0 ] && [ $LT -ne 0 ]; then + return 0 + else + return 1 + fi } if [ "___semver.sh" == "___`basename $0`" ]; then + MAJOR=0 + MINOR=0 + PATCH=0 + SPECIAL="" -MAJOR=0 -MINOR=0 -PATCH=0 -SPECIAL="" - -semverParseInto $1 MAJOR MINOR PATCH SPECIAL -echo "$1 -> M: $MAJOR m:$MINOR p:$PATCH s:$SPECIAL" - -semverParseInto $2 MAJOR MINOR PATCH SPECIAL -echo "$2 -> M: $MAJOR m:$MINOR p:$PATCH s:$SPECIAL" + semverParseInto $1 MAJOR MINOR PATCH SPECIAL + echo "$1 -> M: $MAJOR m:$MINOR p:$PATCH s:$SPECIAL" -semverEQ $1 $2 -echo "$1 == $2 -> $?." + semverParseInto $2 MAJOR MINOR PATCH SPECIAL + echo "$2 -> M: $MAJOR m:$MINOR p:$PATCH s:$SPECIAL" -semverLT $1 $2 -echo "$1 < $2 -> $?." + semverEQ $1 $2 + echo "$1 == $2 -> $?." -semverGT $1 $2 -echo "$1 > $2 -> $?." + semverLT $1 $2 + echo "$1 < $2 -> $?." + semverGT $1 $2 + echo "$1 > $2 -> $?." fi From 611a3eff5b8ab65644c3d1ee6fdaddbbaf7ef8a5 Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Thu, 18 Aug 2016 17:11:15 -0700 Subject: [PATCH 04/12] Add apache license for travis files --- .travis.yml | 16 ++++++++++++++++ tests/after_script.travis.sh | 18 +++++++++++++++++- tests/before_script.travis.sh | 19 +++++++++++++++++-- tests/run_docker.sh | 18 +++++++++++++++++- tests/script.travis.sh | 18 +++++++++++++++++- 5 files changed, 84 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 411733f23f..e03468fae9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,6 +6,22 @@ # please add the following to your local git config: # git config merge.ours.driver true ########## +# +# 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. +# branches: only: diff --git a/tests/after_script.travis.sh b/tests/after_script.travis.sh index fdc635f814..69e28e0e0c 100755 --- a/tests/after_script.travis.sh +++ b/tests/after_script.travis.sh @@ -1,4 +1,20 @@ -#!/bin/bash - +#!/bin/bash +# +# 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. +# set -e diff --git a/tests/before_script.travis.sh b/tests/before_script.travis.sh index d7f9cef1a1..9bfecdc97a 100755 --- a/tests/before_script.travis.sh +++ b/tests/before_script.travis.sh @@ -1,9 +1,24 @@ -#!/bin/bash - +#!/bin/bash +# +# 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. +# set -e if [[ $BUILD_TYPE == Unit ]]; then - # Download spark, hbase mkdir vendors wget http://d3kbcqa49mib13.cloudfront.net/spark-1.3.0-bin-hadoop2.4.tgz diff --git a/tests/run_docker.sh b/tests/run_docker.sh index d5925efb16..ed4001ee29 100755 --- a/tests/run_docker.sh +++ b/tests/run_docker.sh @@ -1,4 +1,20 @@ -#!/bin/bash - +#!/bin/bash +# +# 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. +# USAGE=$"Usage: run_docer Where: diff --git a/tests/script.travis.sh b/tests/script.travis.sh index 859607806d..9beb60d3c1 100755 --- a/tests/script.travis.sh +++ b/tests/script.travis.sh @@ -1,4 +1,20 @@ -#!/bin/bash - +#!/bin/bash +# +# 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. +# set -e From 7a2d97a49c41972a3d3efdf95b50ee4ff09e0dd7 Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Thu, 18 Aug 2016 17:34:15 -0700 Subject: [PATCH 05/12] Add apache license to some html files --- .../controller/metric_evaluator.scala.html | 19 +++++++++++++++++++ .../predictionio/workflow/index.scala.html | 19 +++++++++++++++++++ .../examples/stock/backtesting.scala.html | 19 +++++++++++++++++++ .../tools/dashboard/index.scala.html | 17 +++++++++++++++++ 4 files changed, 74 insertions(+) diff --git a/core/src/main/twirl/org/apache/predictionio/controller/metric_evaluator.scala.html b/core/src/main/twirl/org/apache/predictionio/controller/metric_evaluator.scala.html index 2e679a57c8..a8c2426d28 100644 --- a/core/src/main/twirl/org/apache/predictionio/controller/metric_evaluator.scala.html +++ b/core/src/main/twirl/org/apache/predictionio/controller/metric_evaluator.scala.html @@ -1,3 +1,22 @@ + diff --git a/core/src/main/twirl/org/apache/predictionio/workflow/index.scala.html b/core/src/main/twirl/org/apache/predictionio/workflow/index.scala.html index 5a3894fd79..9aa6ad0027 100644 --- a/core/src/main/twirl/org/apache/predictionio/workflow/index.scala.html +++ b/core/src/main/twirl/org/apache/predictionio/workflow/index.scala.html @@ -1,3 +1,22 @@ + @import org.apache.predictionio.data.storage.EngineInstance @import org.apache.predictionio.data.storage.EngineManifest @import org.apache.predictionio.workflow.ServerConfig diff --git a/examples/experimental/scala-stock/src/main/twirl/io/prediction/examples/stock/backtesting.scala.html b/examples/experimental/scala-stock/src/main/twirl/io/prediction/examples/stock/backtesting.scala.html index 80c796a25e..354eda94d6 100644 --- a/examples/experimental/scala-stock/src/main/twirl/io/prediction/examples/stock/backtesting.scala.html +++ b/examples/experimental/scala-stock/src/main/twirl/io/prediction/examples/stock/backtesting.scala.html @@ -1,3 +1,22 @@ + @import org.apache.predictionio.examples.stock.BacktestingResult diff --git a/tools/src/main/twirl/org/apache/predictionio/tools/dashboard/index.scala.html b/tools/src/main/twirl/org/apache/predictionio/tools/dashboard/index.scala.html index 2e1719cacf..ff235d9fb7 100644 --- a/tools/src/main/twirl/org/apache/predictionio/tools/dashboard/index.scala.html +++ b/tools/src/main/twirl/org/apache/predictionio/tools/dashboard/index.scala.html @@ -1,3 +1,20 @@ + + @import org.apache.predictionio.data.storage.EvaluationInstance @import org.apache.predictionio.tools.dashboard.DashboardConfig @import org.joda.time.DateTime From 473df0afa775eea8642707365fc3b5a32d3f5b16 Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Thu, 18 Aug 2016 17:39:20 -0700 Subject: [PATCH 06/12] Add apache license for integration test files --- tests/Dockerfile | 17 +++++++++++++++++ tests/docker-files/env-conf/hbase-site.xml | 16 ++++++++++++++++ tests/docker-files/env-conf/pio-env.sh | 18 +++++++++++++++++- tests/docker-files/init.sh | 18 +++++++++++++++++- tests/pio_tests/globals.py | 17 +++++++++++++++++ tests/pio_tests/integration.py | 17 +++++++++++++++++ .../pio_tests/scenarios/basic_app_usecases.py | 17 +++++++++++++++++ tests/pio_tests/scenarios/eventserver_test.py | 17 +++++++++++++++++ tests/pio_tests/scenarios/quickstart_test.py | 17 +++++++++++++++++ tests/pio_tests/tests.py | 17 +++++++++++++++++ tests/pio_tests/utils.py | 17 +++++++++++++++++ 11 files changed, 186 insertions(+), 2 deletions(-) diff --git a/tests/Dockerfile b/tests/Dockerfile index fc3d89d6c6..a455d5d000 100644 --- a/tests/Dockerfile +++ b/tests/Dockerfile @@ -1,3 +1,20 @@ +# +# 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. +# + from ubuntu ENV SPARK_VERSION 1.4.0 diff --git a/tests/docker-files/env-conf/hbase-site.xml b/tests/docker-files/env-conf/hbase-site.xml index af3ab4fc65..1b7b507f08 100644 --- a/tests/docker-files/env-conf/hbase-site.xml +++ b/tests/docker-files/env-conf/hbase-site.xml @@ -1,3 +1,19 @@ + diff --git a/tests/docker-files/env-conf/pio-env.sh b/tests/docker-files/env-conf/pio-env.sh index 8391e97ec1..4ffec46931 100644 --- a/tests/docker-files/env-conf/pio-env.sh +++ b/tests/docker-files/env-conf/pio-env.sh @@ -1,6 +1,22 @@ #!/usr/bin/env bash - +# # Copy this file as pio-env.sh and edit it for your site's configuration. +# +# 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. +# # PredictionIO Main Configuration # diff --git a/tests/docker-files/init.sh b/tests/docker-files/init.sh index de50f3f0bd..cba9977e6d 100755 --- a/tests/docker-files/init.sh +++ b/tests/docker-files/init.sh @@ -1,4 +1,20 @@ -#!/bin/bash - +#!/bin/bash +# +# 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. +# set -e diff --git a/tests/pio_tests/globals.py b/tests/pio_tests/globals.py index 1134501aad..2da3c397e9 100644 --- a/tests/pio_tests/globals.py +++ b/tests/pio_tests/globals.py @@ -1,3 +1,20 @@ +# +# 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. +# + import subprocess SUPPRESS_STDOUT=False diff --git a/tests/pio_tests/integration.py b/tests/pio_tests/integration.py index 441365e96c..9f2e7e5b12 100644 --- a/tests/pio_tests/integration.py +++ b/tests/pio_tests/integration.py @@ -1,3 +1,20 @@ +# +# 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. +# + import unittest import logging import pio_tests.globals as globals diff --git a/tests/pio_tests/scenarios/basic_app_usecases.py b/tests/pio_tests/scenarios/basic_app_usecases.py index d8b3a1edff..37e84b9a3e 100644 --- a/tests/pio_tests/scenarios/basic_app_usecases.py +++ b/tests/pio_tests/scenarios/basic_app_usecases.py @@ -1,3 +1,20 @@ +# +# 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. +# + import os import unittest import random diff --git a/tests/pio_tests/scenarios/eventserver_test.py b/tests/pio_tests/scenarios/eventserver_test.py index 8c243d2e3a..c09e8158cc 100644 --- a/tests/pio_tests/scenarios/eventserver_test.py +++ b/tests/pio_tests/scenarios/eventserver_test.py @@ -1,3 +1,20 @@ +# +# 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. +# + import unittest import requests import json diff --git a/tests/pio_tests/scenarios/quickstart_test.py b/tests/pio_tests/scenarios/quickstart_test.py index a083c2b982..04d80d31d1 100644 --- a/tests/pio_tests/scenarios/quickstart_test.py +++ b/tests/pio_tests/scenarios/quickstart_test.py @@ -1,3 +1,20 @@ +# +# 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. +# + import os import unittest import random diff --git a/tests/pio_tests/tests.py b/tests/pio_tests/tests.py index 33d9940e20..77ecb1173a 100755 --- a/tests/pio_tests/tests.py +++ b/tests/pio_tests/tests.py @@ -1,3 +1,20 @@ +# +# 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. +# + import os import sys import unittest diff --git a/tests/pio_tests/utils.py b/tests/pio_tests/utils.py index 629729ecec..e61f28ec2d 100644 --- a/tests/pio_tests/utils.py +++ b/tests/pio_tests/utils.py @@ -1,3 +1,20 @@ +# +# 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. +# + import re import time import os From 0d18dda1025299e4ef8b30dfa8068863c35fdf07 Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Thu, 18 Aug 2016 17:41:16 -0700 Subject: [PATCH 07/12] Add apache license for empty __init__.py files --- tests/pio_tests/__init__.py | 16 ++++++++++++++++ tests/pio_tests/scenarios/__init__.py | 16 ++++++++++++++++ 2 files changed, 32 insertions(+) diff --git a/tests/pio_tests/__init__.py b/tests/pio_tests/__init__.py index e69de29bb2..ecb1860df8 100644 --- a/tests/pio_tests/__init__.py +++ b/tests/pio_tests/__init__.py @@ -0,0 +1,16 @@ +# +# 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. +# \ No newline at end of file diff --git a/tests/pio_tests/scenarios/__init__.py b/tests/pio_tests/scenarios/__init__.py index e69de29bb2..ecb1860df8 100644 --- a/tests/pio_tests/scenarios/__init__.py +++ b/tests/pio_tests/scenarios/__init__.py @@ -0,0 +1,16 @@ +# +# 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. +# \ No newline at end of file From d3cb62f73393ce7ca0bc4317e2b80d4411dcb052 Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Fri, 19 Aug 2016 10:07:50 -0700 Subject: [PATCH 08/12] Add apache license to more build.sbt files in examples/ --- .../java-parallel-helloworld/build.sbt | 17 +++++++++++++++++ .../src/main/java/parallel/build.sbt | 17 +++++++++++++++++ .../add-algorithm/build.sbt | 17 +++++++++++++++++ .../custom-attributes/build.sbt | 17 +++++++++++++++++ .../train-with-rate-event/build.sbt | 17 +++++++++++++++++ .../weighted-items/build.sbt | 17 +++++++++++++++++ .../custom-prepartor/build.sbt | 17 +++++++++++++++++ .../custom-query/build.sbt | 17 +++++++++++++++++ .../custom-serving/build.sbt | 17 +++++++++++++++++ .../filter-by-category/build.sbt | 17 +++++++++++++++++ .../add-and-return-item-properties/build.sbt | 17 +++++++++++++++++ .../add-rateevent/build.sbt | 17 +++++++++++++++++ .../filterbyyear/build.sbt | 17 +++++++++++++++++ .../multi/build.sbt | 17 +++++++++++++++++ .../no-set-user/build.sbt | 17 +++++++++++++++++ .../recommended-user/build.sbt | 17 +++++++++++++++++ 16 files changed, 272 insertions(+) diff --git a/examples/experimental/java-parallel-helloworld/build.sbt b/examples/experimental/java-parallel-helloworld/build.sbt index 46c130607d..ea89b68f95 100644 --- a/examples/experimental/java-parallel-helloworld/build.sbt +++ b/examples/experimental/java-parallel-helloworld/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/experimental/java-parallel-helloworld/src/main/java/parallel/build.sbt b/examples/experimental/java-parallel-helloworld/src/main/java/parallel/build.sbt index 1b3ac2d2a2..56dd2bab06 100644 --- a/examples/experimental/java-parallel-helloworld/src/main/java/parallel/build.sbt +++ b/examples/experimental/java-parallel-helloworld/src/main/java/parallel/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-classification/add-algorithm/build.sbt b/examples/scala-parallel-classification/add-algorithm/build.sbt index 30d0ccc847..98bf136f2c 100644 --- a/examples/scala-parallel-classification/add-algorithm/build.sbt +++ b/examples/scala-parallel-classification/add-algorithm/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-classification/custom-attributes/build.sbt b/examples/scala-parallel-classification/custom-attributes/build.sbt index fc16e53dad..0f219d14de 100644 --- a/examples/scala-parallel-classification/custom-attributes/build.sbt +++ b/examples/scala-parallel-classification/custom-attributes/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-ecommercerecommendation/train-with-rate-event/build.sbt b/examples/scala-parallel-ecommercerecommendation/train-with-rate-event/build.sbt index 650c7c300e..956f79bb87 100644 --- a/examples/scala-parallel-ecommercerecommendation/train-with-rate-event/build.sbt +++ b/examples/scala-parallel-ecommercerecommendation/train-with-rate-event/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-ecommercerecommendation/weighted-items/build.sbt b/examples/scala-parallel-ecommercerecommendation/weighted-items/build.sbt index 650c7c300e..956f79bb87 100644 --- a/examples/scala-parallel-ecommercerecommendation/weighted-items/build.sbt +++ b/examples/scala-parallel-ecommercerecommendation/weighted-items/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-recommendation/custom-prepartor/build.sbt b/examples/scala-parallel-recommendation/custom-prepartor/build.sbt index 191f575fbf..4b90f0370f 100644 --- a/examples/scala-parallel-recommendation/custom-prepartor/build.sbt +++ b/examples/scala-parallel-recommendation/custom-prepartor/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-recommendation/custom-query/build.sbt b/examples/scala-parallel-recommendation/custom-query/build.sbt index 0177e298f1..1a18607fa8 100644 --- a/examples/scala-parallel-recommendation/custom-query/build.sbt +++ b/examples/scala-parallel-recommendation/custom-query/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-recommendation/custom-serving/build.sbt b/examples/scala-parallel-recommendation/custom-serving/build.sbt index de3bac199f..81cd3ec672 100644 --- a/examples/scala-parallel-recommendation/custom-serving/build.sbt +++ b/examples/scala-parallel-recommendation/custom-serving/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-recommendation/filter-by-category/build.sbt b/examples/scala-parallel-recommendation/filter-by-category/build.sbt index de3bac199f..81cd3ec672 100644 --- a/examples/scala-parallel-recommendation/filter-by-category/build.sbt +++ b/examples/scala-parallel-recommendation/filter-by-category/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-similarproduct/add-and-return-item-properties/build.sbt b/examples/scala-parallel-similarproduct/add-and-return-item-properties/build.sbt index 62b1b9bb87..ef66b2fc0d 100644 --- a/examples/scala-parallel-similarproduct/add-and-return-item-properties/build.sbt +++ b/examples/scala-parallel-similarproduct/add-and-return-item-properties/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-similarproduct/add-rateevent/build.sbt b/examples/scala-parallel-similarproduct/add-rateevent/build.sbt index 62b1b9bb87..ef66b2fc0d 100644 --- a/examples/scala-parallel-similarproduct/add-rateevent/build.sbt +++ b/examples/scala-parallel-similarproduct/add-rateevent/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-similarproduct/filterbyyear/build.sbt b/examples/scala-parallel-similarproduct/filterbyyear/build.sbt index 292fa97ea9..1680f6b5d9 100644 --- a/examples/scala-parallel-similarproduct/filterbyyear/build.sbt +++ b/examples/scala-parallel-similarproduct/filterbyyear/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-similarproduct/multi/build.sbt b/examples/scala-parallel-similarproduct/multi/build.sbt index ea02365ed0..da8b97aac4 100644 --- a/examples/scala-parallel-similarproduct/multi/build.sbt +++ b/examples/scala-parallel-similarproduct/multi/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-similarproduct/no-set-user/build.sbt b/examples/scala-parallel-similarproduct/no-set-user/build.sbt index 62b1b9bb87..ef66b2fc0d 100644 --- a/examples/scala-parallel-similarproduct/no-set-user/build.sbt +++ b/examples/scala-parallel-similarproduct/no-set-user/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/examples/scala-parallel-similarproduct/recommended-user/build.sbt b/examples/scala-parallel-similarproduct/recommended-user/build.sbt index 9d6dfe4343..ef4f5a8d28 100644 --- a/examples/scala-parallel-similarproduct/recommended-user/build.sbt +++ b/examples/scala-parallel-similarproduct/recommended-user/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + assemblySettings name := "template-scala-parallel-recommendeduser" From 1ab32d1cc9174cafc1ea8c7c0ca21221255b452d Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Fri, 19 Aug 2016 10:10:19 -0700 Subject: [PATCH 09/12] Add apache license to engine source files used for integration testing --- .../engines/recommendation-engine/build.sbt | 17 +++++++++++++++++ .../src/main/scala/ALSAlgorithm.scala | 17 +++++++++++++++++ .../src/main/scala/ALSModel.scala | 17 +++++++++++++++++ .../src/main/scala/DataSource.scala | 17 +++++++++++++++++ .../src/main/scala/Engine.scala | 17 +++++++++++++++++ .../src/main/scala/Evaluation.scala | 17 +++++++++++++++++ .../src/main/scala/Preparator.scala | 17 +++++++++++++++++ .../src/main/scala/Serving.scala | 17 +++++++++++++++++ 8 files changed, 136 insertions(+) diff --git a/tests/pio_tests/engines/recommendation-engine/build.sbt b/tests/pio_tests/engines/recommendation-engine/build.sbt index c7413bb722..b75c16b3a2 100644 --- a/tests/pio_tests/engines/recommendation-engine/build.sbt +++ b/tests/pio_tests/engines/recommendation-engine/build.sbt @@ -1,3 +1,20 @@ +/* + * 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. + */ + import AssemblyKeys._ assemblySettings diff --git a/tests/pio_tests/engines/recommendation-engine/src/main/scala/ALSAlgorithm.scala b/tests/pio_tests/engines/recommendation-engine/src/main/scala/ALSAlgorithm.scala index 17c2806ac2..f22d2f7acc 100644 --- a/tests/pio_tests/engines/recommendation-engine/src/main/scala/ALSAlgorithm.scala +++ b/tests/pio_tests/engines/recommendation-engine/src/main/scala/ALSAlgorithm.scala @@ -1,3 +1,20 @@ +/* + * 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.template.recommendation import org.apache.predictionio.controller.PAlgorithm diff --git a/tests/pio_tests/engines/recommendation-engine/src/main/scala/ALSModel.scala b/tests/pio_tests/engines/recommendation-engine/src/main/scala/ALSModel.scala index 243c1d1620..4697732d28 100644 --- a/tests/pio_tests/engines/recommendation-engine/src/main/scala/ALSModel.scala +++ b/tests/pio_tests/engines/recommendation-engine/src/main/scala/ALSModel.scala @@ -1,3 +1,20 @@ +/* + * 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.spark.mllib.recommendation // This must be the same package as Spark's MatrixFactorizationModel because // MatrixFactorizationModel's constructor is private and we are using diff --git a/tests/pio_tests/engines/recommendation-engine/src/main/scala/DataSource.scala b/tests/pio_tests/engines/recommendation-engine/src/main/scala/DataSource.scala index eea3ae6c67..12904a29a0 100644 --- a/tests/pio_tests/engines/recommendation-engine/src/main/scala/DataSource.scala +++ b/tests/pio_tests/engines/recommendation-engine/src/main/scala/DataSource.scala @@ -1,3 +1,20 @@ +/* + * 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.template.recommendation import org.apache.predictionio.controller.PDataSource diff --git a/tests/pio_tests/engines/recommendation-engine/src/main/scala/Engine.scala b/tests/pio_tests/engines/recommendation-engine/src/main/scala/Engine.scala index 79840dc531..b680ca8b2a 100644 --- a/tests/pio_tests/engines/recommendation-engine/src/main/scala/Engine.scala +++ b/tests/pio_tests/engines/recommendation-engine/src/main/scala/Engine.scala @@ -1,3 +1,20 @@ +/* + * 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.template.recommendation import org.apache.predictionio.controller.IEngineFactory diff --git a/tests/pio_tests/engines/recommendation-engine/src/main/scala/Evaluation.scala b/tests/pio_tests/engines/recommendation-engine/src/main/scala/Evaluation.scala index 34e5689b0b..2254b96089 100644 --- a/tests/pio_tests/engines/recommendation-engine/src/main/scala/Evaluation.scala +++ b/tests/pio_tests/engines/recommendation-engine/src/main/scala/Evaluation.scala @@ -1,3 +1,20 @@ +/* + * 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.template.recommendation import org.apache.predictionio.controller.Evaluation diff --git a/tests/pio_tests/engines/recommendation-engine/src/main/scala/Preparator.scala b/tests/pio_tests/engines/recommendation-engine/src/main/scala/Preparator.scala index 8f2f7e4b9d..0bab35b658 100644 --- a/tests/pio_tests/engines/recommendation-engine/src/main/scala/Preparator.scala +++ b/tests/pio_tests/engines/recommendation-engine/src/main/scala/Preparator.scala @@ -1,3 +1,20 @@ +/* + * 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.template.recommendation import org.apache.predictionio.controller.PPreparator diff --git a/tests/pio_tests/engines/recommendation-engine/src/main/scala/Serving.scala b/tests/pio_tests/engines/recommendation-engine/src/main/scala/Serving.scala index 38ba8b9ea4..02eb0ecab6 100644 --- a/tests/pio_tests/engines/recommendation-engine/src/main/scala/Serving.scala +++ b/tests/pio_tests/engines/recommendation-engine/src/main/scala/Serving.scala @@ -1,3 +1,20 @@ +/* + * 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.template.recommendation import org.apache.predictionio.controller.LServing From 0beb4be3f32021902c0904b69207a2f9e6dcce4b Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Fri, 19 Aug 2016 10:47:53 -0700 Subject: [PATCH 10/12] Add apache license to source files in docs/ --- docs/javadoc/javadoc-overview.html | 19 +++++++++++++++++++ docs/manual/Gemfile | 17 +++++++++++++++++ docs/manual/Rakefile | 17 +++++++++++++++++ docs/manual/config.rb | 17 +++++++++++++++++ docs/manual/helpers/application_helpers.rb | 17 +++++++++++++++++ docs/manual/helpers/breadcrumb_helpers.rb | 17 +++++++++++++++++ docs/manual/helpers/icon_helpers.rb | 17 +++++++++++++++++ .../helpers/table_of_contents_helpers.rb | 17 +++++++++++++++++ docs/manual/helpers/url_helpers.rb | 17 +++++++++++++++++ docs/manual/lib/custom_renderer.rb | 17 +++++++++++++++++ docs/manual/lib/gallery_generator.rb | 17 +++++++++++++++++ docs/manual/source/github.html | 19 +++++++++++++++++++ 12 files changed, 208 insertions(+) diff --git a/docs/javadoc/javadoc-overview.html b/docs/javadoc/javadoc-overview.html index 8561f1e95b..97474c2937 100644 --- a/docs/javadoc/javadoc-overview.html +++ b/docs/javadoc/javadoc-overview.html @@ -1,3 +1,22 @@ +

PredictionIO API Documentation diff --git a/docs/manual/Gemfile b/docs/manual/Gemfile index f4df6bce8a..10a6ccfac6 100644 --- a/docs/manual/Gemfile +++ b/docs/manual/Gemfile @@ -1,3 +1,20 @@ +# +# 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. +# + source 'https://rubygems.org' gem 'middleman', '~> 3.3.10' diff --git a/docs/manual/Rakefile b/docs/manual/Rakefile index dc1a1833ee..6ac1473340 100644 --- a/docs/manual/Rakefile +++ b/docs/manual/Rakefile @@ -1,3 +1,20 @@ +# +# 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. +# + require 'middleman' require 'nokogiri' require 'rainbow/ext/string' diff --git a/docs/manual/config.rb b/docs/manual/config.rb index 68982dca0e..14cf91a828 100644 --- a/docs/manual/config.rb +++ b/docs/manual/config.rb @@ -1,3 +1,20 @@ +# +# 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. +# + require 'lib/custom_renderer' require 'lib/gallery_generator' diff --git a/docs/manual/helpers/application_helpers.rb b/docs/manual/helpers/application_helpers.rb index a20ea54ef9..c6065366a5 100644 --- a/docs/manual/helpers/application_helpers.rb +++ b/docs/manual/helpers/application_helpers.rb @@ -1,3 +1,20 @@ +# +# 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. +# + module ApplicationHelpers def page_title if current_page.data.title diff --git a/docs/manual/helpers/breadcrumb_helpers.rb b/docs/manual/helpers/breadcrumb_helpers.rb index f69ee15167..3dfbd4a39a 100644 --- a/docs/manual/helpers/breadcrumb_helpers.rb +++ b/docs/manual/helpers/breadcrumb_helpers.rb @@ -1,3 +1,20 @@ +# +# 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. +# + require 'rainbow/ext/string' module BreadcrumbHelpers diff --git a/docs/manual/helpers/icon_helpers.rb b/docs/manual/helpers/icon_helpers.rb index 3d4c63f0de..1597b2fca4 100644 --- a/docs/manual/helpers/icon_helpers.rb +++ b/docs/manual/helpers/icon_helpers.rb @@ -1,3 +1,20 @@ +# +# 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. +# + module IconHelpers def icon(name) if name.nil? diff --git a/docs/manual/helpers/table_of_contents_helpers.rb b/docs/manual/helpers/table_of_contents_helpers.rb index 0819b35acd..bfd4528995 100644 --- a/docs/manual/helpers/table_of_contents_helpers.rb +++ b/docs/manual/helpers/table_of_contents_helpers.rb @@ -1,3 +1,20 @@ +# +# 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. +# + module TableOfContentsHelpers def table_of_contents(resource) content = remove_front_matter_data(File.read(resource.source_file)) diff --git a/docs/manual/helpers/url_helpers.rb b/docs/manual/helpers/url_helpers.rb index f6f63a4f86..0577e7baa2 100644 --- a/docs/manual/helpers/url_helpers.rb +++ b/docs/manual/helpers/url_helpers.rb @@ -1,3 +1,20 @@ +# +# 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. +# + module UrlHelpers def absolute_url(path) URI::Generic.build( diff --git a/docs/manual/lib/custom_renderer.rb b/docs/manual/lib/custom_renderer.rb index 9a9649e05e..a525eea395 100644 --- a/docs/manual/lib/custom_renderer.rb +++ b/docs/manual/lib/custom_renderer.rb @@ -1,3 +1,20 @@ +# +# 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. +# + require 'middleman-core/renderers/redcarpet' class CustomRenderer < Middleman::Renderers::MiddlemanRedcarpetHTML diff --git a/docs/manual/lib/gallery_generator.rb b/docs/manual/lib/gallery_generator.rb index f230c14e2c..351a38136b 100644 --- a/docs/manual/lib/gallery_generator.rb +++ b/docs/manual/lib/gallery_generator.rb @@ -1,3 +1,20 @@ +# +# 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. +# + require 'yaml' require 'uri' diff --git a/docs/manual/source/github.html b/docs/manual/source/github.html index 8edac29e75..c64f6c54c3 100644 --- a/docs/manual/source/github.html +++ b/docs/manual/source/github.html @@ -1,3 +1,22 @@ + --- layout: raw --- From 4a86904dae8abf2c0b2e75f96cbdb33801f3bf4e Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Fri, 19 Aug 2016 13:34:34 -0700 Subject: [PATCH 11/12] Configure RAT Apache license checker to run on travis --- tests/.rat-excludes | 47 ++++++++++++++++++++++++++++++++++ tests/check_license.sh | 58 ++++++++++++++++++++++++++++++++++++++++++ tests/script.travis.sh | 3 +++ 3 files changed, 108 insertions(+) create mode 100644 tests/.rat-excludes create mode 100755 tests/check_license.sh diff --git a/tests/.rat-excludes b/tests/.rat-excludes new file mode 100644 index 0000000000..f21d11237d --- /dev/null +++ b/tests/.rat-excludes @@ -0,0 +1,47 @@ +RELEASE +KEYS +spark-env.sh +.gitignore +.gitattributes +.rat-excludes +.project +sbt-launch-lib.bash +plugins.sbt +build.properties +eventserver.pid +application.conf +assembly.sbt +pio-build.sbt +pio.sbt +unidoc.sbt +spark-defaults.conf +Gemfile.lock +templates.yaml + +PredictionIO-.*/* +bower_components/* +target/* +source/* +test-reports/* +dist/* +vendors/* +.logs/* +sbt/* + +.*md +.*md.erb +.*slim +.*eps +.*txt +.*svg +.*jks +.*json +.*log +.*template +.*js +.*css +.*map +.*data +.*csv +.*Driver +.*rst diff --git a/tests/check_license.sh b/tests/check_license.sh new file mode 100755 index 0000000000..719657f522 --- /dev/null +++ b/tests/check_license.sh @@ -0,0 +1,58 @@ +#!/usr/bin/env bash +# +# 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. +# + +# Go to PredictionIO directory +FWDIR="$(cd "`dirname "$0"`"/..; pwd)" +mkdir -p ${FWDIR}/lib +cd ${FWDIR}/lib + +# Download RAT jar in lib/ +RAT_VERSION=0.11 +RAT_JAR="${FWDIR}/lib/apache-rat-${RAT_VERSION}.jar" +URL="http://repo1.maven.org/maven2/org/apache/rat/apache-rat/${RAT_VERSION}/apache-rat-${RAT_VERSION}.jar" +if [ ! -f "$RAT_JAR" ]; then + if [ $(command -v curl) ]; then + curl -OL --silent "${URL}" + elif [ $(command -v wget) ]; then + wget --quiet ${URL} + fi +fi +if [ ! -f "$RAT_JAR" ]; then + echo "${RAT_JAR} download failed. Please install rat manually.\n" + exit 1 +fi + +# Run RAT testing +TEST_DIR="${FWDIR}/tests" +REPORT_DIR="${FWDIR}/test-reports" +mkdir ${REPORT_DIR} +java -jar ${RAT_JAR} -E ${TEST_DIR}/.rat-excludes -d ${FWDIR} > ${REPORT_DIR}/rat-results.txt +if [ $? -ne 0 ]; then + echo "RAT exited abnormally" + exit 1 +fi + +# Print results +ERRORS="$(cat ${REPORT_DIR}/rat-results.txt | grep -e "??")" +if test ! -z "$ERRORS"; then + echo "Could not find Apache license headers in the following files:" + echo "$ERRORS" + exit 1 +else + echo -e "RAT checks passed." +fi diff --git a/tests/script.travis.sh b/tests/script.travis.sh index 9beb60d3c1..4adb135385 100755 --- a/tests/script.travis.sh +++ b/tests/script.travis.sh @@ -19,6 +19,9 @@ set -e if [[ $BUILD_TYPE == Unit ]]; then + # Run license check + ./tests/check_license.sh + # Prepare pio environment variables set -a source conf/pio-env.sh.travis From 53c408007dfb93ba4526feec1d71c0e6579674ec Mon Sep 17 00:00:00 2001 From: Chan Lee Date: Fri, 19 Aug 2016 15:25:31 -0700 Subject: [PATCH 12/12] Fix license header location for html files All comments should come after @import and declaration --- .../controller/metric_evaluator.scala.html | 31 ++++++++-------- .../predictionio/workflow/index.scala.html | 35 +++++++++---------- docs/javadoc/javadoc-overview.html | 31 ++++++++-------- docs/manual/source/github.html | 31 ++++++++-------- .../examples/stock/backtesting.scala.html | 33 ++++++++--------- .../tools/dashboard/index.scala.html | 33 +++++++++-------- 6 files changed, 89 insertions(+), 105 deletions(-) diff --git a/core/src/main/twirl/org/apache/predictionio/controller/metric_evaluator.scala.html b/core/src/main/twirl/org/apache/predictionio/controller/metric_evaluator.scala.html index a8c2426d28..145fbdd27a 100644 --- a/core/src/main/twirl/org/apache/predictionio/controller/metric_evaluator.scala.html +++ b/core/src/main/twirl/org/apache/predictionio/controller/metric_evaluator.scala.html @@ -1,21 +1,18 @@ diff --git a/core/src/main/twirl/org/apache/predictionio/workflow/index.scala.html b/core/src/main/twirl/org/apache/predictionio/workflow/index.scala.html index 9aa6ad0027..a28e649b4d 100644 --- a/core/src/main/twirl/org/apache/predictionio/workflow/index.scala.html +++ b/core/src/main/twirl/org/apache/predictionio/workflow/index.scala.html @@ -1,22 +1,3 @@ - @import org.apache.predictionio.data.storage.EngineInstance @import org.apache.predictionio.data.storage.EngineManifest @import org.apache.predictionio.workflow.ServerConfig @@ -40,6 +21,22 @@ lastServingSec: Double ) + @{engineInstance.engineFactory} (@{engineInstance.engineVariant}) - PredictionIO Engine Server at @{args.ip}:@{args.port} diff --git a/docs/javadoc/javadoc-overview.html b/docs/javadoc/javadoc-overview.html index 97474c2937..7eb78ec777 100644 --- a/docs/javadoc/javadoc-overview.html +++ b/docs/javadoc/javadoc-overview.html @@ -1,21 +1,18 @@

diff --git a/docs/manual/source/github.html b/docs/manual/source/github.html index c64f6c54c3..9fe96e7dba 100644 --- a/docs/manual/source/github.html +++ b/docs/manual/source/github.html @@ -1,21 +1,18 @@ --- layout: raw diff --git a/examples/experimental/scala-stock/src/main/twirl/io/prediction/examples/stock/backtesting.scala.html b/examples/experimental/scala-stock/src/main/twirl/io/prediction/examples/stock/backtesting.scala.html index 354eda94d6..ad0552ff9d 100644 --- a/examples/experimental/scala-stock/src/main/twirl/io/prediction/examples/stock/backtesting.scala.html +++ b/examples/experimental/scala-stock/src/main/twirl/io/prediction/examples/stock/backtesting.scala.html @@ -1,23 +1,20 @@ +@import org.apache.predictionio.examples.stock.BacktestingResult -@import org.apache.predictionio.examples.stock.BacktestingResult diff --git a/tools/src/main/twirl/org/apache/predictionio/tools/dashboard/index.scala.html b/tools/src/main/twirl/org/apache/predictionio/tools/dashboard/index.scala.html index ff235d9fb7..787d21ad66 100644 --- a/tools/src/main/twirl/org/apache/predictionio/tools/dashboard/index.scala.html +++ b/tools/src/main/twirl/org/apache/predictionio/tools/dashboard/index.scala.html @@ -1,20 +1,3 @@ - - @import org.apache.predictionio.data.storage.EvaluationInstance @import org.apache.predictionio.tools.dashboard.DashboardConfig @import org.joda.time.DateTime @@ -24,6 +7,22 @@ env: Map[String, String], completedInstances: Seq[EvaluationInstance]) + PredictionIO Dashboard at @{dc.ip}:@{dc.port}