glhd / conveyor-belt Goto Github PK
View Code? Open in Web Editor NEWAll the underlying mechanics necessary to write artisan commands that process lots of data efficiently
License: MIT License
All the underlying mechanics necessary to write artisan commands that process lots of data efficiently
License: MIT License
Maybe it would be useful if instead of yes/no
it was "Step(s)" and defaulted to 1
and 0
or no
exited
Maybe useful to inspect the first few for accuracy and then let all
continue when satisfied
Hello,
First of all, thank you very much for taking the time to build this package.
I'm usually building migrations from one DB to another. For example from a Drupal DB to a Laravel implementation, or from WP to Laravel.
When doing it I usually configure a new connection, and pull from it process the data and insert into a Laravel/Twill app.
For that matter I use the new DB connection for pulling the records like:
DB::connection('drupal')
->table('node')
->orderBy('node.nid');
These kind of queries return a collection, a Illuminate\Support\Collection
instead of the collection that eloquent returns Illuminate\Database\Eloquent\Collection
Would if be possible to make it generic by changing the processChunk
function in the src/IteratesQuery.php to accept Illuminate\Support\Collection
?
#replace
\\ use Illuminate\Database\Eloquent\Collection;
#by
use Illuminate\Support\Collection;
So the src/Support/ConveyorBelt.php needs to update the getChunkHandler
function to:
protected function getChunkHandler(): Closure
{
return function ($items) {
$this->command->prepareChunk($items->collect());
foreach ($items as $item) {
if (false === $this->presentRow($item)) {
return false;
}
}
return true;
};
}
Please let me know what do you think and if it is ok to build a pull request for it.
Best.
Is your feature request related to a problem? Please describe.
Not really a problem. Just saw that spout is unmaintained, and the folks at Spatie moved to its forked, mantained version openspout
Describe the solution you'd like
Simple change the dependency
Describe alternatives you've considered
None
Additional context
For reference, this is the commit in spatie/simple-excel
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.