private void createSessionRegionOnServers() { // Create the RegionConfiguration RegionConfiguration configuration = createRegionConfiguration(); // Send it to the server tier Execution execution = FunctionService.onServer(this.cache).setArguments(configuration); ResultCollector collector = execution.execute(CreateRegionFunction.ID); // Verify the region was successfully created on the servers List<RegionStatus> results = (List<RegionStatus>) collector.getResult(); for (RegionStatus status : results) { if (status == RegionStatus.INVALID) { StringBuilder builder = new StringBuilder(); builder .append( "An exception occurred on the server while attempting to create or validate region named ") .append(getSessionManager().getRegionName()) .append(". See the server log for additional details."); throw new IllegalStateException(builder.toString()); } } }
private void createSessionRegionOnServers() { // Create the RegionConfiguration RegionConfiguration configuration = createRegionConfiguration(); // Send it to the server tier Execution execution = FunctionService.onServer(this.cache).setArguments(configuration); ResultCollector collector = execution.execute(CreateRegionFunction.ID); // Verify the region was successfully created on the servers List<RegionStatus> results = (List<RegionStatus>) collector.getResult(); for (RegionStatus status : results) { if (status == RegionStatus.INVALID) { StringBuilder builder = new StringBuilder(); builder .append( "An exception occurred on the server while attempting to create or validate region named ") .append(getSessionManager().getRegionName()) .append(". See the server log for additional details."); throw new IllegalStateException(builder.toString()); } } }