// Copyright 2023 William Perron. All rights reserved. MIT License. package sqliteexporter import ( "context" "go.opentelemetry.io/collector/component" "go.opentelemetry.io/collector/pdata/ptrace" ) type sqliteExporter struct{} // Start tells the component to start. Host parameter can be used for communicating // with the host after Start() has already returned. If an error is returned by // Start() then the collector startup will be aborted. // If this is an exporter component it may prepare for exporting // by connecting to the endpoint. // // If the component needs to perform a long-running starting operation then it is recommended // that Start() returns quickly and the long-running operation is performed in background. // In that case make sure that the long-running operation does not use the context passed // to Start() function since that context will be cancelled soon and can abort the long-running // operation. Create a new context from the context.Background() for long-running operations. func (e *sqliteExporter) Start(ctx context.Context, host component.Host) error { panic("not implemented") // TODO: Implement } // Shutdown is invoked during service shutdown. After Shutdown() is called, if the component // accepted data in any way, it should not accept it anymore. // // This method must be safe to call: // - without Start() having been called // - if the component is in a shutdown state already // // If there are any background operations running by the component they must be aborted before // this function returns. Remember that if you started any long-running background operations from // the Start() method, those operations must be also cancelled. If there are any buffers in the // component, they should be cleared and the data sent immediately to the next component. // // The component's lifecycle is completed once the Shutdown() method returns. No other // methods of the component are called after that. If necessary a new component with // the same or different configuration may be created and started (this may happen // for example if we want to restart the component). func (e *sqliteExporter) Shutdown(ctx context.Context) error { panic("not implemented") // TODO: Implement } func (e *sqliteExporter) ConsumeTraces(ctx context.Context, traces ptrace.Traces) error { panic("not implemented") }