core: update README and CHANGES
This commit is contained in:
		
							parent
							
								
									e0e8113831
								
							
						
					
					
						commit
						a6dbf561e8
					
				
							
								
								
									
										11
									
								
								CHANGES.md
									
									
									
									
									
								
							
							
						
						
									
										11
									
								
								CHANGES.md
									
									
									
									
									
								
							@ -2,4 +2,13 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
## CHANGES: improved branch
 | 
					## CHANGES: improved branch
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  
 | 
					- Create abstractions / models to load and parse metrics, can be easily extended 
 | 
				
			||||||
 | 
					- Define basic operations via [`MetricParser`] trait path **defs/metrics.rs**
 | 
				
			||||||
 | 
					- Use **structs** to group metrics attributes and implement operations like [`metrics_consumer::MetricsConsumerTarget`]
 | 
				
			||||||
 | 
					- Use **enums** with associated values like [`defs::metric_data::MetricsConsumerData`] path  **defs/metric_data** to group attributes and values
 | 
				
			||||||
 | 
					- Remove **Maps collections**, use [Vectors](https://doc.rust-lang.org/std/vec/struct.Vec.html)
 | 
				
			||||||
 | 
					- Use **const** for DEFAULT values on [`defs`] module 
 | 
				
			||||||
 | 
					- Remove all <i>hardcoded</i> values to [`Config`] settings, a **TOML config file** (see config.toml) can be used to define several metrics input and customize output
 | 
				
			||||||
 | 
					- **Output** write to file (append o rewrite mode) is working (for now I/O is sync)
 | 
				
			||||||
 | 
					- **Command line** arguments are processed [`parse_args`] with [`defs::CliSettings`] via [clap](https://docs.rs/clap/latest/clap/) and **overide** the ones loaded in **config files**
 | 
				
			||||||
 | 
					- **Tests** have been accommodated from previous [Branch basic-fixed](https://repo.jesusperez.pro/NewRelic/be-technical-interview-rust/src/branch/basic-fixed) version to **imporved** approach
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										55
									
								
								README.md
									
									
									
									
									
								
							
							
						
						
									
										55
									
								
								README.md
									
									
									
									
									
								
							@ -1,21 +1,66 @@
 | 
				
			|||||||
# Backend internal interview (rust) - improved  
 | 
					# Backend internal interview (rust) - improved  
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					This **Improved** branch is a rather disruptive approach to the [initial proposal](https://repo.jesusperez.pro/NewRelic/be-technical-interview-rust)<br>
 | 
				
			||||||
 | 
					[Branch basic-fixed](https://repo.jesusperez.pro/NewRelic/be-technical-interview-rust/src/branch/basic-fixed) tried to solve proposal from initial code 
 | 
				
			||||||
 | 
					as a **continuity effort** with the necessary changes and some improvement adjustments such as the **parallel input processing**
 | 
				
			||||||
 | 
					
 | 
				
			||||||
> [!NOTE]
 | 
					> [!NOTE]
 | 
				
			||||||
> It is able to **process multiple metrics in parallel**. <br>
 | 
					 | 
				
			||||||
> A full refactoring done for <u>better quality, maintenance and be more readable</u>. (Structs, implementaitions, settings for multiple inputs, etc). <br>
 | 
					> A full refactoring done for <u>better quality, maintenance and be more readable</u>. (Structs, implementaitions, settings for multiple inputs, etc). <br>
 | 
				
			||||||
 | 
					> It is able to **process multiple metrics in parallel**. <br>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					## In summary
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					- [x]  Define a basic model, easily to extend and modify. **Abstraction / Generic**.
 | 
				
			||||||
 | 
					- [x]  Structs and implementations to specific metricis traitments. **Modular appoach**.
 | 
				
			||||||
 | 
					- [x]  Settings and configuration for interactive and non interactive processing (batch mode) **Customize on context**.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
See [main changes](/NewRelic/be-technical-interview-rust/src/branch/improved/CHANGES.md)
 | 
					See [main changes](/NewRelic/be-technical-interview-rust/src/branch/improved/CHANGES.md)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
A **Refactor metric-consumer** task
 | 
					> [!IMPORTANT]  
 | 
				
			||||||
 | 
					> Use [ABOUT](ABOUT.md) content for quick [Verification](ABOUT.md) (it requires download and build)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					## Benefits
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Elements items come from  [main changes](/NewRelic/be-technical-interview-rust/src/branch/improved/CHANGES.md)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					| Element          | Benefit |
 | 
				
			||||||
 | 
					|----------------- |---------|
 | 
				
			||||||
 | 
					| Generic traits   | Group generic task for metric processing, steps / tasks separation |
 | 
				
			||||||
 | 
					| Structs          | Customize atributes and implementation for specific target or patterns  |
 | 
				
			||||||
 | 
					| Enums with values| Associate attributes metrics and values, easy to add new attributes or combine with different values at once |
 | 
				
			||||||
 | 
					| Vectors          | Simplify types / grouped in structs, priorize vectors type, easy to iterate, filter, sort, etc |
 | 
				
			||||||
 | 
					| Const and Config | Group main const, define metric targes and operations in declarative mode for non intective traitment |
 | 
				
			||||||
 | 
					| Command line args| Help to run in terminal as a cli |
 | 
				
			||||||
 | 
					| Unit Tests       | Verify some operations results |
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					> [!TIP]  
 | 
				
			||||||
 | 
					> After download repository and build:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					> - use [howto](howto.md) for command, options, etc.
 | 
				
			||||||
 | 
					> - Build documentation and browse content whit source code (instruction in [about](ABOUT.md))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					## Ideas not included
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					- **Async I/O** to scale and performance ?
 | 
				
			||||||
 | 
					- Other Thread alternatives like [Tokio](https://tokio.rs/) or/and [Coroutines](https://doc.rust-lang.org/std/ops/trait.Coroutine.html)
 | 
				
			||||||
 | 
					- Benchmarking for optimization
 | 
				
			||||||
 | 
					- More **tests**
 | 
				
			||||||
 | 
					- Run as **API mode** not only as batch processing
 | 
				
			||||||
 | 
					<br>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					> [!NOTE]
 | 
				
			||||||
 | 
					> Code is in the private repository with several varias branches.<br>
 | 
				
			||||||
 | 
					> Link to [branch repository improved](https://repo.jesusperez.pro/NewRelic/be-technical-interview-rust/src/branch/improved)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					---
 | 
				
			||||||
 | 
					
 | 
				
			||||||
[Home Task exercise description](Home-Task_exercise_interview_Rust.pdf)
 | 
					[Home Task exercise description](Home-Task_exercise_interview_Rust.pdf)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
There are several branches developed as proposal:
 | 
					There are several branches developed as proposal:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
- [Basic fixed one]((/NewRelic/be-technical-interview-rust/src/branch/basic-fixed)
 | 
					- [Basic fixed one](/NewRelic/be-technical-interview-rust/src/branch/basic-fixed)
 | 
				
			||||||
  > A basic code review, fixed with minor and essential changes to work as expected. <br>
 | 
					  > A basic code review, fixed with minor and essential changes to work as expected. <br>
 | 
				
			||||||
  > Tests are included for verification. <br>
 | 
					  > Tests are included for verification. <br>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
- [Improve one](/NewRelic/be-technical-interview-rust/src/branch/improved)
 | 
					- [Improve one](/NewRelic/be-technical-interview-rust/src/branch/improved)
 | 
				
			||||||
 | 
					 | 
				
			||||||
- [Multiple input one](multi-input)
 | 
					 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user