Changeset 10
- Timestamp:
- 02/13/20 16:30:54 (5 years ago)
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
pom.xml
r9 r10 6 6 <artifactId>runserver</artifactId> 7 7 <packaging>war</packaging> 8 <version>1. 2.0</version>8 <version>1.3.0</version> 9 9 <name>runserver Maven Webapp</name> 10 10 <url>http://maven.apache.org</url> -
src/main/java/geniusweb/runserver/RunNego.java
r8 r10 38 38 /** 39 39 * @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse 40 * response). Returns 41 * <ul> 42 * <li>URL with websocket address to contact the now running party. 43 * <li>SC_NOT_FOUND (404) if attempt is made to access non-running 44 * party. 45 * <li>SC_SERVICE_UNAVAILABLE (503) if there are no free slots to run 46 * the party. 47 * <li>SC_EXPECTATION_FAILED (417) if something else goes wrong during 48 * instantiating the party (then see logs for more details) 49 * </ul> 40 * response). 41 * 42 * @return the ID of the new started run. Or SC_BAD_REQUEST if the request 43 * can not be processed. 50 44 */ 51 45 @Override … … 65 59 } 66 60 log.log(Level.INFO, "request to run Nego: " + settings); 67 RunningNego session= new RunningNego(settings,61 RunningNego running = new RunningNego(settings, 68 62 RunningNegotiationsRepo.instance(), log); 69 session.start();63 running.start(); 70 64 // set content type to prevent some browsers 71 65 // trying to parse this (eg as XML) 72 66 response.setContentType("application/json"); 73 response.getWriter().append( session.getID());67 response.getWriter().append(running.getID()); 74 68 } 75 69 -
src/main/webapp/newsession.xhtml
r9 r10 29 29 <br /> Domain/Profile Server: 30 30 <input type="url" name="url" id="profilesserverurl" 31 value="localhost:8080/profilesserver-1. 2.0"31 value="localhost:8080/profilesserver-1.3.0" 32 32 pattern=".*:[0-9]+/profilesserver" size="30" 33 33 onchange="connectDomain()"> </input> … … 43 43 <br /> <b>Participants</b> <br /> Parties Server: <input type="url" 44 44 name="url" id="partiesserverurl" 45 value="localhost:8080/partiesserver-1. 2.0"45 value="localhost:8080/partiesserver-1.3.0" 46 46 pattern=".*:[0-9]+/partiesserver" size="30" 47 47 onchange="connectParties()"> </input> <br /> <br /> <b>Party … … 273 273 refresh table: copy all parties elements in there. 274 274 Typically parties is something like 275 [{"uri":"http:130.161.180.1:8080/partiesserver/run/randomparty-1. 2.0",275 [{"uri":"http:130.161.180.1:8080/partiesserver/run/randomparty-1.3.0", 276 276 "capabilities":{"protocols":["SAOP"]}, 277 277 "description":"places random bids until it can accept an offer with utility >0.6", 278 "id":"randomparty-1. 2.0",278 "id":"randomparty-1.3.0", 279 279 "partyClass":"geniusweb.exampleparties.randomparty.RandomParty"}, 280 280 ...] … … 571 571 function init() { 572 572 selectProtocol(); 573 document.getElementById("partiesserverurl").value =window.location.hostname+":8080/partiesserver-1. 2.0"574 document.getElementById("profilesserverurl").value =window.location.hostname+":8080/profilesserver-1. 2.0"573 document.getElementById("partiesserverurl").value =window.location.hostname+":8080/partiesserver-1.3.0" 574 document.getElementById("profilesserverurl").value =window.location.hostname+":8080/profilesserver-1.3.0" 575 575 connectDomain(); 576 576 connectParties(); -
src/main/webapp/newtournament.xhtml
r9 r10 47 47 <div id="box" class="box"> 48 48 <br /> Domain/Profile Server: <input type="url" name="url" 49 id="profilesserverurl" value="localhost:8080/profilesserver-1. 2.0"49 id="profilesserverurl" value="localhost:8080/profilesserver-1.3.0" 50 50 pattern=".*:[0-9]+/profilesserver" size="30" 51 51 onchange="connectDomain()"> </input> <br /> Domain: <select … … 76 76 <div id="box" class="box"> 77 77 <br /> Parties Server: <input type="url" name="url" 78 id="partiesserverurl" value="localhost:8080/partiesserver-1. 2.0"78 id="partiesserverurl" value="localhost:8080/partiesserver-1.3.0" 79 79 pattern=".*:[0-9]+/partiesserver" size="30" 80 80 onchange="connectParties()"> </input> <br /> <br /> … … 423 423 */ 424 424 function init() { 425 document.getElementById("partiesserverurl").value =window.location.hostname+":8080/partiesserver-1. 2.0";426 document.getElementById("profilesserverurl").value =window.location.hostname+":8080/profilesserver-1. 2.0";425 document.getElementById("partiesserverurl").value =window.location.hostname+":8080/partiesserver-1.3.0"; 426 document.getElementById("profilesserverurl").value =window.location.hostname+":8080/profilesserver-1.3.0"; 427 427 428 428 -
src/main/webapp/plotlog.xhtml
r9 r10 93 93 var profs=json['partyprofiles']; 94 94 for (var party in profs) { 95 partyprofiles[party]=profs[party]['profile'] ;95 partyprofiles[party]=profs[party]['profile'].split('?',1)[0]; // hacky, remove complete query. 96 96 } 97 97
Note:
See TracChangeset
for help on using the changeset viewer.