-
Notifications
You must be signed in to change notification settings - Fork 0
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
Spalloc Server integration testing #76
Open
dkfellows
wants to merge
24
commits into
main
Choose a base branch
from
spalloc-server
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
20c5ea4
jenkins trigger
dkfellows 14110a2
Change to use spalloc: URLs
dkfellows 335ca56
Switch to the new server in compat mode
dkfellows 718490d
Try to avoid using internal IP address for spalloc
dkfellows 718e72d
Merge branch 'main' into spalloc-server
dkfellows 004ded5
Merge branch 'spalloc-server' of
rowleya 9d6d6cc
Try jenkins direct
rowleya 0d8e731
Get the URL right!
rowleya 0f6c2be
Fix missing folder
rowleya c8e9a74
Test one-by-one
rowleya 3b9928d
Missing space
rowleya 8f43237
Try a different capture method
rowleya 3d29fd7
A different way to get output...
rowleya 8008b2b
Revert to default
rowleya 113a2c4
Add setproctitle so we know what test is running where
rowleya 10afa9e
Fix install
rowleya 2d2ceb2
Revert back for main tests
rowleya 3259716
Try without proxy mode
rowleya 141cf1b
Try with proxy now
rowleya 1665b52
Merge branch 'main' into spalloc-server-jdbc
rowleya 43ab1be
Check normal master again
rowleya 7225665
Merge branch 'spalloc-server-jdbc' of
rowleya 02b7cec
With proxy and new spalloc
rowleya 85b28c2
Merge branch 'main' into spalloc-server-jdbc
rowleya File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -134,25 +134,9 @@ pipeline { | |
stage('Before Script') { | ||
steps { | ||
// Write a sPyNNaker config file for spalloc and java use | ||
sh 'echo "[Machine]" > ~/.spynnaker.cfg' | ||
sh 'echo "spalloc_server = spalloc://[email protected]:22246" >> ~/.spynnaker.cfg' | ||
sh 'echo "enable_advanced_monitor_support = True" >> ~/.spynnaker.cfg' | ||
sh 'echo "[Java]" >> ~/.spynnaker.cfg' | ||
sh 'echo "use_java = True" >> ~/.spynnaker.cfg' | ||
sh 'echo "java_call=/usr/bin/java" >> ~/.spynnaker.cfg' | ||
sh 'echo "java_properties=-Dspinnaker.parallel_tasks=10" >> ~/.spynnaker.cfg' | ||
sh 'printf "java_spinnaker_path=" >> ~/.spynnaker.cfg' | ||
sh 'pwd >> ~/.spynnaker.cfg' | ||
makeConfig('~/.spynnaker.cfg') | ||
// Write a GFE config file for spalloc and java use | ||
sh 'echo "[Machine]" > ~/.spiNNakerGraphFrontEnd.cfg' | ||
sh 'echo "spalloc_server = spalloc://[email protected]:22246" >> ~/.spiNNakerGraphFrontEnd.cfg' | ||
sh 'echo "enable_advanced_monitor_support = True" >> ~/.spiNNakerGraphFrontEnd.cfg' | ||
sh 'echo "[Java]" >> ~/.spiNNakerGraphFrontEnd.cfg' | ||
sh 'echo "use_java = True" >> ~/.spiNNakerGraphFrontEnd.cfg' | ||
sh 'echo "java_call=/usr/bin/java" >> ~/.spiNNakerGraphFrontEnd.cfg' | ||
sh 'echo "java_properties=-Dspinnaker.parallel_tasks=10" >> ~/.spiNNakerGraphFrontEnd.cfg' | ||
sh 'printf "java_spinnaker_path=" >> ~/.spiNNakerGraphFrontEnd.cfg' | ||
sh 'pwd >> ~/.spiNNakerGraphFrontEnd.cfg' | ||
makeConfig('~/.spiNNakerGraphFrontEnd.cfg') | ||
// Prepare coverage | ||
sh 'rm -f coverage.xml' | ||
sh 'rm -f .coverage' | ||
|
@@ -271,10 +255,28 @@ pipeline { | |
} | ||
} | ||
|
||
def makeConfig(String filename) { | ||
//def spalloc = 'spalloc://[email protected]:22246' | ||
def spalloc = 'spalloc://[email protected]:22246' | ||
def javaPath = '/usr/bin/java' | ||
def numThreads = '10' | ||
|
||
sh 'echo "[Machine]" > ' + filename | ||
sh 'echo "spalloc_server = ' + spalloc + '" >> ' + filename | ||
sh 'echo "enable_advanced_monitor_support = True" >> ' + filename | ||
|
||
sh 'echo "[Java]" >> ' + filename | ||
sh 'echo "use_java = True" >> ' + filename | ||
sh 'echo "java_call=' + javaPath + '" >> ' + filename | ||
sh 'echo "java_properties=-Dspinnaker.parallel_tasks=' + numThreads + '" >> ' + filename | ||
sh 'printf "java_spinnaker_path=" >> ' + filename | ||
sh 'pwd >> ' + filename | ||
} | ||
|
||
def run_pytest(String tests, int timeout, String results, String covfile, String threads) { | ||
def resfile = 'junit/' + results + '.xml' | ||
covfile += '_cov.xml' | ||
sh 'echo "<testsuite tests="0"></testsuite>" > ' + resfile | ||
writeFile file: resfile, text: '<testsuite tests="0"></testsuite>' | ||
sh 'py.test ' + tests + | ||
' -rs -n ' + threads + ' --forked --show-progress --cov-config=.coveragerc --cov-branch ' + | ||
'--cov spynnaker8 --cov spynnaker --cov spinn_front_end_common --cov pacman ' + | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note - the internal IP address is used as both the Jenkins server and the machine have addresses on this internal network. Using the external IP means that traffic is likely to flow out of and in to the machine room i.e. the tests become more dependent on the networking state outside of the machine room.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, but tests fail catastrophically if I do that. I'm guessing there's some sort of iptables issue causing trouble. (Configuring
/etc/hosts
is better than using hardcoded IP addresses.)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This probably means that the service isn't listening on all IP addresses. I believe that you can fix this by adding:
address: 0.0.0.0
to the yml file here (or whereever the actual config comes from):
https://github.com/SpiNNakerManchester/JavaSpiNNaker/blob/spalloc-server/SpiNNaker-allocserv/src/main/resources/application.yml#L57