Exemplo n.º 1
0
func (h *Harvester) getState() file.State {

	if h.config.InputType == config.StdinInputType {
		return file.State{}
	}

	// refreshes the values in State with the values from the harvester itself
	h.state.FileStateOS = file.GetOSState(h.state.Fileinfo)
	return h.state
}
Exemplo n.º 2
0
Arquivo: log.go Projeto: yhyang1/beats
// refreshState refreshes the values in State with the values from the harvester itself
func (h *Harvester) refreshState() {
	h.State.Source = h.Path
	h.State.Offset = h.getOffset()
	h.State.FileStateOS = file.GetOSState(h.State.Fileinfo)
}