Skip to main content
added update after feedback
Source Link

I'm not sure what the problem is, there could be a lot of causes, like a different configuration between your local environment and the other server.

It might be useful to set logging to debug. To do this, go into your config folder on your localhost machine, open the logback.xml and set this property to debug

<property name="log.level" value="DEBUG"/>

You will then get all the broker logging for your app on your local machine (the location where logfiles are written are also specified in this xml file). If you could post the contents of this log, we might find something more useful.

YOu should also check the dd4t debug log. DD4T has some built in logging. To enable it, make sure you have something like this in your web.config

For example, if you wish to enable logging using log4net, do this :

on the zone, add this

<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" />

in your appsettings, add this line:

<add key="DD4T.LoggerClass" value="DD4T.LogWrappers.Log4Net.Log4NetLogger, DD4T.LogWrappers.Log4Net" />

and then you also need some log4net configuration (can be anywhere below the root of your web.config file

<log4net>
<appender name="RollingFile" type="log4net.Appender.RollingFileAppender">
  <file value="App_Data/dd4t.log" />
  <appendToFile value="true" />
  <maximumFileSize value="100KB" />
  <maxSizeRollBackups value="2" />
  <layout type="log4net.Layout.PatternLayout">
    <conversionPattern value="%date [%thread] %-5level %logger [%ndc] - %message%newline" />
  </layout>
</appender>
<root>
  <level value="DEBUG" />
  <appender-ref ref="RollingFile" />
</root>

This will also write some DD4T specific logging in your App_Data folder.

UPDATE

As you mentioned in a comment the page is in the broker db, but the pagecontent is not, then I suspect something is wrong with your deployer cd_storage config.

Could you check the cd_storage config of your deployer (the server where you publish to). If this is different, and for example, is publishing pages to the filesystem, while the cd_storage config on your dev environment expects the page content to be in the broker db, then you get problems like these.

Note that, even if you publish pages to the filesystem, this means that the page content is put on the file system, but page metadata (such as the filename etc) get published to the broker db.

So, could you verify your cd_storage_conf.xml file on your deployer server, and make sure it's in sync with the cd_storage_conf.xml in your dev environment ?

I'm not sure what the problem is, there could be a lot of causes, like a different configuration between your local environment and the other server.

It might be useful to set logging to debug. To do this, go into your config folder on your localhost machine, open the logback.xml and set this property to debug

<property name="log.level" value="DEBUG"/>

You will then get all the broker logging for your app on your local machine (the location where logfiles are written are also specified in this xml file). If you could post the contents of this log, we might find something more useful.

YOu should also check the dd4t debug log. DD4T has some built in logging. To enable it, make sure you have something like this in your web.config

For example, if you wish to enable logging using log4net, do this :

on the zone, add this

<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" />

in your appsettings, add this line:

<add key="DD4T.LoggerClass" value="DD4T.LogWrappers.Log4Net.Log4NetLogger, DD4T.LogWrappers.Log4Net" />

and then you also need some log4net configuration (can be anywhere below the root of your web.config file

<log4net>
<appender name="RollingFile" type="log4net.Appender.RollingFileAppender">
  <file value="App_Data/dd4t.log" />
  <appendToFile value="true" />
  <maximumFileSize value="100KB" />
  <maxSizeRollBackups value="2" />
  <layout type="log4net.Layout.PatternLayout">
    <conversionPattern value="%date [%thread] %-5level %logger [%ndc] - %message%newline" />
  </layout>
</appender>
<root>
  <level value="DEBUG" />
  <appender-ref ref="RollingFile" />
</root>

This will also write some DD4T specific logging in your App_Data folder.

I'm not sure what the problem is, there could be a lot of causes, like a different configuration between your local environment and the other server.

It might be useful to set logging to debug. To do this, go into your config folder on your localhost machine, open the logback.xml and set this property to debug

<property name="log.level" value="DEBUG"/>

You will then get all the broker logging for your app on your local machine (the location where logfiles are written are also specified in this xml file). If you could post the contents of this log, we might find something more useful.

YOu should also check the dd4t debug log. DD4T has some built in logging. To enable it, make sure you have something like this in your web.config

For example, if you wish to enable logging using log4net, do this :

on the zone, add this

<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" />

in your appsettings, add this line:

<add key="DD4T.LoggerClass" value="DD4T.LogWrappers.Log4Net.Log4NetLogger, DD4T.LogWrappers.Log4Net" />

and then you also need some log4net configuration (can be anywhere below the root of your web.config file

<log4net>
<appender name="RollingFile" type="log4net.Appender.RollingFileAppender">
  <file value="App_Data/dd4t.log" />
  <appendToFile value="true" />
  <maximumFileSize value="100KB" />
  <maxSizeRollBackups value="2" />
  <layout type="log4net.Layout.PatternLayout">
    <conversionPattern value="%date [%thread] %-5level %logger [%ndc] - %message%newline" />
  </layout>
</appender>
<root>
  <level value="DEBUG" />
  <appender-ref ref="RollingFile" />
</root>

This will also write some DD4T specific logging in your App_Data folder.

UPDATE

As you mentioned in a comment the page is in the broker db, but the pagecontent is not, then I suspect something is wrong with your deployer cd_storage config.

Could you check the cd_storage config of your deployer (the server where you publish to). If this is different, and for example, is publishing pages to the filesystem, while the cd_storage config on your dev environment expects the page content to be in the broker db, then you get problems like these.

Note that, even if you publish pages to the filesystem, this means that the page content is put on the file system, but page metadata (such as the filename etc) get published to the broker db.

So, could you verify your cd_storage_conf.xml file on your deployer server, and make sure it's in sync with the cd_storage_conf.xml in your dev environment ?

Source Link

I'm not sure what the problem is, there could be a lot of causes, like a different configuration between your local environment and the other server.

It might be useful to set logging to debug. To do this, go into your config folder on your localhost machine, open the logback.xml and set this property to debug

<property name="log.level" value="DEBUG"/>

You will then get all the broker logging for your app on your local machine (the location where logfiles are written are also specified in this xml file). If you could post the contents of this log, we might find something more useful.

YOu should also check the dd4t debug log. DD4T has some built in logging. To enable it, make sure you have something like this in your web.config

For example, if you wish to enable logging using log4net, do this :

on the zone, add this

<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" />

in your appsettings, add this line:

<add key="DD4T.LoggerClass" value="DD4T.LogWrappers.Log4Net.Log4NetLogger, DD4T.LogWrappers.Log4Net" />

and then you also need some log4net configuration (can be anywhere below the root of your web.config file

<log4net>
<appender name="RollingFile" type="log4net.Appender.RollingFileAppender">
  <file value="App_Data/dd4t.log" />
  <appendToFile value="true" />
  <maximumFileSize value="100KB" />
  <maxSizeRollBackups value="2" />
  <layout type="log4net.Layout.PatternLayout">
    <conversionPattern value="%date [%thread] %-5level %logger [%ndc] - %message%newline" />
  </layout>
</appender>
<root>
  <level value="DEBUG" />
  <appender-ref ref="RollingFile" />
</root>

This will also write some DD4T specific logging in your App_Data folder.