public TableSerdes GetTableSerdes<T>( Table table, DataInputOutputSerde<T> aggregationSerde, StatementContext statementContext) { return null; // this implementation does not require serdes }
public QueryPlanIndexItem( string[] hashProps, Type[] hashPropTypes, EventPropertyValueGetter hashGetter, MultiKeyFromObjectArray transformFireAndForget, DataInputOutputSerde hashKeySerde, string[] rangeProps, Type[] rangePropTypes, EventPropertyValueGetter[] rangeGetters, DataInputOutputSerde[] rangeKeySerdes, bool unique, EventAdvancedIndexProvisionRuntime advancedIndexProvisionDesc) { HashProps = hashProps; HashPropTypes = hashPropTypes; HashGetter = hashGetter; HashKeySerde = hashKeySerde; RangeProps = rangeProps == null || rangeProps.Length == 0 ? null : rangeProps; RangePropTypes = rangePropTypes; RangeGetters = rangeGetters; RangeKeySerdes = rangeKeySerdes; TransformFireAndForget = transformFireAndForget; IsUnique = unique; AdvancedIndexProvisionDesc = advancedIndexProvisionDesc; }
public void RegisterSerde( EventTypeMetadata metadata, DataInputOutputSerde underlyingSerde, Type underlyingClass) { _serdes.Add(new EventTypeCollectedSerde(metadata, underlyingSerde, underlyingClass)); }
public DIONullableObjectArraySerde( Type componentType, DataInputOutputSerde componentBinding) { _componentType = componentType; _componentBinding = componentBinding; }
public EventTableFactory CreateComposite( int indexedStreamNum, EventType eventType, string[] indexProps, Type[] indexCoercionTypes, EventPropertyValueGetter indexGetter, MultiKeyFromObjectArray transformFireAndForget, DataInputOutputSerde keySerde, string[] rangeProps, Type[] rangeCoercionTypes, EventPropertyValueGetter[] rangeGetters, DataInputOutputSerde[] rangeSerdes, DataInputOutputSerde optionalValueSerde, bool isFireAndForget) { return new PropertyCompositeEventTableFactory( indexedStreamNum, indexProps, indexCoercionTypes, indexGetter, transformFireAndForget, rangeProps, rangeCoercionTypes, rangeGetters); }
public void ActivateVariable( string name, DataInputOutputSerde serde) { var variable = ModuleIncidentals.Variables.Get(name); if (variable == null) { throw new ArgumentException("Failed to find variable information for '" + name + "'"); } string contextDeploymentId = null; if (variable.OptionalContextName != null) { contextDeploymentId = ContextDeployTimeResolver.ResolveContextDeploymentId( variable.OptionalContextModule, variable.OptionalContextVisibility, variable.OptionalContextName, DeploymentId, ServicesContext.ContextPathRegistry); } ServicesContext.VariableManagementService.AddVariable(DeploymentId, variable, contextDeploymentId, serde); // for non-context variables we allocate the state if (contextDeploymentId == null) { ServicesContext.VariableManagementService.AllocateVariableState( DeploymentId, name, DEFAULT_AGENT_INSTANCE_ID, IsRecovery, null, ServicesContext.EventBeanTypedEventFactory); } }
public PropertyCompositeEventTableFactoryFactory( int indexedStreamNum, int? subqueryNum, bool isFireAndForget, string[] keyProps, Type[] keyTypes, EventPropertyValueGetter keyGetter, DataInputOutputSerde keySerde, string[] rangeProps, Type[] rangeTypes, EventPropertyValueGetter[] rangeGetters, DataInputOutputSerde[] rangeKeySerdes) { this._indexedStreamNum = indexedStreamNum; this._subqueryNum = subqueryNum; this._isFireAndForget = isFireAndForget; this._keyProps = keyProps; this._keyTypes = keyTypes; this._keyGetter = keyGetter; this._keySerde = keySerde; this._rangeProps = rangeProps; this._rangeTypes = rangeTypes; this._rangeGetters = rangeGetters; this._rangeKeySerdes = rangeKeySerdes; }
public ResultSetProcessorGroupedOutputAllGroupReps MakeRSGroupedOutputAllNoOpt( AgentInstanceContext agentInstanceContext, Type[] groupKeyTypes, DataInputOutputSerde serde, EventType[] eventTypes) { return new ResultSetProcessorGroupedOutputAllGroupRepsImpl(); }
public ResultSetProcessorAggregateGroupedOutputLastHelper MakeRSAggregateGroupedOutputLastOpt( AgentInstanceContext agentInstanceContext, ResultSetProcessorAggregateGrouped processor, Type[] groupKeyTypes, DataInputOutputSerde serde) { return new ResultSetProcessorAggregateGroupedOutputLastHelperImpl(processor); }
public AggregationServiceFactory GroupAll( AggregationServiceFactory nonHAFactory, AggregationRowFactory rowFactory, AggregationUseFlags useFlags, DataInputOutputSerde<AggregationRow> serde) { return nonHAFactory; }
public ResultSetProcessorRowPerGroupUnboundHelper MakeRSRowPerGroupUnboundGroupRep( Type[] groupKeyTypes, DataInputOutputSerde serde, EventType eventType, AgentInstanceContext agentInstanceContext) { return new ResultSetProcessorRowPerGroupUnboundHelperImpl(); }
public void AddVariable( string deploymentId, VariableMetaData metaData, string optionalDeploymentIdContext, DataInputOutputSerde optionalSerde) { lock (this) { // check if already exists var deploymentEntry = DeploymentsWithVariables.Get(deploymentId); if (deploymentEntry != null) { var variableX = deploymentEntry.GetVariable(metaData.VariableName); if (variableX != null) { throw new ArgumentException( "Variable already exists by name '" + metaData.VariableName + "' and deployment '" + deploymentId + "'"); } } else { deploymentEntry = new VariableDeployment(); DeploymentsWithVariables.Put(deploymentId, deploymentEntry); } // find empty spot var emptySpot = -1; var count = 0; foreach (var entry in variableVersionsPerCP) { if (entry == null) { emptySpot = count; break; } count++; } int variableNumber; if (emptySpot != -1) { variableNumber = emptySpot; variableVersionsPerCP[emptySpot] = new ConcurrentDictionary<int, VariableReader>(); changeCallbacksPerCP[emptySpot] = null; } else { variableNumber = currentVariableNumber; variableVersionsPerCP.Add(new ConcurrentDictionary<int, VariableReader>()); changeCallbacksPerCP.Add(null); currentVariableNumber++; } var variable = new Variable(variableNumber, deploymentId, metaData, optionalDeploymentIdContext); deploymentEntry.AddVariable(metaData.VariableName, variable); if (OptionalStateHandler != null && !metaData.IsConstant) { OptionalStateHandler.AddVariable(deploymentId, metaData.VariableName, variable, optionalSerde); } } }
public DataInputOutputSerde[] GetContextPartitionKeySerdeSubset(int nestingLevel) { var serdes = new DataInputOutputSerde[nestingLevel - 1]; for (var i = 0; i < nestingLevel - 1; i++) { serdes[i] = ContextPartitionKeySerdes[i]; } return serdes; }
public EventTypeCollectedSerde( EventTypeMetadata metadata, DataInputOutputSerde underlyingSerde, Type underlying) { Metadata = metadata; UnderlyingSerde = underlyingSerde; Underlying = underlying; }
public ResultSetProcessorRowPerGroupOutputLastHelper MakeRSRowPerGroupOutputLastOpt( AgentInstanceContext agentInstanceContext, ResultSetProcessorRowPerGroup resultSetProcessorRowPerGroup, Type[] groupKeyTypes, DataInputOutputSerde serde, EventType[] eventTypes) { return new ResultSetProcessorRowPerGroupOutputLastHelperImpl(resultSetProcessorRowPerGroup); }
public EventTableFactory CreateUnindexed( int indexedStreamNum, EventType eventType, DataInputOutputSerde optionalValueSerde, bool isFireAndForget, EventTableFactoryFactoryContext eventTableFactoryContext) { return new UnindexedEventTableFactory(indexedStreamNum); }
public ResultSetProcessorGroupedOutputFirstHelper MakeRSGroupedOutputFirst( AgentInstanceContext agentInstanceContext, Type[] groupKeyTypes, OutputConditionPolledFactory optionalOutputFirstConditionFactory, AggregationGroupByRollupDesc optionalGroupByRollupDesc, int optionalRollupLevel, DataInputOutputSerde serde) { return new ResultSetProcessorGroupedOutputFirstHelperImpl(); }
public ProxyAggregationGroupByRollupLevel( int levelNumber, int levelOffset, int[] rollupKeys, DataInputOutputSerde subkeySerde, Func<object, object> procComputeSubkey) : base(levelNumber, levelOffset, rollupKeys, subkeySerde) { ProcComputeSubkey = procComputeSubkey; }
public AggregationServiceFactory GroupByRollup( AggregationServiceFactory nonHAFactory, AggregationGroupByRollupDesc groupByRollupDesc, AggregationRowFactory rowFactory, AggregationUseFlags useFlags, DataInputOutputSerde<AggregationRow> serde, Type[] groupByTypes) { return nonHAFactory; }
public AggregationGroupByRollupLevel( int levelNumber, int levelOffset, int[] rollupKeys, DataInputOutputSerde subkeySerde) { LevelNumber = levelNumber; LevelOffset = levelOffset; RollupKeys = rollupKeys; SubkeySerde = subkeySerde; }
public TableSerdes( DataInputOutputSerde[] column, DataInputOutputSerde<AggregationRow> aggregations) { if (column == null || aggregations == null) { throw new ArgumentException("Expected serdes not received"); } ColumnStartingZero = column; Aggregations = aggregations; }
private DataInputOutputSerdeForge SerdeMayArray( Type type, SerdeProviderAdditionalInfo info) { if (type.IsArray) { DataInputOutputSerde mkSerde = GetMKSerdeClassForComponentType(type.GetElementType()); return(new DataInputOutputSerdeForgeSingleton(mkSerde.GetType())); } return(SerdeForClass(type, info)); }
public EventTableFactory CreateSorted( int indexedStreamNum, EventType eventType, string indexedProp, Type indexType, EventPropertyValueGetter getter, DataInputOutputSerde serde, DataInputOutputSerde optionalValueSerde, bool isFireAndForget, EventTableFactoryFactoryContext eventTableFactoryContext) { return new PropertySortedEventTableFactory(indexedStreamNum, indexedProp, getter, indexType); }
public AggregationServiceFactory GroupBy( AggregationServiceFactory nonHAFactory, AggregationRowFactory rowFactory, AggregationUseFlags useFlags, DataInputOutputSerde<AggregationRow> serde, Type[] groupByTypes, AggSvcGroupByReclaimAgedEvalFuncFactory reclaimMaxAge, AggSvcGroupByReclaimAgedEvalFuncFactory reclaimFreq, TimeAbacus timeAbacus, DataInputOutputSerde groupKeySerde) { return nonHAFactory; }
public AggregationLocalGroupByLevel( AggregationRowFactory rowFactory, DataInputOutputSerde<AggregationRow> rowSerde, Type[] groupKeyTypes, ExprEvaluator groupKeyEval, bool isDefaultLevel, DataInputOutputSerde keySerde) { RowFactory = rowFactory; RowSerde = rowSerde; GroupKeyTypes = groupKeyTypes; GroupKeyEval = groupKeyEval; IsDefaultLevel = isDefaultLevel; KeySerde = keySerde; }
public PropertySortedFactoryFactory( int indexedStreamNum, int? subqueryNum, bool isFireAndForget, string indexProp, Type indexType, EventPropertyValueGetter valueGetter, DataInputOutputSerde indexSerde) : base(indexedStreamNum, subqueryNum, isFireAndForget) { _indexProp = indexProp; _indexType = indexType; _valueGetter = valueGetter; _indexSerde = indexSerde; }
public ExprFilterSpecLookupable( String expression, ExprEventEvaluator eval, ExprEvaluator expr, Type returnType, bool isNonPropertyEval, DataInputOutputSerde valueSerde) { _expression = expression; _eval = eval; _expr = expr; _returnType = Boxing.GetBoxedType(returnType); // For type consistency for recovery and serde define as boxed type _isNonPropertyEval = isNonPropertyEval; _valueSerde = valueSerde; }
/// <summary> /// NOTE: Code-generation-invoked method, method name and parameter order matters /// </summary> /// <param name="output">output</param> /// <param name="unitKey">unit key</param> /// <param name="writer">writer</param> /// <param name="serdeNullable">binding</param> /// <param name="circularBuffer">buffer</param> /// <param name="numDataPoints">points</param> /// <param name="currentBufferElementPointer">pointer</param> /// <param name="sizeBuf">size</param> /// <throws>IOException io error</throws> public static void Write( DataOutput output, byte[] unitKey, EventBeanCollatedWriter writer, DataInputOutputSerde serdeNullable, object[] circularBuffer, long numDataPoints, int currentBufferElementPointer, int sizeBuf) { output.WriteBoolean(circularBuffer != null); if (circularBuffer != null) { output.WriteLong(numDataPoints); output.WriteInt(currentBufferElementPointer); for (var i = 0; i < sizeBuf; i++) { serdeNullable.Write(circularBuffer[i], output, unitKey, writer); } } }
public PropertyHashedFactoryFactory( int indexedStreamNum, int? subqueryNum, bool isFireAndForget, String[] indexProps, Type[] indexTypes, bool unique, EventPropertyValueGetter valueGetter, MultiKeyFromObjectArray transformFireAndForget, DataInputOutputSerde keySerde) : base(indexedStreamNum, subqueryNum, isFireAndForget) { this.indexProps = indexProps; this.indexTypes = indexTypes; this.unique = unique; this.valueGetter = valueGetter; this.transformFireAndForget = transformFireAndForget; this.keySerde = keySerde; }
public EventTableFactory CreateHashedOnly( int indexedStreamNum, EventType eventType, string[] indexProps, Type[] indexTypes, MultiKeyFromObjectArray transformFireAndForget, DataInputOutputSerde keySerde, bool unique, string optionalIndexName, EventPropertyValueGetter getter, DataInputOutputSerde optionalValueSerde, bool isFireAndForget, EventTableFactoryFactoryContext eventTableFactoryContext) { return new PropertyHashedEventTableFactory( indexedStreamNum, indexProps, unique, optionalIndexName, getter, transformFireAndForget); }