midgardproject / phpcr-midgard2

Midgard2 implementation of PHP Content Repository (PHPCR)
http://midgard-project.org/phpcr/
46 stars 4 forks source link

Binary properties don't get stored in blob dir #150

Open brainformance-cledeg opened 11 years ago

brainformance-cledeg commented 11 years ago

I'm using doctrine phpcr odm for my application with the doctrine dbal transport. Because of the need to store large files in the phpcr (>200mb) I wanted to switch to midgard2. The problem now is, that the content of nt:file won't get stored any longer. After creating the nt:file document the content is definetly in the object, but after persisting its gone. Properties like size and mime type get properly persist. The row in the blobs table is there and the file gets created but the content of the file is everytime "ÿØÿà" if the file is a image. if the file is a pdf its "%PDF-1.4 %âãÏÓ 4 0 obj <</Type/XObject /Subtype/Image /Width 3508 /Height 2480 /BitsPerComponent 8 /ColorSpace/DeviceRGB /Filter /DCTDecode /Length 267934

stream ÿØÿà"

seems like the stream only persists some header information.

I know this sounds like a doctrine issue, but the implementation worked so far with another transport.

best regards

piotras commented 11 years ago

Can you provide simple example to reproduce it? Or the test in phpcr-api-tests which cover this case?