Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add open options settings for test configs #320

Open
wants to merge 494 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
494 commits
Select commit Hold shift + click to select a range
806ac1e
Fixed the issue that doesnt set the max heap size correctly from the …
Jul 2, 2019
d4aa81f
Fixed the max heap size issue
Jul 2, 2019
b8c6ca1
Merge pull request #180 from neo4j/max-heapsize-fix
bfeshti Jul 2, 2019
f555223
Adding the ability to install neo4j labs plugins on container startup
Jul 5, 2019
c832a61
created a bug reporting template
jennyowen Jul 9, 2019
6236030
Revert "removed stray files"
jennyowen Jul 9, 2019
84c6811
added test for install neo4jlabs plugins at runtime
Jul 9, 2019
aef2eda
Merge pull request #181 from eastlondoner/andy/install-apoc-at-runtime
eastlondoner Jul 10, 2019
43ffbbd
Merge branch 'master' of github.com:neo4j/docker-neo4j
jennyowen Jul 10, 2019
84425d9
Revert "Merge pull request #181 from eastlondoner/andy/install-apoc-a…
jennyowen Jul 11, 2019
9c2f856
packaging was tagging enterprise and community the same
jennyowen Jul 12, 2019
a996470
Merge branch 'master' of github.com:neo4j/docker-neo4j
jennyowen Jul 12, 2019
1f9266e
Revert "packaging was tagging enterprise and community the same"
glindroth Jul 17, 2019
a42253b
packaging was tagging enterprise and community the same, now with no …
jennyowen Jul 22, 2019
07f9834
Merge branch 'master' of github.com:neo4j/docker-neo4j
jennyowen Jul 22, 2019
ab8b51d
patched 3.5 heap overide fix to 3.6 and 4.0
jennyowen Jul 22, 2019
a2ac34f
removed redundant 'build' folder
jennyowen Aug 1, 2019
57c65a8
Turns off driver encryption in tests.
Aug 5, 2019
cbde9af
Merge branch 'master' of github.com:neo-technology/docker-neo4j
jennyowen Aug 5, 2019
9efb81f
fixed bug in license checking code
jennyowen Aug 5, 2019
1e2ae8e
made test of license acceptance more thorough
jennyowen Aug 6, 2019
e181228
Fixed ovverriding of custom configurations by docker-entrypoint
Aug 6, 2019
47fb7b6
Added missing max heap conf line
Aug 6, 2019
0e30677
added 4.0 docker scripts to public docker repo.
jennyowen Aug 7, 2019
fc8432c
license acceptance test failed because the container kill command was…
jennyowen Aug 7, 2019
33e2268
Merge pull request #187 from jennyowen/private-merge
jennyowen Aug 7, 2019
fa72c38
can now set non-root user via envoriment variable.
jennyowen Aug 9, 2019
a4d66eb
Switch to using the latest neo4j driver (beta)
Aug 25, 2019
7d7f92e
Revert "Revert "Merge pull request #181 from eastlondoner/andy/instal…
Aug 8, 2019
8e0902a
bring TestPluginInstallation.java up to date with changes to SetConta…
Aug 9, 2019
962557a
adding install-plugins-at-runtime to 4.0 code
Aug 25, 2019
9713b2a
Tweaks to pom and makefile so neo4j version env var name stuff works …
Aug 25, 2019
2c5abc5
Merge pull request #191 from eastlondoner/andy/use-latest-neo-driver
eastlondoner Aug 26, 2019
5fdff60
Merge pull request #188 from eastlondoner/andy/install-apoc-at-runtime
jennyowen Aug 26, 2019
01259fd
Fixed ovverriding of custom configurations by docker-entrypoint
Aug 6, 2019
0a55fc1
Fixes based on the suggestions from the last review
Sep 5, 2019
27eff35
Resolved merging conflicts
Sep 5, 2019
82afb5a
Small fixes based on suggestions from the review
Sep 6, 2019
2ac6306
Edited the entrypoint to pass configs based on Edition
Sep 6, 2019
45e179d
Reverted changes made to pass the configs based on Edition to include…
Sep 6, 2019
030fac1
Merge pull request #186 from neo4j/docker-entrypoint-fix
bfeshti Sep 6, 2019
a18c1b8
docker-entrypoint will now set default configs based on Neo4j Edition
Sep 11, 2019
7168356
added changes for the 3.3 also
Sep 11, 2019
b880bf4
patches based on the last review
Sep 11, 2019
a1895ec
docker-entrypoint will now set default configs based on Neo4j Edition
Sep 11, 2019
22ee74a
Merge pull request #192 from neo4j/set-configs-based-on-edition
bfeshti Sep 12, 2019
838c023
rebased on master
jennyowen Sep 12, 2019
8a4b3cc
env NEO4J_dbms_directories_logs was being overwritten by folder writa…
jennyowen Sep 12, 2019
d1a0b1d
Changed unsupported.dbms.udc.source to docker
Sep 13, 2019
49031c2
Merge pull request #195 from neo4j/change-unsupported.dbms.udc.source…
bfeshti Sep 13, 2019
fcdfdf0
neo4jlabs-plugins.json was been included in local docker image build …
jennyowen Sep 25, 2019
d0e1a25
Merge pull request #196 from neo4j/fix-makefile
jennyowen Sep 25, 2019
fbb40ee
changing the versions.json urls to use github.io (github pages) urls
eastlondoner Sep 27, 2019
8f8924a
improved Neo4j version parser and muted PluginInstallation test when …
jennyowen Oct 2, 2019
5dcf7ee
removed all reference to environment variable NEO4J_VERSION in favour…
jennyowen Oct 3, 2019
694f925
makefile now creates devenv file
jennyowen Oct 3, 2019
1c1df2d
Tried to improve container closing so that tests don't leave so many …
jennyowen Oct 4, 2019
06048d0
Merge pull request #197 from eastlondoner/master
eastlondoner Oct 4, 2019
f8178db
disabled plugin test for 4.0
jennyowen Oct 7, 2019
488b0fb
Merge branch 'master' of github.com:neo4j/docker-neo4j
jennyowen Oct 7, 2019
c08fb1c
improved development instructions
jennyowen Oct 7, 2019
c4d848e
updated main readme
jennyowen Oct 7, 2019
b4c0b36
merged public repository into private
jennyowen Oct 30, 2019
93935cc
patched changes to 3.5 entrypoint onto 3.6 entrypoint
jennyowen Oct 30, 2019
1c64629
added `require-password-change` flag to `set-initial-password`
jennyowen Oct 31, 2019
bb60e76
fixed weird inconsistencies between docker entrypoints
jennyowen Nov 1, 2019
9044dc4
Rename tx-logs to transactions
klaren Nov 1, 2019
5fad554
tx-logs folder was renamed
jennyowen Nov 5, 2019
c375ea1
removed some unused test conf files
jennyowen Nov 8, 2019
2996846
Merge branch 'master' of github.com:neo4j/docker-neo4j
jennyowen Nov 8, 2019
5b71dfd
fixed jvm.additional overriden by docker-entrypoint
Nov 15, 2019
10014c4
removed old jvm.additional overriding config
Nov 15, 2019
6d9e8f2
updated set intitial password to new requires password reset argument…
jennyowen Nov 21, 2019
5c8cb8a
Merge branch 'master' of github.com:neo4j/docker-neo4j into mergepubl…
jennyowen Nov 21, 2019
09bc490
edited pom to make it easier to switch between java 8 and 11
jennyowen Nov 21, 2019
57f0ed2
enabled require-password-reset feature in 4.0
jennyowen Nov 21, 2019
7e95b5c
removing private files
jennyowen Nov 22, 2019
8de0b0a
Reverted previous changes and added a more reliable way to fix jvm.ad…
Nov 25, 2019
1e47370
fixed indentation and added some helpful comments
Nov 25, 2019
bc476cb
Merge pull request #205 from neo4j/fix-jvm.additional-not-overriden
bfeshti Nov 25, 2019
154b9d2
Added 4.1 docker-image-src
Nov 25, 2019
54d1bd4
Merge pull request #209 from neo4j/add-4.1-docker-image-src
bfeshti Nov 25, 2019
f40b214
refactored to use try with resources to clean up containers
jennyowen Nov 25, 2019
f58bf3a
refactored new test to use try with resources
jennyowen Nov 25, 2019
3efe2f1
increased timeouts and cleaned some obsolete imports
jennyowen Nov 26, 2019
ee631e7
given mounted folders more descriptive names
jennyowen Dec 2, 2019
476bbd9
fixed upgrade from before file permissions in 3.5 fix and added tests.
jennyowen Dec 3, 2019
817d59d
patched 3.5 changes to other docker entrypoints
jennyowen Dec 4, 2019
110bc9c
ignore upgrade test in 4.0 until I can close the old version containe…
jennyowen Dec 4, 2019
9dc76dd
fixed annoying stderr warnings for 4.0
jennyowen Dec 4, 2019
6197aa3
patched 4.0 fixes to 4.1
jennyowen Dec 4, 2019
d8f74ae
Replaced curl with wget in the entryoint
Dec 10, 2019
b7dad0f
Merge branch 'master' into fix-curl-vulnerability
Dec 10, 2019
e50093a
Final touch of replacing curl
Dec 10, 2019
e35ddb8
Merge pull request #216 from neo4j/fix-curl-vulnerability
bfeshti Dec 10, 2019
de6d73a
add seperate build targets for community and enterprise
Dec 10, 2019
8903096
add neo4j community bintray repository to pom so that neo4j java depe…
Dec 10, 2019
a9e4153
allow setting an env var to skip the plugin test if it causes problems
Dec 10, 2019
c75b2b2
Merge pull request #206 from eastlondoner/run-plugins-tests
eastlondoner Dec 11, 2019
8aac9d0
add the ability to easily run a particular junit test or tests matchi…
Dec 11, 2019
05e39e8
tidying up java test code
Dec 11, 2019
946059d
apply default configurations for plugins when installing a plugin (if…
Dec 11, 2019
a5fd50a
Improve handling of NEO4J_ config setting env variables
Dec 12, 2019
b5a0164
Merge pull request #217 from eastlondoner/configure-plugins-automatic…
eastlondoner Dec 12, 2019
ce9a7e9
use the latest neo4j driver
Dec 11, 2019
1905283
Merge pull request #220 from eastlondoner/tidying
eastlondoner Dec 12, 2019
53076ab
Merge pull request #218 from eastlondoner/make-individual-test
eastlondoner Dec 12, 2019
deed771
Merge pull request #219 from eastlondoner/use-latest-neo4j-driver
eastlondoner Dec 12, 2019
96797c6
Merge pull request #221 from eastlondoner/improve-config-handling
eastlondoner Dec 12, 2019
707b9cb
unset NEO4J_AUTH was setting no password rather than default password…
jennyowen Jan 22, 2020
53ba5c5
Update neo4jlabs-plugins.json
jbarrasa Jan 30, 2020
b192927
Update neo4jlabs-plugins.json
jbarrasa Feb 4, 2020
5ac55f4
Merge pull request #227 from jbarrasa/master
eastlondoner Feb 4, 2020
a9c12d5
updated test dependencies in pom
jennyowen Mar 2, 2020
47075e1
Merge branch 'master' of github.com:neo4j/docker-neo4j
jennyowen Mar 2, 2020
05ec38e
Revert "updated test dependencies in pom"
jennyowen Mar 2, 2020
9e86faa
updated pom dependendies
jennyowen Mar 3, 2020
ddcda66
removed udc.source from 4.0.x
Mar 4, 2020
ce5cb12
Fixed a typo
Mar 4, 2020
cf4063d
Moved assumption on top of the test
Mar 5, 2020
7e6d4b6
Merge pull request #234 from neo4j/Remove_udc.source_from_4.0.x
bfeshti Mar 5, 2020
8714fbc
removed user=root flag from chmod of home folder
jennyowen Mar 9, 2020
f8783c5
Merge branch 'master' into confpermissions
jennyowen Mar 9, 2020
27ddc04
added link to Neo4j Community
jennyowen Mar 16, 2020
057ecf5
updated support guidance on README
jennyowen Mar 16, 2020
8eb77c9
changed listen address overrides because they seem unnecessary and ma…
jennyowen Mar 25, 2020
3dcdf60
patched changes to 4.0 conf overrides to 4.1
jennyowen Mar 25, 2020
28191a4
refactored code after review from hugo, patched changes back to 3.4.
jennyowen Apr 1, 2020
eba50a9
Merge branch 'master' of github.com:neo4j/docker-neo4j
jennyowen Apr 1, 2020
20e64f4
fixed issue #243
jennyowen Apr 15, 2020
4edbfb1
adding graph-data-science to NEO4JLABS_PLUGINS
Apr 16, 2020
663161f
Merge pull request #245 from eastlondoner/gds-plugin
eastlondoner Apr 17, 2020
52c2c74
TestMounting was incorrectly passing some data mounting tests, fixed.
jennyowen May 6, 2020
baec1f1
Merge branch 'master' of github.com:neo4j/docker-neo4j
jennyowen May 6, 2020
d5c97b6
improved readwrite checks on mounted folders
jennyowen May 21, 2020
bdf86b5
copied new docker source files for 4.2
jennyowen Jun 2, 2020
b0acb4f
moved set password command to after configuration to fix a bug in aura
jennyowen Jun 3, 2020
4c002cf
explicitly set neo4j uid and gid to 7474
jennyowen Jun 9, 2020
03bc788
Revert "explicitly set neo4j uid and gid to 7474"
jennyowen Jun 15, 2020
b65ad72
Revert "Revert "explicitly set neo4j uid and gid to 7474""
jennyowen Jun 16, 2020
994bf19
started test for database dump
jennyowen Mar 12, 2020
b09dd44
made tests that mount 2 or more folders keep the temp folders togethe…
jennyowen Mar 12, 2020
3d75707
added some notes to dump load test
jennyowen Mar 13, 2020
9e5927a
added host FS operation to create test folder under TEST_TMP_FOLDER w…
jennyowen Jun 16, 2020
3f8cc0a
removed dump and load test
jennyowen Jun 16, 2020
3d059c5
Merge branch 'hardcode-uid-gid'
jennyowen Jun 18, 2020
fb989d6
fixed authentication bug in 4.1
jennyowen Jun 26, 2020
c1d4889
fixed authentication bug in 4.1
jennyowen Jun 26, 2020
981c878
refactored make files to create arm64 build
jennyowen Jul 7, 2020
d9aefd7
patched Dockerfile changes to 4.1 and 4.2
jennyowen Jul 8, 2020
fe410ec
Merge branch 'arm-support'
jennyowen Jul 8, 2020
6f5d362
added back packaging make targets to copy release image to output folder
jennyowen Jul 8, 2020
94ed955
added readme section about arm64 images
jennyowen Jul 16, 2020
cc64a60
Update README.md
jennyowen Jul 16, 2020
e3e06a8
fixed package-arm make target
jennyowen Jul 20, 2020
c364cc2
Merge branch 'master' of github.com:neo4j/docker-neo4j
jennyowen Jul 20, 2020
04d5df6
proper tagging of packages arm64 build
jennyowen Jul 21, 2020
19667f3
added test for mounting named volume
jennyowen Jul 22, 2020
15355fb
refactored named volume code
jennyowen Jul 23, 2020
896ac82
NamedVolume didn't work if you mounted 2 volumes, it only mounts the …
jennyowen Jul 28, 2020
28a1fbf
added more upgrade tests and mounting tests for named volumes
jennyowen Jul 30, 2020
618ea23
patched docker entrypoint fixes to 4.1 and 4.2
jennyowen Jul 30, 2020
41393ff
patched docker entrypoint fixes to 4.1 and 4.2
jennyowen Jul 30, 2020
770e297
Merge branch 'namedvolumes' of github.com:neo4j/docker-neo4j into nam…
jennyowen Jul 30, 2020
b5f5106
patched permissions checks to 3.5 docker entrypoint
jennyowen Jul 30, 2020
f431f75
fixed patching error in entrypoint scripts
jennyowen Aug 6, 2020
72d5f72
now chown neo4j.conf
jennyowen Sep 15, 2020
e7aba0e
patched neo4j.conf ownership change to 4.0 and 4.2
jennyowen Sep 15, 2020
638e560
changed startup check strategy to try and fix flakiness in configurat…
jennyowen Oct 15, 2020
7afa379
fixed licensing test
jennyowen Oct 16, 2020
9ae6fe0
enabled extended configuration setting and added basic unit tests
jennyowen Oct 23, 2020
afd988a
changed extended conf test to use setting in community and enterprise
jennyowen Oct 23, 2020
0ff5625
created new docker source for 4.3
jennyowen Oct 26, 2020
4e826ad
Relaxed expectation on config log print
Roxling Oct 29, 2020
20792cf
Merge pull request #279 from Roxling/relaxed-config-log
Roxling Oct 29, 2020
b202339
bump testcontainers version
Dec 14, 2020
5ec4a6b
Merge pull request #282 from eastlondoner/update-test-containers
eastlondoner Dec 14, 2020
74fbfe2
add Bloom plugin
GlacialBoy Jan 18, 2021
30302c0
add Bloom plugin
GlacialBoy Jan 18, 2021
3d42514
check read permission for licenses folder
GlacialBoy Jan 18, 2021
49fe2ad
Merge pull request #283 from neo4j/cla/addbloomplugin
GlacialBoy Jan 19, 2021
4148271
fixed ARM64 build script
jennyowen Feb 8, 2021
1d29325
dbms.routing.advertised_address default added for 4.3
jennyowen Feb 5, 2021
771e700
Merge branch 'new-default-confs'
jennyowen Feb 9, 2021
b2b7720
Merge branch 'master' of github.com:neo4j/docker-neo4j
jennyowen Feb 9, 2021
17e6c7e
added instructions for building arm images
jennyowen Feb 18, 2021
8fb9a8d
removed old unused repo from pom
jennyowen Apr 27, 2021
5877dcb
add --expand-commands flag to neo4j-admin commands (#294)
eastlondoner May 20, 2021
315b333
temporarily revert tests for command expansion bugs because those bug…
eastlondoner May 20, 2021
340f758
added new 4.4 folder
glindroth May 24, 2021
b3f3a26
use new 'neo4j dry-run' mechanism to start neo4j process in 4.3 (#295)
eastlondoner Jun 2, 2021
e0c2d43
Revert "use new 'neo4j dry-run' mechanism to start neo4j process in 4…
glindroth Jun 3, 2021
a518e2d
Revert "Revert "use new 'neo4j dry-run' mechanism to start neo4j proc…
glindroth Jun 4, 2021
b774b69
updated 4.2 to stop overwriting enterprise configuration settings
jennyowen Jun 9, 2021
a3f89af
patched 4.2 entrypoint changes to other branches
jennyowen Jun 9, 2021
a5f3d5b
updated 4.4 entrypoint to have latest 4.3 changes
jennyowen Jun 9, 2021
6ff1612
patched 3.5 entrypoint to fix configuration overrides. Updated licens…
jennyowen Jun 9, 2021
7986a74
fixed conf test failure in 4.3+
jennyowen Jun 9, 2021
8170386
added apoc-core
renetapopova Jul 9, 2021
f9b6989
fix
renetapopova Jul 9, 2021
468b450
defined install plugin from location
renetapopova Jul 9, 2021
abe0989
reworked my PR
renetapopova Jul 13, 2021
57630ba
fixes the json
renetapopova Jul 13, 2021
7318b01
fixed the unbound parameter
renetapopova Jul 13, 2021
1f085d1
fixed the location in json
renetapopova Jul 13, 2021
f2eed34
another fix in json
renetapopova Jul 13, 2021
e8cb7cb
test bundled plugins
Jul 19, 2021
cf342b2
fix bash string check
Jul 19, 2021
cb00f07
tweak bash
Jul 19, 2021
b8c827c
what I should have done
Jul 19, 2021
be421c1
add debug output to test
Jul 19, 2021
cd24506
apoc versioning not as expected
Jul 19, 2021
daad125
Merge pull request #302 from renetapopova/apoc-core
renetapopova Jul 20, 2021
857a388
added makefile target for testing arm images
jennyowen Sep 13, 2021
f088026
updated makefile to tag arm images with `neo4j` rather than experimen…
jennyowen Sep 17, 2021
66b8bec
fixed race condition in extended conf test
jennyowen Sep 20, 2021
e5c2e8f
new make targets for arm releasing
jennyowen Sep 20, 2021
86d6b6e
Merge branch 'arm-support'
jennyowen Sep 20, 2021
207ff0a
updated TestContainers dependencies to get ARM support
jennyowen Sep 21, 2021
2041181
Make targets for neo4j-admin image
jennyowen Oct 19, 2021
ef47c5a
refactored test folders
jennyowen Oct 19, 2021
05f88fd
fix: upgrade org.slf4j:slf4j-api from 1.7.30 to 1.7.32
snyk-bot Oct 20, 2021
c7296af
fix: upgrade org.slf4j:slf4j-log4j12 from 1.7.30 to 1.7.32
snyk-bot Oct 20, 2021
b8612b8
Merge pull request #308 from neo4j/snyk-upgrade-87d83deb096cad2c92e72…
jennyowen Oct 20, 2021
115d757
Merge pull request #309 from neo4j/snyk-upgrade-4429ab96f6cde5176882e…
jennyowen Oct 20, 2021
8642791
some initial tests for neo4j-admin image
jennyowen Oct 21, 2021
e5de058
dump load tests for non-default user
jennyowen Oct 21, 2021
1d48def
authetication and multiuser tests for dump/load
jennyowen Oct 21, 2021
daf16d9
backup and restore test, refactored database IO helper
jennyowen Oct 22, 2021
e30f423
ensure admin image doesn't run neo4j server
jennyowen Oct 22, 2021
c647d02
copied neo4j-admin source to other neo4j versions
jennyowen Oct 22, 2021
9c58288
added mvn test parameters for neo4j-admin image
jennyowen Oct 22, 2021
ac7145b
database io refactors broke upgrade tests, fixed
jennyowen Oct 22, 2021
f168f61
Merge branch 'master' of github.com:neo4j/docker-neo4j
jennyowen Oct 22, 2021
5fbb6d0
fix: upgrade org.slf4j:slf4j-api from 1.7.30 to 1.7.32
snyk-bot Oct 20, 2021
c00b941
fix: upgrade org.slf4j:slf4j-log4j12 from 1.7.30 to 1.7.32
snyk-bot Oct 20, 2021
0d0a1d6
added maven options to make test targets. Deleted unused HA test
jennyowen Oct 27, 2021
81a2edb
added new source for 5.0 branch
jennyowen Nov 1, 2021
8f0321f
teardown method to delete mount folders after unit test
jennyowen Nov 3, 2021
f6a6d8b
Merge branch 'betterTeardown'
jennyowen Nov 3, 2021
cb3f98a
testDumpLoad was running before 4.4.0 for some reason, hopefully fixed
jennyowen Nov 4, 2021
fcfcf10
Revert "testDumpLoad was running before 4.4.0 for some reason, hopefu…
jennyowen Nov 4, 2021
e241b4c
Revert "Merge branch 'betterTeardown'"
jennyowen Nov 4, 2021
d9eb296
fixed broken default_listen_address config in 3.5
jennyowen Nov 8, 2021
aa2002d
fixed typo
jennyowen Nov 8, 2021
79985e3
Change pagecache size debug log output assertion due to type change
tinwelint Nov 19, 2021
7f4dcf5
Temporary disable upgrade tests since upgrade is under update for 5.0…
MishaDemianenko Nov 19, 2021
bdf9a9e
Merge pull request #317 from MishaDemianenko/temp-disable-upgrade
MishaDemianenko Nov 19, 2021
34cd62c
Merge pull request #316 from neo4j/page-cache-mem-type-change
tinwelint Nov 22, 2021
f069fcb
Add open options settings for test configs
MishaDemianenko Dec 1, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: jennyowen, bfeshti

---

## Guidelines

Please note that GitHub issues are only meant for bug reports/feature requests.
If you have questions on how to use Neo4j, please ask on [Neo4j Community](https://community.neo4j.com/) or [StackOverflow](http://stackoverflow.com/questions/tagged/neo4j) instead of creating an issue here.

To help us understand your issue, please specify important details, primarily:

- **Steps to reproduce**. *Not including reproduction steps will mean your bug will take considerably longer to investigate and fix. Please don't skip this*.
- Expected behaviour
- Actual behaviour
- Neo4j image tag being used, eg `neo4j:latest`, `neo4j:enterprise-3.5` etc
- The output of the `docker version` command
- Operating system: (for example Windows 95/Ubuntu 16.04)

Additionally, include (as appropriate) log-files, stacktraces, and other debug output.
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,10 @@
/out/
/in/
/devenv.local
/local-mounts/
/target/

# simlinks to dev scripts in https://github.com/neo-technology/teamcity-witchcraft
download_tool.py
docker_tests_get_installers.py
__pycache__/
131 changes: 117 additions & 14 deletions DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,26 +8,129 @@ other Linuxes. Pull requests welcomed for other platforms.
## OSX only

1. install GNU Make (>=4.0)
1. install the Docker Toolbox
1. install the Docker Toolbox. See: https://docs.docker.com/install/

## Debian
## Linux

1. install `uuid-runtime`
1. install the Docker Toolbox. See https://docs.docker.com/install/

## All platforms
# Building the Image

1. download the Neo4j Community unix tarball
1. copy `devenv.local.template` as `devenv.local`; fill in the
directory to which you have downloaded the tarball and its version
The build will create two images (one for Enterprise and one for Community) for a single version of Neo4j.

# Build process
The make script will automatically download the source files needed to build the images.
You just need to specify the **full** Neo4j version including major, minor and patch numbers. For example:

## OSX only
```bash
NEO4JVERSION=3.5.11 make clean build
```

If you want to build an alpha/beta release, this will still work:

```bash
NEO4JVERSION=3.5.0-alpha01 make clean build
```

When the make script is complete, the image name will be written to file in `tmp/.image-id-community` and `tmp/.image-id-enterprise`:

```bash
$ cat tmp/.image-id-community
test/19564

$ cat tmp/.image-id-enterprise
test/13909
```

## Building ARM64 based images

There is a separate make script for building ARM64 based images.

Like with `amd64` images, you must still specify the **full** Neo4j version including major, minor and patch numbers. For example:

```bash
NEO4JVERSION=3.5.11 make -f make-arm64.mk clean tag-arm
```


## If the Neo4j Version is not Publicly Available

The make script cannot automatically download unreleased source files, so you need to manually download them before building the images.

1. Assuming you cloned this repository to `$NEO4J_DOCKER_ROOT`,
download the community and enterprise unix tar.gz files and copy them to `$NEO4J_DOCKER_ROOT/in`.
1. Run the make script setting `NEO4JVERSION` to the version number in the files downloaded into the `in/` folder.

For example:

```bash
$ cd $NEO4J_DOCKER_ROOT
$ ls $NEO4J_DOCKER_ROOT/in
neo4j-community-4.0.0-alpha05-unix.tar.gz neo4j-enterprise-4.0.0-alpha05-unix.tar.gz

$ NEO4JVERSION=4.0.0-alpha05 make clean build
```


# Running the Tests

The tests are written in java, and require Maven plus jdk 11 for Neo4j version 4.0 onwards or jdk 8 for earlier Neo4j versions.

The tests require some information about the image before they can test it.
These can be passed as an environment variable or a command line parameter when invoking maven:


| Env Variable | Maven parameter | Description |
|-----------------|-----------------|------------------------------------------------------------|
| `NEO4JVERSION` | `-Dversion` | the Neo4j version of the image |
| `NEO4J_IMAGE` | `-Dimage` | the tag of the image to test |
| `NEO4J_EDITION` | `-Dedition` | Either `community` or `enterprise` depending on the image. |

<!-- prettified with http://www.tablesgenerator.com/markdown_tables -->

## Using Maven
The Makefile can run the entire test suite.
1. Make sure `java --version` is java 11 or java 8 as necessary.
2. `NEO4JVERSION=<VERSION> make test` This is a make target that will run these commands:
```bash
mvn test -Dimage=$(cat tmp/.image-id-community) -Dedition=community -Dversion=${NEO4JVERSION}
mvn test -Dimage=$(cat tmp/.image-id-enterprise) -Dedition=enterprise -Dversion=${NEO4JVERSION}
```

## In Intellij

1. Make sure the project SDK is java 11 or java 8 as necessary.
1. Edit the [pom.xml file](../master/pom.xml) to replace `${env.NEO4JVERSION}` with the `NEO4JVERSION` you used to build the image.
*(Yes this is terrible, and we need to think of an alternative to this)*.

For example:
```xml
<neo4j.version>${env.NEO4JVERSION}</neo4j.version>
```
becomes
```xml
<neo4j.version>4.0.0-alpha05</neo4j.version>
```
1. Install the [EnvFile](https://plugins.jetbrains.com/plugin/7861-envfile) Intellij plugin.
2. Under Run Configurations edit the Template JUnit configuration:
1. Select the "EnvFile" tab
2. Make sure "Enable EnvFile" is checked.
3. Click the `+` then click to add a `.env` file.
4. In the file selection box select `./tmp/devenv-enterprise.env` or `./tmp/devenv-community.env` depending on which one you want to test.
5. Rebuilding the Neo4j image will regenerate the `.env` files, so you don't need to worry about keeping the environment up to date.


### If the Neo4j Version is not Publicly Available

1. Clone the Neo4j github repository and checkout the branch you want.
2. Make sure `java --version` returns java 11 if you're building Neo4j 4.0+, or java 8 if building an earlier branch.
1. Run `mvn install` plus whatever maven build flags you like. This should install the latest neo4j jars into the maven cache.
1. Follow instructions for [running tests in Intellij](#in-intellij),
use the `NEO4JVERSION` that is in the pom file of your Neo4j repository clone.

### cannot find symbol `com.sun.security.auth.module.UnixSystem`

1. create a docker-machine VM
1. export the docker-machine environment for docker
This can happen if you switch from java 8 to java 11 and then try to rebuild the tests in Intellij.

## All platforms
Check that the `java.version` property in the [pom.xml file](../master/pom.xml) is set to 11 instead of 1.8.
DO NOT commit this set to 11 (yes this is a terrible solution).

1. `. devenv`
1. `make`
138 changes: 50 additions & 88 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,106 +1,68 @@
SHELL := bash
.ONESHELL:
.SHELLFLAGS := -eu -o pipefail -c
.DELETE_ON_ERROR:
.SECONDEXPANSION:
.SECONDARY:
include make-common.mk

ifeq ($(origin .RECIPEPREFIX), undefined)
$(error This Make does not support .RECIPEPREFIX. Please use GNU Make 4.0 or later)
endif
.RECIPEPREFIX = >
NEO4J_BASE_IMAGE?="openjdk:11-jdk-slim"

ifndef NEO4J_VERSION
$(error NEO4J_VERSION is not set)
endif
# Use make test TESTS='<pattern>' to run specific tests
# e.g. `make test TESTS='TestCausalCluster'` or `make test TESTS='*Cluster*'`
# the value of variable is passed to the maven test property. For more info see https://maven.apache.org/surefire/maven-surefire-plugin/examples/single-test.html
# by default this is empty which means all tests will be run
TESTS?=""

tarball = neo4j-$(1)-$(2)-unix.tar.gz
dist_site := http://dist.neo4j.org
series := $(shell echo "$(NEO4J_VERSION)" | sed -E 's/^([0-9]+\.[0-9]+)\..*/\1/')

all: out/enterprise/.sentinel out/community/.sentinel
all: test
.PHONY: all

test: test-community test-enterprise
test: test-enterprise test-community
.PHONY: test

out/%/.sentinel: tmp/image-%/.sentinel tmp/.tests-pass-%
> mkdir -p $(@D)
> cp -r $(<D)/* $(@D)
> touch $@
test-enterprise: build-enterprise
> mvn test -Dimage=$$(cat tmp/.image-id-enterprise) -Dadminimage=$$(cat tmp/.image-id-neo4j-admin-enterprise) -Dedition=enterprise -Dversion=$(NEO4JVERSION) -Dtest=$(TESTS)
.PHONY: test-enterprise

tmp/.tests-pass-%: tmp/.image-id-% $(shell find test -name 'test-*') $(shell find test -name '*.yml') $(shell find test -name '*.sh')
> mkdir -p $(@D)
> image_id=$$(cat $<)
> for test in $(filter test/test-%,$^); do
> echo "Running $${test}"
> "$${test}" "$${image_id}" "${series}" "$*"
> done
> touch $@
test-community: build-community
> mvn test -Dimage=$$(cat tmp/.image-id-community) -Dadminimage=$$(cat tmp/.image-id-neo4j-admin-community) -Dedition=community -Dversion=$(NEO4JVERSION) -Dtest=$(TESTS)
.PHONY: test-community

# just build the images, don't test or package
build: build-community build-enterprise
.PHONY: build

build-community: tmp/.image-id-community tmp/.image-id-neo4j-admin-community tmp/devenv-community.env
.PHONY: build-community

build-enterprise: tmp/.image-id-enterprise tmp/.image-id-neo4j-admin-enterprise tmp/devenv-enterprise.env
.PHONY: build-enterprise

tmp/devenv-%.env: tmp/.image-id-% tmp/.image-id-neo4j-admin-%
> echo "NEO4JVERSION=$(NEO4JVERSION)" > ${@}
> echo "NEO4J_IMAGE=$$(cat tmp/.image-id-${*})" >> ${@}
> echo "NEO4JADMIN_IMAGE=$$(cat tmp/.image-id-neo4j-admin-${*})" >> ${@}
> echo "NEO4J_EDITION=${*}" >> ${@}

# create release images and loadable images
package: package-community package-enterprise
.PHONY: package

package-community: tmp/.image-id-community tmp/.image-id-neo4j-admin-community out/community/.sentinel
> mkdir -p out
> docker tag $$(cat $<) neo4j:$(NEO4JVERSION)
> docker save neo4j:$(NEO4JVERSION) > out/neo4j-community-$(NEO4JVERSION)-docker-loadable.tar

package-enterprise: tmp/.image-id-enterprise tmp/.image-id-neo4j-admin-enterprise out/enterprise/.sentinel
> mkdir -p out
> docker tag $$(cat $<) neo4j:$(NEO4JVERSION)-enterprise
> docker save neo4j:$(NEO4JVERSION)-enterprise > out/neo4j-enterprise-$(NEO4JVERSION)-docker-loadable.tar

# create image from local build context
tmp/.image-id-%: tmp/local-context-%/.sentinel
> mkdir -p $(@D)
> image=test/$$RANDOM
> docker build --tag=$$image \
--build-arg="NEO4J_URI=file:///tmp/$(call tarball,$*,$(NEO4J_VERSION))" \
--build-arg="NEO4J_URI=file:///tmp/$(call tarball,$*,$(NEO4JVERSION))" \
$(<D)
> echo -n $$image >$@

tmp/local-context-%/.sentinel: tmp/image-%/.sentinel in/$(call tarball,%,$(NEO4J_VERSION))
> rm -rf $(@D)
# copy the releaseable version of the image to the output folder.
out/%/.sentinel: tmp/image-%/.sentinel
> mkdir -p $(@D)
> cp -r $(<D)/* $(@D)
> cp $(filter %.tar.gz,$^) $(@D)/local-package
> touch $@

tmp/image-%/.sentinel: src/$(series)/Dockerfile src/$(series)/docker-entrypoint.sh \
in/$(call tarball,%,$(NEO4J_VERSION))
> mkdir -p $(@D)
> cp $(filter %/docker-entrypoint.sh,$^) $(@D)/docker-entrypoint.sh
> sha=$$(shasum --algorithm=256 $(filter %.tar.gz,$^) | cut -d' ' -f1)
> <$(filter %/Dockerfile,$^) sed \
-e "s|%%NEO4J_SHA%%|$${sha}|" \
-e "s|%%NEO4J_TARBALL%%|$(call tarball,$*,$(NEO4J_VERSION))|" \
-e "s|%%NEO4J_EDITION%%|$*|" \
-e "s|%%NEO4J_DIST_SITE%%|$(dist_site)|" \
>$(@D)/Dockerfile
> mkdir -p $(@D)/local-package
> touch $(@D)/local-package/.sentinel
> touch $@

run = trapping-sigint \
docker run --publish 7474:7474 --publish 7687:7687 \
--env=NEO4J_ACCEPT_LICENSE_AGREEMENT=yes \
--env=NEO4J_AUTH=neo4j/foo --rm $$(cat $1)
build-enterprise: tmp/.image-id-enterprise
> @echo "Neo4j $(NEO4J_VERSION)-enterprise available as: $$(cat $<)"
build-community: tmp/.image-id-community
> @echo "Neo4j $(NEO4J_VERSION)-community available as: $$(cat $<)"
run-enterprise: tmp/.image-id-enterprise
> $(call run,$<)
run-community: tmp/.image-id-community
> $(call run,$<)
test-enterprise: tmp/.tests-pass-enterprise
test-community: tmp/.tests-pass-community
.PHONY: run-enterprise run-community build-enterprise build-community test-enterprise test-community

fetch_tarball = curl --fail --silent --show-error --location --remote-name \
$(dist_site)/$(call tarball,$(1),$(NEO4J_VERSION))

cache: in/neo4j-%-$(NEO4J_VERSION)-unix.tar.gz
.PHONY: cache

in/neo4j-community-$(NEO4J_VERSION)-unix.tar.gz:
> mkdir -p in
> cd in
> $(call fetch_tarball,community)

in/neo4j-enterprise-$(NEO4J_VERSION)-unix.tar.gz:
> mkdir -p in
> cd in
> $(call fetch_tarball,enterprise)

clean:
> rm -rf tmp
> rm -rf out
.PHONY: clean
> touch $@
Loading