Ignore:
Timestamp:
07/16/13 23:31:35 (11 years ago)
Author:
psniegowski
Message:

HIGHLIGHTS:

for Joinables running

CHANGELOG:
Add WorkPackageLogic? and classes representing prime experiment state.

Add classes for PrimeExperiment? state.

Extract single netload routine in Simulator.

Working netload with dummy content in PrimeExperiment?.

More development with NetLoadSaveLogic? and PrimeExperiment?.

Improvement around prime.

Improve BufferedDispatcher?.isActive logic.

Add prime-all.xml configuration.

Manual connecting to existing simulators from GUI.

Guard in SimulatorConnector? against expdef mismatch.

Guard against empty target dispatcher in BufferedDispatcher?.

Make BufferedDispatcher? a Dispatcher (and Joinable).

Minor improvements.

Done StackedJoinable?, improve Experiment.

Develop StackedJoinable?.

Add StackedJoinable? utility joinables controller.

Add dependency on apache-commons-lang.

Add ready ListChange? on Simulators.

Improve hints in ListChange?.

Several improvements.

Found bug with dispatching in Experiment.

Minor improvements.

Fix bug with early finishing Server.

Many changes in Dispatching.

Fix bug with connection.

Do not obfuscate log with socket related exceptions.

Add SocketClosedException?.

Add SimulatorConnector?.

Work out conception of experiment composing of logics building blocks.

Rename SinkInterface? to Sink.

Move saving of Accesses into AccessOperations?.

Some improvements to Experiment.

Improve joinables.

Fix issue with joinables closing.

Add direct and managed consoles to popup menu.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • java/main/src/main/java/com/framsticks/hosting/Server.java

    r101 r102  
    3737        protected ServerSocket acceptSocket;
    3838        protected Tree hosted;
    39         protected final JoinableCollection<ClientAtServer> clients = new JoinableCollection<ClientAtServer>();
     39        protected final JoinableCollection<ClientAtServer> clients = new JoinableCollection<ClientAtServer>(JoinableCollection.FinishPolicy.Never);
    4040
    4141        public static class Accept {
     
    6868        }
    6969
    70         @Override
    71         protected void joinableInterrupt() {
    72                 Dispatching.drop(acceptThread, this);
    73                 Dispatching.drop(hosted, this);
    74                 Dispatching.drop(clients, this);
    75                 try {
    76                         acceptSocket.close();
    77                 } catch (IOException e) {
    78                         log.debug("exception caught during socket closing: ", e);
    79                 }
    80                 finishJoinable();
    81         }
    8270
    8371        /**
     
    10189        public void childChangedState(Joinable joinable, JoinableState state) {
    10290                proceedToState(state);
    103         }
    104 
    105         @Override
    106         protected void joinableStart() {
    107                 Dispatching.use(acceptThread, this);
    108                 Dispatching.use(hosted, this);
    109                 Dispatching.use(clients, this);
    110                 try {
    111                         acceptSocket = new ServerSocket();
    112                 } catch (IOException e) {
    113                         throw new FramsticksException().msg("failed to create server socket").cause(e);
    114                 }
    115                 tryBind(0);
    11691        }
    11792
     
    175150        }
    176151
     152
     153        @Override
     154        protected void joinableStart() {
     155                Dispatching.use(acceptThread, this);
     156                Dispatching.use(hosted, this);
     157                Dispatching.use(clients, this);
     158                try {
     159                        acceptSocket = new ServerSocket();
     160                        acceptSocket.setReuseAddress(true);
     161                } catch (IOException e) {
     162                        throw new FramsticksException().msg("failed to create server socket").cause(e);
     163                }
     164                tryBind(0);
     165        }
     166
     167        @Override
     168        protected void joinableInterrupt() {
     169                Dispatching.drop(acceptThread, this);
     170                Dispatching.drop(hosted, this);
     171                Dispatching.drop(clients, this);
     172
     173                try {
     174                        acceptSocket.close();
     175                } catch (IOException e) {
     176                        log.debug("exception caught during socket closing: ", e);
     177                }
     178
     179                finishJoinable();
     180        }
     181
    177182        @Override
    178183        protected void joinableFinish() {
Note: See TracChangeset for help on using the changeset viewer.