Skip to content

Commit 14db09a

Browse files
committed
Merge branch 'v4.x' into v3.x
2 parents 8404538 + f0ff947 commit 14db09a

40 files changed

Lines changed: 733 additions & 1018 deletions

.github/workflows/phpstan.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,12 @@ jobs:
1616
runs-on: ubuntu-latest
1717
timeout-minutes: 5
1818
steps:
19-
- uses: actions/checkout@v4
19+
- uses: actions/checkout@v6
2020

2121
- name: Setup PHP
2222
uses: shivammathur/setup-php@v2
2323
with:
24-
php-version: '8.2'
24+
php-version: '8.3'
2525
coverage: none
2626

2727
- name: Install composer dependencies

.github/workflows/run-tests.yml

Lines changed: 24 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,26 @@ on:
55
branches:
66
- main
77
- dev-main
8+
89
jobs:
910
test:
1011
runs-on: ubuntu-22.04
12+
timeout-minutes: 15
13+
strategy:
14+
fail-fast: true
15+
matrix:
16+
php: [ 8.3, 8.4 ]
17+
laravel: [ 13.*, 12.*, 11.* ]
18+
include:
19+
- laravel: 13.*
20+
testbench: 11.*
21+
- laravel: 12.*
22+
testbench: 10.*
23+
- laravel: 11.*
24+
testbench: 9.*
25+
26+
name: P${{ matrix.php }} - L${{ matrix.laravel }}
27+
1128
env:
1229
BROADCAST_DRIVER: log
1330
CACHE_DRIVER: redis
@@ -20,7 +37,6 @@ jobs:
2037
MAIL_MAILER: array
2138
TELESCOPE_ENABLED: false
2239

23-
# Docs: https://docs.github.com/en/actions/using-containerized-services
2440
services:
2541
opensearch:
2642
image: opensearchproject/opensearch:latest
@@ -44,31 +60,30 @@ jobs:
4460

4561
steps:
4662
- name: Checkout
47-
uses: actions/checkout@v4
63+
uses: actions/checkout@v6
4864

49-
- name: Verify Opensearch connection
65+
- name: Verify OpenSearch connection
5066
run: |
5167
curl -X GET "localhost:${{ job.services.opensearch.ports['9200'] }}/_cluster/health?pretty=true"
5268
5369
- name: Setup PHP
5470
uses: shivammathur/setup-php@v2
5571
with:
56-
php-version: 8.2
72+
php-version: ${{ matrix.php }}
5773
tools: composer:v2
5874
coverage: xdebug
5975
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick, fileinfo, mysql
6076

61-
- name: Install Project Dependencies 💻
77+
- name: Install dependencies
6278
run: |
63-
composer install --no-interaction --prefer-dist --optimize-autoloader
79+
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update
80+
composer update --prefer-stable --prefer-dist --no-interaction
6481
6582
- name: List Installed Dependencies
6683
run: composer show -D
6784

6885
- name: Run tests
69-
run: |
70-
./vendor/bin/pest --version
71-
./vendor/bin/pest
86+
run: vendor/bin/pest --ci
7287
env:
7388
REDIS_PORT: ${{ job.services.redis.ports['6379'] }}
7489
OPENSEARCH_HOST: http://localhost:${{ job.services.opensearch.ports['9200'] }}

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ secrets.nix
1717

1818
.phpunit*
1919

20+
.OPEN*
2021

2122
.idea
2223
.phpunit.cache

CHANGELOG.md

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,43 @@
22

33
All notable changes to this `laravel-opensearch` package will be documented in this file.
44

5+
## v3.1.0 - 2026-03-26
6+
7+
This release is compatible with Laravel 11, 12 & 13
8+
9+
### Added
10+
11+
- **Laravel 13 support**
12+
- Composer test scripts for per-version testing: `composer test:l11`, `composer test:l12`, `composer test:l13`, `composer test:all`
13+
14+
### Changed
15+
16+
- Dropped Laravel 10 support (EOL)
17+
- `pdphilip/elasticsearch` switched from `v5.0.4` (main) to `v0.5.2` (v0-core engine-only build — no ES PHP client bundled)
18+
- `opensearch-project/opensearch-php` constraint relaxed from `2.3.1` to `^2.3`
19+
- Removed `"replace": {"elasticsearch/elasticsearch": "*"}` (no longer needed with v0-core)
20+
- CI matrix updated: PHP 8.3/8.4, Laravel 11/12/13
21+
22+
**Full Changelog**: https://github.com/pdphilip/laravel-opensearch/compare/v3.0.3...v3.1.0
23+
24+
## v3.0.3 - 2025-08-20
25+
26+
This release is compatible with Laravel 10, 11 & 12
27+
28+
### What's Changed
29+
30+
* Update Morphs Blueprints for Laravel ^12.23 Compatibility by @pbarsallo in https://github.com/pdphilip/laravel-opensearch/pull/20
31+
32+
### New Contributors
33+
34+
* @pbarsallo made their first contribution in https://github.com/pdphilip/laravel-opensearch/pull/20
35+
36+
### Bugfix
37+
38+
* fixed methods `processBulkInsert()`, `rawAggregation()` & `rawDsl()` - close #19
39+
40+
**Full Changelog**: https://github.com/pdphilip/laravel-opensearch/compare/v3.0.2...v3.0.3
41+
542
## v3.0.2 - 2025-07-13
643

744
This release is compatible with Laravel 10, 11 & 12

composer.json

Lines changed: 107 additions & 93 deletions
Original file line numberDiff line numberDiff line change
@@ -1,96 +1,110 @@
11
{
2-
"name": "pdphilip/opensearch",
3-
"description": "An OpenSearch implementation of Laravel's Eloquent ORM",
4-
"keywords": [
5-
"laravel",
6-
"eloquent",
7-
"OpenSearch",
8-
"database",
9-
"model"
10-
],
11-
"homepage": "https://github.com/pdphilip/laravel-opensearch",
12-
"authors": [
13-
{
14-
"name": "David Philip",
15-
"email": "pd.philip@gmail.com",
16-
"homepage": "https://github.com/pdphilip"
17-
}
18-
],
19-
"license": "MIT",
20-
"require": {
21-
"php": "^8.2",
22-
"illuminate/container": "^10.0|^11|^12",
23-
"illuminate/database": "^10.30|^11|^12",
24-
"illuminate/events": "^10.0|^11|^12",
25-
"illuminate/support": "^10.0|^11|^12",
26-
"pdphilip/elasticsearch": "v0.5.0",
27-
"opensearch-project/opensearch-php": "2.3.1",
28-
"spatie/ignition": "^1.15"
29-
},
30-
"require-dev": {
31-
"orchestra/testbench": "^10.1||^9.0.0||^8.22.0",
32-
"mockery/mockery": "^1.4.4",
33-
"doctrine/coding-standard": "12.0.x-dev",
34-
"pestphp/pest": "^3.8.2",
35-
"pestphp/pest-plugin-laravel": "^3",
36-
"laravel/pint": "^1.14",
37-
"nunomaduro/collision": "^8.1.1||^7.10.0",
38-
"larastan/larastan": "^3",
39-
"pestphp/pest-plugin-arch": "^3",
40-
"phpstan/extension-installer": "^1.4",
41-
"phpstan/phpstan-deprecation-rules": "^2",
42-
"phpstan/phpstan-phpunit": "^2"
43-
},
44-
"autoload-dev": {
45-
"psr-4": {
46-
"PDPhilip\\OpenSearch\\Tests\\": "tests/"
47-
}
48-
},
49-
"autoload": {
50-
"psr-4": {
51-
"PDPhilip\\OpenSearch\\": "src/",
52-
"PDPhilip\\OpenSearch\\Tests\\": "tests"
53-
}
54-
},
55-
"config": {
56-
"allow-plugins": {
57-
"php-http/discovery": true,
58-
"pestphp/pest-plugin": true,
59-
"dealerdirect/phpcodesniffer-composer-installer": true,
60-
"phpstan/extension-installer": true
61-
}
62-
},
63-
"extra": {
64-
"laravel": {
65-
"providers": [
66-
"PDPhilip\\OpenSearch\\OpenSearchServiceProvider"
67-
]
68-
}
69-
},
70-
"scripts": {
71-
"post-autoload-dump": [
72-
"@clear",
73-
"@prepare"
2+
"name": "pdphilip/opensearch",
3+
"description": "An OpenSearch implementation of Laravel's Eloquent ORM",
4+
"keywords": [
5+
"laravel",
6+
"eloquent",
7+
"OpenSearch",
8+
"database",
9+
"model"
7410
],
75-
"clear": "@php vendor/bin/testbench package:purge-skeleton --ansi",
76-
"prepare": "@php vendor/bin/testbench package:discover --ansi",
77-
"build": "@php vendor/bin/testbench workbench:build --ansi",
78-
"serve": [
79-
"Composer\\Config::disableProcessTimeout",
80-
"@build",
81-
"@php vendor/bin/testbench serve"
11+
"homepage": "https://github.com/pdphilip/laravel-opensearch",
12+
"authors": [
13+
{
14+
"name": "David Philip",
15+
"email": "pd.philip@gmail.com",
16+
"homepage": "https://github.com/pdphilip"
17+
}
8218
],
83-
"lint": "pint -v",
84-
"types": "phpstan analyse --ansi --memory-limit=2G",
85-
"pest": "pest --colors=always",
86-
"test:lint": "pint --test -v",
87-
"test:types": "phpstan analyse --ansi",
88-
"test:unit": "pest --colors=always",
89-
"test": [
90-
"Composer\\Config::disableProcessTimeout",
91-
"@test:lint",
92-
"@test:types",
93-
"@test:unit"
94-
]
95-
}
96-
}
19+
"license": "MIT",
20+
"require": {
21+
"php": "^8.3",
22+
"illuminate/container": "^11.0|^12.0|^13.0",
23+
"illuminate/database": "^11.0|^12.0|^13.0",
24+
"illuminate/events": "^11.0|^12.0|^13.0",
25+
"illuminate/support": "^11.0|^12.0|^13.0",
26+
"pdphilip/elasticsearch": "v0.5.4",
27+
"opensearch-project/opensearch-php": "^2.6",
28+
"spatie/ignition": "^1.15"
29+
},
30+
"require-dev": {
31+
"orchestra/testbench": "^9.0||^10.0||^11.0",
32+
"mockery/mockery": "^1.4.4",
33+
"doctrine/coding-standard": "12.0.x-dev",
34+
"pestphp/pest": "^3||^4",
35+
"pestphp/pest-plugin-laravel": "^3||^4",
36+
"laravel/pint": "^1.14",
37+
"nunomaduro/collision": "^8.1.1",
38+
"larastan/larastan": "^3",
39+
"pestphp/pest-plugin-arch": "^3||^4",
40+
"phpstan/extension-installer": "^1.4||^2.0",
41+
"phpstan/phpstan-deprecation-rules": "^2",
42+
"phpstan/phpstan-phpunit": "^2"
43+
},
44+
"autoload-dev": {
45+
"psr-4": {
46+
"PDPhilip\\OpenSearch\\Tests\\": "tests/"
47+
}
48+
},
49+
"autoload": {
50+
"psr-4": {
51+
"PDPhilip\\OpenSearch\\": "src/",
52+
"PDPhilip\\OpenSearch\\Tests\\": "tests"
53+
}
54+
},
55+
"config": {
56+
"allow-plugins": {
57+
"php-http/discovery": true,
58+
"pestphp/pest-plugin": true,
59+
"dealerdirect/phpcodesniffer-composer-installer": true,
60+
"phpstan/extension-installer": true
61+
}
62+
},
63+
"extra": {
64+
"laravel": {
65+
"providers": [
66+
"PDPhilip\\OpenSearch\\OpenSearchServiceProvider"
67+
]
68+
}
69+
},
70+
"scripts": {
71+
"post-autoload-dump": "@composer run prepare",
72+
"prepare": "@php vendor/bin/testbench package:discover --ansi",
73+
"build": "@php vendor/bin/testbench workbench:build --ansi",
74+
"serve": [
75+
"Composer\\Config::disableProcessTimeout",
76+
"@build",
77+
"@php vendor/bin/testbench serve"
78+
],
79+
"lint": "pint -v",
80+
"types": "phpstan analyse --ansi --memory-limit=2G",
81+
"pest": "pest --colors=always",
82+
"test:lint": "pint --test -v",
83+
"test:types": "phpstan analyse --ansi",
84+
"test:unit": "pest --colors=always",
85+
"test": [
86+
"Composer\\Config::disableProcessTimeout",
87+
"@test:lint",
88+
"@test:types",
89+
"@test:unit"
90+
],
91+
"test:l11": [
92+
"@composer update --with laravel/framework:^11.0 --prefer-stable --no-interaction --quiet",
93+
"@test:unit"
94+
],
95+
"test:l12": [
96+
"@composer update --with laravel/framework:^12.0 --prefer-stable --no-interaction --quiet",
97+
"@test:unit"
98+
],
99+
"test:l13": [
100+
"@composer update --with laravel/framework:^13.0 --prefer-stable --no-interaction --quiet",
101+
"@test:unit"
102+
],
103+
"test:all": [
104+
"Composer\\Config::disableProcessTimeout",
105+
"@test:l11",
106+
"@test:l12",
107+
"@test:l13"
108+
]
109+
}
110+
}

0 commit comments

Comments
 (0)