Project

General

Profile

Actions

Bug #66952

closed

Intermittent mapping ignore

Added by Richard D almost 9 years ago. Updated almost 8 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Extbase
Target version:
-
Start date:
2015-05-14
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
5.4
Tags:
Complexity:
hard
Is Regression:
No
Sprint Focus:

Description

Typo3 6.2.12
One custom extension on one website seems to be generating from ext_typoscript_setup incorrectly

There are two records mapped as:
@COMPANY\Extension\Domain\Model\Coupon {
subclasses {
Tx_Extension_CouponForF = COMPANY\Extension\Domain\Model\CouponF
}
mapping {
tableName = tx_extension_domain_model_coupon
recordType = Tx_Extension_Coupon
}
}

COMPANY\Extension\Domain\Model\CouponF {
mapping {
tableName = tx_extension_domain_model_coupon
recordType = Tx_Extension_CouponForF
}
}@

The website runs fine however at random intervals we get a Typo3 error similar to:
table tx_extension_domain_model_couponf does not exist
Once this error occurs the error will not go away until the install tool cache is cleared. It will then work for a period until the error occurs again. The record/relation that it is attempting to pull is a property of another table.

I've checked cf_extbase_datamapfactory_datamap and content is set to:
O:52:"TYPO3\CMS\Extbase\Persistence\Generic\Mapper\DataMap":19:{s:12:" * className";s:39:"COMPANY\Extension\Domain\Model\CouponF";s:12:" * tableName";s:36:"tx_extension_domain_model_couponf";s:13:" * recordType";N;s:13:" * subclasses";a:0:{}s:13:" * columnMaps";a:0:{}s:19:" * pageIdColumnName";s:3:"pid";s:23:" * languageIdColumnName";N;s:30:" * translationOriginColumnName";N;s:29:" * modificationDateColumnName";N;s:25:" * creationDateColumnName";N;s:20:" * creatorColumnName";N;s:24:" * deletedFlagColumnName";N;s:25:" * disabledFlagColumnName";N;s:22:" * startTimeColumnName";N;s:20:" * endTimeColumnName";N;s:30:" * frontendUserGroupColumnName";N;s:23:" * recordTypeColumnName";N;s:11:" * isStatic";b:0;s:12:" * rootLevel";b:0;}
when it breaks. When the install tool cache is cleared it becomes:
O:52:"TYPO3\CMS\Extbase\Persistence\Generic\Mapper\DataMap":19:{s:12:" * className";s:39:"COMPANY\Extension\Domain\Model\CouponF";s:12:" * tableName";s:35:"tx_extension_domain_model_coupon";s:13:" * recordType";s:26:"Tx_Extension_CouponForF";s:13:" * subclasses";a:0:{}s:13:" * columnMaps";a:1:{s:13:"txExtbaseType";O:54:"TYPO3\CMS\Extbase\Persistence\Generic\Mapper\ColumnMap":18:{s:15:" * propertyName";s:13:"txExtbaseType";s:13:" * columnName";s:15:"tx_extbase_type";s:17:" * typeOfRelation";s:13:"RELATION_NONE";s:17:" * childClassName";N;s:17:" * childTableName";N;s:27:" * childTableWhereStatement";N;s:23:" * childSortByFieldName";N;s:20:" * relationTableName";N;s:32:" * relationTablePageIdColumnName";N;s:27:" * relationTableMatchFields";N;s:28:" * relationTableInsertFields";N;s:30:" * relationTableWhereStatement";N;s:21:" * parentKeyFieldName";N;s:23:" * parentTableFieldName";N;s:20:" * childKeyFieldName";N;s:24:" * dateTimeStorageFormat";N;s:7:" * type";O:43:"TYPO3\CMS\Core\DataHandling\TableColumnType":1:{s:8:" * value";s:5:"INPUT";}s:15:" * internalType";O:46:"TYPO3\CMS\Core\DataHandling\TableColumnSubType":1:{s:8:" * value";s:0:"";}}}s:19:" * pageIdColumnName";s:3:"pid";s:23:" * languageIdColumnName";s:16:"sys_language_uid";s:30:" * translationOriginColumnName";s:11:"l10n_parent";s:29:" * modificationDateColumnName";s:6:"tstamp";s:25:" * creationDateColumnName";s:6:"crdate";s:20:" * creatorColumnName";s:9:"cruser_id";s:24:" * deletedFlagColumnName";s:7:"deleted";s:25:" * disabledFlagColumnName";s:6:"hidden";s:22:" * startTimeColumnName";N;s:20:" * endTimeColumnName";N;s:30:" * frontendUserGroupColumnName";N;s:23:" * recordTypeColumnName";s:15:"tx_extbase_type";s:11:" * isStatic";b:0;s:12:" * rootLevel";b:0;}

Actions #1

Updated by Richard D almost 9 years ago

Update - the extension was not filling the properties of the CouponF. I cleared the Typo3 install tool cache 7 times - 2 times the cf_extbase_datamapfactory_datamap re-occurred, and the last time I ran it out of 7 the cf_extbase_datamapfactory_datamap stopped occurring and the properties of CouponF magically filled again.

I have had problems with properties not filling for models quite a few times, however they only seem to happen whenever I make a change to the extension in some way. Annoying but understandable. This time however I had made no changes to the extension and clearing the install tool cache did not bring back the properties.

Another note: uninstalling and re-installing the extension causes the cf_extbase_datamapfactory_datamap issue every time.

Actions #2

Updated by Richard D almost 9 years ago

Second update:

It seems that recordType is the main issue - seems a bit obvious. I am guessing some of the code in the core allows recordType to be whatever you want whereas other parts assume recordType for classes/subclasses is "Tx_Extension_" + the model name.

Once the recordType was renamed from Tx_Extension_CouponForF to Tx_Extension_CouponF the issue seems to go away.

It is relatively inconsistent that it works sometimes and not others. Happy for a close or further discussion around expectation of format of recordType.

Actions #3

Updated by Richard D almost 9 years ago

Third update - it is still occurring...

Actions #4

Updated by Christian Kuhn almost 9 years ago

Sounds a bit weird. This issue will required a pretty heavy dive and a funny setup in trying to reproduce. I'm unsure on how to proceed here.

Actions #5

Updated by Richard D almost 9 years ago

I rewrote the code to avoid the inheritance that was causing the issue. I'm unable to reproduce on the test site with the same code, Typo3 version, operating system, php version, apache version. Only occurred on the production server.

The main differences between the two sites are:
  • the live site had the plugin on PID 1 while the test site had it on a subpage.
  • the live site had a huge amount of images broken up into about 30 folders (approx 400gb of images size of 1.5MB each). There was no timeout occurring that I could notice regarding processing.

Must be a very edge case bug.

Actions #6

Updated by Riccardo De Contardi almost 8 years ago

  • Status changed from New to Closed

It is safe to close this issue for now, as the author said he was eventually able to work around the issue.

Moreover, we would need a lot more information to have a chance to reproduce it; please feel free to reopen it
when and if it will come out again, and add all possible information.

Thanks again for your findings and work.

Actions

Also available in: Atom PDF