conflict_resolution
stringlengths
27
16k
<<<<<<< import java.util.List; import net.minecraft.command.CommandException; ======= >>>>>>> import net.minecraft.command.CommandException; <<<<<<< import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; ======= import net.minecraftforge.event.entity.player.PlayerInteractEvent.Action; >>>>>>> import net.minecraftforge.event.entity.player.PlayerInteractEvent.Action; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; <<<<<<< public class CommandBind extends FEcmdModuleCommands ======= import cpw.mods.fml.common.eventhandler.SubscribeEvent; public class CommandBind extends ParserCommandBase >>>>>>> public class CommandBind extends ParserCommandBase <<<<<<< public void processCommandPlayer(EntityPlayerMP sender, String[] args) throws CommandException ======= @SuppressWarnings("unchecked") public void parse(CommandParserArgs arguments) >>>>>>> @SuppressWarnings("unchecked") public void parse(CommandParserArgs arguments) throws CommandException <<<<<<< ItemStack is = sender.inventory.getCurrentItem(); if (!is.hasTagCompound()) is.setTagCompound(new NBTTagCompound()); if (args[0].equalsIgnoreCase("clear")) { is.getTagCompound().removeTag("FEbinding"); NBTTagCompound display = is.getTagCompound().getCompoundTag("display"); display.setTag("Lore", new NBTTagList()); } else { StringBuilder cmd = new StringBuilder(); for (int i = 1; i < args.length; i++) { cmd.append(args[i] + " "); } ======= String command = arguments.toString(); bindTag.setString(side, command); >>>>>>> String command = arguments.toString(); bindTag.setString(side, command); <<<<<<< ChatOutputHandler.chatConfirmation(sender, "Command bound to object."); } } @Override public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { if (args.length == 1) { return getListOfStringsMatchingLastWord(args, "left", "right", "clear"); ======= lore.appendTag(loreTag); display.setTag("Lore", lore); tag.setTag("display", display); >>>>>>> lore.appendTag(loreTag); display.setTag("Lore", lore); tag.setTag("display", display);
<<<<<<< ======= public static Gson createDefaultGson() { GsonBuilder builder = new GsonBuilder(); return builder.create(); } >>>>>>>
<<<<<<< LeaderBoardStore store = new LeaderBoardStore(); ======= final CommentFetcher commentFetcher = new CommentFetcher(gitHubApiFacade, configuration.getOrganization(), configuration.getDaysBack()); final LeaderBoardStore store = new LeaderBoardStore(); >>>>>>> final LeaderBoardStore store = new LeaderBoardStore(); <<<<<<< environment.manage(new RecurringCommentFetcher(getFetchers(configuration, gitHubApiFacade), store, configuration.getRefreshRateMinutes(), TimeUnit.MINUTES)); } private Map<String, CommentFetcher> getFetchers(LeaderBoardServerConfiguration configuration, GitHubApiFacade gitHubApiFacade) { return ImmutableMap.of( "today", new CommentFetcher(gitHubApiFacade, configuration.getOrganization(), 1), "week", new CommentFetcher(gitHubApiFacade, configuration.getOrganization(), 7), "month", new CommentFetcher(gitHubApiFacade, configuration.getOrganization(), 30) ); ======= environment.managedScheduledExecutorService("comment-fetcher", 1).scheduleAtFixedRate(new Runnable() { @Override public void run() { store.set(commentFetcher.getCommentsByUser()); } }, 0, configuration.getRefreshRateMinutes(), TimeUnit.MINUTES); >>>>>>> startFetchers(buildRunnables(store, getFetchers(configuration, gitHubApiFacade)), environment, configuration.getRefreshRateMinutes()); } private Iterable<Runnable> buildRunnables(final LeaderBoardStore store, Map<String, CommentFetcher> fetchers) { return Iterables.transform(fetchers.entrySet(), new Function<Map.Entry<String, CommentFetcher>, Runnable>() { @Override public Runnable apply(final Map.Entry<String, CommentFetcher> fetcherEntry) { return new Runnable() { @Override public void run() { store.set(fetcherEntry.getKey(), fetcherEntry.getValue().getCommentsByUser()); } }; } }); } private void startFetchers(Iterable<Runnable> fetchers, Environment environment, int refreshRateMinutes) { for (final Runnable fetcher : fetchers) { environment.managedScheduledExecutorService("comment-fetcher", 1) .scheduleAtFixedRate(fetcher, 0, refreshRateMinutes, TimeUnit.MINUTES); } } private Map<String, CommentFetcher> getFetchers(LeaderBoardServerConfiguration configuration, GitHubApiFacade gitHubApiFacade) { return ImmutableMap.of( "today", new CommentFetcher(gitHubApiFacade, configuration.getOrganization(), 1), "week", new CommentFetcher(gitHubApiFacade, configuration.getOrganization(), 7), "month", new CommentFetcher(gitHubApiFacade, configuration.getOrganization(), 30) );
<<<<<<< emitScrollEvent(ScrollEventType.BEGIN_DRAG, 0, 0); ======= if (scrollEnabled == false) return false; ReactScrollViewHelper.emitScrollBeginDragEvent(this); >>>>>>> if (scrollEnabled == false) return false; emitScrollEvent(ScrollEventType.BEGIN_DRAG, 0, 0);
<<<<<<< } ======= } >>>>>>> } <<<<<<< net = new NetStreamReceiver("localhost", 2001, false); ======= net = new NetStreamReceiver("localhost", 2001, debug); >>>>>>> net = new NetStreamReceiver("localhost", 2001, debug); <<<<<<< ======= >>>>>>> <<<<<<< Thread.sleep(150); ======= t.join(); >>>>>>> t.join(); <<<<<<< net = new NetStreamReceiver("localhost", 2002, false); ======= net = new NetStreamReceiver("localhost", 2002, debug); >>>>>>> net = new NetStreamReceiver("localhost", 2002, debug); <<<<<<< Graph g = new MultiGraph(id + prefix); ======= Graph g = new MultiGraph(id + prefix); >>>>>>> Graph g = new MultiGraph(id + prefix); <<<<<<< ======= >>>>>>> <<<<<<< ======= try { nsc.close(); } catch (IOException e1) { } >>>>>>> try { nsc.close(); } catch (IOException e1) { }
<<<<<<< @Override() ======= >>>>>>> @Override() <<<<<<< @Override() ======= >>>>>>> @Override() <<<<<<< @Override() ======= >>>>>>> @Override()
<<<<<<< ======= private static final Map<String, List<AnnotatedPropertyInfo>> RenderingTargetFieldsMap = new ConcurrentHashMap<>(); @ContextData(name = FormFlowConstants.FORM_STEP_TRACE_MAP) protected Map<String, Object> formTraceMap; @ContextData(name = FormFlowConstants.FORM_STEP_TRACE_MAP_STR, scope = Context.SCOPE_DEFAULT) protected String formTraceMapStr; @ContextData(name = FormFlowConstants.FORM_STEP_RENDER_TARGET) protected String renderTargetStep; >>>>>>> <<<<<<< private FieldRenderingInfo getRenderingInfo(AnnotatedPropertyInfo f, Integer[] indexes) { ======= private List<AnnotatedPropertyInfo> retrieveRenderTargetFieldList(Object form) { List<AnnotatedPropertyInfo> list = RenderingTargetFieldsMap.get(form.getClass().getName()); if (list == null) { list = new LinkedList<AnnotatedPropertyInfo>(AnnotatedPropertyUtil.retrieveProperties(form.getClass())); Iterator<AnnotatedPropertyInfo> it = list.iterator(); while (it.hasNext()) { // remove all the non form field properties if (it.next().getAnnotation(FormField.class) == null) { it.remove(); } } if (Configuration.getConfiguration().isCacheEnable()) { RenderingTargetFieldsMap.put(form.getClass().getName(), list); } } return list; } private FieldRenderingInfo getRenderingInfo(AnnotatedPropertyInfo f, int cascadeFormArrayIndex) { >>>>>>> private FieldRenderingInfo getRenderingInfo(AnnotatedPropertyInfo f, Integer[] indexes) {
<<<<<<< import com.romraider.Settings; import com.romraider.editor.ecu.ECUEditor; import com.romraider.logger.ecu.definition.EcuDataConvertor; import com.romraider.logger.ecu.definition.EcuParameter; import com.romraider.logger.ecu.definition.EcuSwitch; import com.romraider.logger.ecu.definition.ExternalData; import com.romraider.logger.ecu.definition.LoggerData; import com.romraider.logger.ecu.ui.DataRegistrationBroker; import com.romraider.logger.ecu.ui.tab.DynoChartPanel; ======= import static com.romraider.logger.car.util.SpeedCalculator.calculateMph; import static com.romraider.logger.car.util.SpeedCalculator.calculateRpm; >>>>>>> import com.romraider.Settings; import com.romraider.editor.ecu.ECUEditor; import com.romraider.logger.ecu.definition.EcuDataConvertor; import com.romraider.logger.ecu.definition.EcuParameter; import com.romraider.logger.ecu.definition.EcuSwitch; import com.romraider.logger.ecu.definition.ExternalData; import com.romraider.logger.ecu.definition.LoggerData; import com.romraider.logger.ecu.ui.DataRegistrationBroker; import static com.romraider.logger.car.util.SpeedCalculator.calculateMph; import static com.romraider.logger.car.util.SpeedCalculator.calculateRpm; <<<<<<< ======= import javax.swing.ButtonGroup; import javax.swing.DefaultComboBoxModel; import javax.swing.JButton; import javax.swing.JCheckBox; import javax.swing.JComboBox; import javax.swing.JComponent; import javax.swing.JFileChooser; import javax.swing.JLabel; import javax.swing.JPanel; import javax.swing.JRadioButton; import javax.swing.JTextField; import javax.swing.JToggleButton; import javax.swing.border.TitledBorder; import javax.swing.text.JTextComponent; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import org.apache.log4j.Logger; import org.w3c.dom.Document; import org.w3c.dom.Element; import org.w3c.dom.Node; import org.w3c.dom.NodeList; import org.xml.sax.SAXException; import org.xml.sax.SAXParseException; import com.romraider.editor.ecu.ECUEditor; import com.romraider.logger.ecu.definition.EcuDataConvertor; import com.romraider.logger.ecu.definition.EcuParameter; import com.romraider.logger.ecu.definition.EcuSwitch; import com.romraider.logger.ecu.definition.ExternalData; import com.romraider.logger.ecu.definition.LoggerData; import com.romraider.logger.ecu.ui.DataRegistrationBroker; >>>>>>> <<<<<<< private double distance; private long lastET; private double[] etResults = new double[12]; ======= private double distance = 0; private long lastET = 0; private final double[] etResults = new double[12]; >>>>>>> private double distance; private long lastET; private double[] etResults = new double[12];
<<<<<<< private DruidScanQuery(@NonNull DataSource dataSource, DruidFilter filter, Integer batchSize, @NonNull List<Interval> intervals, List<String> columns, ResultFormat resultFormat, Long limit, Boolean legacy, Context context) { ======= private DruidScanQuery(@NonNull String dataSource, List<DruidVirtualColumn> virtualColumns, DruidFilter filter, Integer batchSize, @NonNull List<Interval> intervals, List<String> columns, ResultFormat resultFormat, Long limit, Boolean legacy, Context context) { this.virtualColumns = virtualColumns; >>>>>>> private DruidScanQuery(@NonNull DataSource dataSource, List<DruidVirtualColumn> virtualColumns, DruidFilter filter, Integer batchSize, @NonNull List<Interval> intervals, List<String> columns, ResultFormat resultFormat, Long limit, Boolean legacy, Context context) { this.virtualColumns = virtualColumns;
<<<<<<< import in.zapr.druid.druidry.query.config.Context; import in.zapr.druid.druidry.query.config.Interval; ======= import in.zapr.druid.druidry.Context; import in.zapr.druid.druidry.Interval; import in.zapr.druid.druidry.dataSource.DataSource; >>>>>>> import in.zapr.druid.druidry.query.config.Context; import in.zapr.druid.druidry.query.config.Interval; import in.zapr.druid.druidry.dataSource.DataSource;
<<<<<<< private static AmplifyStateTracker sharedInstance; private static final int ONE_WEEK = 7; private static final int ONE_DAY = 1; ======= private static IAmplifyStateTracker sharedInstance; private static final int DEFAULT_USER_GAVE_POSITIVE_FEEDBACK_MAXIMUM_COUNT = 7; private static final int DEFAULT_INSTALL_TIME_COOLDOWN_DAYS = 7; private static final int DEFAULT_LAST_UPDATE_TIME_COOLDOWN_DAYS = 7; private static final int DEFAULT_USER_DECLINED_CRITICAL_FEEDBACK_COOLDOWN_DAYS = 7; private static final int DEFAULT_USER_DECLINED_POSITIVE_FEEDBACK_COOLDOWN_DAYS = 7; private static final int DEFAULT_USER_GAVE_CRITICAL_FEEDBACK_COOLDOWN_DAYS = 7; >>>>>>> private static AmplifyStateTracker sharedInstance; private static final int DEFAULT_USER_GAVE_POSITIVE_FEEDBACK_MAXIMUM_COUNT = 7; private static final int DEFAULT_INSTALL_TIME_COOLDOWN_DAYS = 7; private static final int DEFAULT_LAST_UPDATE_TIME_COOLDOWN_DAYS = 7; private static final int DEFAULT_USER_DECLINED_CRITICAL_FEEDBACK_COOLDOWN_DAYS = 7; private static final int DEFAULT_USER_DECLINED_POSITIVE_FEEDBACK_COOLDOWN_DAYS = 7; private static final int DEFAULT_USER_GAVE_CRITICAL_FEEDBACK_COOLDOWN_DAYS = 7;
<<<<<<< public boolean canConsoleUseCommand() { return true; } @Override public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) ======= public List<String> addTabCompletionOptions(ICommandSender sender, String[] args) >>>>>>> public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos)
<<<<<<< /** * returns a bitset containing the selected indices * * @param selectionManager * @param va * @return */ private BitSet getSelectedIndices(SelectionManager selectionManager, VirtualArray va) { ======= /** * returns a bitset containing the selected indices * * @param selectionManager * @param va * @return */ private BitSet getSelectedIndices(SelectionManager selectionManager, VirtualArray va) { >>>>>>> /** * returns a bitset containing the selected indices * @param selectionManager * @param va * @return */ private BitSet getSelectedIndices(SelectionManager selectionManager, VirtualArray va) {
<<<<<<< /* * Copyright (C) 2012-2017 52°North Initiative for Geospatial Open Source ======= /** * Copyright (C) 2012-2017 52°North Initiative for Geospatial Open Source >>>>>>> /* * Copyright (C) 2012-2017 52°North Initiative for Geospatial Open Source <<<<<<< import org.n52.sos.ds.hibernate.entities.HibernateRelations.HasGeometry; import com.google.common.collect.Sets; ======= import org.n52.sos.ds.hibernate.entities.HibernateRelations.HasGeometry; >>>>>>> import org.n52.sos.ds.hibernate.entities.HibernateRelations.HasGeometry; import org.n52.sos.util.StringHelper; import com.google.common.collect.Sets; <<<<<<< private boolean mobile = false; private boolean insitu = true; ======= private boolean mobile = false; private boolean insitu = true; >>>>>>> private boolean mobile = false; private boolean insitu = true; private boolean mobile = false; private boolean insitu = true; <<<<<<< /** * @return the mobile */ public boolean isMobile() { return mobile; } /** * @return the mobile */ public boolean getMobile() { return mobile; } /** * @param mobile the mobile to set */ public void setMobile(boolean mobile) { this.mobile = mobile; } /** * @return the insitu */ public boolean isInsitu() { return insitu; } /** * @return the insitu */ public boolean getInsitu() { return insitu; } /** * @param insitu the insitu to set */ public void setInsitu(boolean insitu) { this.insitu = insitu; } ======= /** * @return the mobile */ public boolean isMobile() { return mobile; } /** * @return the mobile */ public boolean getMobile() { return mobile; } /** * @param mobile the mobile to set */ public void setMobile(boolean mobile) { this.mobile = mobile; } /** * @return the insitu */ public boolean isInsitu() { return insitu; } /** * @return the insitu */ public boolean getInsitu() { return insitu; } /** * @param insitu the insitu to set */ public void setInsitu(boolean insitu) { this.insitu = insitu; } >>>>>>> /** * @return the mobile */ public boolean isMobile() { return mobile; } /** * @return the mobile */ public boolean getMobile() { return mobile; } /** * @param mobile the mobile to set */ public void setMobile(boolean mobile) { this.mobile = mobile; } /** * @return the insitu */ public boolean isInsitu() { return insitu; } /** * @return the insitu */ public boolean getInsitu() { return insitu; } /** * @param insitu the insitu to set */ public void setInsitu(boolean insitu) { this.insitu = insitu; } /** * @return the mobile */ public boolean isMobile() { return mobile; } /** * @return the mobile */ public boolean getMobile() { return mobile; } /** * @param mobile the mobile to set */ public void setMobile(boolean mobile) { this.mobile = mobile; } /** * @return the insitu */ public boolean isInsitu() { return insitu; } /** * @return the insitu */ public boolean getInsitu() { return insitu; } /** * @param insitu the insitu to set */ public void setInsitu(boolean insitu) { this.insitu = insitu; }
<<<<<<< public PermissionLevel getPermissionLevel() { return PermissionLevel.OP; } @Override public void processCommandPlayer(MinecraftServer server, EntityPlayerMP sender, String[] args) throws CommandException ======= public void processCommandPlayer(EntityPlayerMP sender, String[] args) throws CommandException >>>>>>> public void processCommandPlayer(MinecraftServer server, EntityPlayerMP sender, String[] args) throws CommandException
<<<<<<< import java.util.Arrays; import java.util.concurrent.Callable; ======= >>>>>>> import java.util.Arrays; <<<<<<< if (!visible) return false; Display d = Display.getDefault(); final Composite p = canvas.asComposite(); boolean v; try { v = DisplayUtils.syncExec(d, new Callable<Boolean>() { @Override public Boolean call() throws Exception { return !p.isDisposed() && p.isVisible(); } }); } catch (Exception e) { v = true; } return v; ======= return visible && canvas.isVisible(); >>>>>>> return visible && canvas.isVisible();
<<<<<<< import net.minecraft.util.BlockPos; ======= import net.minecraft.util.MathHelper; >>>>>>> import net.minecraft.util.BlockPos; import net.minecraft.util.MathHelper; <<<<<<< import com.forgeessentials.util.output.ChatOutputHandler; ======= import com.forgeessentials.util.output.ChatOutputHandler; import com.forgeessentials.util.output.LoggingHandler; import cpw.mods.fml.common.FMLCommonHandler; import cpw.mods.fml.common.eventhandler.SubscribeEvent; import cpw.mods.fml.common.gameevent.TickEvent; >>>>>>> import com.forgeessentials.util.output.ChatOutputHandler; import com.forgeessentials.util.output.LoggingHandler; <<<<<<< super.func_180266_a(entity, yaw); ======= placeInExistingPortal(entity, x, y, z, rotationYaw); >>>>>>> func_180620_b(entity, yaw);
<<<<<<< /* * Copyright (C) 2012-2019 52°North Initiative for Geospatial Open Source ======= /** * Copyright (C) 2012-2020 52°North Initiative for Geospatial Open Source >>>>>>> /* * Copyright (C) 2012-2020 52°North Initiative for Geospatial Open Source
<<<<<<< import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.ObjectMapper; ======= import com.google.common.collect.Lists; >>>>>>> import com.google.common.collect.Lists; <<<<<<< ======= import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.ObjectMapper; import org.apache.commons.io.FileUtils; import org.apache.commons.io.FilenameUtils; >>>>>>> import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.ObjectMapper; import org.apache.commons.io.FileUtils; import org.apache.commons.io.FilenameUtils;
<<<<<<< import app.metatron.discovery.common.GlobalObjectMapper; import app.metatron.discovery.domain.dataprep.*; import app.metatron.discovery.domain.dataprep.PrepDataset.OP_TYPE; import app.metatron.discovery.domain.dataprep.exceptions.PrepErrorCodes; import app.metatron.discovery.domain.dataprep.exceptions.PrepException; import app.metatron.discovery.domain.dataprep.exceptions.PrepMessageKey; import app.metatron.discovery.domain.dataprep.teddy.*; import app.metatron.discovery.domain.dataprep.teddy.exceptions.IllegalColumnNameForHiveException; import app.metatron.discovery.domain.datasource.connection.DataConnection; import app.metatron.discovery.domain.datasource.connection.DataConnectionRepository; ======= import app.metatron.discovery.common.GlobalObjectMapper; import app.metatron.discovery.domain.dataprep.*; import app.metatron.discovery.domain.dataprep.PrepDataset.OP_TYPE; import app.metatron.discovery.domain.dataprep.exceptions.PrepErrorCodes; import app.metatron.discovery.domain.dataprep.exceptions.PrepException; import app.metatron.discovery.domain.dataprep.exceptions.PrepMessageKey; import app.metatron.discovery.domain.dataprep.teddy.*; import app.metatron.discovery.domain.dataprep.teddy.exceptions.IllegalColumnNameForHiveException; import app.metatron.discovery.domain.dataprep.teddy.exceptions.TransformExecutionFailedException; import app.metatron.discovery.domain.dataprep.teddy.exceptions.TransformTimeoutException; import app.metatron.discovery.domain.datasource.connection.DataConnection; import app.metatron.discovery.domain.datasource.connection.DataConnectionRepository; >>>>>>> import app.metatron.discovery.common.GlobalObjectMapper; import app.metatron.discovery.domain.dataprep.*; import app.metatron.discovery.domain.dataprep.PrepDataset.OP_TYPE; import app.metatron.discovery.domain.dataprep.exceptions.PrepErrorCodes; import app.metatron.discovery.domain.dataprep.exceptions.PrepException; import app.metatron.discovery.domain.dataprep.exceptions.PrepMessageKey; import app.metatron.discovery.domain.dataprep.teddy.*; import app.metatron.discovery.domain.dataprep.teddy.exceptions.IllegalColumnNameForHiveException; import app.metatron.discovery.domain.dataprep.teddy.exceptions.TransformExecutionFailedException; import app.metatron.discovery.domain.dataprep.teddy.exceptions.TransformTimeoutException; import app.metatron.discovery.domain.datasource.connection.DataConnection; import app.metatron.discovery.domain.datasource.connection.DataConnectionRepository; <<<<<<< import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.ObjectMapper; import com.google.common.collect.Lists; import com.google.common.collect.Maps; import org.apache.commons.io.FileUtils; import org.apache.commons.io.FilenameUtils; ======= import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.ObjectMapper; import com.google.common.collect.Maps; >>>>>>> import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.ObjectMapper; import com.google.common.collect.Maps; <<<<<<< import java.util.concurrent.TimeUnit; ======= >>>>>>> <<<<<<< switch (ssType) { case FILE: // CSVs are stored on HDFS first. (FILE dataset != FILE snapshot) map.put(PrepProperties.HADOOP_CONF_DIR, prepProperties.getHadoopConfDir()); break; case HDFS: map.put(PrepProperties.HADOOP_CONF_DIR, prepProperties.getHadoopConfDir()); break; case JDBC: // not implemented assert false : ssType.name(); break; case HIVE: map.put(PrepProperties.HADOOP_CONF_DIR, prepProperties.getHadoopConfDir()); ======= PrepDataset.IMPORT_TYPE importType = dataset.getImportTypeEnum(); boolean dsFile = (importType == PrepDataset.IMPORT_TYPE.FILE); boolean dsDb = (importType == PrepDataset.IMPORT_TYPE.DB); boolean dsHive = (importType == PrepDataset.IMPORT_TYPE.HIVE); >>>>>>> PrepDataset.IMPORT_TYPE importType = dataset.getImportTypeEnum(); boolean dsFile = (importType == PrepDataset.IMPORT_TYPE.FILE); boolean dsDb = (importType == PrepDataset.IMPORT_TYPE.DB); boolean dsHive = (importType == PrepDataset.IMPORT_TYPE.HIVE); <<<<<<< public Map<String,Object> getConfiguration(String wrangledDsId) { ======= // FIXME: just send static configurations. we do not need specific dataset info. public Map<String,Object> getConfiguration(String wrangledDsId) { >>>>>>> // FIXME: just send static configurations. we do not need specific dataset info. public Map<String,Object> getConfiguration(String wrangledDsId) { <<<<<<< if(!jobs.isEmpty()) { teddyExecutor.updateAsCanceling(ssId); ======= if( jobs == null || jobs.isEmpty()) { return "NO_MATCHED_SNAPSHOT_ID"; } else { teddyExecutor.updateAsCanceling(ssId); for (Future<List<Row>> job : jobs) { job.cancel(true); } return "OK"; } >>>>>>> if( jobs == null || jobs.isEmpty()) { return "NO_MATCHED_SNAPSHOT_ID"; } else { teddyExecutor.updateAsCanceling(ssId); for (Future<List<Row>> job : jobs) { job.cancel(true); } return "OK"; }
<<<<<<< import com.founder.fix.fixflow.core.IdentityService; import com.founder.fix.fixflow.core.ProcessEngine; ======= import com.founder.fix.fixflow.core.ProcessEngine; >>>>>>> import com.founder.fix.fixflow.core.IdentityService; import com.founder.fix.fixflow.core.ProcessEngine; <<<<<<< import com.founder.fix.fixflow.shell.FlowUtilServiceImpl; import com.founder.fix.fixflow.util.JSONUtil; ======= >>>>>>> import com.founder.fix.fixflow.shell.FlowUtilServiceImpl; <<<<<<< ProcessEngine engine = getProcessEngine(userId); RuntimeService runtimeService = engine.getRuntimeService(); IdentityService identityService = engine.getIdentityService(); String pageI = StringUtil.getString(params.get("pageIndex")); String rowI = StringUtil.getString(params.get("pageSize")); int pageIndex=1; int rowNum =10; if(StringUtil.isNotEmpty(pageI)){ pageIndex = Integer.valueOf(pageI); } if(StringUtil.isNotEmpty(rowI)){ rowNum = Integer.valueOf(rowI); } ProcessInstanceQuery processInstanceQuery = runtimeService.createProcessInstanceQuery(); if(StringUtil.isNotEmpty(processDefinitionKey)) processInstanceQuery.processDefinitionKey(processDefinitionKey); if(StringUtil.isNotEmpty(processInstanceId)) processInstanceQuery.processInstanceId(processDefinitionKey); if(StringUtil.isNotEmpty(subject)) processInstanceQuery.subjectLike(processDefinitionKey); if(StringUtil.isNotEmpty(initor)) processInstanceQuery.initiatorLike(processDefinitionKey); if(processInstanceStatus !=null){ processInstanceQuery.processInstanceStatus(processInstanceStatus); } processInstanceQuery.orderByUpdateTime().desc(); List<ProcessInstance> processInstances = processInstanceQuery.listPagination(pageIndex, rowNum); FlowUtilServiceImpl flowUtil = new FlowUtilServiceImpl(); List<Map<String,Object>> instanceMaps = new ArrayList<Map<String,Object>>(); for(ProcessInstance tmp: processInstances){ Map<String, Object> persistentState = tmp.getPersistentState(); String processDefinitionId = tmp.getProcessDefinitionId(); ProcessDefinitionBehavior processDefinitionBehavior = engine.getModelService().getProcessDefinition(processDefinitionId); String processDefinitionName = processDefinitionBehavior.getName(); persistentState.put("processDefinitionName", processDefinitionName); String nowNodeInfo = flowUtil.getShareTaskNowNodeInfo(tmp.getId()); persistentState.put("nowNodeInfo", nowNodeInfo); UserTo user = identityService.getUserTo(tmp.getStartAuthor()); if(user !=null){ persistentState.put("startAuthorName", user.getUserName()); }else{ persistentState.put("startAuthorName", tmp.getStartAuthor()); } instanceMaps.add(persistentState); ======= ProcessEngine engine = getProcessEngine(userId); try{ RuntimeService runtimeService = engine.getRuntimeService(); String pageI = StringUtil.getString(params.get("pageIndex")); String rowI = StringUtil.getString(params.get("pageSize")); int pageIndex=1; int rowNum =10; if(StringUtil.isNotEmpty(pageI)){ pageIndex = Integer.valueOf(pageI); } if(StringUtil.isNotEmpty(rowI)){ rowNum = Integer.valueOf(rowI); } ProcessInstanceQuery processInstanceQuery = runtimeService.createProcessInstanceQuery(); if(StringUtil.isNotEmpty(processDefinitionKey)) processInstanceQuery.processDefinitionKey(processDefinitionKey); if(StringUtil.isNotEmpty(processInstanceId)) processInstanceQuery.processInstanceId(processDefinitionKey); if(StringUtil.isNotEmpty(subject)) processInstanceQuery.subjectLike(processDefinitionKey); // if(StringUtil.isNotEmpty(bizKey)) // processInstanceQuery.(processDefinitionKey); if(StringUtil.isNotEmpty(initor)) processInstanceQuery.initiatorLike(processDefinitionKey); if(processInstanceStatus !=null){ processInstanceQuery.processInstanceStatus(processInstanceStatus); } processInstanceQuery.orderByUpdateTime().desc(); //根据流程定义key查询 List<ProcessInstance> processInstances = processInstanceQuery.listPagination(pageIndex, rowNum); List<Map<String,Object>> instanceMaps = new ArrayList<Map<String,Object>>(); for(ProcessInstance tmp: processInstances){ instanceMaps.add(tmp.getPersistentState()); } Long count = processInstanceQuery.count(); Pagination page = new Pagination(pageIndex,rowNum); page.setTotal(count.intValue()); resultMap.put("dataList", instanceMaps); resultMap.put("pageInfo", page); }finally{ closeProcessEngine(); >>>>>>> ProcessEngine engine = getProcessEngine(userId); RuntimeService runtimeService = engine.getRuntimeService(); IdentityService identityService = engine.getIdentityService(); try{ String pageI = StringUtil.getString(params.get("pageIndex")); String rowI = StringUtil.getString(params.get("pageSize")); int pageIndex=1; int rowNum =10; if(StringUtil.isNotEmpty(pageI)){ pageIndex = Integer.valueOf(pageI); } if(StringUtil.isNotEmpty(rowI)){ rowNum = Integer.valueOf(rowI); } ProcessInstanceQuery processInstanceQuery = runtimeService.createProcessInstanceQuery(); if(StringUtil.isNotEmpty(processDefinitionKey)) processInstanceQuery.processDefinitionKey(processDefinitionKey); if(StringUtil.isNotEmpty(processInstanceId)) processInstanceQuery.processInstanceId(processDefinitionKey); if(StringUtil.isNotEmpty(subject)) processInstanceQuery.subjectLike(processDefinitionKey); if(StringUtil.isNotEmpty(initor)) processInstanceQuery.initiatorLike(processDefinitionKey); if(processInstanceStatus !=null){ processInstanceQuery.processInstanceStatus(processInstanceStatus); } processInstanceQuery.orderByUpdateTime().desc(); List<ProcessInstance> processInstances = processInstanceQuery.listPagination(pageIndex, rowNum); FlowUtilServiceImpl flowUtil = new FlowUtilServiceImpl(); List<Map<String,Object>> instanceMaps = new ArrayList<Map<String,Object>>(); for(ProcessInstance tmp: processInstances){ Map<String, Object> persistentState = tmp.getPersistentState(); String processDefinitionId = tmp.getProcessDefinitionId(); ProcessDefinitionBehavior processDefinitionBehavior = engine.getModelService().getProcessDefinition(processDefinitionId); String processDefinitionName = processDefinitionBehavior.getName(); persistentState.put("processDefinitionName", processDefinitionName); String nowNodeInfo = flowUtil.getShareTaskNowNodeInfo(tmp.getId()); persistentState.put("nowNodeInfo", nowNodeInfo); UserTo user = identityService.getUserTo(tmp.getStartAuthor()); if(user !=null){ persistentState.put("startAuthorName", user.getUserName()); }else{ persistentState.put("startAuthorName", tmp.getStartAuthor()); } instanceMaps.add(persistentState); } Long count = processInstanceQuery.count(); Pagination page = new Pagination(pageIndex,rowNum); page.setTotal(count.intValue()); resultMap.put("dataList", instanceMaps); resultMap.put("pageInfo", page); }finally{ closeProcessEngine();
<<<<<<< ======= import com.asakusafw.compiler.flow.Location; import com.asakusafw.runtime.stage.BaseStageClient; >>>>>>> import com.asakusafw.compiler.flow.Location; <<<<<<< import com.asakusafw.runtime.stage.BaseStageClient; import com.asakusafw.utils.collections.Lists; ======= import com.asakusafw.runtime.stage.StageConstants; >>>>>>> import com.asakusafw.runtime.stage.BaseStageClient; import com.asakusafw.runtime.stage.StageConstants; import com.asakusafw.utils.collections.Lists;
<<<<<<< Map<String, String> env = new HashMap<String, String>(); env.putAll(System.getenv()); env.putAll(toMap(variables)); ProfileContext context = new ProfileContext(loader, new VariableResolver(env)); Properties properties = CommandLineUtil.loadProperties(new File(profile)); result.context = context; ======= ProfileContext context = ProfileContext.system(loader); Properties properties = CommandLineUtil.loadProperties(file); >>>>>>> Map<String, String> env = new HashMap<String, String>(); env.putAll(System.getenv()); env.putAll(toMap(variables)); ProfileContext context = new ProfileContext(loader, new VariableResolver(env)); Properties properties = CommandLineUtil.loadProperties(file); result.context = context;
<<<<<<< public boolean mReenableSimplifiedChemicalRecipes = false; ======= public boolean mAMHInteraction = true; >>>>>>> public boolean mReenableSimplifiedChemicalRecipes = false; public boolean mAMHInteraction = true;
<<<<<<< gregtechproxy.mEasierEVPlusCables = tMainConfig.get("general", "EasierEVPlusCables", false).getBoolean(false); ======= gregtechproxy.mBrickedBlastFurnace = tMainConfig.get("general", "BrickedBlastFurnace", true).getBoolean(true); >>>>>>> gregtechproxy.mEasierEVPlusCables = tMainConfig.get("general", "EasierEVPlusCables", false).getBoolean(false); gregtechproxy.mBrickedBlastFurnace = tMainConfig.get("general", "BrickedBlastFurnace", true).getBoolean(true);
<<<<<<< ======= static class HandleKitOverrides implements QuestionerCallback { private String[] args; private EntityPlayerMP sender; private HandleKitOverrides(EntityPlayerMP sender, String[] args) { this.args = args; this.sender = sender; } @Override public void respond(Boolean response) { if (response != null && response == true) { int cooldown = -1; if (args.length == 3) { cooldown = parseIntWithMin(sender, args[2], -1); } new Kit(sender, args[0].toLowerCase(), cooldown); ChatOutputHandler.chatConfirmation(sender, Translator.format("Kit created successfully. %s cooldown.", ChatOutputHandler.formatTimeDurationReadable(cooldown, true))); } } } @Override public void loadConfig(Configuration config, String category) { kitForNewPlayers = config.get(category, "kitForNewPlayers", "", "Name of kit to issue to new players. If this is left blank, it will be ignored.") .getString(); } @Override public void loadData() { // TODO (1) Load Kit data here! } >>>>>>> @Override public void loadConfig(Configuration config, String category) { kitForNewPlayers = config.get(category, "kitForNewPlayers", "", "Name of kit to issue to new players. If this is left blank, it will be ignored.") .getString(); } @Override public void loadData() { // TODO (1) Load Kit data here! }
<<<<<<< import java.util.ArrayList; import java.util.HashMap; import java.util.List; ======= import java.util.ArrayList; import java.util.List; import java.util.concurrent.ConcurrentHashMap; >>>>>>> import java.util.ArrayList; import java.util.List; import java.util.concurrent.ConcurrentHashMap; <<<<<<< this.achievementList = new HashMap(); this.issuedAchievements = new HashMap(); for (int i = 0; i < oreList.size(); i++) { if (oreList.get(i) != null) { if (GT_Values.D1 && this.achievementList.get(oreList.get(i).mName) == null) { GT_Log.out.println("achievement." + oreList.get(i).mName + "=Find " + oreList.get(i).mName + " Ore"); StringBuilder dimensions = new StringBuilder(); boolean isFirst = true; if (oreStats.get(i)[3] == 1) { dimensions.append("Overworld"); isFirst = false; } if (oreStats.get(i)[4] == 1) { if (!isFirst) dimensions.append("/"); dimensions.append("Nether"); isFirst = false; } if (oreStats.get(i)[5] == 1) { if (!isFirst) dimensions.append("/"); dimensions.append("End"); isFirst = false; } GT_Log.out.println("achievement." + oreList.get(i).mName + ".desc=Height: " + (oreStats.get(i)[0]) + "-" + (oreStats.get(i)[1]) + ", Chance: " + (oreStats.get(i)[2]) + ", " + dimensions.toString()); ======= this.achievementList = new ConcurrentHashMap(); this.issuedAchievements = new ConcurrentHashMap(); int oreList_sS=oreList.size(); for (int i = 0; i < oreList_sS; i++) { if (GT_Values.D1 && this.achievementList.get(oreList.get(i).name()) == null) { GT_Log.out.println("achievement." + oreList.get(i).name() + "=Find " + oreList.get(i).name() + " Ore"); StringBuilder dimensions = new StringBuilder(); boolean isFirst = true; if(oreStats.get(i)[3] == 1) { dimensions.append("Overworld"); isFirst = false; } if(oreStats.get(i)[4] == 1) { if(!isFirst) dimensions.append("/"); dimensions.append("Nether"); isFirst = false; } if(oreStats.get(i)[5] == 1) { if(!isFirst) dimensions.append("/"); dimensions.append("End"); isFirst = false; >>>>>>> this.achievementList = new ConcurrentHashMap(); this.issuedAchievements = new ConcurrentHashMap(); int oreList_sS=oreList.size(); for (int i = 0; i < oreList_sS; i++) { if (oreList.get(i) != null) { if (GT_Values.D1 && this.achievementList.get(oreList.get(i).mName) == null) { GT_Log.out.println("achievement." + oreList.get(i).mName + "=Find " + oreList.get(i).mName + " Ore"); StringBuilder dimensions = new StringBuilder(); boolean isFirst = true; if (oreStats.get(i)[3] == 1) { dimensions.append("Overworld"); isFirst = false; } if (oreStats.get(i)[4] == 1) { if (!isFirst) dimensions.append("/"); dimensions.append("Nether"); isFirst = false; } if (oreStats.get(i)[5] == 1) { if (!isFirst) dimensions.append("/"); dimensions.append("End"); isFirst = false; } GT_Log.out.println("achievement." + oreList.get(i).mName + ".desc=Height: " + (oreStats.get(i)[0]) + "-" + (oreStats.get(i)[1]) + ", Chance: " + (oreStats.get(i)[2]) + ", " + dimensions.toString()); <<<<<<< for (int i = 0; i < data.getAllMaterialStacks().size(); i++) { issueAchievement(player, data.getAllMaterialStacks().get(i).mMaterial.mName); ======= int data_getAllMaterialStacks_sS=data.getAllMaterialStacks().size(); for (int i = 0; i < data_getAllMaterialStacks_sS; i++) { issueAchievement(player, data.getAllMaterialStacks().get(i).mMaterial.name()); >>>>>>> int data_getAllMaterialStacks_sS=data.getAllMaterialStacks().size(); for (int i = 0; i < data_getAllMaterialStacks_sS; i++) { issueAchievement(player, data.getAllMaterialStacks().get(i).mMaterial.mName);
<<<<<<< package gregtech.api.metatileentity.implementations; import gregtech.api.enums.Textures; import gregtech.api.gui.*; import gregtech.api.interfaces.ITexture; import gregtech.api.interfaces.tileentity.IGregTechTileEntity; import gregtech.api.metatileentity.MetaTileEntity; import gregtech.api.objects.GT_RenderedTexture; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.InventoryPlayer; import net.minecraft.item.ItemStack; public class GT_MetaTileEntity_Hatch_DataAccess extends GT_MetaTileEntity_Hatch { public GT_MetaTileEntity_Hatch_DataAccess(int aID, String aName, String aNameRegional, int aTier) { super(aID, aName, aNameRegional, aTier, 16, "Data Access for Multiblocks"); } public GT_MetaTileEntity_Hatch_DataAccess(String aName, int aTier, String aDescription, ITexture[][][] aTextures) { super(aName, aTier, aTier == 4 ? 4 : 16, aDescription, aTextures); } public GT_MetaTileEntity_Hatch_DataAccess(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) { super(aName, aTier, aTier == 4 ? 4 : 16, aDescription, aTextures); } @Override public ITexture[] getTexturesActive(ITexture aBaseTexture) { return new ITexture[]{aBaseTexture, new GT_RenderedTexture(Textures.BlockIcons.OVERLAY_DATA_ACCESS)}; } @Override public ITexture[] getTexturesInactive(ITexture aBaseTexture) { return new ITexture[]{aBaseTexture, new GT_RenderedTexture(Textures.BlockIcons.OVERLAY_DATA_ACCESS)}; } @Override public boolean isSimpleMachine() { return true; } @Override public boolean isFacingValid(byte aFacing) { return true; } @Override public boolean isAccessAllowed(EntityPlayer aPlayer) { return true; } @Override public boolean isValidSlot(int aIndex) { return true; } @Override public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) { return new GT_MetaTileEntity_Hatch_DataAccess(mName, mTier, mDescriptionArray, mTextures); } @Override public boolean onRightclick(IGregTechTileEntity aBaseMetaTileEntity, EntityPlayer aPlayer) { if (aBaseMetaTileEntity.isClientSide()) return true; aBaseMetaTileEntity.openGUI(aPlayer); return true; } @Override public Object getServerGUI(int aID, InventoryPlayer aPlayerInventory, IGregTechTileEntity aBaseMetaTileEntity) { switch (mTier) { case 4: return new GT_Container_2by2(aPlayerInventory, aBaseMetaTileEntity); default: return new GT_Container_4by4(aPlayerInventory, aBaseMetaTileEntity); } } @Override public Object getClientGUI(int aID, InventoryPlayer aPlayerInventory, IGregTechTileEntity aBaseMetaTileEntity) { switch (mTier) { case 4: return new GT_GUIContainer_2by2(aPlayerInventory, aBaseMetaTileEntity, "Data Access Hatch", "DataAccess"); case 6: return new GT_GUIContainer_4by4(aPlayerInventory, aBaseMetaTileEntity, "Data Access Hatch", "DataAccess"); default: return new GT_GUIContainer_4by4(aPlayerInventory, aBaseMetaTileEntity, "Data Access Hatch", "DataAccess"); } } @Override public boolean allowPullStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) { return false; } @Override public boolean allowPutStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) { return false; } @Override public int getInventoryStackLimit() { return 1; } } ======= package gregtech.api.metatileentity.implementations; import gregtech.api.enums.Textures; import gregtech.api.gui.*; import gregtech.api.interfaces.ITexture; import gregtech.api.interfaces.tileentity.IGregTechTileEntity; import gregtech.api.metatileentity.MetaTileEntity; import gregtech.api.objects.GT_RenderedTexture; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.InventoryPlayer; import net.minecraft.item.ItemStack; public class GT_MetaTileEntity_Hatch_DataAccess extends GT_MetaTileEntity_Hatch { public GT_MetaTileEntity_Hatch_DataAccess(int aID, String aName, String aNameRegional, int aTier) { super(aID, aName, aNameRegional, aTier, 16, new String[]{ "Data Access for Multiblocks", "Adds " + (aTier == 4 ? 4 : 16) + " extra slots for Data Sticks"}); } public GT_MetaTileEntity_Hatch_DataAccess(String aName, int aTier, String aDescription, ITexture[][][] aTextures) { super(aName, aTier, aTier == 4 ? 4 : 16, aDescription, aTextures); } public GT_MetaTileEntity_Hatch_DataAccess(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) { super(aName, aTier, aTier == 4 ? 4 : 16, aDescription, aTextures); } @Override public ITexture[] getTexturesActive(ITexture aBaseTexture) { return new ITexture[]{aBaseTexture, new GT_RenderedTexture(Textures.BlockIcons.OVERLAY_DATA_ACCESS)}; } @Override public ITexture[] getTexturesInactive(ITexture aBaseTexture) { return new ITexture[]{aBaseTexture, new GT_RenderedTexture(Textures.BlockIcons.OVERLAY_DATA_ACCESS)}; } @Override public boolean isSimpleMachine() { return true; } @Override public boolean isFacingValid(byte aFacing) { return true; } @Override public boolean isAccessAllowed(EntityPlayer aPlayer) { return true; } @Override public boolean isValidSlot(int aIndex) { return true; } @Override public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) { return new GT_MetaTileEntity_Hatch_DataAccess(mName, mTier, mDescriptionArray, mTextures); } @Override public boolean onRightclick(IGregTechTileEntity aBaseMetaTileEntity, EntityPlayer aPlayer) { if (aBaseMetaTileEntity.isClientSide()) return true; aBaseMetaTileEntity.openGUI(aPlayer); return true; } @Override public Object getServerGUI(int aID, InventoryPlayer aPlayerInventory, IGregTechTileEntity aBaseMetaTileEntity) { switch (mTier) { case 4: return new GT_Container_2by2(aPlayerInventory, aBaseMetaTileEntity); default: return new GT_Container_4by4(aPlayerInventory, aBaseMetaTileEntity); } } @Override public Object getClientGUI(int aID, InventoryPlayer aPlayerInventory, IGregTechTileEntity aBaseMetaTileEntity) { switch (mTier) { case 4: return new GT_GUIContainer_2by2(aPlayerInventory, aBaseMetaTileEntity, "Data Access Hatch", "DataAccess"); case 6: return new GT_GUIContainer_4by4(aPlayerInventory, aBaseMetaTileEntity, "Data Access Hatch", "DataAccess"); default: return new GT_GUIContainer_4by4(aPlayerInventory, aBaseMetaTileEntity, "Data Access Hatch", "DataAccess"); } } @Override public boolean allowPullStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) { return false; } @Override public boolean allowPutStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) { return false; } } >>>>>>> package gregtech.api.metatileentity.implementations; import gregtech.api.enums.Textures; import gregtech.api.gui.*; import gregtech.api.interfaces.ITexture; import gregtech.api.interfaces.tileentity.IGregTechTileEntity; import gregtech.api.metatileentity.MetaTileEntity; import gregtech.api.objects.GT_RenderedTexture; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.InventoryPlayer; import net.minecraft.item.ItemStack; public class GT_MetaTileEntity_Hatch_DataAccess extends GT_MetaTileEntity_Hatch { public GT_MetaTileEntity_Hatch_DataAccess(int aID, String aName, String aNameRegional, int aTier) { super(aID, aName, aNameRegional, aTier, 16, new String[]{ "Data Access for Multiblocks", "Adds " + (aTier == 4 ? 4 : 16) + " extra slots for Data Sticks"}); } public GT_MetaTileEntity_Hatch_DataAccess(String aName, int aTier, String aDescription, ITexture[][][] aTextures) { super(aName, aTier, aTier == 4 ? 4 : 16, aDescription, aTextures); } public GT_MetaTileEntity_Hatch_DataAccess(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) { super(aName, aTier, aTier == 4 ? 4 : 16, aDescription, aTextures); } @Override public ITexture[] getTexturesActive(ITexture aBaseTexture) { return new ITexture[]{aBaseTexture, new GT_RenderedTexture(Textures.BlockIcons.OVERLAY_DATA_ACCESS)}; } @Override public ITexture[] getTexturesInactive(ITexture aBaseTexture) { return new ITexture[]{aBaseTexture, new GT_RenderedTexture(Textures.BlockIcons.OVERLAY_DATA_ACCESS)}; } @Override public boolean isSimpleMachine() { return true; } @Override public boolean isFacingValid(byte aFacing) { return true; } @Override public boolean isAccessAllowed(EntityPlayer aPlayer) { return true; } @Override public boolean isValidSlot(int aIndex) { return true; } @Override public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) { return new GT_MetaTileEntity_Hatch_DataAccess(mName, mTier, mDescriptionArray, mTextures); } @Override public boolean onRightclick(IGregTechTileEntity aBaseMetaTileEntity, EntityPlayer aPlayer) { if (aBaseMetaTileEntity.isClientSide()) return true; aBaseMetaTileEntity.openGUI(aPlayer); return true; } @Override public Object getServerGUI(int aID, InventoryPlayer aPlayerInventory, IGregTechTileEntity aBaseMetaTileEntity) { switch (mTier) { case 4: return new GT_Container_2by2(aPlayerInventory, aBaseMetaTileEntity); default: return new GT_Container_4by4(aPlayerInventory, aBaseMetaTileEntity); } } @Override public Object getClientGUI(int aID, InventoryPlayer aPlayerInventory, IGregTechTileEntity aBaseMetaTileEntity) { switch (mTier) { case 4: return new GT_GUIContainer_2by2(aPlayerInventory, aBaseMetaTileEntity, "Data Access Hatch", "DataAccess"); case 6: return new GT_GUIContainer_4by4(aPlayerInventory, aBaseMetaTileEntity, "Data Access Hatch", "DataAccess"); default: return new GT_GUIContainer_4by4(aPlayerInventory, aBaseMetaTileEntity, "Data Access Hatch", "DataAccess"); } } @Override public boolean allowPullStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) { return false; } @Override public boolean allowPutStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) { return false; } @Override public int getInventoryStackLimit() { return 1; } }
<<<<<<< addStringLocalization("Interaction_DESCRIPTION_Index_212", "Input enabled"); addStringLocalization("Interaction_DESCRIPTION_Index_213", "Input disabled"); addStringLocalization("Interaction_DESCRIPTION_Index_214", "Connected"); addStringLocalization("Interaction_DESCRIPTION_Index_215", "Disconnected"); ======= addStringLocalization("Item_DESCRIPTION_Index_000", "Stored Heat: %s"); addStringLocalization("Item_DESCRIPTION_Index_001", "Durability: %s/%s"); addStringLocalization("Item_DESCRIPTION_Index_002", "%s lvl %s"); addStringLocalization("Item_DESCRIPTION_Index_003", "Attack Damage: %s"); addStringLocalization("Item_DESCRIPTION_Index_004", "Mining Speed: %s"); addStringLocalization("Item_DESCRIPTION_Index_005", "Turbine Efficiency: %s"); addStringLocalization("Item_DESCRIPTION_Index_006", "Optimal Steam flow: %sL/sec"); addStringLocalization("Item_DESCRIPTION_Index_007", "Optimal Gas flow(EU burnvalue per tick): %sEU/t"); addStringLocalization("Item_DESCRIPTION_Index_008", "Optimal Plasma flow(Plasma energyvalue per tick): %sEU/t"); addStringLocalization("Item_DESCRIPTION_Index_009", "Contains %s EU Tier: %s"); addStringLocalization("Item_DESCRIPTION_Index_010", "Empty. You should recycle it properly."); addStringLocalization("Item_DESCRIPTION_Index_011", "%s / %s EU - Voltage: %s"); addStringLocalization("Item_DESCRIPTION_Index_012", "No Fluids Contained"); addStringLocalization("Item_DESCRIPTION_Index_013", "%sL / %sL"); addStringLocalization("Item_DESCRIPTION_Index_014", "Missing Coodinates!"); addStringLocalization("Item_DESCRIPTION_Index_015", "Device at:"); addStringLocalization("Item_DESCRIPTION_Index_016", "Amount: %s L"); addStringLocalization("Item_DESCRIPTION_Index_017", "Temperature: %s K"); addStringLocalization("Item_DESCRIPTION_Index_018", "State: %s"); >>>>>>> addStringLocalization("Interaction_DESCRIPTION_Index_212", "Input enabled"); addStringLocalization("Interaction_DESCRIPTION_Index_213", "Input disabled"); addStringLocalization("Interaction_DESCRIPTION_Index_214", "Connected"); addStringLocalization("Interaction_DESCRIPTION_Index_215", "Disconnected"); addStringLocalization("Item_DESCRIPTION_Index_000", "Stored Heat: %s"); addStringLocalization("Item_DESCRIPTION_Index_001", "Durability: %s/%s"); addStringLocalization("Item_DESCRIPTION_Index_002", "%s lvl %s"); addStringLocalization("Item_DESCRIPTION_Index_003", "Attack Damage: %s"); addStringLocalization("Item_DESCRIPTION_Index_004", "Mining Speed: %s"); addStringLocalization("Item_DESCRIPTION_Index_005", "Turbine Efficiency: %s"); addStringLocalization("Item_DESCRIPTION_Index_006", "Optimal Steam flow: %sL/sec"); addStringLocalization("Item_DESCRIPTION_Index_007", "Optimal Gas flow(EU burnvalue per tick): %sEU/t"); addStringLocalization("Item_DESCRIPTION_Index_008", "Optimal Plasma flow(Plasma energyvalue per tick): %sEU/t"); addStringLocalization("Item_DESCRIPTION_Index_009", "Contains %s EU Tier: %s"); addStringLocalization("Item_DESCRIPTION_Index_010", "Empty. You should recycle it properly."); addStringLocalization("Item_DESCRIPTION_Index_011", "%s / %s EU - Voltage: %s"); addStringLocalization("Item_DESCRIPTION_Index_012", "No Fluids Contained"); addStringLocalization("Item_DESCRIPTION_Index_013", "%sL / %sL"); addStringLocalization("Item_DESCRIPTION_Index_014", "Missing Coodinates!"); addStringLocalization("Item_DESCRIPTION_Index_015", "Device at:"); addStringLocalization("Item_DESCRIPTION_Index_016", "Amount: %s L"); addStringLocalization("Item_DESCRIPTION_Index_017", "Temperature: %s K"); addStringLocalization("Item_DESCRIPTION_Index_018", "State: %s");
<<<<<<< int id = mContainer.mTileEntity.getMetaTileID(); if (id == 1157 || id == 1158 || id == 1177 || id == 1178 || id == 1179) { ItemStack tItem = mContainer.mTileEntity.getMetaTileEntity().getStackInSlot(1); if (tItem == null || !GT_Utility.areStacksEqual(tItem, GT_ModHandler.getIC2Item("miningPipe", 1L))) { fontRendererObj.drawString("Missing Mining Pipe", 10, ((GT_Container_MultiMachine) mContainer).mActive == 0 ? 40 : 24, 16448255); } } else if (id == 1131 || id == 1151 || id == 1152 || id == 1153) { ItemStack tItem = mContainer.mTileEntity.getMetaTileEntity().getStackInSlot(1); if (tItem == null || !(tItem.getItem() == GT_MetaGenerated_Tool_01.INSTANCE && tItem.getItemDamage() >= 170 && tItem.getItemDamage() <= 177)) { fontRendererObj.drawString("Missing Turbine Rotor", 10, ((GT_Container_MultiMachine) mContainer).mActive == 0 ? 40 : 24, 16448255); } } ======= int id = mContainer.mTileEntity.getMetaTileID(); if(id == 1157 || id == 1158){ ItemStack tItem = mContainer.mTileEntity.getMetaTileEntity().getStackInSlot(1); if(tItem==null || !GT_Utility.areStacksEqual(tItem, GT_ModHandler.getIC2Item("miningPipe", 1L))){ fontRendererObj.drawString(trans("143","Missing Mining Pipe"), 10,((GT_Container_MultiMachine) mContainer).mActive == 0 ? 40 : 24, 16448255); } }else if(id == 1131 || id == 1151 || id == 1152 || id == 1153){ ItemStack tItem = mContainer.mTileEntity.getMetaTileEntity().getStackInSlot(1); if(tItem==null || !(tItem.getItem()==GT_MetaGenerated_Tool_01.INSTANCE&&tItem.getItemDamage()>=170&&tItem.getItemDamage()<=177)){ fontRendererObj.drawString(trans("144","Missing Turbine Rotor"), 10, ((GT_Container_MultiMachine) mContainer).mActive == 0 ? 40 : 24, 16448255); } } >>>>>>> int id = mContainer.mTileEntity.getMetaTileID(); if (id == 1157 || id == 1158 || id == 1177 || id == 1178 || id == 1179) { ItemStack tItem = mContainer.mTileEntity.getMetaTileEntity().getStackInSlot(1); if(tItem==null || !GT_Utility.areStacksEqual(tItem, GT_ModHandler.getIC2Item("miningPipe", 1L))){ fontRendererObj.drawString(trans("143","Missing Mining Pipe"), 10,((GT_Container_MultiMachine) mContainer).mActive == 0 ? 40 : 24, 16448255); } }else if(id == 1131 || id == 1151 || id == 1152 || id == 1153){ ItemStack tItem = mContainer.mTileEntity.getMetaTileEntity().getStackInSlot(1); if(tItem==null || !(tItem.getItem()==GT_MetaGenerated_Tool_01.INSTANCE&&tItem.getItemDamage()>=170&&tItem.getItemDamage()<=177)){ fontRendererObj.drawString(trans("144","Missing Turbine Rotor"), 10, ((GT_Container_MultiMachine) mContainer).mActive == 0 ? 40 : 24, 16448255); } }
<<<<<<< GT_Values.RA.addBlastRecipe(aOreStack, GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Calcite, aMultiplier), null, null, GT_Utility.mul(aMultiplier * (GT_Mod.gregtechproxy.mMixedOreOnlyYieldsTwoThirdsOfPureOre ? 2 : 3) * aMaterial.mSmeltingMultiplier, new Object[]{tSmeltInto}), ItemList.TE_Slag.get(1L, new Object[]{GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.DarkAsh, 1L)}), tSmeltInto.stackSize * 500, 120, 1500); ======= GT_Values.RA.addBlastRecipe(aOreStack, GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Calcite, aMultiplier), null, null, GT_Utility.mul(aMultiplier * 2 * aMaterial.mSmeltingMultiplier, new Object[]{tSmeltInto}), ItemList.TE_Slag.get(1L, new Object[]{GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.DarkAsh, 1L)}), tSmeltInto.stackSize * 500, 120, 1500); GT_Values.RA.addBlastRecipe(aOreStack, GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Quicklime, aMultiplier * 3), null, null, GT_Utility.mul(aMultiplier * 2 * aMaterial.mSmeltingMultiplier, new Object[]{tSmeltInto}), ItemList.TE_Slag.get(1L, new Object[]{GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.DarkAsh, 1L)}), tSmeltInto.stackSize * 500, 120, 1500); >>>>>>> GT_Values.RA.addBlastRecipe(aOreStack, GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Calcite, aMultiplier), null, null, GT_Utility.mul(aMultiplier * (GT_Mod.gregtechproxy.mMixedOreOnlyYieldsTwoThirdsOfPureOre ? 2 : 3) * aMaterial.mSmeltingMultiplier, new Object[]{tSmeltInto}), ItemList.TE_Slag.get(1L, new Object[]{GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.DarkAsh, 1L)}), tSmeltInto.stackSize * 500, 120, 1500); GT_Values.RA.addBlastRecipe(aOreStack, GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Quicklime, aMultiplier * 3), null, null, GT_Utility.mul(aMultiplier * 2 * aMaterial.mSmeltingMultiplier, new Object[]{tSmeltInto}), ItemList.TE_Slag.get(1L, new Object[]{GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.DarkAsh, 1L)}), tSmeltInto.stackSize * 500, 120, 1500);
<<<<<<< /* * Copyright (C) 2012-2017 52°North Initiative for Geospatial Open Source ======= /** * Copyright (C) 2012-2017 52°North Initiative for Geospatial Open Source >>>>>>> <<<<<<< import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.n52.shetland.ogc.gml.AbstractFeature; import org.n52.shetland.ogc.gml.time.TimeInstant; import org.n52.shetland.ogc.gml.time.TimePeriod; import org.n52.shetland.ogc.om.OmObservation; import org.n52.shetland.ogc.om.features.FeatureCollection; import org.n52.shetland.ogc.om.features.samplingFeatures.SamplingFeature; import org.n52.shetland.ogc.ows.exception.CodedException; import org.n52.shetland.ogc.ows.exception.NoApplicableCodeException; import org.n52.shetland.ogc.ows.exception.OwsExceptionReport; import org.n52.shetland.util.ReferencedEnvelope; ======= >>>>>>> <<<<<<< import org.n52.sos.ds.FeatureQueryHandler; import org.n52.sos.ds.FeatureQueryHandlerQueryObject; ======= import org.n52.sos.exception.CodedException; import org.n52.sos.exception.ows.NoApplicableCodeException; import org.n52.sos.ogc.gml.AbstractFeature; import org.n52.sos.ogc.gml.time.TimeInstant; import org.n52.sos.ogc.gml.time.TimePeriod; import org.n52.sos.ogc.om.OmObservation; import org.n52.sos.ogc.om.features.FeatureCollection; import org.n52.sos.ogc.om.features.samplingFeatures.AbstractSamplingFeature; import org.n52.sos.ogc.ows.OwsExceptionReport; import org.n52.sos.ogc.sos.SosEnvelope; import org.slf4j.Logger; import org.slf4j.LoggerFactory; >>>>>>> <<<<<<< protected ReferencedEnvelope getEnvelope(Set<String> features) throws OwsExceptionReport { final Set<String> dbFeatures = new HashSet<>(features.size()); for (String feature : features) { dbFeatures.add(feature); } FeatureQueryHandlerQueryObject queryHandler = new FeatureQueryHandlerQueryObject(getConnection()).setFeatures(dbFeatures); return this.featureQueryHandler.getEnvelopeForFeatureIDs(queryHandler); ======= protected SosEnvelope getEnvelope(Set<String> features) throws OwsExceptionReport { return getFeatureQueryHandler().getEnvelopeForFeatureIDs(features, getConnection()); >>>>>>>
<<<<<<< import com.forgeessentials.core.commands.ForgeEssentialsCommandBase; import com.forgeessentials.util.OutputHandler; import com.forgeessentials.util.PlayerInfo; import com.forgeessentials.commons.selections.WarpPoint; import com.forgeessentials.util.teleport.TeleportCenter; ======= import java.util.ArrayList; import java.util.List; import java.util.UUID; >>>>>>> import com.forgeessentials.core.commands.ForgeEssentialsCommandBase; import com.forgeessentials.util.OutputHandler; import com.forgeessentials.util.PlayerInfo; import com.forgeessentials.commons.selections.WarpPoint; import com.forgeessentials.util.teleport.TeleportCenter; import java.util.ArrayList; import java.util.List; import java.util.UUID;
<<<<<<< List<ActionProvider> metacardActionProviderList = new ArrayList<ActionProvider>(); metacardActionProviderList.add(buildActionProvider(METACARD_ACTION)); List<ActionProvider> thumbnailActionProviderList = new ArrayList<ActionProvider>(); List<ActionProvider> resourceActionProviderList = new ArrayList<ActionProvider>(); resourceActionProviderList.add(buildActionProvider(RESOURCE_ACTION, true)); List<FederatedSource> federatedSourceList = new ArrayList<FederatedSource>(); FederatedSource fedSource1 = mock(FederatedSource.class); when(fedSource1.getId()).thenReturn(FED_SOURCE_1_ID); federatedSourceList.add(fedSource1); federatedSourceList.add(fedSource1); // add it twice, should be filtered FederatedSource fedSource2 = mock(FederatedSource.class); when(fedSource2.getId()).thenReturn(FED_SOURCE_2_ID); when(fedSource2.getContentTypes()).thenReturn(contentTypes); federatedSourceList.add(fedSource2); SourceInfoRequestLocal sourceInfoRequestLocal = mock(SourceInfoRequestLocal.class); CatalogFramework catalog = mock(CatalogFramework.class); SourceInfoResponse localSourceInfoResponse = mock(SourceInfoResponse.class); when(catalog.getId()).thenReturn(LOCAL_ID); Set<SourceDescriptor> localSrcSet = new HashSet<SourceDescriptor>(); SourceDescriptor localSrc = mock(SourceDescriptor.class); localSrcSet.add(localSrc); when(localSrc.getContentTypes()).thenReturn(contentTypes); when(localSourceInfoResponse.getSourceInfo()).thenReturn(localSrcSet); try { when(catalog.getSourceInfo(sourceInfoRequestLocal)).thenReturn(localSourceInfoResponse); } catch (SourceUnavailableException e) { } BeansWrapper beansWrapper = new BeansWrapper(); Exchange exchange = mock(Exchange.class); when(exchange.getProperty("title")).thenReturn(TITLE); when(exchange.getProperty("header")).thenReturn(HEADER); when(exchange.getProperty("footer")).thenReturn(FOOTER); when(exchange.getProperty("catalog")).thenReturn(catalog); when(exchange.getProperty("beansWrapper")).thenReturn(beansWrapper); when(exchange.getProperty("sourceInfoReq")).thenReturn(sourceInfoRequestLocal); when(exchange.getProperty("federatedSites")).thenReturn(federatedSourceList); when(exchange.getProperty("htmlActionProviderList")).thenReturn(htmlActionProviderList); when(exchange.getProperty("metacardActionProviderList")).thenReturn(metacardActionProviderList); when(exchange.getProperty("thumbnailActionProviderList")).thenReturn(thumbnailActionProviderList); when(exchange.getProperty("resourceActionProviderList")).thenReturn(resourceActionProviderList); return exchange; } ======= List<ActionProvider> metacardActionProviderList = new ArrayList<ActionProvider>(); metacardActionProviderList.add(buildActionProvider(METACARD_ACTION)); List<ActionProvider> thumbnailActionProviderList = new ArrayList<ActionProvider>(); List<ActionProvider> resourceActionProviderList = new ArrayList<ActionProvider>(); resourceActionProviderList.add(buildActionProvider(RESOURCE_ACTION, true)); SourceInfoRequestEnterprise sourceInfoRequest = mock(SourceInfoRequestEnterprise.class); CatalogFramework catalog = mock(CatalogFramework.class); SourceInfoResponse sourceInfoResponse = mock(SourceInfoResponse.class); Set<SourceDescriptor> srcSet = new HashSet<SourceDescriptor>(); when(catalog.getId()).thenReturn(LOCAL_ID); SourceDescriptor localSrc = mock(SourceDescriptor.class); when(localSrc.getSourceId()).thenReturn(LOCAL_ID); when(localSrc.isAvailable()).thenReturn(true); when(localSrc.getContentTypes()).thenReturn(contentTypes); srcSet.add(localSrc); SourceDescriptor fedSource1 = mock(SourceDescriptor.class); when(fedSource1.getSourceId()).thenReturn(FED_SOURCE_1_ID); when(fedSource1.isAvailable()).thenReturn(true); srcSet.add(fedSource1); srcSet.add(fedSource1); // add it twice, should be filtered SourceDescriptor fedSource2 = mock(SourceDescriptor.class); when(fedSource2.getSourceId()).thenReturn(FED_SOURCE_2_ID); when(fedSource2.getContentTypes()).thenReturn(new HashSet<ContentType>()); when(fedSource2.isAvailable()).thenReturn(false); srcSet.add(fedSource2); when(sourceInfoResponse.getSourceInfo()).thenReturn(srcSet); try { when(catalog.getSourceInfo(sourceInfoRequest)).thenReturn(sourceInfoResponse); } catch (SourceUnavailableException e) { } Exchange exchange = mock(Exchange.class); when(exchange.getProperty("title")).thenReturn(TITLE); when(exchange.getProperty("header")).thenReturn(HEADER); when(exchange.getProperty("footer")).thenReturn(FOOTER); when(exchange.getProperty("catalog")).thenReturn(catalog); when(exchange.getProperty("sourceInfoReqEnterprise")).thenReturn(sourceInfoRequest); when(exchange.getProperty("htmlActionProviderList")).thenReturn(htmlActionProviderList); when(exchange.getProperty("metacardActionProviderList")).thenReturn( metacardActionProviderList); when(exchange.getProperty("thumbnailActionProviderList")).thenReturn( thumbnailActionProviderList); when(exchange.getProperty("resourceActionProviderList")).thenReturn( resourceActionProviderList); return exchange; } >>>>>>> List<ActionProvider> metacardActionProviderList = new ArrayList<ActionProvider>(); metacardActionProviderList.add(buildActionProvider(METACARD_ACTION)); List<ActionProvider> thumbnailActionProviderList = new ArrayList<ActionProvider>(); List<ActionProvider> resourceActionProviderList = new ArrayList<ActionProvider>(); resourceActionProviderList.add(buildActionProvider(RESOURCE_ACTION, true)); SourceInfoRequestEnterprise sourceInfoRequest = mock(SourceInfoRequestEnterprise.class); CatalogFramework catalog = mock(CatalogFramework.class); SourceInfoResponse sourceInfoResponse = mock(SourceInfoResponse.class); Set<SourceDescriptor> srcSet = new HashSet<SourceDescriptor>(); when(catalog.getId()).thenReturn(LOCAL_ID); SourceDescriptor localSrc = mock(SourceDescriptor.class); when(localSrc.getSourceId()).thenReturn(LOCAL_ID); when(localSrc.isAvailable()).thenReturn(true); when(localSrc.getContentTypes()).thenReturn(contentTypes); srcSet.add(localSrc); SourceDescriptor fedSource1 = mock(SourceDescriptor.class); when(fedSource1.getSourceId()).thenReturn(FED_SOURCE_1_ID); when(fedSource1.isAvailable()).thenReturn(true); srcSet.add(fedSource1); srcSet.add(fedSource1); // add it twice, should be filtered SourceDescriptor fedSource2 = mock(SourceDescriptor.class); when(fedSource2.getSourceId()).thenReturn(FED_SOURCE_2_ID); when(fedSource2.getContentTypes()).thenReturn(new HashSet<ContentType>()); when(fedSource2.isAvailable()).thenReturn(false); srcSet.add(fedSource2); when(sourceInfoResponse.getSourceInfo()).thenReturn(srcSet); try { when(catalog.getSourceInfo(sourceInfoRequest)).thenReturn(sourceInfoResponse); } catch (SourceUnavailableException e) { } BeansWrapper beansWrapper = new BeansWrapper(); Exchange exchange = mock(Exchange.class); when(exchange.getProperty("title")).thenReturn(TITLE); when(exchange.getProperty("header")).thenReturn(HEADER); when(exchange.getProperty("footer")).thenReturn(FOOTER); when(exchange.getProperty("catalog")).thenReturn(catalog); when(exchange.getProperty("beansWrapper")).thenReturn(beansWrapper); when(exchange.getProperty("sourceInfoReqEnterprise")).thenReturn(sourceInfoRequest); when(exchange.getProperty("htmlActionProviderList")).thenReturn(htmlActionProviderList); when(exchange.getProperty("metacardActionProviderList")).thenReturn( metacardActionProviderList); when(exchange.getProperty("thumbnailActionProviderList")).thenReturn( thumbnailActionProviderList); when(exchange.getProperty("resourceActionProviderList")).thenReturn( resourceActionProviderList); return exchange; }
<<<<<<< ======= private static MimeType JSON_MIME_TYPE; >>>>>>> <<<<<<< private BundleContext bundleContext; private int incrementer = 0; ======= private int incrementer = 0; >>>>>>> private int incrementer = 0; <<<<<<< private String bundleName; ======= >>>>>>> <<<<<<< bundleName = bundleContext.getBundle().getSymbolicName().toLowerCase() + incrementer; ======= String endpointName = ENDPOINT_NAME + incrementer; >>>>>>> String endpointName = ENDPOINT_NAME + incrementer;
<<<<<<< import javax.inject.Inject; import org.junit.runner.notification.RunNotifier; import org.junit.runners.model.FrameworkField; import org.junit.runners.model.FrameworkMethod; import org.junit.runners.model.InitializationError; import org.junit.runners.model.TestClass; ======= >>>>>>> import org.junit.runner.notification.RunNotifier; import org.junit.runner.notification.RunNotifier; import org.junit.runners.model.FrameworkMethod; import org.junit.runners.model.FrameworkMethod; import org.junit.runners.model.InitializationError; import org.junit.runners.model.InitializationError; <<<<<<< ======= import org.junit.runner.notification.RunNotifier; import org.junit.runners.model.FrameworkMethod; import org.junit.runners.model.InitializationError; >>>>>>> <<<<<<< if (! isRestart) { ======= if (isClean) >>>>>>> if (isClean) { <<<<<<< _services = services; bindFields(test, testClass); ======= _services = serviceManager; bindFields(test); >>>>>>> _services = services; bindFields(test);
<<<<<<< .filter(tenant -> tenant.type() == Tenant.Type.user && ((UserTenant) tenant).is(identity.getName()) || tenant.type() == Tenant.Type.athenz && userDomains.apply(identity).contains(((AthenzTenant) tenant).domain())) ======= .filter(tenant -> tenant.type() == Tenant.Type.athenz && userDomains.contains(((AthenzTenant) tenant).domain())) >>>>>>> .filter(tenant -> tenant.type() == Tenant.Type.athenz && userDomains.apply(identity).contains(((AthenzTenant) tenant).domain()))
<<<<<<< Set<ContainerEndpoint> endpoints = new LinkedHashSet<>(); ======= Set<String> rotationNames = new HashSet<>(); ApplicationCertificate applicationCertificate; >>>>>>> Set<ContainerEndpoint> endpoints = new LinkedHashSet<>(); ApplicationCertificate applicationCertificate; <<<<<<< ActivateResult result = deploy(applicationId, applicationPackage, zone, options, endpoints); ======= ActivateResult result = deploy(applicationId, applicationPackage, zone, options, rotationNames, applicationCertificate); >>>>>>> ActivateResult result = deploy(applicationId, applicationPackage, zone, options, endpoints, applicationCertificate); <<<<<<< Set<ContainerEndpoint> endpoints) { ======= Set<String> rotationNames, ApplicationCertificate applicationCertificate) { >>>>>>> Set<ContainerEndpoint> endpoints, ApplicationCertificate applicationCertificate) { <<<<<<< configServer.deploy(deploymentId, deployOptions, Set.of(), endpoints, applicationPackage.zippedContent()); ======= configServer.deploy(deploymentId, deployOptions, rotationNames, List.of(), applicationCertificate, applicationPackage.zippedContent()); >>>>>>> configServer.deploy(deploymentId, deployOptions, Set.of(), endpoints, applicationCertificate, applicationPackage.zippedContent());
<<<<<<< import com.yahoo.vespa.flags.Flags; import com.yahoo.vespa.flags.IntFlag; ======= import com.yahoo.vespa.flags.PermanentFlags; >>>>>>> import com.yahoo.vespa.flags.Flags; import com.yahoo.vespa.flags.IntFlag; import com.yahoo.vespa.flags.PermanentFlags; <<<<<<< this.enable_public_signup_flow = Flags.ENABLE_PUBLIC_SIGNUP_FLOW.bindTo(flagSource); this.maxTrialTenants = Flags.MAX_TRIAL_TENANTS.bindTo(flagSource); ======= this.enable_public_signup_flow = PermanentFlags.ENABLE_PUBLIC_SIGNUP_FLOW.bindTo(flagSource); >>>>>>> this.enable_public_signup_flow = PermanentFlags.ENABLE_PUBLIC_SIGNUP_FLOW.bindTo(flagSource); this.maxTrialTenants = Flags.MAX_TRIAL_TENANTS.bindTo(flagSource);
<<<<<<< @Override public boolean useNewRestapiHandler() { return useNewRestapiHandler; } ======= >>>>>>>
<<<<<<< import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.util.BlockPos; ======= >>>>>>> <<<<<<< String[] newArgs = new String[args.length - 1]; for (int i = 0; i < args.length - 1; i++) { newArgs[i] = args[i + 1]; } String msg = doCmd(sender, DimensionManager.getWorld(parseInt(args[0])), newArgs); if (msg != null) { ChatOutputHandler.chatConfirmation(sender, msg); } ======= arguments.confirm("/time set|add <t> [dim]"); arguments.confirm("/time freeze [dim]"); return; >>>>>>> arguments.confirm("/time set|add <t> [dim]"); arguments.confirm("/time freeze [dim]"); return; <<<<<<< public String doCmd(ICommandSender sender, World world, String[] args) throws CommandException ======= public static void parseFreeze(CommandParserArgs arguments) >>>>>>> public static void parseFreeze(CommandParserArgs arguments) throws CommandException <<<<<<< { world.setWorldTime(parseInt(args[1])); } WeatherTimeData wt = CommandDataManager.WTmap.get(world.provider.getDimensionId()); wt.freezeTime = world.getWorldTime(); return Translator.format("Set time to %s.", args[1]); ======= arguments.confirm(Translator.translate("Unfroze time in all worlds")); >>>>>>> arguments.confirm(Translator.translate("Unfroze time in all worlds")); <<<<<<< WeatherTimeData wt = CommandDataManager.WTmap.get(world.provider.getDimensionId()); if (args.length == 1) ======= for (World w : DimensionManager.getWorlds()) >>>>>>> for (World w : DimensionManager.getWorlds())
<<<<<<< private ProxyServer(Spec spec, ConfigSourceSet source, ConfigProxyStatistics statistics, TimingValues timingValues, boolean delayedResponseHandling, MemoryCache memoryCache, ConfigSourceClient configClient) { this.delayedResponses = new DelayedResponses(); ======= private ProxyServer(Spec spec, DelayedResponses delayedResponses, ConfigSourceSet source, TimingValues timingValues, boolean delayedResponseHandling, MemoryCache memoryCache, ConfigSourceClient configClient) { this.delayedResponses = delayedResponses; >>>>>>> private ProxyServer(Spec spec, ConfigSourceSet source, TimingValues timingValues, boolean delayedResponseHandling, MemoryCache memoryCache, ConfigSourceClient configClient) { this.delayedResponses = new DelayedResponses(); <<<<<<< return new ProxyServer(null, source, statistics, defaultTimingValues(), delayedResponseHandling, ======= return new ProxyServer(null, new DelayedResponses(), source, defaultTimingValues(), delayedResponseHandling, >>>>>>> return new ProxyServer(null, source, defaultTimingValues(), delayedResponseHandling, <<<<<<< ProxyServer proxyServer = new ProxyServer(new Spec(null, port), configSources, statistics, ======= DelayedResponses delayedResponses = new DelayedResponses(); ProxyServer proxyServer = new ProxyServer(new Spec(null, port), delayedResponses, configSources, >>>>>>> ProxyServer proxyServer = new ProxyServer(new Spec(null, port), configSources, <<<<<<< if (statistics != null) statistics.stop(); ======= >>>>>>>
<<<<<<< public void testModelWithReferencedIndexingCluster() { String services = "<?xml version=\"1.0\" encoding=\"utf-8\" ?>\n" + "<services version=\"1.0\">\n" + "\n" + " <admin version=\"2.0\">\n" + " <adminserver hostalias=\"vespa-1\"/>\n" + " <configservers>\n" + " <configserver hostalias=\"vespa-1\"/>\n" + " </configservers>\n" + " </admin>\n" + "\n" + " <container id=\"container\" version=\"1.0\">\n" + " <document-processing/>\n" + " <document-api/>\n" + " <search/>\n" + " <nodes jvmargs=\"-Xms512m -Xmx512m\">\n" + " <node hostalias=\"vespa-1\"/>\n" + " </nodes>\n" + " </container>\n" + "\n" + " <content id=\"storage\" version=\"1.0\">\n" + " <search>\n" + " <visibility-delay>1.0</visibility-delay>\n" + " </search>\n" + " <redundancy>2</redundancy>\n" + " <documents>\n" + " <document type=\"type1\" mode=\"index\"/>\n" + " <document-processing cluster=\"container\"/>\n" + " </documents>\n" + " <nodes>\n" + " <node hostalias=\"vespa-1\" distribution-key=\"0\"/>\n" + " </nodes>\n" + " </content>\n" + "\n" + "</services>"; VespaModel model = createNonProvisionedMultitenantModel(services); assertThat(model.getRoot().getHostSystem().getHosts().size(), is(1)); ContentCluster content = model.getContentClusters().get("storage"); assertEquals(1, content.getRootGroup().getNodes().size()); ContainerCluster controller = content.getClusterControllers(); assertEquals(1, controller.getContainers().size()); } @Test ======= public void testSharedNodesNotHosted() { String hosts = "<?xml version=\"1.0\" encoding=\"utf-8\" ?>\n" + "<hosts>\n" + " <host name=\"vespa-1\">\n" + " <alias>vespa-1</alias>\n" + " </host>\n" + " <host name=\"vespa-2\">\n" + " <alias>vespa-2</alias>\n" + " </host>\n" + " <host name=\"vespa-3\">\n" + " <alias>vespa-3</alias>\n" + " </host>\n" + "</hosts>"; String services = "<?xml version=\"1.0\" encoding=\"utf-8\" ?>\n" + "<services version=\"1.0\">\n" + "\n" + " <admin version=\"2.0\">\n" + " <adminserver hostalias=\"vespa-1\"/>\n" + " <configservers>\n" + " <configserver hostalias=\"vespa-1\"/>\n" + " </configservers>\n" + " </admin>\n" + "\n" + " <container id=\"container\" version=\"1.0\">\n" + " <document-processing/>\n" + " <document-api/>\n" + " <search/>\n" + " <nodes jvmargs=\"-Xms512m -Xmx512m\">\n" + " <node hostalias=\"vespa-1\"/>\n" + " <node hostalias=\"vespa-2\"/>\n" + " <node hostalias=\"vespa-3\"/>\n" + " </nodes>\n" + " </container>\n" + "\n" + " <content id=\"storage\" version=\"1.0\">\n" + " <search>\n" + " <visibility-delay>1.0</visibility-delay>\n" + " </search>\n" + " <redundancy>2</redundancy>\n" + " <documents>\n" + " <document type=\"type1\" mode=\"index\"/>\n" + " <document-processing cluster=\"container\"/>\n" + " </documents>\n" + " <nodes>\n" + " <node hostalias=\"vespa-1\" distribution-key=\"0\"/>\n" + " <node hostalias=\"vespa-2\" distribution-key=\"1\"/>\n" + " <node hostalias=\"vespa-3\" distribution-key=\"2\"/>\n" + " </nodes>\n" + " </content>\n" + "\n" + "</services>"; VespaModel model = createNonProvisionedModel(false, hosts, services); assertEquals(3, model.getRoot().getHostSystem().getHosts().size()); ContentCluster content = model.getContentClusters().get("storage"); assertEquals(3, content.getRootGroup().getNodes().size()); } @Test >>>>>>> public void testModelWithReferencedIndexingCluster() { String services = "<?xml version=\"1.0\" encoding=\"utf-8\" ?>\n" + "<services version=\"1.0\">\n" + "\n" + " <admin version=\"2.0\">\n" + " <adminserver hostalias=\"vespa-1\"/>\n" + " <configservers>\n" + " <configserver hostalias=\"vespa-1\"/>\n" + " </configservers>\n" + " </admin>\n" + "\n" + " <container id=\"container\" version=\"1.0\">\n" + " <document-processing/>\n" + " <document-api/>\n" + " <search/>\n" + " <nodes jvmargs=\"-Xms512m -Xmx512m\">\n" + " <node hostalias=\"vespa-1\"/>\n" + " </nodes>\n" + " </container>\n" + "\n" + " <content id=\"storage\" version=\"1.0\">\n" + " <search>\n" + " <visibility-delay>1.0</visibility-delay>\n" + " </search>\n" + " <redundancy>2</redundancy>\n" + " <documents>\n" + " <document type=\"type1\" mode=\"index\"/>\n" + " <document-processing cluster=\"container\"/>\n" + " </documents>\n" + " <nodes>\n" + " <node hostalias=\"vespa-1\" distribution-key=\"0\"/>\n" + " </nodes>\n" + " </content>\n" + "\n" + "</services>"; VespaModel model = createNonProvisionedMultitenantModel(services); assertThat(model.getRoot().getHostSystem().getHosts().size(), is(1)); ContentCluster content = model.getContentClusters().get("storage"); assertEquals(1, content.getRootGroup().getNodes().size()); ContainerCluster controller = content.getClusterControllers(); assertEquals(1, controller.getContainers().size()); } @Test public void testSharedNodesNotHosted() { String hosts = "<?xml version=\"1.0\" encoding=\"utf-8\" ?>\n" + "<hosts>\n" + " <host name=\"vespa-1\">\n" + " <alias>vespa-1</alias>\n" + " </host>\n" + " <host name=\"vespa-2\">\n" + " <alias>vespa-2</alias>\n" + " </host>\n" + " <host name=\"vespa-3\">\n" + " <alias>vespa-3</alias>\n" + " </host>\n" + "</hosts>"; String services = "<?xml version=\"1.0\" encoding=\"utf-8\" ?>\n" + "<services version=\"1.0\">\n" + "\n" + " <admin version=\"2.0\">\n" + " <adminserver hostalias=\"vespa-1\"/>\n" + " <configservers>\n" + " <configserver hostalias=\"vespa-1\"/>\n" + " </configservers>\n" + " </admin>\n" + "\n" + " <container id=\"container\" version=\"1.0\">\n" + " <document-processing/>\n" + " <document-api/>\n" + " <search/>\n" + " <nodes jvmargs=\"-Xms512m -Xmx512m\">\n" + " <node hostalias=\"vespa-1\"/>\n" + " <node hostalias=\"vespa-2\"/>\n" + " <node hostalias=\"vespa-3\"/>\n" + " </nodes>\n" + " </container>\n" + "\n" + " <content id=\"storage\" version=\"1.0\">\n" + " <search>\n" + " <visibility-delay>1.0</visibility-delay>\n" + " </search>\n" + " <redundancy>2</redundancy>\n" + " <documents>\n" + " <document type=\"type1\" mode=\"index\"/>\n" + " <document-processing cluster=\"container\"/>\n" + " </documents>\n" + " <nodes>\n" + " <node hostalias=\"vespa-1\" distribution-key=\"0\"/>\n" + " <node hostalias=\"vespa-2\" distribution-key=\"1\"/>\n" + " <node hostalias=\"vespa-3\" distribution-key=\"2\"/>\n" + " </nodes>\n" + " </content>\n" + "\n" + "</services>"; VespaModel model = createNonProvisionedModel(false, hosts, services); assertEquals(3, model.getRoot().getHostSystem().getHosts().size()); ContentCluster content = model.getContentClusters().get("storage"); assertEquals(3, content.getRootGroup().getNodes().size()); } @Test
<<<<<<< private String createContainerEnvironmentSettings(Environment environment, ContainerNodeSpec nodeSpec) { ObjectMapper objectMapper = new ObjectMapper(); String configServers = environment.getConfigServerUris().stream() .map(URI::getHost) .collect(Collectors.joining(",")); ContainerEnvironmentSettings settings = new ContainerEnvironmentSettings(); settings.set("configServerAddresses", configServers); settings.set("nodeType", nodeSpec.nodeType); try { return objectMapper.writeValueAsString(settings); } catch (JsonProcessingException e) { throw new IllegalArgumentException("Could not write " + settings, e); } } private class ContainerEnvironmentSettings { @JsonProperty(value="environmentVariables") private final Map<String, Object> variables = new HashMap<>(); void set(String argument, Object value) { variables.put(argument, value); } } ======= /** * Returns map of directories to mount and whether they should be writable by everyone */ private static Map<Path, Boolean> getDirectoriesToMount(Environment environment) { final Map<Path, Boolean> directoriesToMount = new HashMap<>(); directoriesToMount.put(Paths.get("/etc/yamas-agent"), true); directoriesToMount.put(Paths.get("/etc/filebeat"), true); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/daemontools_y"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/jdisc_core"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/langdetect/"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/vespa"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/yca"), true); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/yck"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/yell"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/ykeykey"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/ykeykeyd"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/yms_agent"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/ysar"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/ystatus"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/zpu"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/cache"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/crash"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/db/jdisc"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/db/vespa"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/jdisc_container"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/jdisc_core"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/maven"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/run"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/scoreboards"), true); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/service"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/share"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/spool"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/vespa"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/yca"), true); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/ycore++"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/zookeeper"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/zpe"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("tmp"), false); return directoriesToMount; } >>>>>>> private String createContainerEnvironmentSettings(Environment environment, ContainerNodeSpec nodeSpec) { ObjectMapper objectMapper = new ObjectMapper(); String configServers = environment.getConfigServerUris().stream() .map(URI::getHost) .collect(Collectors.joining(",")); ContainerEnvironmentSettings settings = new ContainerEnvironmentSettings(); settings.set("configServerAddresses", configServers); settings.set("nodeType", nodeSpec.nodeType); try { return objectMapper.writeValueAsString(settings); } catch (JsonProcessingException e) { throw new IllegalArgumentException("Could not write " + settings, e); } } private class ContainerEnvironmentSettings { @JsonProperty(value="environmentVariables") private final Map<String, Object> variables = new HashMap<>(); void set(String argument, Object value) { variables.put(argument, value); } } /** * Returns map of directories to mount and whether they should be writable by everyone */ private static Map<Path, Boolean> getDirectoriesToMount(Environment environment) { final Map<Path, Boolean> directoriesToMount = new HashMap<>(); directoriesToMount.put(Paths.get("/etc/yamas-agent"), true); directoriesToMount.put(Paths.get("/etc/filebeat"), true); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/daemontools_y"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/jdisc_core"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/langdetect/"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/vespa"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/yca"), true); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/yck"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/yell"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/ykeykey"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/ykeykeyd"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/yms_agent"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/ysar"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/ystatus"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("logs/zpu"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/cache"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/crash"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/db/jdisc"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/db/vespa"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/jdisc_container"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/jdisc_core"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/maven"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/run"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/scoreboards"), true); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/service"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/share"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/spool"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/vespa"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/yca"), true); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/ycore++"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/zookeeper"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("var/zpe"), false); directoriesToMount.put(environment.pathInNodeUnderVespaHome("tmp"), false); return directoriesToMount; }
<<<<<<< controllerTester.controller().applications().lockedOrThrow(application.id(), lockedApplication -> { ======= try (Lock lock = controllerTester.controller().applications().lock(application.id())) { LockedApplication lockedApplication = controllerTester.controller().applications() .require(application.id(), lock); lockedApplication = lockedApplication.with(new ApplicationMetrics(0.5, 0.7)); >>>>>>> controllerTester.controller().applications().lockedOrThrow(application.id(), lockedApplication -> { lockedApplication = lockedApplication.with(new ApplicationMetrics(0.5, 0.7)); <<<<<<< }); ======= controllerTester.controller().applications().store(lockedApplication); } >>>>>>> controllerTester.controller().applications().store(lockedApplication); });
<<<<<<< final Integer containerPid = getContainer(containerName.asString()) .filter(container -> container.state.isRunning()) .map(container -> container.pid) .orElseThrow(() -> new RuntimeException("PID not found for container: " + containerName.asString())); ======= final Integer containerPid = docker.getContainer(containerName) .flatMap(container -> container.pid) .orElseThrow(() -> new RuntimeException("PID not found for container with name: " + containerName.asString())); >>>>>>> final Integer containerPid = docker.getContainer(containerName) .filter(container -> container.state.isRunning()) .map(container -> container.pid) .orElseThrow(() -> new RuntimeException("PID not found for container with name: " + containerName.asString()));
<<<<<<< private static final Quota UNLIMITED = new Quota(Optional.empty(), Optional.empty()); ======= >>>>>>> private static final Quota UNLIMITED = new Quota(Optional.empty(), Optional.empty()); /** The max size of a cluster inside application */ <<<<<<< private final Optional<BigDecimal> budget; // TODO: Remove constructor once Vespa < 7.300 is gone from production public Quota(Optional<Integer> maxClusterSize, Optional<Integer> budget) { this(maxClusterSize, budget.map(BigDecimal::new), true); } ======= /** The max budget in dollars per hour */ private final Optional<Integer> budget; >>>>>>> /** The max budget in dollars per hour */ private final Optional<BigDecimal> budget; // TODO: Remove constructor once Vespa < 7.300 is gone from production public Quota(Optional<Integer> maxClusterSize, Optional<Integer> budget) { this(maxClusterSize, budget.map(BigDecimal::new), true); }
<<<<<<< import com.yahoo.vespa.flags.Flags; import com.yahoo.vespa.flags.IntFlag; ======= import com.yahoo.vespa.flags.PermanentFlags; >>>>>>> import com.yahoo.vespa.flags.Flags; import com.yahoo.vespa.flags.IntFlag; import com.yahoo.vespa.flags.PermanentFlags; <<<<<<< this.enablePublicSignup = Flags.ENABLE_PUBLIC_SIGNUP_FLOW.bindTo(flagSource); this.maxTrialTenants = Flags.MAX_TRIAL_TENANTS.bindTo(flagSource); ======= this.enablePublicSignup = PermanentFlags.ENABLE_PUBLIC_SIGNUP_FLOW.bindTo(flagSource); >>>>>>> this.enablePublicSignup = PermanentFlags.ENABLE_PUBLIC_SIGNUP_FLOW.bindTo(flagSource); this.maxTrialTenants = Flags.MAX_TRIAL_TENANTS.bindTo(flagSource);
<<<<<<< private static String connectionSpec(ZookeeperServerConfig config) { return config.server().stream() .map(server -> server.hostname() + ":" + config.clientPort()) .collect(Collectors.joining(",")); ======= private static boolean retryOn(KeeperException e) { return e instanceof KeeperException.ReconfigInProgress || e instanceof KeeperException.ConnectionLossException || e instanceof KeeperException.NewConfigNoQuorum; } private static String localConnectionSpec(ZookeeperServerConfig config) { return HostName.getLocalhost() + ":" + config.clientPort(); >>>>>>> private static String localConnectionSpec(ZookeeperServerConfig config) { return HostName.getLocalhost() + ":" + config.clientPort();
<<<<<<< return new LocalSession(tenant, sessionId, FilesApplicationPackage.fromFile(testApp), zkc, sessionDir, applications, new HostRegistry<>()); ======= return new LocalSession(tenant, sessionId, preparer, FilesApplicationPackage.fromFile(testApp), zkc, sessionDir, applications); >>>>>>> return new LocalSession(tenant, sessionId, FilesApplicationPackage.fromFile(testApp), zkc, sessionDir, applications);
<<<<<<< import com.yahoo.config.provision.DockerImage; import com.yahoo.log.LogLevel; ======= import java.util.logging.Level; >>>>>>> import com.yahoo.config.provision.DockerImage; import java.util.logging.Level;
<<<<<<< LocalSession session = new LocalSession(tenantName, sessionId, applicationPackage, sessionZKClient, getSessionAppDir(sessionId), applicationRepo, hostRegistry); ======= LocalSession session = new LocalSession(tenantName, sessionId, sessionPreparer, applicationPackage, sessionZKClient, getSessionAppDir(sessionId), applicationRepo); >>>>>>> LocalSession session = new LocalSession(tenantName, sessionId, applicationPackage, sessionZKClient, getSessionAppDir(sessionId), applicationRepo); <<<<<<< SessionZooKeeperClient sessionZooKeeperClient = createSessionZooKeeperClient(sessionId); return new LocalSession(tenantName, sessionId, applicationPackage, sessionZooKeeperClient, getSessionAppDir(sessionId), applicationRepo, hostRegistry); ======= SessionZooKeeperClient sessionZooKeeperClient = createSessionZooKeeperClient(getSessionPath(sessionId)); return new LocalSession(tenantName, sessionId, sessionPreparer, applicationPackage, sessionZooKeeperClient, getSessionAppDir(sessionId), applicationRepo); >>>>>>> SessionZooKeeperClient sessionZooKeeperClient = createSessionZooKeeperClient(sessionId); return new LocalSession(tenantName, sessionId, applicationPackage, sessionZooKeeperClient, getSessionAppDir(sessionId), applicationRepo); <<<<<<< SessionZooKeeperClient sessionZKClient = createSessionZooKeeperClient(sessionId); return new LocalSession(tenantName, sessionId, applicationPackage, sessionZKClient, getSessionAppDir(sessionId), applicationRepo, hostRegistry); ======= Path sessionIdPath = sessionsPath.append(String.valueOf(sessionId)); SessionZooKeeperClient sessionZKClient = createSessionZooKeeperClient(sessionIdPath); return new LocalSession(tenantName, sessionId, sessionPreparer, applicationPackage, sessionZKClient, getSessionAppDir(sessionId), applicationRepo); >>>>>>> SessionZooKeeperClient sessionZKClient = createSessionZooKeeperClient(sessionId); return new LocalSession(tenantName, sessionId, applicationPackage, sessionZKClient, getSessionAppDir(sessionId), applicationRepo);
<<<<<<< import com.yahoo.metrics.simple.MetricReceiver; import com.yahoo.vespa.hosted.dockerapi.metrics.MetricReceiverWrapper; import org.apache.commons.io.IOUtils; import org.junit.Ignore; ======= >>>>>>> import com.yahoo.metrics.simple.MetricReceiver; import com.yahoo.vespa.hosted.dockerapi.metrics.MetricReceiverWrapper; import org.apache.commons.io.IOUtils; import org.junit.Ignore; <<<<<<< import java.net.NetworkInterface; import java.net.SocketException; import java.net.URL; import java.util.Collections; ======= >>>>>>> import java.net.URL; <<<<<<< * LINUX: * 1. Remove Ignore annotations * 2. Change ownership of docker.sock * $ sudo chown <your username> /var/run/docker.sock * 3. (Temporary) Manually create the docker network used by DockerImpl by running: * $ sudo docker network create --ipv6 --gateway=<your local IPv6 address> --subnet=fe80::1/16 habla * 4. (Temporary) Manually build docker test image. Inside src/test/resources/simple-ipv6-server run: * $ sudo docker build -t "simple-ipv6-server:Dockerfile" . * 5. (Temporary) Comment out createDockerImage() and shutdown() * * * TIPS: * For cleaning up your local docker machine (DON'T DO THIS ON PROD) * docker stop $(docker ps -a -q) * docker rm $(docker ps -a -q) * ======= >>>>>>> * TIPS: * For cleaning up your local docker machine (DON'T DO THIS ON PROD) * docker stop $(docker ps -a -q) * docker rm $(docker ps -a -q) * <<<<<<< ======= createDockerImage(docker); ContainerName containerName = new ContainerName("foo"); docker.stopContainer(containerName); docker.deleteContainer(containerName); assertThat(docker.getAllManagedContainers().isEmpty(), is(true)); docker.createContainerCommand(dockerImage, containerName, "hostName1").create(); List<Container> containers = docker.getAllManagedContainers(); assertThat(containers.size(), is(1)); docker.deleteContainer(containerName); >>>>>>> <<<<<<< setDocker(); ======= docker = new DockerImpl(dockerConfig); createDockerTestNetworkIfNeeded(); >>>>>>> setDocker();
<<<<<<< public static final UnboundBooleanFlag USE_LB_STATUS_FILE = defineFeatureFlag( "use-lb-status-file", false, "Serve status.html from the new path", "Takes effect on restart of Docker container", APPLICATION_ID, HOSTNAME); ======= public static final UnboundBooleanFlag USE_HTTPS_LOAD_BALANCER_UPSTREAM = defineFeatureFlag( "use-https-load-balancer-upstream", false, "Use https between load balancer and upstream containers", "Takes effect at redeployment", APPLICATION_ID); >>>>>>> public static final UnboundBooleanFlag USE_LB_STATUS_FILE = defineFeatureFlag( "use-lb-status-file", false, "Serve status.html from the new path", "Takes effect on restart of Docker container", APPLICATION_ID, HOSTNAME); public static final UnboundBooleanFlag USE_HTTPS_LOAD_BALANCER_UPSTREAM = defineFeatureFlag( "use-https-load-balancer-upstream", false, "Use https between load balancer and upstream containers", "Takes effect at redeployment", APPLICATION_ID);
<<<<<<< ======= private final double defaultSoftStartSeconds; private final boolean useBucketSpaceMetric; private final String proxyProtocol; private final Optional<AthenzDomain> athenzDomain; >>>>>>> private final double defaultSoftStartSeconds; private final String proxyProtocol; private final Optional<AthenzDomain> athenzDomain; <<<<<<< ======= defaultSoftStartSeconds = Flags.DEFAULT_SOFT_START_SECONDS.bindTo(flagSource) .with(FetchVector.Dimension.APPLICATION_ID, applicationId.serializedForm()).value(); defaultTopKprobability = Flags.DEFAULT_TOP_K_PROBABILITY.bindTo(flagSource) .with(FetchVector.Dimension.APPLICATION_ID, applicationId.serializedForm()).value(); this.useBucketSpaceMetric = Flags.USE_BUCKET_SPACE_METRIC.bindTo(flagSource) .with(FetchVector.Dimension.APPLICATION_ID, applicationId.serializedForm()).value(); this.proxyProtocol = Flags.PROXY_PROTOCOL.bindTo(flagSource) .with(FetchVector.Dimension.APPLICATION_ID, applicationId.serializedForm()).value(); this.athenzDomain = athenzDomain; >>>>>>> defaultSoftStartSeconds = Flags.DEFAULT_SOFT_START_SECONDS.bindTo(flagSource) .with(FetchVector.Dimension.APPLICATION_ID, applicationId.serializedForm()).value(); defaultTopKprobability = Flags.DEFAULT_TOP_K_PROBABILITY.bindTo(flagSource) .with(FetchVector.Dimension.APPLICATION_ID, applicationId.serializedForm()).value(); this.proxyProtocol = Flags.PROXY_PROTOCOL.bindTo(flagSource) .with(FetchVector.Dimension.APPLICATION_ID, applicationId.serializedForm()).value(); this.athenzDomain = athenzDomain; <<<<<<< public boolean useBucketSpaceMetric() { return true; } ======= public double defaultSoftStartSeconds() { return 0; } @Override public double defaultTopKProbability() { return defaultTopKprobability; } @Override public boolean useBucketSpaceMetric() { return useBucketSpaceMetric; } @Override public boolean useNewAthenzFilter() { return true; } @Override public String proxyProtocol() { return proxyProtocol; } @Override public Optional<AthenzDomain> athenzDomain() { return athenzDomain; } >>>>>>> public boolean useBucketSpaceMetric() { return true; } @Override public boolean useNewAthenzFilter() { return true; } @Override public String proxyProtocol() { return proxyProtocol; } @Override public Optional<AthenzDomain> athenzDomain() { return athenzDomain; }
<<<<<<< if (deployState.isHosted()) { // request 1 node ClusterSpec clusterSpec = ClusterSpec.request(ClusterSpec.Type.container, ClusterSpec.Id.from(cluster.getName())) .vespaVersion(deployState.getWantedNodeVespaVersion()) .dockerImageRepo(deployState.getWantedDockerImageRepo()) .build(); Capacity capacity = Capacity.fromCount(1, Optional.empty(), false, !deployState.getProperties().isBootstrap()); return hostSystem.allocateHosts(clusterSpec, capacity, 1, logger).keySet().iterator().next(); ======= if (deployState.isHosted()) { Optional<HostResource> singleContentHost = getHostResourceFromContentClusters(cluster, containerElement, context); if (singleContentHost.isPresent()) { // there is a content cluster; put the container on its first node return singleContentHost.get(); } else { // request 1 node ClusterSpec clusterSpec = ClusterSpec.request(ClusterSpec.Type.container, ClusterSpec.Id.from(cluster.getName()), deployState.getWantedNodeVespaVersion(), false, Optional.empty(), deployState.getWantedDockerImageRepo()); Capacity capacity = Capacity.fromCount(1, Optional.empty(), false, ! deployState.getProperties().isBootstrap()); return hostSystem.allocateHosts(clusterSpec, capacity, 1, logger).keySet().iterator().next(); } >>>>>>> if (deployState.isHosted()) { Optional<HostResource> singleContentHost = getHostResourceFromContentClusters(cluster, containerElement, context); if (singleContentHost.isPresent()) { // there is a content cluster; put the container on its first node return singleContentHost.get(); } else { // request 1 node ClusterSpec clusterSpec = ClusterSpec.request(ClusterSpec.Type.container, ClusterSpec.Id.from(cluster.getName())) .vespaVersion(deployState.getWantedNodeVespaVersion()) .dockerImageRepo(deployState.getWantedDockerImageRepo()) .build(); Capacity capacity = Capacity.fromCount(1, Optional.empty(), false, ! deployState.getProperties().isBootstrap()); return hostSystem.allocateHosts(clusterSpec, capacity, 1, logger).keySet().iterator().next(); }
<<<<<<< public LockedApplication with(ZoneId zoneId, List<ClusterMetrics> clusterMetrics) { Deployment deployment = deployments.get(zoneId); if (deployment == null) return this; // No longer deployed in this zone. return with(deployment.withClusterMetrics(clusterMetrics)); } ======= public LockedApplication withApplicationCertificate(Optional<ApplicationCertificate> applicationCertificate) { return new LockedApplication(lock, id, createdAt, deploymentSpec, validationOverrides, deployments, deploymentJobs, change, outstandingChange, ownershipIssueId, owner, majorVersion, metrics, pemDeployKey, rotations, rotationStatus, applicationCertificate); } >>>>>>> public LockedApplication with(ZoneId zoneId, List<ClusterMetrics> clusterMetrics) { Deployment deployment = deployments.get(zoneId); if (deployment == null) return this; // No longer deployed in this zone. return with(deployment.withClusterMetrics(clusterMetrics)); } public LockedApplication withApplicationCertificate(Optional<ApplicationCertificate> applicationCertificate) { return new LockedApplication(lock, id, createdAt, deploymentSpec, validationOverrides, deployments, deploymentJobs, change, outstandingChange, ownershipIssueId, owner, majorVersion, metrics, pemDeployKey, rotations, rotationStatus, applicationCertificate); }
<<<<<<< Set<ContainerEndpoint> containerEndpoints, byte[] content) { ======= List<ContainerEndpoint> containerEndpoints, ApplicationCertificate applicationCertificate, byte[] content) { >>>>>>> Set<ContainerEndpoint> containerEndpoints, ApplicationCertificate applicationCertificate, byte[] content) {
<<<<<<< Set<String> ALLOWED_PROTOCOLS = Set.of("TLSv1.2"); // TODO Enable TLSv1.3 String SSL_CONTEXT_VERSION = "TLS"; // Use SSLContext implementations that supports all TLS versions ======= Set<String> ALLOWED_PROTOCOLS = com.yahoo.vespa.jdk8compat.Set.of("TLSv1.2"); // TODO Enable TLSv1.3 String SSL_CONTEXT_VERSION = "TLSv1.2"; // TODO Enable TLSv1.3 >>>>>>> Set<String> ALLOWED_PROTOCOLS = com.yahoo.vespa.jdk8compat.Set.of("TLSv1.2"); // TODO Enable TLSv1.3 String SSL_CONTEXT_VERSION = "TLS"; // Use SSLContext implementations that supports all TLS versions
<<<<<<< import java.text.SimpleDateFormat; import java.util.Date; import java.util.LinkedHashMap; import java.util.LinkedList; import java.util.Map; ======= import java.time.Duration; import java.time.Instant; >>>>>>> import java.text.SimpleDateFormat; import java.util.Date; import java.util.LinkedHashMap; import java.util.LinkedList; import java.util.Map; import java.time.Duration; import java.time.Instant; <<<<<<< if (!workToDoNow.get()) { addDebugMessage("Signaling work to be done"); } workToDoNow.set(true); ======= >>>>>>> if (!workToDoNow.get()) { addDebugMessage("Signaling work to be done"); }
<<<<<<< tester.makeReadyHosts(4, defaultResources).deployZoneApp(); tester.prepareAndActivateInfraApplication(ProvisioningTester.makeApplicationId(), NodeType.host); ======= tester.makeReadyHosts(4, defaultResources).activateTenantHosts(); tester.prepareAndActivateInfraApplication(tester.makeApplicationId(), NodeType.host); >>>>>>> tester.makeReadyHosts(4, defaultResources).activateTenantHosts(); tester.prepareAndActivateInfraApplication(ProvisioningTester.makeApplicationId(), NodeType.host); <<<<<<< tester.makeReadyHosts(4, defaultResources).deployZoneApp(); tester.prepareAndActivateInfraApplication(ProvisioningTester.makeApplicationId(), NodeType.host); ======= tester.makeReadyHosts(4, defaultResources).activateTenantHosts(); tester.prepareAndActivateInfraApplication(tester.makeApplicationId(), NodeType.host); >>>>>>> tester.makeReadyHosts(4, defaultResources).activateTenantHosts(); tester.prepareAndActivateInfraApplication(ProvisioningTester.makeApplicationId(), NodeType.host); <<<<<<< ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(4, defaultResources).deployZoneApp(); ======= ApplicationId application = tester.makeApplicationId(); tester.makeReadyHosts(4, defaultResources).activateTenantHosts(); >>>>>>> ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(4, defaultResources).activateTenantHosts(); <<<<<<< ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).deployZoneApp(); ======= ApplicationId application = tester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).activateTenantHosts(); >>>>>>> ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).activateTenantHosts(); <<<<<<< ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).deployZoneApp(); ======= ApplicationId application = tester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).activateTenantHosts(); >>>>>>> ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).activateTenantHosts(); <<<<<<< ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).deployZoneApp(); ======= ApplicationId application = tester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).activateTenantHosts(); >>>>>>> ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).activateTenantHosts(); <<<<<<< ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(4, large).deployZoneApp(); ======= ApplicationId application = tester.makeApplicationId(); tester.makeReadyHosts(4, large).activateTenantHosts(); >>>>>>> ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(4, large).activateTenantHosts(); <<<<<<< ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(14, defaultResources).deployZoneApp(); ======= ApplicationId application = tester.makeApplicationId(); tester.makeReadyHosts(14, defaultResources).activateTenantHosts(); >>>>>>> ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(14, defaultResources).activateTenantHosts(); <<<<<<< tester.makeReadyHosts(10, defaultResources).deployZoneApp(); ApplicationId application = ProvisioningTester.makeApplicationId(); ======= tester.makeReadyHosts(10, defaultResources).activateTenantHosts(); ApplicationId application = tester.makeApplicationId(); >>>>>>> tester.makeReadyHosts(10, defaultResources).activateTenantHosts(); ApplicationId application = ProvisioningTester.makeApplicationId(); <<<<<<< tester.makeReadyHosts(9, defaultResources).deployZoneApp(); // need 2+2+3+3=10 ApplicationId application = ProvisioningTester.makeApplicationId(); ======= tester.makeReadyHosts(9, defaultResources).activateTenantHosts(); // need 2+2+3+3=10 ApplicationId application = tester.makeApplicationId(); >>>>>>> tester.makeReadyHosts(9, defaultResources).activateTenantHosts(); // need 2+2+3+3=10 ApplicationId application = ProvisioningTester.makeApplicationId(); <<<<<<< tester.makeReadyHosts(13, defaultResources).deployZoneApp(); ApplicationId application = ProvisioningTester.makeApplicationId(); ======= tester.makeReadyHosts(13, defaultResources).activateTenantHosts(); ApplicationId application = tester.makeApplicationId(); >>>>>>> tester.makeReadyHosts(13, defaultResources).activateTenantHosts(); ApplicationId application = ProvisioningTester.makeApplicationId(); <<<<<<< tester.makeReadyHosts(13, defaultResources).deployZoneApp(); ApplicationId application = ProvisioningTester.makeApplicationId(); ======= tester.makeReadyHosts(13, defaultResources).activateTenantHosts(); ApplicationId application = tester.makeApplicationId(); >>>>>>> tester.makeReadyHosts(13, defaultResources).activateTenantHosts(); ApplicationId application = ProvisioningTester.makeApplicationId(); <<<<<<< tester.makeReadyHosts(4, defaultResources).deployZoneApp(); ApplicationId application = ProvisioningTester.makeApplicationId(); ======= tester.makeReadyHosts(4, defaultResources).activateTenantHosts(); ApplicationId application = tester.makeApplicationId(); >>>>>>> tester.makeReadyHosts(4, defaultResources).activateTenantHosts(); ApplicationId application = ProvisioningTester.makeApplicationId(); <<<<<<< ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).deployZoneApp(); ======= ApplicationId application = tester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).activateTenantHosts(); >>>>>>> ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(10, defaultResources).activateTenantHosts(); <<<<<<< ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(2, defaultResources).deployZoneApp(); ======= ApplicationId application = tester.makeApplicationId(); tester.makeReadyHosts(2, defaultResources).activateTenantHosts(); >>>>>>> ApplicationId application = ProvisioningTester.makeApplicationId(); tester.makeReadyHosts(2, defaultResources).activateTenantHosts();
<<<<<<< import com.google.protobuf.InvalidProtocolBufferException; ======= import com.google.protobuf.Any; import com.google.protobuf.ByteString; >>>>>>> import com.google.protobuf.InvalidProtocolBufferException; import com.google.protobuf.Any; import com.google.protobuf.ByteString;
<<<<<<< import org.tron.service.check.CheckTransaction; import org.tron.service.check.TransactionId; ======= import org.tron.client.SideChainGatewayApi; import org.tron.common.config.Args; import org.tron.common.utils.WalletUtil; >>>>>>> import org.tron.service.check.CheckTransaction; import org.tron.service.check.TransactionId; import org.tron.common.config.Args; import org.tron.common.utils.WalletUtil; <<<<<<< TransactionId txId = MainChainGatewayApi .withdrawTRC10(this.from, this.trc10, this.value, this.txData); ======= String txId; if (this.trc10.equalsIgnoreCase("2000000")) { txId = MainChainGatewayApi .withdrawTRC20(this.from, WalletUtil.encode58Check(Args.getInstance().getSunTokenAddress()), this.value, this.txData); } else { txId = MainChainGatewayApi .withdrawTRC10(this.from, this.trc10, this.value, this.txData); } >>>>>>> TransactionId txId; if (this.trc10.equalsIgnoreCase("2000000")) { txId = MainChainGatewayApi .withdrawTRC20(this.from, WalletUtil.encode58Check(Args.getInstance().getSunTokenAddress()), this.value, this.txData); } else { txId = MainChainGatewayApi .withdrawTRC10(this.from, this.trc10, this.value, this.txData); } <<<<<<< CheckTransaction.getInstance().submitCheck(txId); ======= >>>>>>> CheckTransaction.getInstance().submitCheck(txId);
<<<<<<< @Getter @Setter private int energyFee; @Getter @Setter private long totalEnergyLimit; ======= @Getter @Setter private int sideChainChargingBandwidth; >>>>>>> @Getter @Setter private int energyFee; @Getter @Setter private long totalEnergyLimit; @Getter @Setter private int sideChainChargingBandwidth; <<<<<<< ======= INSTANCE.energyChargingSwitchOn = config.hasPath("committee.energyChargingSwitchOn") ? config .getInt("committee.energyChargingSwitchOn") : 0; INSTANCE.sideChainChargingType = config.hasPath("sidechain.chargingType") ? config .getInt("sidechain.chargingType") : 0; INSTANCE.sideChainChargingBandwidth = config.hasPath("sidechain.chargingBandwidth") ? config .getInt("sidechain.chargingBandwidth") : 0; >>>>>>>
<<<<<<< /* * Copyright (C) 2012-2019 52°North Initiative for Geospatial Open Source ======= /** * Copyright (C) 2012-2020 52°North Initiative for Geospatial Open Source >>>>>>> /* * Copyright (C) 2012-2020 52°North Initiative for Geospatial Open Source
<<<<<<< Manager.getInstance().setProcessFail(eventActuator.getNonceKey()); String msg = ErrorCode.CREATE_TRANSACTION_FAIL .getMsg(ByteArray.toStr(eventActuator.getNonceKey())); ======= Manager.getInstance().setProcessStatus(eventActuator.getNonceKey(), NonceStatus.FAIL); String msg = ErrorCode.CREATE_TRANSACTION_FAIL.getMsg("fail"); >>>>>>> Manager.getInstance().setProcessStatus(eventActuator.getNonceKey(), NonceStatus.FAIL); String msg = ErrorCode.CREATE_TRANSACTION_FAIL .getMsg(ByteArray.toStr(eventActuator.getNonceKey()));
<<<<<<< .mintToken(sideContractAddress, this.from, this.amount); SideChainGatewayApi.getTxInfo(trxId); ======= .mintToken(sideContractAddress, this.from, Long.parseLong(this.amount)); SideChainGatewayApi.checkTxInfo(trxId); >>>>>>> .mintToken(sideContractAddress, this.from, this.amount); SideChainGatewayApi.checkTxInfo(trxId);
<<<<<<< tryLoadDevCredentialsFromAssets(); ======= >>>>>>> tryLoadDevCredentialsFromAssets();
<<<<<<< ======= private class NavigationAdapter extends ArrayAdapter<Pane> { public NavigationAdapter() { super(mIitc, R.layout.list_item_selectable); add(Pane.MAP); add(Pane.INFO); add(Pane.FULL); add(Pane.COMPACT); add(Pane.PUBLIC); add(Pane.FACTION); if (mPrefs.getBoolean("pref_advanced_menu", false)) { add(Pane.DEBUG); } } @Override public View getView(int position, View convertView, ViewGroup parent) { TextView view = (TextView) super.getView(position, convertView, parent); Pane item = getItem(position); if (item == Pane.MAP) { view.setText("Map"); } else { view.setText(getPaneTitle(item)); } int icon = 0; switch (item) { case MAP: icon = R.drawable.ic_action_map; break; case INFO: icon = R.drawable.ic_action_about; break; case FULL: icon = R.drawable.ic_action_view_as_list; break; case COMPACT: icon = R.drawable.ic_action_view_as_list_compact; break; case PUBLIC: icon = R.drawable.ic_action_group; break; case FACTION: icon = R.drawable.ic_action_cc_bcc; break; case DEBUG: icon = R.drawable.ic_action_error; break; } if (icon != 0) { view.setCompoundDrawablesWithIntrinsicBounds(icon, 0, 0, 0); } return view; } } public static enum Pane { COMPACT, DEBUG, FACTION, FULL, INFO, MAP, PUBLIC } >>>>>>>
<<<<<<< outgoingBatch.incrementDataEventCount(); outgoingBatch.incrementTableCount(tableName); ======= if (tableName != null) { outgoingBatch.incrementTableCount(tableName.toLowerCase()); } >>>>>>> outgoingBatch.incrementDataEventCount(); if (tableName != null) { outgoingBatch.incrementTableCount(tableName.toLowerCase()); } <<<<<<< @Override public Map<String, Date> getLastDataCaptureByChannel() { Map<String, Date> captureMap = new HashMap<String, Date>(); LastCaptureByChannelMapper mapper = new LastCaptureByChannelMapper(captureMap); List<String> temp = sqlTemplate.query(getSql("findLastCaptureTimeByChannelSql"), mapper); return mapper.getCaptureMap(); } ======= class TableRow { Table table; Row row; String whereSql; public TableRow(Table table, Row row, String whereSql) { this.table = table; this.row = row; this.whereSql = whereSql; } @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((table == null) ? 0 : table.hashCode()); result = prime * result + ((whereSql == null) ? 0 : whereSql.hashCode()); return result; } @Override public boolean equals(Object o) { if (o instanceof TableRow) { TableRow tr = (TableRow) o; return tr.table.equals(table) && tr.whereSql.equals(whereSql); } return false; } public Table getTable() { return table; } public Row getRow() { return row; } public String getWhereSql() { return whereSql; } } >>>>>>> @Override public Map<String, Date> getLastDataCaptureByChannel() { Map<String, Date> captureMap = new HashMap<String, Date>(); LastCaptureByChannelMapper mapper = new LastCaptureByChannelMapper(captureMap); List<String> temp = sqlTemplate.query(getSql("findLastCaptureTimeByChannelSql"), mapper); return mapper.getCaptureMap(); } class TableRow { Table table; Row row; String whereSql; public TableRow(Table table, Row row, String whereSql) { this.table = table; this.row = row; this.whereSql = whereSql; } @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((table == null) ? 0 : table.hashCode()); result = prime * result + ((whereSql == null) ? 0 : whereSql.hashCode()); return result; } @Override public boolean equals(Object o) { if (o instanceof TableRow) { TableRow tr = (TableRow) o; return tr.table.equals(table) && tr.whereSql.equals(whereSql); } return false; } public Table getTable() { return table; } public Row getRow() { return row; } public String getWhereSql() { return whereSql; } }
<<<<<<< ======= if (currentBatch.getStatus() != Status.RS) { changeBatchStatus(Status.SE, currentBatch, mode); currentBatch.setTransferStartTime(new Date()); } >>>>>>> if (currentBatch.getStatus() != Status.RS) { currentBatch.setTransferStartTime(new Date()); }
<<<<<<< import org.jumpmind.symmetric.model.AbstractBatch.Status; ======= import org.jumpmind.symmetric.load.DefaultReloadGenerator; import org.jumpmind.symmetric.load.IReloadGenerator; >>>>>>> import org.jumpmind.symmetric.model.AbstractBatch.Status; import org.jumpmind.symmetric.load.DefaultReloadGenerator; import org.jumpmind.symmetric.load.IReloadGenerator; <<<<<<< extensionService.addExtensionPoint("csv", new CSVRouter(engine)); ======= extensionService.addExtensionPoint(DefaultReloadGenerator.NAME, new DefaultReloadGenerator(engine)); >>>>>>> extensionService.addExtensionPoint("csv", new CSVRouter(engine)); extensionService.addExtensionPoint(DefaultReloadGenerator.NAME, new DefaultReloadGenerator(engine)); <<<<<<< processInfo.setStatus(ProcessInfo.ProcessStatus.CREATING); ======= processInfo.setStatus(ProcessInfo.Status.CREATING); >>>>>>> processInfo.setStatus(ProcessInfo.ProcessStatus.CREATING);
<<<<<<< Node sourceNode = nodeService.findIdentity(); IStagedResource targetResource = targetEngine.getStagingManager().create( Constants.STAGING_CATEGORY_INCOMING, Batch.getStagedLocation(false, sourceNode.getNodeId()), currentBatch.getBatchId()); ======= >>>>>>> <<<<<<< processInfo.setStatus(org.jumpmind.symmetric.model.ProcessInfo.ProcessStatus.ERROR); ======= List<OutgoingBatch> checkBatches = outgoingBatchService.getOutgoingBatchRange( request.getStartBatchId(), request.getEndBatchId()).getBatches(); for (OutgoingBatch outgoingBatch : checkBatches) { outgoingBatch.setStatus(Status.RQ); IStagedResource resource = getStagedResource(outgoingBatch); if (resource != null) { resource.close(); resource.delete(); } outgoingBatchService.updateOutgoingBatch(outgoingBatch); } processInfo.setStatus(org.jumpmind.symmetric.model.ProcessInfo.Status.ERROR); >>>>>>> processInfo.setStatus(org.jumpmind.symmetric.model.ProcessInfo.ProcessStatus.ERROR); List<OutgoingBatch> checkBatches = outgoingBatchService.getOutgoingBatchRange( request.getStartBatchId(), request.getEndBatchId()).getBatches(); for (OutgoingBatch outgoingBatch : checkBatches) { outgoingBatch.setStatus(Status.RQ); IStagedResource resource = getStagedResource(outgoingBatch); if (resource != null) { resource.close(); resource.delete(); } outgoingBatchService.updateOutgoingBatch(outgoingBatch); }
<<<<<<< " end \n" + " $(custom_on_update_text) \n" + " set nocount off \n" + " end \n" ======= " $(custom_on_update_text) \n" + " set nocount off \n" + " end " ); sqlTemplates.put("updateHandleKeyUpdatesTriggerTemplate" , "create trigger $(triggerName) on $(schemaName)$(tableName) for update " + getOrderClause() + " as\n" + " begin \n" + " set nocount on \n" + " declare @TransactionId varchar(1000) \n" + " declare @DataRow varchar(16384) \n" + " declare @OldPk varchar(2000) \n" + " declare @OldDataRow varchar(16384) \n" + " declare @clientapplname varchar(50) \n" + " select @clientapplname = clientapplname from master.dbo.sysprocesses where spid = @@spid \n" + " declare @clientname varchar(50) \n" + " select @clientname = clientname from master.dbo.sysprocesses where spid = @@spid and clientapplname = 'SymmetricDS' \n" + " declare @ChannelId varchar(128) \n" + " $(declareOldKeyVariables) \n" + " $(declareNewKeyVariables) \n" + " declare @txid varchar(50) \n" + " if (@@TRANCOUNT > 0) begin \n" + " select @txid = $(txIdExpression) \n" + " end \n" + " $(custom_before_update_text) \n" + " if ($(syncOnIncomingBatchCondition)) begin \n" + " declare DeleteCursor cursor for \n" + " select $(oldKeys), $(oldColumns) $(oldKeyNames) from deleted where $(syncOnDeleteCondition) \n" + " declare InsertCursor cursor for \n" + " $(if:containsBlobClobColumns) \n" + " select $(columns) $(newKeyNames), $(channelExpression) from inserted inner join $(schemaName)$(tableName) $(origTableAlias) on $(tableNewPrimaryKeyJoin) where $(syncOnInsertCondition)\n" + " $(else:containsBlobClobColumns) \n" + " select $(columns) $(newKeyNames), $(channelExpression) from inserted where $(syncOnInsertCondition) \n" + " $(end:containsBlobClobColumns) \n" + " open DeleteCursor \n" + " open InsertCursor \n" + " fetch DeleteCursor into @OldPk, @OldDataRow $(oldKeyVariables) \n" + " fetch InsertCursor into @DataRow $(newKeyVariables), @ChannelId \n" + " while @@sqlstatus = 0 begin \n" + " if ($(dataHasChangedCondition)) begin \n" + " insert into $(defaultCatalog)$(defaultSchema)$(prefixName)_data (table_name, event_type, trigger_hist_id, row_data, pk_data, old_data, channel_id, transaction_id, source_node_id, external_data, create_time) \n" + " values('$(targetTableName)','U', $(triggerHistoryId), @DataRow, @OldPk, @OldDataRow, @ChannelId, @txid, @clientname, $(externalSelect), getdate())\n" + " end \n" + " fetch DeleteCursor into @OldPk, @OldDataRow $(oldKeyVariables) \n" + " fetch InsertCursor into @DataRow $(newKeyVariables), @ChannelId \n" + " end \n" + " close DeleteCursor \n" + " close InsertCursor \n" + " deallocate cursor DeleteCursor \n" + " deallocate cursor InsertCursor \n" + " end \n" + " $(custom_on_update_text) \n" + " set nocount off \n" + " end \n" >>>>>>> " $(custom_on_update_text) \n" + " set nocount off \n" + " end \n"
<<<<<<< if (fkTable == t) { //selfDependent.add(t); } else { depth.increment(); resolveForeginKeyOrder(fkTable, allTables, resolved, temporary, finalList, t, missingDependencyMap, dependencyMap, depth, position, tablePrefix, resolvedPosition, parentPosition); Integer resolvedParentTableChannel = resolvedPosition.get(fkTable); if (resolvedParentTableChannel != null) { parentTablesChannels.add(resolvedParentTableChannel); } ======= if (fkTable != null) { resolveForeginKeyOrder(fkTable, allTables, resolved, temporary, finalList, t); >>>>>>> if (fkTable != null) { depth.increment(); resolveForeginKeyOrder(fkTable, allTables, resolved, temporary, finalList, t, missingDependencyMap, dependencyMap, depth, position, tablePrefix, resolvedPosition, parentPosition); Integer resolvedParentTableChannel = resolvedPosition.get(fkTable); if (resolvedParentTableChannel != null) { parentTablesChannels.add(resolvedParentTableChannel); } <<<<<<< if (t != null) { if (parentPosition.intValue() > 0) { if (dependencyMap.get(parentPosition.intValue()) == null) { dependencyMap.put(parentPosition.intValue(), new HashSet<Table>()); } if (parentTablesChannels.size() > 1) { parentPosition.setValue(mergeChannels(parentTablesChannels, dependencyMap, resolvedPosition)); } dependencyMap.get(parentPosition.intValue()).add(t); } else { if (dependencyMap.get(position.intValue()) == null) { dependencyMap.put(position.intValue(), new HashSet<Table>()); } dependencyMap.get(position.intValue()).add(t); } resolved.add(t); resolvedPosition.put(t, parentPosition.intValue() > 0 ? parentPosition.intValue() : position.intValue()); finalList.add(0, t); if (depth.intValue() == 1) { if (parentPosition.intValue() < 0) { position.increment(); } } else { depth.decrement(); } } ======= if (t != null) { resolved.add(t); finalList.add(0, t); } >>>>>>> if (t != null) { if (parentPosition.intValue() > 0) { if (dependencyMap.get(parentPosition.intValue()) == null) { dependencyMap.put(parentPosition.intValue(), new HashSet<Table>()); } if (parentTablesChannels.size() > 1) { parentPosition.setValue(mergeChannels(parentTablesChannels, dependencyMap, resolvedPosition)); } dependencyMap.get(parentPosition.intValue()).add(t); } else { if (dependencyMap.get(position.intValue()) == null) { dependencyMap.put(position.intValue(), new HashSet<Table>()); } dependencyMap.get(position.intValue()).add(t); } resolved.add(t); resolvedPosition.put(t, parentPosition.intValue() > 0 ? parentPosition.intValue() : position.intValue()); finalList.add(0, t); if (depth.intValue() == 1) { if (parentPosition.intValue() < 0) { position.increment(); } } else { depth.decrement(); } }
<<<<<<< synchronized (lock) { if (!isPreviouslyExtracted(currentBatch)) { if (currentBatch.getExtractStartTime() == null) { currentBatch.setExtractStartTime(new Date()); } if (updateBatchStatistics) { changeBatchStatus(Status.QY, currentBatch, mode); } currentBatch.resetStats(); DataContext ctx = new DataContext(); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE_ID, targetNode.getNodeId()); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE_EXTERNAL_ID, targetNode.getExternalId()); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE_GROUP_ID, targetNode.getNodeGroupId()); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE, targetNode); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE, sourceNode); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE_ID, sourceNode.getNodeId()); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE_EXTERNAL_ID, sourceNode.getExternalId()); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE_GROUP_ID, sourceNode.getNodeGroupId()); IDataReader dataReader = buildExtractDataReader(sourceNode, targetNode, currentBatch, processInfo); new DataProcessor(dataReader, writer, "extract").process(ctx); extractTimeInMs = System.currentTimeMillis() - ts; Statistics stats = getExtractStats(writer); ======= if (!isPreviouslyExtracted(currentBatch)) { currentBatch.setExtractCount(currentBatch.getExtractCount() + 1); if (updateBatchStatistics) { changeBatchStatus(Status.QY, currentBatch, mode); } currentBatch.resetStats(); DataContext ctx = new DataContext(); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE_ID, targetNode.getNodeId()); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE_EXTERNAL_ID, targetNode.getExternalId()); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE_GROUP_ID, targetNode.getNodeGroupId()); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE, targetNode); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE, sourceNode); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE_ID, sourceNode.getNodeId()); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE_EXTERNAL_ID, sourceNode.getExternalId()); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE_GROUP_ID, sourceNode.getNodeGroupId()); IDataReader dataReader = buildExtractDataReader(sourceNode, targetNode, currentBatch, processInfo); new DataProcessor(dataReader, writer, "extract").process(ctx); extractTimeInMs = System.currentTimeMillis() - ts; Statistics stats = getExtractStats(writer); if (stats != null) { >>>>>>> if (!isPreviouslyExtracted(currentBatch)) { currentBatch.setExtractCount(currentBatch.getExtractCount() + 1); if (currentBatch.getExtractStartTime() == null) { currentBatch.setExtractStartTime(new Date()); } if (updateBatchStatistics) { changeBatchStatus(Status.QY, currentBatch, mode); } currentBatch.resetStats(); DataContext ctx = new DataContext(); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE_ID, targetNode.getNodeId()); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE_EXTERNAL_ID, targetNode.getExternalId()); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE_GROUP_ID, targetNode.getNodeGroupId()); ctx.put(Constants.DATA_CONTEXT_TARGET_NODE, targetNode); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE, sourceNode); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE_ID, sourceNode.getNodeId()); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE_EXTERNAL_ID, sourceNode.getExternalId()); ctx.put(Constants.DATA_CONTEXT_SOURCE_NODE_GROUP_ID, sourceNode.getNodeGroupId()); IDataReader dataReader = buildExtractDataReader(sourceNode, targetNode, currentBatch, processInfo); new DataProcessor(dataReader, writer, "extract").process(ctx); extractTimeInMs = System.currentTimeMillis() - ts; Statistics stats = getExtractStats(writer); if (stats != null) {
<<<<<<< public Data findData(long dataId); ======= public long findMinDataId(); >>>>>>> public Data findData(long dataId); public long findMinDataId();
<<<<<<< private long startTime; private String sqlState; private int sqlCode; private String sqlMessage; private String lastUpdatedHostName; private Date lastUpdatedTime; private Date createTime; ======= >>>>>>> private long startTime; <<<<<<< startTime = writerStatistics.get(DataWriterStatisticConstants.STARTTIME); lastUpdatedTime = new Date(); ======= setLastUpdatedTime(new Date()); >>>>>>> setStartTime(writerStatistics.get(DataWriterStatisticConstants.STARTTIME)); setLastUpdatedTime(new Date()); <<<<<<< public long getStartTime() { return startTime; } public void setStartTime(long startTime) { this.startTime = startTime; } public String getSqlState() { return sqlState; } public void setSqlState(String sqlState) { this.sqlState = sqlState; } public int getSqlCode() { return sqlCode; } public void setSqlCode(int sqlCode) { this.sqlCode = sqlCode; } public String getSqlMessage() { return sqlMessage; } public void setSqlMessage(String sqlMessage) { this.sqlMessage = sqlMessage; } public String getLastUpdatedHostName() { return lastUpdatedHostName; } public void setLastUpdatedHostName(String lastUpdateHostName) { this.lastUpdatedHostName = lastUpdateHostName; } public Date getLastUpdatedTime() { return lastUpdatedTime; } public void setLastUpdatedTime(Date lastUpdateTime) { this.lastUpdatedTime = lastUpdateTime; } ======= >>>>>>> public long getStartTime() { return startTime; } public void setStartTime(long startTime) { this.startTime = startTime; }
<<<<<<< putSql("selectIncomingBatchSummaryByStatusAndChannelSql", "select count(*) as batches, status, sum(statement_count) as data, node_id, min(create_time) as oldest_batch_time, channel_id, " + " max(last_update_time) as last_update_time, max(sql_message) as sql_message, min(batch_id) as batch_id " + " from $(incoming_batch) where status in (:STATUS_LIST) group by status, node_id, channel_id order by oldest_batch_time asc "); putSql("selectIncomingBatchSummaryByStatusSql", "select count(*) as batches, status, sum(statement_count) as data, node_id, min(create_time) as oldest_batch_time, " + " max(last_update_time) as last_update_time" + " from $(incoming_batch) where status in (:STATUS_LIST) group by status, node_id order by oldest_batch_time asc "); putSql("lastUpdateByChannelSql", "select max(last_update_time) as last_update_time, channel_id from $(incoming_batch) group by channel_id"); ======= putSql("getAllBatchesSql", "select batch_id, node_id from $(incoming_batch)"); >>>>>>> putSql("selectIncomingBatchSummaryByStatusAndChannelSql", "select count(*) as batches, status, sum(statement_count) as data, node_id, min(create_time) as oldest_batch_time, channel_id, " + " max(last_update_time) as last_update_time, max(sql_message) as sql_message, min(batch_id) as batch_id " + " from $(incoming_batch) where status in (:STATUS_LIST) group by status, node_id, channel_id order by oldest_batch_time asc "); putSql("selectIncomingBatchSummaryByStatusSql", "select count(*) as batches, status, sum(statement_count) as data, node_id, min(create_time) as oldest_batch_time, " + " max(last_update_time) as last_update_time" + " from $(incoming_batch) where status in (:STATUS_LIST) group by status, node_id order by oldest_batch_time asc "); putSql("lastUpdateByChannelSql", "select max(last_update_time) as last_update_time, channel_id from $(incoming_batch) group by channel_id"); putSql("getAllBatchesSql", "select batch_id, node_id from $(incoming_batch)");
<<<<<<< ======= protected DataGapDetector gapDetector; >>>>>>> protected DataGapDetector gapDetector; <<<<<<< setSqlMap(new RouterServiceSqlMap(symmetricDialect.getPlatform(), createSqlReplacementTokens())); ======= setSqlMap(new RouterServiceSqlMap(symmetricDialect.getPlatform(), createSqlReplacementTokens())); >>>>>>> setSqlMap(new RouterServiceSqlMap(symmetricDialect.getPlatform(), createSqlReplacementTokens())); <<<<<<< ======= if (gapDetector == null) { if (parameterService.is(ParameterConstants.ROUTING_USE_FAST_GAP_DETECTOR)) { gapDetector = new DataGapFastDetector(engine.getDataService(), parameterService, engine.getContextService(), symmetricDialect, this, engine.getStatisticManager(), engine.getNodeService()); } else { gapDetector = new DataGapDetector(engine.getDataService(), parameterService, symmetricDialect, this, engine.getStatisticManager(), engine.getNodeService()); } } >>>>>>> if (gapDetector == null) { if (parameterService.is(ParameterConstants.ROUTING_USE_FAST_GAP_DETECTOR)) { gapDetector = new DataGapFastDetector(engine.getDataService(), parameterService, engine.getContextService(), symmetricDialect, this, engine.getStatisticManager(), engine.getNodeService()); } else { gapDetector = new DataGapDetector(engine.getDataService(), parameterService, symmetricDialect, this, engine.getStatisticManager(), engine.getNodeService()); } } <<<<<<< DataGapDetector gapDetector = null; if (parameterService.is(ParameterConstants.ROUTING_USE_FAST_GAP_DETECTOR)) { gapDetector = new DataGapFastDetector(engine.getDataService(), parameterService, engine.getContextService(), symmetricDialect, this, engine.getStatisticManager(), engine.getNodeService()); } else { gapDetector = new DataGapDetector(engine.getDataService(), parameterService, symmetricDialect, this, engine.getStatisticManager(), engine.getNodeService()); } ======= >>>>>>> <<<<<<< dataCount += routeDataForChannel(processInfo, nodeChannel, sourceNode, gapDetector); ======= dataCount += routeDataForChannel(processInfo, nodeChannel, sourceNode); >>>>>>> dataCount += routeDataForChannel(processInfo, nodeChannel, sourceNode);
<<<<<<< import org.jumpmind.symmetric.model.AbstractBatch.Status; ======= import org.jumpmind.symmetric.io.stage.StagingFileLock; >>>>>>> import org.jumpmind.symmetric.io.stage.StagingFileLock; import org.jumpmind.symmetric.model.AbstractBatch.Status; <<<<<<< ======= private Map<String, Semaphore> locks = new ConcurrentHashMap<String, Semaphore>(); >>>>>>> private Map<String, Semaphore> locks = new ConcurrentHashMap<String, Semaphore>(); <<<<<<< if (lock != null) { lock.release(); } synchronized (locks) { locks.remove(semaphoreKey); } ======= releaseLock(lock, currentBatch, useStagingDataWriter); >>>>>>> releaseLock(lock, currentBatch, useStagingDataWriter);
<<<<<<< public void clearCache() { } ======= /* (non-Javadoc) * @see org.jumpmind.symmetric.service.INodeService#getExternalId(java.lang.String) */ @Override public String getExternalId(String nodeId) { return nodeId; } >>>>>>> public void clearCache() { } /* (non-Javadoc) * @see org.jumpmind.symmetric.service.INodeService#getExternalId(java.lang.String) */ @Override public String getExternalId(String nodeId) { return nodeId; }
<<<<<<< public static final String TOKEN = "token"; ======= public class AuthoritiesManager implements ActionFilter { public AuthoritiesManager() { } >>>>>>> public class AuthoritiesManager implements ActionFilter { public static final String TOKEN = "token"; <<<<<<< actionContext.getRequest().getSession().setAttribute(TOKEN, token); ======= actionContext.getRequest().getSession().setAttribute(CURRENT_USER, token.getUser()); >>>>>>> actionContext.getRequest().getSession().setAttribute(CURRENT_USER, token.getUser()); <<<<<<< ======= @SuppressWarnings("all") Object obj = session.getAttribute(CURRENT_USER); if (obj == null) { return new JsonView(Restful.instance().code(ApiException.TokenAuthorNotFound).msg("未登录").ok(false)); } >>>>>>>
<<<<<<< /** * 通过api的方式获得线程 * * @return * @throws SchedulerException * @throws TaskException */ @At("/thread/info") @Ok("json") public JSONObject runInfo() throws SchedulerException, TaskException { // 线程任务 List<TaskInfo> threads = ThreadManager.getAllThread(); ======= @At public Restful list(@Param("hostPorts[]") String[] hostPorts ,@Param("groupName") String groupName ,@Param(value = "first" , df = "true") boolean first) throws Exception { >>>>>>> /** * 通过api的方式获得线程 * * @return * @throws TaskException */ @At public Restful list(@Param("hostPorts[]") String[] hostPorts ,@Param("groupName") String groupName ,@Param(value = "first" , df = "true") boolean first) throws Exception { <<<<<<< * 停止一个运行的action * * @param host * @param name ======= * 停止一个运行的action,或者task * >>>>>>> * 停止一个运行的action * * 停止一个运行的action,或者task *
<<<<<<< unlockedSetStat(BITRATE_DOWNLOAD, 0d); unlockedSetStat(BITRATE_UPLOAD, 0d); ======= unlockedSetStat(AUDIOCHANNELS, 0); unlockedSetStat(BITRATE_DOWNLOAD, 0); unlockedSetStat(BITRATE_UPLOAD, 0); >>>>>>> unlockedSetStat(BITRATE_DOWNLOAD, 0); unlockedSetStat(BITRATE_UPLOAD, 0);
<<<<<<< ======= * The payload type number configured for VP8 for this channel, * or -1 if none is configured (the other end does not support VP8). */ private byte vp8PayloadType = -1; /** * The <tt>SimulcastMode</tt> for this <tt>VideoChannel</tt>. */ private SimulcastMode simulcastMode; /** >>>>>>> * The payload type number configured for VP8 for this channel, * or -1 if none is configured (the other end does not support VP8). */ private byte vp8PayloadType = -1; /**
<<<<<<< * @author Pawel Domas ======= * @author Boris Grozev >>>>>>> * @author Boris Grozev * @author Pawel Domas <<<<<<< for (Iterator<WeakReference<RtpChannel>> i = channels.iterator(); ======= boolean add = true; for (Iterator<WeakReference<Channel>> i = channels.iterator(); >>>>>>> boolean add = true; for (Iterator<WeakReference<RtpChannel>> i = channels.iterator(); <<<<<<< return channels.add(new WeakReference<RtpChannel>(channel)); ======= return added; } /** * Notifies this <tt>Endpoint</tt> that an associated <tt>Channel</tt> has * received or measured a new audio level for a specific (contributing) * synchronization source identifier/SSRC. * * @param channel the <tt>Channel</tt> which has received or measured the * specified <tt>audioLevel</tt> for the specified <tt>ssrc</tt> * @param ssrc the synchronization source identifier/SSRC of the RTP stream * received within the specified <tt>channel</tt> for which the specified * <tt>audioLevel</tt> was received or measured * @param audioLevel the audio level which was received or measured for the * specified <tt>ssrc</tt> received within the specified <tt>channel</tt> */ void audioLevelChanged(Channel channel, long ssrc, int audioLevel) { // TODO Auto-generated method stub } /** * Gets a <tt>List</tt> with the channels of this <tt>Endpoint</tt> with * a particular <tt>MediaType</tt>. * * @param mediaType the <tt>MediaType</tt>. * @return a <tt>List</tt> with the channels of this <tt>Endpoint</tt> with * a particular <tt>MediaType</tt>. */ public List<Channel> getChannels(MediaType mediaType) { List<Channel> channels = new LinkedList<Channel>(); synchronized (channels) { for (Iterator<WeakReference<Channel>> i = this.channels.iterator(); i.hasNext();) { Channel channel = i.next().get(); if (channel == null) continue; if ((mediaType == null) || (mediaType.equals( channel.getContent().getMediaType()))) { channels.add(channel); } } >>>>>>> return added; } /** * Notifies this <tt>Endpoint</tt> that an associated <tt>Channel</tt> has * received or measured a new audio level for a specific (contributing) * synchronization source identifier/SSRC. * * @param channel the <tt>Channel</tt> which has received or measured the * specified <tt>audioLevel</tt> for the specified <tt>ssrc</tt> * @param ssrc the synchronization source identifier/SSRC of the RTP stream * received within the specified <tt>channel</tt> for which the specified * <tt>audioLevel</tt> was received or measured * @param audioLevel the audio level which was received or measured for the * specified <tt>ssrc</tt> received within the specified <tt>channel</tt> */ void audioLevelChanged(Channel channel, long ssrc, int audioLevel) { // TODO Auto-generated method stub } /** * Gets a <tt>List</tt> with the channels of this <tt>Endpoint</tt> with * a particular <tt>MediaType</tt>. * * @param mediaType the <tt>MediaType</tt>. * @return a <tt>List</tt> with the channels of this <tt>Endpoint</tt> with * a particular <tt>MediaType</tt>. */ public List<RtpChannel> getChannels(MediaType mediaType) { List<RtpChannel> channels = new LinkedList<RtpChannel>(); synchronized (this.channels) { for (WeakReference<RtpChannel> channel1 : this.channels) { RtpChannel channel = channel1.get(); if (channel == null) continue; if ((mediaType == null) || (mediaType.equals( channel.getContent().getMediaType()))) { channels.add(channel); } }
<<<<<<< import org.jitsi_modified.impl.neomedia.rtp.*; ======= import org.jitsi.service.neomedia.format.*; >>>>>>> import org.jitsi_modified.impl.neomedia.rtp.*; import org.jitsi.service.neomedia.format.*;
<<<<<<< * Checks if the given packet with the given format is part of a key frame. */ private static boolean isKeyframe( @NotNull RawPacket rtpPacket, @NotNull PayloadType payloadType) { byte[] buf = rtpPacket.getBuffer(); int payloadOff = rtpPacket.getPayloadOffset(), payloadLen = rtpPacket.getPayloadLength(); if (payloadType instanceof Vp8PayloadType) { return org.jitsi.impl.neomedia.codec.video.vp8.DePacketizer .isKeyFrame(buf, payloadOff, payloadLen); } else if (payloadType instanceof H264PayloadType) { return org.jitsi.impl.neomedia.codec.video.h264.DePacketizer .isKeyFrame(buf, payloadOff, payloadLen); } else if (payloadType instanceof Vp9PayloadType) { return org.jitsi.impl.neomedia.codec.video.vp9.DePacketizer .isKeyFrame(buf, payloadOff, payloadLen); } else { return false; } } /** ======= * The <tt>Logger</tt> used by the * <tt>GenericAdaptiveTrackProjectionContext</tt> class and its instances to * log debug information. */ private static final Logger logger = Logger.getLogger(GenericAdaptiveTrackProjectionContext.class); private final long ssrc; /** >>>>>>> * Checks if the given packet with the given format is part of a key frame. */ private static boolean isKeyframe( @NotNull RawPacket rtpPacket, @NotNull PayloadType payloadType) { byte[] buf = rtpPacket.getBuffer(); int payloadOff = rtpPacket.getPayloadOffset(), payloadLen = rtpPacket.getPayloadLength(); if (payloadType instanceof Vp8PayloadType) { return org.jitsi.impl.neomedia.codec.video.vp8.DePacketizer .isKeyFrame(buf, payloadOff, payloadLen); } else if (payloadType instanceof H264PayloadType) { return org.jitsi.impl.neomedia.codec.video.h264.DePacketizer .isKeyFrame(buf, payloadOff, payloadLen); } else if (payloadType instanceof Vp9PayloadType) { return org.jitsi.impl.neomedia.codec.video.vp9.DePacketizer .isKeyFrame(buf, payloadOff, payloadLen); } else { return false; } } /** * The <tt>Logger</tt> used by the * <tt>GenericAdaptiveTrackProjectionContext</tt> class and its instances to * log debug information. */ private static final Logger logger = Logger.getLogger(GenericAdaptiveTrackProjectionContext.class); private final long ssrc; /** <<<<<<< ======= private void maybeInitializeTimestampDelta(long sourceTimestamp) { if (timestampDeltaInitialized) { return; } if (RTPUtils.isNewerTimestampThan( maxDestinationSequenceNumber, sourceTimestamp)) { long destinationTimestamp = (maxDestinationTimestamp + 3000) & RawPacket.TIMESTAMP_MASK; timestampDelta = RTPUtils.rtpTimestampDiff(destinationTimestamp, sourceTimestamp); } timestampDeltaInitialized = true; } private static boolean isKeyframe( @NotNull RawPacket rtpPacket, @NotNull MediaFormat format) { // XXX merge with MediaStream.isKeyframe(). byte[] buf = rtpPacket.getBuffer(); int payloadOff = rtpPacket.getPayloadOffset(), payloadLen = rtpPacket.getPayloadLength(); if (Constants.VP8.equalsIgnoreCase(format.getEncoding())) { return org.jitsi.impl.neomedia.codec.video.vp8.DePacketizer .isKeyFrame(buf, payloadOff, payloadLen); } else if (Constants.H264.equalsIgnoreCase(format.getEncoding())) { return org.jitsi.impl.neomedia.codec.video.h264.DePacketizer .isKeyFrame(buf, payloadOff, payloadLen); } else if (Constants.VP9.equalsIgnoreCase(format.getEncoding())) { return org.jitsi.impl.neomedia.codec.video.vp9.DePacketizer .isKeyFrame(buf, payloadOff, payloadLen); } else { return false; } } >>>>>>> private void maybeInitializeTimestampDelta(long sourceTimestamp) { if (timestampDeltaInitialized) { return; } if (RTPUtils.isNewerTimestampThan( maxDestinationSequenceNumber, sourceTimestamp)) { long destinationTimestamp = (maxDestinationTimestamp + 3000) & RawPacket.TIMESTAMP_MASK; timestampDelta = RTPUtils.rtpTimestampDiff(destinationTimestamp, sourceTimestamp); } timestampDeltaInitialized = true; }
<<<<<<< private Integer cause; private String uniqueid; private String language; public String getLanguage() { return language; } public void setLanguage(String language) { this.language = language; } ======= >>>>>>> private Integer cause; private String language; public String getLanguage() { return language; } public void setLanguage(String language) { this.language = language; } <<<<<<< /** * Returns the cause of the hangup. * * @return the hangup cause. * @see org.asteriskjava.live.HangupCause */ public Integer getCause() { return cause; } /** * Sets the cause of the hangup. * * @param cause the hangup cause. */ public void setCause(Integer cause) { this.cause = cause; } public String getUniqueid() { return uniqueid; } public void setUniqueid(String uniqueid) { this.uniqueid = uniqueid; } ======= >>>>>>> /** * Returns the cause of the hangup. * * @return the hangup cause. * @see org.asteriskjava.live.HangupCause */ public Integer getCause() { return cause; } /** * Sets the cause of the hangup. * * @param cause the hangup cause. */ public void setCause(Integer cause) { this.cause = cause; }
<<<<<<< synchronized (mLockRecDataList) { mRecDataList.clear(); } ======= >>>>>>> <<<<<<< 设置波形颜色 @param waveCount 波形数量 1或者2 ======= * 设置自定义的paint */ public void setLinePaint(Paint paint) { if (paint != null) { mPaint = paint; } } /** * 设置波形颜色 * * @param waveCount 波形数量 1或者2 >>>>>>> * 设置自定义的paint */ public void setLinePaint(Paint paint) { if (paint != null) { mPaint = paint; } } /** 设置波形颜色 @param waveCount 波形数量 1或者2
<<<<<<< import com.fasterxml.jackson.core.util.SimpleTokenReadContext; ======= import com.fasterxml.jackson.core.util.JacksonFeatureSet; >>>>>>> import com.fasterxml.jackson.core.util.JacksonFeatureSet; import com.fasterxml.jackson.core.util.SimpleTokenReadContext; <<<<<<< public boolean canUseSchema(FormatSchema schema) { return (schema instanceof CsvSchema); } @Override ======= public ObjectCodec getCodec() { return _objectCodec; } @Override public void setCodec(ObjectCodec c) { _objectCodec = c; } @Override >>>>>>>
<<<<<<< protected DumpSettings buildDumperOptions(int jsonFeatures, int yamlFeatures, SpecVersion version) ======= protected DumperOptions buildDumperOptions(int streamWriteFeatures, int yamlFeatures, org.yaml.snakeyaml.DumperOptions.Version version) >>>>>>> protected DumpSettings buildDumperOptions(int streamWriteFeatures, int yamlFeatures, SpecVersion version) <<<<<<< return opt.build(); ======= // 14-May-2018: [dataformats-text#84] allow use of platform linefeed if (Feature.USE_PLATFORM_LINE_BREAKS.enabledIn(_formatWriteFeatures)) { opt.setLineBreak(DumperOptions.LineBreak.getPlatformLineBreak()); } return opt; >>>>>>> return opt.build(); <<<<<<< ScalarStyle style = STYLE_QUOTED; if (Feature.MINIMIZE_QUOTES.enabledIn(_formatFeatures) && !isBooleanContent(text)) { ======= DumperOptions.ScalarStyle style = STYLE_QUOTED; if (Feature.MINIMIZE_QUOTES.enabledIn(_formatWriteFeatures) && !isBooleanContent(text)) { >>>>>>> ScalarStyle style = STYLE_QUOTED; if (Feature.MINIMIZE_QUOTES.enabledIn(_formatWriteFeatures) && !isBooleanContent(text)) { <<<<<<< String encoded = b64variant.encode(data); _emitter.emit(new ScalarEvent(Optional.empty(), Optional.ofNullable(TAG_BINARY), EXPLICIT_TAGS, encoded, STYLE_BASE64)); ======= final String lf = _lf(); String encoded = b64variant.encode(data, false, lf); _emitter.emit(new ScalarEvent(null, TAG_BINARY, EXPLICIT_TAGS, encoded, null, null, STYLE_BASE64)); >>>>>>> final String lf = _lf(); String encoded = b64variant.encode(data, false, lf); _emitter.emit(new ScalarEvent(Optional.empty(), Optional.ofNullable(TAG_BINARY), EXPLICIT_TAGS, encoded, STYLE_BASE64));
<<<<<<< import com.fasterxml.jackson.core.util.SimpleTokenReadContext; ======= import com.fasterxml.jackson.core.util.JacksonFeatureSet; >>>>>>> import com.fasterxml.jackson.core.util.JacksonFeatureSet; import com.fasterxml.jackson.core.util.SimpleTokenReadContext; <<<<<<< /********************************************************************** ======= /********************************************************** /* Overrides: capability introspection methods /********************************************************** */ @Override public boolean requiresCustomCodec() { return false;} @Override public boolean canReadObjectId() { // yup return true; } @Override public boolean canReadTypeId() { return true; // yes, YAML got 'em } @Override public JacksonFeatureSet<StreamReadCapability> getReadCapabilities() { // Defaults are fine return DEFAULT_READ_CAPABILITIES; } /* /********************************************************** >>>>>>> /********************************************************************** /* Overrides: capability introspection methods /********************************************************************** */ @Override public boolean canReadObjectId() { // yup return true; } @Override public boolean canReadTypeId() { return true; // yes, YAML got 'em } @Override public JacksonFeatureSet<StreamReadCapability> getReadCapabilities() { // Defaults are fine return DEFAULT_READ_CAPABILITIES; } /* /********************************************************************** <<<<<<< public boolean canReadObjectId() { // yup return true; } @Override public boolean canReadTypeId() { return true; // yes, YAML got 'em } @Override ======= >>>>>>>
<<<<<<< ======= import com.fasterxml.jackson.core.json.JsonWriteContext; import com.fasterxml.jackson.core.util.JacksonFeatureSet; >>>>>>> import com.fasterxml.jackson.core.util.JacksonFeatureSet;
<<<<<<< import java.util.Optional; ======= import java.util.Set; >>>>>>> import java.util.Optional; import java.util.Set; <<<<<<< private final static ScalarStyle STYLE_NAME = ScalarStyle.PLAIN; ======= private final static DumperOptions.ScalarStyle STYLE_UNQUOTED_NAME = DumperOptions.ScalarStyle.PLAIN; >>>>>>> private final static ScalarStyle STYLE_UNQUOTED_NAME = ScalarStyle.PLAIN;
<<<<<<< public Number getNumberValue() throws IOException { ======= /** * Method used by {@link CsvParser#isExpectedNumberIntToken()} to coerce * current token into integer number, if it looks like one. * * @since 2.12 */ public boolean isExpectedNumberIntToken() { if (_textBuffer.looksLikeInt()) { try { _parseIntValue(); } catch (IOException e) { // should not occur but is declared so throw new RuntimeException(e); } return true; } return false; } /** * @param exact Whether we should try to retain maximum precision or not; * passed as {@code true} by {@code getNumberValueExact()}, and as * {@code false} by regular {@code getNumberValue)}. */ public Number getNumberValue(boolean exact) throws IOException { >>>>>>> /** * Method used by {@link CsvParser#isExpectedNumberIntToken()} to coerce * current token into integer number, if it looks like one. */ public boolean isExpectedNumberIntToken() { if (_textBuffer.looksLikeInt()) { try { _parseIntValue(); } catch (IOException e) { // should not occur but is declared so throw new RuntimeException(e); } return true; } return false; } /** * @param exact Whether we should try to retain maximum precision or not; * passed as {@code true} by {@code getNumberValueExact()}, and as * {@code false} by regular {@code getNumberValue)}. */ public Number getNumberValue(boolean exact) throws IOException { <<<<<<< char[] buf = _textBuffer.getTextBuffer(); int offset = _textBuffer.getTextOffset(); char c = buf[offset]; boolean neg; if (c == '-') { neg = true; ++offset; } else { neg = false; if (c == '+') { ++offset; } } int len = buf.length - offset; if (len <= 9) { // definitely fits in int int i = NumberInput.parseInt(buf, offset, len); _numberInt = neg ? -i : i; _numTypesValid = NR_INT; return; } if (len <= 18) { // definitely fits AND is easy to parse using 2 int parse calls long l = NumberInput.parseLong(buf, offset, len); if (neg) { l = -l; } // [JACKSON-230] Could still fit in int, need to check if (len == 10) { if (neg) { if (l >= MIN_INT_L) { _numberInt = (int) l; _numTypesValid = NR_INT; return; } } else { if (l <= MAX_INT_L) { _numberInt = (int) l; _numTypesValid = NR_INT; return; } } } _numberLong = l; _numTypesValid = NR_LONG; return; } _parseSlowIntValue(expType, buf, offset, len, neg); ======= _parseIntValue(); >>>>>>> _parseIntValue(); <<<<<<< private final void _parseSlowFloatValue(int expType) throws IOException { ======= private final void _parseSlowFloatValue(boolean exactNumber) throws IOException { >>>>>>> private final void _parseSlowFloatValue(boolean exactNumber) throws IOException { <<<<<<< private final void _parseSlowIntValue(int expType, char[] buf, int offset, int len, boolean neg) throws IOException { ======= private final void _parseSlowIntValue(char[] buf, int offset, int len, boolean neg) throws IOException { >>>>>>> private final void _parseSlowIntValue(char[] buf, int offset, int len, boolean neg) throws IOException {
<<<<<<< ScalarStyle style; ======= >>>>>>> <<<<<<< style = STYLE_QUOTED; } else if (_cfgMinimizeQuotes) { if (isBooleanContent(text)) { style = STYLE_QUOTED; // If this string could be interpreted as a number, it must be quoted. } else if (Feature.ALWAYS_QUOTE_NUMBERS_AS_STRINGS.enabledIn(_formatWriteFeatures) && PLAIN_NUMBER_P.matcher(text).matches()) { ======= _writeScalar(text, "string", STYLE_QUOTED); return; } DumperOptions.ScalarStyle style; if (Feature.MINIMIZE_QUOTES.enabledIn(_formatFeatures)) { // If one of reserved values ("true", "null"), or, number, preserve quoting: if (_valueNeedsQuoting(text) || (Feature.ALWAYS_QUOTE_NUMBERS_AS_STRINGS.enabledIn(_formatFeatures) && PLAIN_NUMBER_P.matcher(text).matches()) ) { >>>>>>> _writeScalar(text, "string", STYLE_QUOTED); return; } ScalarStyle style; if (_cfgMinimizeQuotes) { // If one of reserved values ("true", "null"), or, number, preserve quoting: if (_valueNeedsQuoting(text) || (Feature.ALWAYS_QUOTE_NUMBERS_AS_STRINGS.enabledIn(_formatWriteFeatures) && PLAIN_NUMBER_P.matcher(text).matches()) ) {
<<<<<<< * Default value is `false` for backwards compatibility ======= * Default value is {@code false} for backwards compatibility * * @since 2.9 >>>>>>> * Default value is {@code false} for backwards compatibility <<<<<<< ======= /** * Feature enabling of which adds indentation with indicator for array entry generation * (default indentation being 2 spaces). *<p> * Default value is {@code false} for backwards compatibility * * @since 2.12 */ INDENT_ARRAYS_WITH_INDICATOR(false), /** * Option passed to SnakeYAML that determines if the line breaks used for * serialization should be same as what the default is for current platform. * If disabled, Unix linefeed ({@code \n}) will be used. * <p> * Default value is {@code false} for backwards compatibility. * * @since 2.9.6 */ USE_PLATFORM_LINE_BREAKS(false), >>>>>>> /** * Feature enabling of which adds indentation with indicator for array entry generation * (default indentation being 2 spaces). *<p> * Default value is {@code false} for backwards compatibility */ INDENT_ARRAYS_WITH_INDICATOR(false), <<<<<<< // 03-Oct-2020, tatu: Specify spec version; however, does not seem to make // any difference? opt.setYamlDirective(Optional.ofNullable(version)); return opt.build(); ======= // [dataformats-text#175]: further configurability that overrides prev setting if (Feature.INDENT_ARRAYS_WITH_INDICATOR.enabledIn(_formatFeatures)) { opt.setIndicatorIndent(2); opt.setIndentWithIndicator(true); } // 14-May-2018: [dataformats-text#84] allow use of platform linefeed if (Feature.USE_PLATFORM_LINE_BREAKS.enabledIn(_formatFeatures)) { opt.setLineBreak(DumperOptions.LineBreak.getPlatformLineBreak()); } return opt; >>>>>>> // [dataformats-text#175]: further configurability that overrides prev setting if (Feature.INDENT_ARRAYS_WITH_INDICATOR.enabledIn(_formatWriteFeatures)) { opt.setIndicatorIndent(2); opt.setIndent(2); // 26-Oct-2020, tatu: not sure how this setting translates // opt.setIndentWithIndicator(true); } // 03-Oct-2020, tatu: Specify spec version; however, does not seem to make // any difference? opt.setYamlDirective(Optional.ofNullable(version)); return opt.build();
<<<<<<< super(readCtxt, stdFeatures); _textBuffer = ioCtxt.csvTextBuffer(); DupDetector dups = StreamReadFeature.STRICT_DUPLICATE_DETECTION.enabledIn(stdFeatures) ======= super(stdFeatures); if (reader == null) { throw new IllegalArgumentException("Can not pass `null` as `java.io.Reader` to read from"); } _objectCodec = codec; _textBuffer = ctxt.csvTextBuffer(); DupDetector dups = JsonParser.Feature.STRICT_DUPLICATE_DETECTION.enabledIn(stdFeatures) >>>>>>> super(readCtxt, stdFeatures); if (reader == null) { throw new IllegalArgumentException("Can not pass `null` as `java.io.Reader` to read from"); } _textBuffer = ioCtxt.csvTextBuffer(); DupDetector dups = StreamReadFeature.STRICT_DUPLICATE_DETECTION.enabledIn(stdFeatures)