Skip to content

Commit

Permalink
First commit for 8.0.0-alpha release
Browse files Browse the repository at this point in the history
  • Loading branch information
ezimuel committed Mar 1, 2022
1 parent 0334e5b commit aeb7aaa
Show file tree
Hide file tree
Showing 605 changed files with 13,639 additions and 212,853 deletions.
2 changes: 1 addition & 1 deletion .ci/run-repository.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ script_path=$(dirname $(realpath -s $0))
source $script_path/functions/imports.sh
set -euo pipefail

PHP_VERSION=${PHP_VERSION-7.4-cli}
PHP_VERSION=${PHP_VERSION-8.0-cli}
ELASTICSEARCH_URL=${ELASTICSEARCH_URL-"$elasticsearch_url"}
elasticsearch_container=${elasticsearch_container-}

Expand Down
2 changes: 1 addition & 1 deletion .ci/test-matrix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ STACK_VERSION:
- 8.0.0-SNAPSHOT

PHP_VERSION:
- 8.1-cli
- 8.0-cli
- 7.4-cli
- 7.3-cli

TEST_SUITE:
- free
Expand Down
3 changes: 0 additions & 3 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,8 @@
/util export-ignore
/.gitattributes export-ignore
/.gitignore export-ignore
/.gitmodules export-ignore
/.php_cs export-ignore
/phpstan.neon export-ignore
/phpunit-integration-tests.xml export-ignore
/phpunit-yaml-free-tests.xml export-ignore
/phpunit-yaml-platinum-tests.xml export-ignore
/phpunit.xml.dist export-ignore
/ruleset.xml export-ignore
24 changes: 1 addition & 23 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:

strategy:
matrix:
php-version: [7.3, 7.4, 8.0]
php-version: [7.4, 8.0, 8.1]
os: [ubuntu-latest]
es-version: [8.0.0-SNAPSHOT]

Expand Down Expand Up @@ -40,10 +40,6 @@ jobs:
run: |
composer install --prefer-dist
- name: PHP Coding Standards
run: |
composer run-script phpcs
- name: PHP Static Analysis Tool
run: |
composer run-script phpstan
Expand All @@ -53,22 +49,4 @@ jobs:
vendor/bin/phpunit -c phpunit.xml.dist
env:
TEST_SUITE: free

- name: Configure sysctl limits
run: |
sudo swapoff -a
sudo sysctl -w vm.swappiness=1
sudo sysctl -w fs.file-max=262144
sudo sysctl -w vm.max_map_count=262144
- name: Runs Elasticsearch ${{ matrix.es-version }}
uses: elastic/elastic-github-actions/elasticsearch@master
with:
stack-version: ${{ matrix.es-version }}

- name: Integration tests
run: |
vendor/bin/phpunit -c phpunit-integration-tests.xml
env:
ELASTICSEARCH_URL: http://localhost:9200

2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ build
tests/*-junit.xml

# YAML tests
tests/Elasticsearch/Tests/Yaml
tests/Yaml

# Exclude .ci/make.sh artifcats
.ci/output
23 changes: 0 additions & 23 deletions .php_cs

This file was deleted.

23 changes: 23 additions & 0 deletions BREAKING_CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,26 @@
# 8.0

This major release is a complete new PHP client for Elasticsearch. We build it from scratch!
We tried to reduce the BC breaks as much as possible but there are some big differences :rage:

## Architectural changes:

- we changed the namespace, now everything is under `Elastic\Elasticsearch`;
- we used the [elastic-transport-php](https://github.com/elastic/elastic-transport-php) library
to manage the HTTP requests and responses; This library allows the usage of any [PSR-18](https://www.php-fig.org/psr/psr-18/)
client.
- we changed the response type of each endpoints using a wrapper class of a [PSR-7](https://www.php-fig.org/psr/psr-7/)
response. This class allows the access of the body response as array or object. This means
you can access the API response as in 7.x, no BC break here! :angel:

## Specific changes:

- to be completed
# 7.17

- We changed the signature of `Elasticsearch\Common\EmptyLogger::log` adding the `void` return type.
This change has been needed to support psr/log v3.

# 7.4

- Using a deprecated parameter is notified triggering a [E_USER_DEPRECATED](https://www.php.net/manual/en/errorfunc.constants.php)
Expand Down
47 changes: 47 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,50 @@
## Release 7.17.0

- Allow psr/log v3
[#1184](https://github.com/elastic/elasticsearch-php/pull/1184)

## Release 7.16.0

- Added support of includePortInHostHeader in ClientBuilder::fromConfig
[#1181](https://github.com/elastic/elasticsearch-php/pull/1181)
- Fixed UTF-16 issue in SmartSerializer with single unpaired surrogate in unicode escape
[#1179](https://github.com/elastic/elasticsearch-php/pull/1179)
- Replace trait with abstract class to avoid Deprecated Functionality issue in PHP 8.1
[#1175](https://github.com/elastic/elasticsearch-php/pull/1175)

## Release 7.15.0

- Updated endpoints for Elasticsearch 7.15.0
[995f6d4](https://github.com/elastic/elasticsearch-php/commit/995f6d4bde7de76004e95d7a434b1d59da7a7e75)

## Release 7.14.0

- Usage of psr/log version 2
[#1154](https://github.com/elastic/elasticsearch-php/pull/1154)
- Update search iterators to send `scroll_id` inside the request body
[#1134](https://github.com/elastic/elasticsearch-php/pull/1134)
- Added the `ingest.geoip.downloader.enabled=false` setting for ES
[5867351](https://github.com/elastic/elasticsearch-php/commit/586735109dc18f22bfdf3b73ab0621b37e857be1)
- Removed phpcs for autogenerated files (endpoints)
[651c57b](https://github.com/elastic/elasticsearch-php/commit/651c57b2e6bf98a0fd48220949966e630e5a804a)

## Release 7.13.1

- Added port in url for trace and logger messages
[#1126](https://github.com/elastic/elasticsearch-php/pull/1126)
## Release 7.13.0

- (DOCS) Added the HTTP meta data section
[#1143](https://github.com/elastic/elasticsearch-php/pull/1143)
- Added support for API Compatibility Header
[#1142](https://github.com/elastic/elasticsearch-php/pull/1142)
- (DOCS) Added Helpers section to PHP book
[#1129](https://github.com/elastic/elasticsearch-php/pull/1129)
- Added the API description in phpdoc section for each endpoint
[9e05c81](https://github.com/elastic/elasticsearch-php/commit/9e05c8108b638b60cc676b6a4f4be97c7df9eb64)
- Usage of PHPUnit 9 only + migrated xml configurations
[038b5dd](https://github.com/elastic/elasticsearch-php/commit/038b5dd043dc76b20b9f5f265ea914a38d33568d)

## Release 7.12.0

- Updated the endpoints for ES 7.12 + removed cpliakas/git-wrapper
Expand Down
23 changes: 18 additions & 5 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
Copyright 2013-2020 Elasticsearch B.V.
Copyright 2022 Elasticsearch B.V (https://www.elastic.co)

elasticsearch-php is licensed under the Apache License, Version 2.0
(<LICENSE-APACHE> or <http://www.apache.org/licenses/LICENSE-2.0>) or the GNU
Lesser General Public License, Version 2.1 (<LICENSE-LGPL> or
<https://www.gnu.org/licenses/lgpl-2.1.html>) at your option.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
174 changes: 0 additions & 174 deletions LICENSE-APACHE

This file was deleted.

Loading

0 comments on commit aeb7aaa

Please sign in to comment.