Open Extarys opened 7 years ago
@Extarys rethinkdb dont have increments ids, try use the index method instead. Like this:
public function up()
{
Schema::create('users', function (Blueprint $table) {
// if really is a primary key, change in rethinkdb config of that table
// (r.table('users').info() you see) or use the default 'id' field
$table->index('hero_id');
//that line is not necessary, the fields are dinamically created
//on inserts and updates operations
$table->string('name');
// that line too, NoSQL dont need a structure like mysql
// with the columns created previously
$table->timestamps();
});
}
Laravel Migrations I only used for index purpouses.
I had (and handle) many errors like this and anothers, the Rethink documentation is very good and help a lot. I copied from the Laravel for MongoDB link some codes to resolve some errors.
I really liked RethinkDB, mostly the realtime feature (is amazing), but for continue safety with that DB, check this link.
Thanks! Yes I do know they "shut down", thanks for the info (you never know) The Linux foundation took over the project. They are suppose to release a new version soon (2.4 I think) May I ask what are you using now? :)
I did not know about The Linux Foundation, thanks! Is a DB I really like. I really hope it works and they succeed.
I have using RethinkDB yet, in a realtime app, but with nodejs, koajs, rethinkdbdash and socket.io, is very powerfull the changesfeed and I have a proxy (nginx) to get the websockets connection from that server in nodejs.
Cool! I installed koa a moment ago, may I ask if you use a controller/model middleware and which one if so? The one I found logged that it will be discontinued in the next koa verison :(
I found Koa-socket-2, build over socketio, I will give it a try. koa-router, koa-views with twig and rethinkdbdash.
Sorry, but the app is very simple and I did not have to use anything like that.
Dont worry.
Was nice talking to you :P :D
Hey!
Trying Laravel for the first time (and installed rethinkDB yesterday, it's amazing!)
php artisan make:rethink-migration users --create=users
use Illuminate\Database\Schema\Blueprint;
call is still in the file, and rethinkdb is not thereuse brunojk\LaravelRethinkdb\Schema\Blueprint;
Also, calling
php artisan migrate
throw the following error:The file:
What should I do? :(
EDIT Reran with -vvv, output below